mirror of
https://github.com/wailsapp/wails.git
synced 2025-05-04 11:00:32 +08:00
[windows] StartHidden
This commit is contained in:
parent
df41e8eb3a
commit
134b41e4be
@ -112,7 +112,14 @@ void Run(struct Application* app, int argc, char **argv) {
|
||||
SetWindowLongPtr(app->window, GWLP_USERDATA, (LONG_PTR)app);
|
||||
|
||||
MSG msg;
|
||||
ShowWindow(app->window, SW_SHOWNORMAL);
|
||||
|
||||
// Process whether window should show by default
|
||||
int initialCmdShow = SW_SHOWNORMAL;
|
||||
if ( app->startHidden == 1 ) {
|
||||
initialCmdShow = SW_HIDE;
|
||||
}
|
||||
ShowWindow(app->window, initialCmdShow);
|
||||
|
||||
UpdateWindow(app->window);
|
||||
BOOL res;
|
||||
while ((res = GetMessage(&msg, NULL, 0, 0)) != -1) {
|
||||
|
Loading…
Reference in New Issue
Block a user