File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -70,8 +70,7 @@ application_glue::application_glue(const utki::version_duplet& gl_version) :
7070 this ->gl_version,
7171 ruisapp::window_parameters{
7272 .dims = {1 , 1 },
73- .fullscreen = false ,
74- .visible = false
73+ .fullscreen = false
7574},
7675 nullptr // no shared gl context
7776 )),
Original file line number Diff line number Diff line change 88
99#include " ../../application.hpp"
1010
11- #include " display.hxx"
1211#include " window.hxx"
1312
1413namespace {
Original file line number Diff line number Diff line change @@ -70,7 +70,9 @@ class native_window : public ruis::render::native_window
7070 struct cocoa_window_wrapper {
7171 CocoaWindow* const window;
7272
73- cocoa_window_wrapper (const ruisapp::window_parameters& window_params) :
73+ cocoa_window_wrapper (const ruisapp::window_parameters& window_params,
74+ bool visible
75+ ) :
7476 window ([&]() {
7577 auto w = [[CocoaWindow alloc]
7678 initWithContentRect:NSMakeRect(
@@ -93,7 +95,7 @@ class native_window : public ruis::render::native_window
9395 {
9496 [this ->window setTitle:[NSString stringWithUTF8String:window_params.title .c_str ()]];
9597
96- if (window_params. visible ) {
98+ if (visible) {
9799 [this ->window makeKeyAndOrderFront:nil];
98100 [this ->window orderFrontRegardless];
99101 }
@@ -192,7 +194,9 @@ public:
192194 const ruisapp::window_parameters& window_params,
193195 native_window* shared_gl_context_native_window
194196 ) :
195- cocoa_window (window_params),
197+ cocoa_window (window_params,//
198+ shared_gl_context_native_window != nullptr
199+ ),
196200 opengl_context (
197201 window_params, //
198202 shared_gl_context_native_window ? shared_gl_context_native_window->opengl_context.context
You can’t perform that action at this time.
0 commit comments