diff options
Diffstat (limited to 'ui/cocoa.m')
-rw-r--r-- | ui/cocoa.m | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/ui/cocoa.m b/ui/cocoa.m index 90d9aa57ea..18de0bb3ea 100644 --- a/ui/cocoa.m +++ b/ui/cocoa.m @@ -32,7 +32,7 @@ #include "ui/input.h" #include "sysemu/sysemu.h" #include "qapi/error.h" -#include "qmp-commands.h" +#include "qapi/qapi-commands.h" #include "sysemu/blockdev.h" #include "qemu-version.h" #include <Carbon/Carbon.h> @@ -1683,7 +1683,7 @@ static void addRemovableDevicesMenuItems(void) qapi_free_BlockInfoList(pointerToFree); } -void cocoa_display_init(DisplayState *ds, DisplayOptions *opts) +static void cocoa_display_init(DisplayState *ds, DisplayOptions *opts) { COCOA_DEBUG("qemu_cocoa: cocoa_display_init\n"); @@ -1713,3 +1713,15 @@ void cocoa_display_init(DisplayState *ds, DisplayOptions *opts) */ addRemovableDevicesMenuItems(); } + +static QemuDisplay qemu_display_cocoa = { + .type = DISPLAY_TYPE_COCOA, + .init = cocoa_display_init, +}; + +static void register_cocoa(void) +{ + qemu_display_register(&qemu_display_cocoa); +} + +type_init(register_cocoa); |