From 67dfd0614911f378d5685442acf6dc50f82f512a Mon Sep 17 00:00:00 2001 From: Yuval Dolev Date: Mon, 23 Dec 2019 02:39:44 +0200 Subject: [PATCH] Started working on macOS platform layer. --- platform_mac/mac_4ed.mm | 16 ++++++++++++++++ platform_mac/{mac_4ed.cpp => mac_4ed_old.cpp} | 0 platform_mac/{mac_4ed.m => mac_4ed_old.m} | 0 platform_win32/win32_4ed.cpp | 2 +- 4 files changed, 17 insertions(+), 1 deletion(-) create mode 100644 platform_mac/mac_4ed.mm rename platform_mac/{mac_4ed.cpp => mac_4ed_old.cpp} (100%) rename platform_mac/{mac_4ed.m => mac_4ed_old.m} (100%) diff --git a/platform_mac/mac_4ed.mm b/platform_mac/mac_4ed.mm new file mode 100644 index 00000000..e5993845 --- /dev/null +++ b/platform_mac/mac_4ed.mm @@ -0,0 +1,16 @@ +int +main(int arg_count, char **args){ + Thread_Context _tctx = {}; + thread_ctx_init(&_tctx, ThreadKind_Main, + get_base_allocator_system(), + get_base_allocator_system()); + + block_zero_struct(&global_mac_vars); + global_mac_vars.tctx = &_tctx; + + // NOTE(yuval): Application Core Update + Application_Step_Result result = {}; + if (app.step != 0){ + result = app.step(mac_vars.tctx, &target, base_ptr, &input); + } +} \ No newline at end of file diff --git a/platform_mac/mac_4ed.cpp b/platform_mac/mac_4ed_old.cpp similarity index 100% rename from platform_mac/mac_4ed.cpp rename to platform_mac/mac_4ed_old.cpp diff --git a/platform_mac/mac_4ed.m b/platform_mac/mac_4ed_old.m similarity index 100% rename from platform_mac/mac_4ed.m rename to platform_mac/mac_4ed_old.m diff --git a/platform_win32/win32_4ed.cpp b/platform_win32/win32_4ed.cpp index 0ed48a78..e1fec7a4 100644 --- a/platform_win32/win32_4ed.cpp +++ b/platform_win32/win32_4ed.cpp @@ -335,7 +335,7 @@ system_set_fullscreen_sig(){ internal system_is_fullscreen_sig(){ - // NOTE(allen): Report the fullscreen status as it would be set at the beginning of the + // NOTE(allen): Report the fullscreen status as it would be set at the beginning of the // next frame. That is, take into account all fullscreen toggle requests that have come in // already this frame. Read: "full_screen XOR do_toggle" b32 result = (win32vars.full_screen != win32vars.do_toggle);