From bc876ec30c8cd387a210b1a156aa733d26ebe343 Mon Sep 17 00:00:00 2001 From: Lior Halphon Date: Sat, 16 Jun 2018 14:36:06 +0300 Subject: [PATCH] Whoops --- Cocoa/Document.m | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Cocoa/Document.m b/Cocoa/Document.m index 78dfd77..c1cc764 100644 --- a/Cocoa/Document.m +++ b/Cocoa/Document.m @@ -141,17 +141,17 @@ static void printImage(GB_gameboy_t *gb, uint32_t *image, uint8_t height, return self; } +/* Todo: Unify the 3 init functions */ - (void) initDMG { current_model = MODEL_DMG; GB_init(&gb, cocoa_to_internal_model[current_model]); - [self initCommon]; GB_load_boot_rom(&gb, [[[NSBundle mainBundle] pathForResource:@"dmg_boot" ofType:@"bin"] UTF8String]); + [self initCommon]; } - (void) initCGB { - [self initCommon]; if ([[NSUserDefaults standardUserDefaults] boolForKey:@"EmulateAGB"]) { current_model = MODEL_AGB; GB_init(&gb, cocoa_to_internal_model[current_model]); @@ -162,6 +162,7 @@ static void printImage(GB_gameboy_t *gb, uint32_t *image, uint8_t height, GB_init(&gb, cocoa_to_internal_model[current_model]); GB_load_boot_rom(&gb, [[[NSBundle mainBundle] pathForResource:@"cgb_boot" ofType:@"bin"] UTF8String]); } + [self initCommon]; } - (void) initCommon