Remove all tab line indents from VMSettingsController.mm

This commit is contained in:
Maximilian Irlinger 2014-09-19 07:28:21 +02:00
parent 72c79d1a6d
commit 85c81e3848

View File

@ -70,16 +70,16 @@ void prefs_exit()
- (id) tableView: (NSTableView *) table objectValueForTableColumn: (NSTableColumn *) col row: (int) row - (id) tableView: (NSTableView *) table objectValueForTableColumn: (NSTableColumn *) col row: (int) row
{ {
DiskType *d = (DiskType*)[diskArray objectAtIndex:row]; DiskType *d = (DiskType*)[diskArray objectAtIndex:row];
if ([[col identifier] isEqualTo:@"isCDROMcol"]) { if ([[col identifier] isEqualTo:@"isCDROMcol"]) {
return [NSString stringWithFormat:@"%d", [d isCDROM]]; return [NSString stringWithFormat:@"%d", [d isCDROM]];
} }
return [d path]; return [d path];
} }
-(void)tableView:(NSTableView *)tableView setObjectValue:(id)object forTableColumn:(NSTableColumn *)tableColumn row:(NSInteger)row -(void)tableView:(NSTableView *)tableView setObjectValue:(id)object forTableColumn:(NSTableColumn *)tableColumn row:(NSInteger)row
{ {
if ([[tableColumn identifier] isEqual:@"isCDROMcol"]) { if ([[tableColumn identifier] isEqual:@"isCDROMcol"]) {
DiskType *d = (DiskType*)[diskArray objectAtIndex:row]; DiskType *d = (DiskType*)[diskArray objectAtIndex:row];
[d setIsCDROM:![d isCDROM]]; [d setIsCDROM:![d isCDROM]];
@ -104,7 +104,7 @@ static NSString *getStringFromPrefs(const char *key)
DiskType *disk = [[DiskType alloc] init]; DiskType *disk = [[DiskType alloc] init];
[disk setPath:[NSString stringWithUTF8String: dsk ]]; [disk setPath:[NSString stringWithUTF8String: dsk ]];
[disk setIsCDROM:NO]; [disk setIsCDROM:NO];
[diskArray addObject:disk]; [diskArray addObject:disk];
} }
@ -114,13 +114,13 @@ static NSString *getStringFromPrefs(const char *key)
DiskType *disk = [[DiskType alloc] init]; DiskType *disk = [[DiskType alloc] init];
[disk setPath:[NSString stringWithUTF8String: dsk ]]; [disk setPath:[NSString stringWithUTF8String: dsk ]];
[disk setIsCDROM:YES]; [disk setIsCDROM:YES];
[diskArray addObject:disk]; [diskArray addObject:disk];
} }
[disks setDataSource: self]; [disks setDataSource: self];
[disks reloadData]; [disks reloadData];
int bootdriver = PrefsFindInt32("bootdriver"), active = 0; int bootdriver = PrefsFindInt32("bootdriver"), active = 0;
switch (bootdriver) { switch (bootdriver) {
case 0: active = 0; break; case 0: active = 0; break;
@ -259,9 +259,9 @@ static NSString *makeRelativeIfNecessary(NSString *path)
if (theReturnCode == NSOKButton) { if (theReturnCode == NSOKButton) {
DiskType *d = [[DiskType alloc] init]; DiskType *d = [[DiskType alloc] init];
[d setPath:makeRelativeIfNecessary([open filename])]; [d setPath:makeRelativeIfNecessary([open filename])];
[d setIsCDROM:([isCDROMcheckbox state] == NSOnState)]; [d setIsCDROM:([isCDROMcheckbox state] == NSOnState)];
[diskArray addObject: d]; [diskArray addObject: d];
[disks reloadData]; [disks reloadData];
} }
@ -301,7 +301,7 @@ static NSString *makeRelativeIfNecessary(NSString *path)
DiskType *d = [[DiskType alloc] init]; DiskType *d = [[DiskType alloc] init];
[d setPath:makeRelativeIfNecessary([save filename])]; [d setPath:makeRelativeIfNecessary([save filename])];
[d setIsCDROM:NO]; [d setIsCDROM:NO];
[diskArray addObject: d]; [diskArray addObject: d];
[disks reloadData]; [disks reloadData];
} }
@ -397,14 +397,14 @@ static NSString *makeRelativeIfNecessary(NSString *path)
// Remove all cdroms // Remove all cdroms
while (PrefsFindString("cdrom")) while (PrefsFindString("cdrom"))
PrefsRemoveItem("cdrom"); PrefsRemoveItem("cdrom");
// Write all disks // Write all disks
for (int i = 0; i < [diskArray count]; i++) { for (int i = 0; i < [diskArray count]; i++) {
DiskType *d = [diskArray objectAtIndex:i]; DiskType *d = [diskArray objectAtIndex:i];
PrefsAddString([d isCDROM] ? "cdrom" : "disk", [[d path] UTF8String]); PrefsAddString([d isCDROM] ? "cdrom" : "disk", [[d path] UTF8String]);
} }
PrefsReplaceInt32("bootdriver", ([bootFrom indexOfSelectedItem] == 1 ? CDROMRefNum : 0)); PrefsReplaceInt32("bootdriver", ([bootFrom indexOfSelectedItem] == 1 ? CDROMRefNum : 0));
PrefsReplaceString("rom", [[romFile stringValue] UTF8String]); PrefsReplaceString("rom", [[romFile stringValue] UTF8String]);
PrefsReplaceString("extfs", [[unixRoot stringValue] UTF8String]); PrefsReplaceString("extfs", [[unixRoot stringValue] UTF8String]);