Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

[REBOL] Re: listen to events only for a specific window?

From: arolls:bigpond:au at: 14-Jul-2001 2:13

I'm sorry, but in both these examples the original window still receives events. The reason I wanted to do this is to catch unforseen situations in VID code that produce an error and halt rebol. See my anim/VR4.r "Dilbert" demo. You can uncomment a bit of code which reveals a button, which, when pressed, gets angry and produces an error. This usually has the effect of stopping the fun completely. You have to restart the program in this case. But I have put in a mechanism for catching the error and showing a window, just as in the example at the very bottom of this email, with details of the error and some buttons to let the user decide what to do. Unfortunately, after showing the error window to the user, the first window keeps going. If there is a situation in some code in the future where an error occurs at each "tick" of an animation, I can imagine my error-trapping code opening new error message windows 30 times per second. Not very friendly. I need to stop the animation! The first window needs to stop until the user has decided what to do about it. (Could be, auto-email author.) I hope you understand me now. :) Anton.