LWJGL
May 23, 2012, 04:01:33 *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: LWJGL 2.8.3 released!
 
   Home   Help Search Login Register  



Pages: [1]
  Print  
Author Topic: [FIXED] Windows: Activating a maximized window will un-maximize/restore it  (Read 509 times)
Simon Felix
Regular nerd
**
Posts: 96



WWW
« on: February 05, 2012, 17:39:56 »

Hello again everyone

Steps to repro:
1. Maximize LWJGL window
2. Bring another window to the foreground (click the taskbar for example)
3. Bring the LWJGL window again to the foreground (click it for example)

Result:
LWJGL window's state is "restored" instead of "maximized".

Expected result:
Window should stay maximized.

I attached a patch to fix the bug. However I only tested it under Windows 8. Will test tomorrow under Windows 7. But I have no XP at the moment. Can somebody else check that it works properly with XP?

Cheers,
Simon
Logged

Download Cultris II, the fastest Tetris clone from http://gewaltig.net/
Matzon
Administrator
Demigod
*****
Posts: 2177



« Reply #1 on: February 05, 2012, 23:23:08 »

looks good, dont think this should trigger anything in XP. Will ignore the redoMakeContextCurrent stuff Wink
Will test and apply tonight
Logged

http://certusgames.com (Free Online Multiplayer Java Games)
http://lwjgl.org (OpenGL/OpenAL for Java)
Simon Felix
Regular nerd
**
Posts: 96



WWW
« Reply #2 on: February 06, 2012, 09:36:56 »

It works also under Windows 7.

I renamed the "did_maximize" variable because the code might be confusing to read otherwise. The variable "did_maximize" is true when the window was restored to the "restored" or "maximized" window state. Now I added another variable called "maximized" that says whether the window was/is in the "maximized" or "restored" state (before minimizing). Just wanted to make the code clearer...
Logged

Download Cultris II, the fastest Tetris clone from http://gewaltig.net/
Matzon
Administrator
Demigod
*****
Posts: 2177



« Reply #3 on: February 06, 2012, 12:37:40 »

applied in r3741, thanks
Logged

http://certusgames.com (Free Online Multiplayer Java Games)
http://lwjgl.org (OpenGL/OpenAL for Java)
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines
SMFAds for Free Forums
Valid XHTML 1.0! Valid CSS!