You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers. No questions about C++ programming or topics which are answered in the tutorials!
Well, I have a question: is there a way to detect when a user closes a GUI window (something like the WM_CLOSE message in WINAPI)?
This doesn't seem to work:
The close button has a default handler, so you won't get the event. There is a patch availabel to remove default handling. Search for it in the forums.
This is an idea that just came into my mind. It's a way without modifying the engine, although it has a hackish touch:
1. Get and hide the original close button (getCloseButton)
2. Create a new button with same configuration as the original one (text, font, position) and place it as child into the window.
The events of that "button clone" won't get catched by the window.
It is like it is. And because it is like it is, things are like they are.
jox wrote:This is an idea that just came into my mind. It's a way without modifying the engine, although it has a hackish touch:
1. Get and hide the original close button (getCloseButton)
2. Create a new button with same configuration as the original one (text, font, position) and place it as child into the window.
The events of that "button clone" won't get catched by the window.