mirror of https://github.com/bsnes-emu/bsnes.git
UI Updates
This commit is contained in:
parent
bb3a73ff88
commit
f67d3947d6
|
@ -770,7 +770,6 @@ static unsigned *multiplication_table_for_frequency(unsigned frequency)
|
||||||
[self.view screenSizeChanged];
|
[self.view screenSizeChanged];
|
||||||
[self loadROM];
|
[self loadROM];
|
||||||
[self reset:nil];
|
[self reset:nil];
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void) initMemoryView
|
- (void) initMemoryView
|
||||||
|
@ -875,6 +874,9 @@ static unsigned *multiplication_table_for_frequency(unsigned frequency)
|
||||||
[[NSBundle mainBundle] loadNibNamed:@"GBS" owner:self topLevelObjects:nil];
|
[[NSBundle mainBundle] loadNibNamed:@"GBS" owner:self topLevelObjects:nil];
|
||||||
[_mainWindow setContentSize:self.gbsPlayerView.bounds.size];
|
[_mainWindow setContentSize:self.gbsPlayerView.bounds.size];
|
||||||
_mainWindow.styleMask &= ~NSWindowStyleMaskResizable;
|
_mainWindow.styleMask &= ~NSWindowStyleMaskResizable;
|
||||||
|
dispatch_async(dispatch_get_main_queue(), ^{ // Cocoa is weird, no clue why it's needed
|
||||||
|
[_mainWindow standardWindowButton:NSWindowZoomButton].enabled = false;
|
||||||
|
});
|
||||||
[_mainWindow.contentView addSubview:self.gbsPlayerView];
|
[_mainWindow.contentView addSubview:self.gbsPlayerView];
|
||||||
|
|
||||||
self.gbsTitle.stringValue = [NSString stringWithCString:info->title encoding:NSISOLatin1StringEncoding] ?: @"GBS Player";
|
self.gbsTitle.stringValue = [NSString stringWithCString:info->title encoding:NSISOLatin1StringEncoding] ?: @"GBS Player";
|
||||||
|
@ -913,7 +915,7 @@ static unsigned *multiplication_table_for_frequency(unsigned frequency)
|
||||||
GB_load_battery(&gb, [[self.fileURL URLByDeletingPathExtension] URLByAppendingPathExtension:@"ram"].path.UTF8String);
|
GB_load_battery(&gb, [[self.fileURL URLByDeletingPathExtension] URLByAppendingPathExtension:@"ram"].path.UTF8String);
|
||||||
}
|
}
|
||||||
else if ([[[self.fileType pathExtension] lowercaseString] isEqualToString:@"gbs"]) {
|
else if ([[[self.fileType pathExtension] lowercaseString] isEqualToString:@"gbs"]) {
|
||||||
GB_gbs_info_t info;
|
__block GB_gbs_info_t info;
|
||||||
GB_load_gbs(&gb, self.fileURL.path.UTF8String, &info);
|
GB_load_gbs(&gb, self.fileURL.path.UTF8String, &info);
|
||||||
[self prepareGBSInterface:&info];
|
[self prepareGBSInterface:&info];
|
||||||
}
|
}
|
||||||
|
|
|
@ -412,7 +412,7 @@ int GB_load_gbs(GB_gameboy_t *gb, const char *path, GB_gbs_info_t *info)
|
||||||
LE16(gb->gbs_header.play_address),
|
LE16(gb->gbs_header.play_address),
|
||||||
LE16(gb->gbs_header.play_address) >> 8,
|
LE16(gb->gbs_header.play_address) >> 8,
|
||||||
0x18, // JR pc ± $XX
|
0x18, // JR pc ± $XX
|
||||||
-10 // To HALT
|
-10 // To HALT
|
||||||
}, 13);
|
}, 13);
|
||||||
|
|
||||||
GB_gbs_switch_track(gb, gb->gbs_header.first_track - 1);
|
GB_gbs_switch_track(gb, gb->gbs_header.first_track - 1);
|
||||||
|
|
Loading…
Reference in New Issue