src/video/windows/SDL_windowswindow.c
changeset 12006 1b7ed3438a7f
parent 11939 69afb0599152
child 12067 0e37a23d93cb
equal deleted inserted replaced
12005:94f3f018d3eb 12006:1b7ed3438a7f
    95 
    95 
    96         /* You can have a borderless resizable window */
    96         /* You can have a borderless resizable window */
    97         if (window->flags & SDL_WINDOW_RESIZABLE) {
    97         if (window->flags & SDL_WINDOW_RESIZABLE) {
    98             style |= STYLE_RESIZABLE;
    98             style |= STYLE_RESIZABLE;
    99         }
    99         }
       
   100 
       
   101 		/* Need to set initialize minimize style, or when we call ShowWindow with WS_MINIMIZE it will activate a random window */
       
   102 		if ( window->flags & SDL_WINDOW_MINIMIZED )
       
   103 			style |= WS_MINIMIZE;
   100     }
   104     }
   101     return style;
   105     return style;
   102 }
   106 }
   103 
   107 
   104 static void
   108 static void
   332         return -1;
   336         return -1;
   333     }
   337     }
   334 
   338 
   335     /* Inform Windows of the frame change so we can respond to WM_NCCALCSIZE */
   339     /* Inform Windows of the frame change so we can respond to WM_NCCALCSIZE */
   336     SetWindowPos(hwnd, NULL, 0, 0, 0, 0, SWP_FRAMECHANGED | SWP_NOSIZE | SWP_NOZORDER | SWP_NOMOVE | SWP_NOACTIVATE);
   340     SetWindowPos(hwnd, NULL, 0, 0, 0, 0, SWP_FRAMECHANGED | SWP_NOSIZE | SWP_NOZORDER | SWP_NOMOVE | SWP_NOACTIVATE);
       
   341 
       
   342 	if ( window->flags & SDL_WINDOW_MINIMIZED )
       
   343 		ShowWindow( hwnd, SW_SHOWMINNOACTIVE );
   337 
   344 
   338     if (!(window->flags & SDL_WINDOW_OPENGL)) {
   345     if (!(window->flags & SDL_WINDOW_OPENGL)) {
   339         return 0;
   346         return 0;
   340     }
   347     }
   341 
   348