Hello,
(sorry for my bad english, i came from germany)
i’m starting one week ago with SDL. I use SDL.Net (SDL dotnet) under
Visual Basic 9, my OS ist WindowsXP.
At the moment i have a problem, i think its trival, but is’nt it for me.
I start with a Windows.Forms-Application (not Console-Application!) and
by clicking an an Button i create a SDL-Window with Video.SetVideo …
that works great and i can render frames for my test-programm in the
tick-event-handler. Why i use a Windows.Forms-Application? I must
display a WebBrowser-Control by example and need some Windows to display
Data outside of the SDL-Window.
Now my Problem:
The SDL-Windows have a red X in the right upper corner to close the
SDL-Window and when i click on it (or Press ALT-F4), the whole
Application will close, not only the SDL-Window. I have installed a
Eventhandler to catch the sdl-quit-Event, but find not way to break the
quiting-process.
I must catch the quit-event, so that i can ask the user “Quit, Yes or
No”. I can display a messagebox, but i can not break the quit-event.
I dont have found helpful code-examples. I search over three days and
read a lot of Expamles in C, C++ and C# and two in Visual Basic
I think its a simple problem … please help me to master it.
Greetings, Valerie