diff --git a/Cocoa/Document.m b/Cocoa/Document.m index 0d3f39a..1ded2b9 100644 --- a/Cocoa/Document.m +++ b/Cocoa/Document.m @@ -134,7 +134,7 @@ static void vblank(GB_gameboy_t *gb, GB_vblank_type_t type) [self vblankWithType:type]; } -static void consoleLog(GB_gameboy_t *gb, const char *string, GB_log_attributes attributes) +static void consoleLog(GB_gameboy_t *gb, const char *string, GB_log_attributes_t attributes) { Document *self = (__bridge Document *)GB_get_user_data(gb); [self log:string withAttributes: attributes]; @@ -1534,7 +1534,7 @@ enum GBWindowResizeAction [_consoleOutputLock unlock]; } -- (void)log:(const char *)string withAttributes:(GB_log_attributes)attributes +- (void)log:(const char *)string withAttributes:(GB_log_attributes_t)attributes { NSString *nsstring = @(string); // For ref-counting if (_capturedOutput) { diff --git a/Core/gb.c b/Core/gb.c index f5360e6..9c046cb 100644 --- a/Core/gb.c +++ b/Core/gb.c @@ -13,7 +13,7 @@ #include "gb.h" -void GB_attributed_logv(GB_gameboy_t *gb, GB_log_attributes attributes, const char *fmt, va_list args) +void GB_attributed_logv(GB_gameboy_t *gb, GB_log_attributes_t attributes, const char *fmt, va_list args) { char *string = NULL; vasprintf(&string, fmt, args); @@ -29,7 +29,7 @@ void GB_attributed_logv(GB_gameboy_t *gb, GB_log_attributes attributes, const ch free(string); } -void GB_attributed_log(GB_gameboy_t *gb, GB_log_attributes attributes, const char *fmt, ...) +void GB_attributed_log(GB_gameboy_t *gb, GB_log_attributes_t attributes, const char *fmt, ...) { va_list args; va_start(args, fmt); diff --git a/Core/gb.h b/Core/gb.h index 960899c..2089a19 100644 --- a/Core/gb.h +++ b/Core/gb.h @@ -235,7 +235,7 @@ typedef enum { GB_LOG_DASHED_UNDERLINE = 2, GB_LOG_UNDERLINE = 4, GB_LOG_UNDERLINE_MASK = GB_LOG_DASHED_UNDERLINE | GB_LOG_UNDERLINE -} GB_log_attributes; +} GB_log_attributes_t; typedef enum { GB_BOOT_ROM_DMG_0, @@ -265,7 +265,7 @@ typedef enum { #endif -typedef void (*GB_log_callback_t)(GB_gameboy_t *gb, const char *string, GB_log_attributes attributes); +typedef void (*GB_log_callback_t)(GB_gameboy_t *gb, const char *string, GB_log_attributes_t attributes); typedef char *(*GB_input_callback_t)(GB_gameboy_t *gb); typedef void (*GB_debugger_reload_callback_t)(GB_gameboy_t *gb); typedef void (*GB_infrared_callback_t)(GB_gameboy_t *gb, bool on); @@ -935,7 +935,7 @@ void GB_set_turbo_mode(GB_gameboy_t *gb, bool on, bool no_frame_skip); void GB_set_rendering_disabled(GB_gameboy_t *gb, bool disabled); void GB_log(GB_gameboy_t *gb, const char *fmt, ...) __printflike(2, 3); -void GB_attributed_log(GB_gameboy_t *gb, GB_log_attributes attributes, const char *fmt, ...) __printflike(3, 4); +void GB_attributed_log(GB_gameboy_t *gb, GB_log_attributes_t attributes, const char *fmt, ...) __printflike(3, 4); void GB_set_pixels_output(GB_gameboy_t *gb, uint32_t *output); uint32_t *GB_get_pixels_output(GB_gameboy_t *gb); diff --git a/QuickLook/get_image_for_rom.c b/QuickLook/get_image_for_rom.c index 6c9ac91..1c9366a 100755 --- a/QuickLook/get_image_for_rom.c +++ b/QuickLook/get_image_for_rom.c @@ -19,7 +19,7 @@ static char *async_input_callback(GB_gameboy_t *gb) return NULL; } -static void log_callback(GB_gameboy_t *gb, const char *string, GB_log_attributes attributes) +static void log_callback(GB_gameboy_t *gb, const char *string, GB_log_attributes_t attributes) { } diff --git a/SDL/main.c b/SDL/main.c index f00267c..81298a0 100644 --- a/SDL/main.c +++ b/SDL/main.c @@ -61,7 +61,7 @@ static char *completer(const char *substring, uintptr_t *context) return ret; } -static void log_callback(GB_gameboy_t *gb, const char *string, GB_log_attributes attributes) +static void log_callback(GB_gameboy_t *gb, const char *string, GB_log_attributes_t attributes) { CON_attributes_t con_attributes = {0,}; con_attributes.bold = attributes & GB_LOG_BOLD; @@ -128,7 +128,7 @@ retry: { static char *captured_log = NULL; -static void log_capture_callback(GB_gameboy_t *gb, const char *string, GB_log_attributes attributes) +static void log_capture_callback(GB_gameboy_t *gb, const char *string, GB_log_attributes_t attributes) { size_t current_len = strlen(captured_log); size_t len_to_add = strlen(string); diff --git a/iOS/GBViewController.m b/iOS/GBViewController.m index 06bf865..281d8cd 100644 --- a/iOS/GBViewController.m +++ b/iOS/GBViewController.m @@ -107,7 +107,7 @@ static void printDone(GB_gameboy_t *gb) } -static void consoleLog(GB_gameboy_t *gb, const char *string, GB_log_attributes attributes) +static void consoleLog(GB_gameboy_t *gb, const char *string, GB_log_attributes_t attributes) { static NSString *buffer = @""; buffer = [buffer stringByAppendingString:@(string)];