mirror of
https://github.com/kanjitalk755/macemu.git
synced 2025-01-15 06:30:13 +00:00
use non-deprecated methods
This commit is contained in:
parent
2d14b5fb8b
commit
0f472ed95e
@ -75,7 +75,7 @@ static NSString *getStringFromPrefs(const char *key)
|
|||||||
const char *value = PrefsFindString(key);
|
const char *value = PrefsFindString(key);
|
||||||
if (value == NULL)
|
if (value == NULL)
|
||||||
return @"";
|
return @"";
|
||||||
return [NSString stringWithCString: value];
|
return [NSString stringWithUTF8String: value];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void) setupGUI
|
- (void) setupGUI
|
||||||
@ -85,7 +85,7 @@ static NSString *getStringFromPrefs(const char *key)
|
|||||||
const char *dsk;
|
const char *dsk;
|
||||||
int index = 0;
|
int index = 0;
|
||||||
while ((dsk = PrefsFindString("disk", index++)) != NULL)
|
while ((dsk = PrefsFindString("disk", index++)) != NULL)
|
||||||
[diskArray addObject: [NSString stringWithCString: dsk ]];
|
[diskArray addObject: [NSString stringWithUTF8String: dsk ]];
|
||||||
|
|
||||||
[disks setDataSource: self];
|
[disks setDataSource: self];
|
||||||
[disks reloadData];
|
[disks reloadData];
|
||||||
@ -203,7 +203,7 @@ static NSString *makeRelativeIfNecessary(NSString *path)
|
|||||||
if (!strncmp(cwd, filename, cwdlen)) {
|
if (!strncmp(cwd, filename, cwdlen)) {
|
||||||
if (cwdlen >= 0 && cwd[cwdlen-1] != '/')
|
if (cwdlen >= 0 && cwd[cwdlen-1] != '/')
|
||||||
cwdlen++;
|
cwdlen++;
|
||||||
return [NSString stringWithCString: filename + cwdlen];
|
return [NSString stringWithUTF8String: filename + cwdlen];
|
||||||
}
|
}
|
||||||
return path;
|
return path;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user