Hi.
Now, my program shows a message box when certain event occurred. For example, when edit box has nothing, input return key, or user clicks some button, etc.
To give feedback to user, I make a message box; therefore, since the message box is modal, the program should ignore all the other events when the message box is generated.
But it doesn't. Well, the button events are clearly ignored, but the key events are not.
After it shows feedback message box, it continuously make other message boxes whenever I input certain key.
How can I make sure that there exits just one message box on the irrDevice?
Or is there another method to solve this problem?
Wait for your novel answer.
How can I make just one MessageBox on the device?
How can I make just one MessageBox on the device?
From Seoul, South Korea
Re: How can I make just one MessageBox on the device?
Oh... I just solved this by checking focus of GUIEnv...
From Seoul, South Korea
-
hybrid
- Admin
- Posts: 14144
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
Re: How can I make just one MessageBox on the device?
You should note the actual setup of the event handler mechanism. All events are first passed to the user event handler, i.e. the one that you created and passed to the device. This way, you can filter out any event that should not make it to the other handlers. Next, the event is passed to the camera handler, if any exists, and if OnEvent returned true so far. These handlers are also kind of user-defined handlers. At least you can also provide one on your own, but e.g. the FPS cam also has one. And finally, events are passed to the GUI handler. If you want to stop event processing earlier, you have to return false in one of your handlers, or disable the event processing. For cameras you can disable the whole handler, for GUI events you have to disable distinct elements.