Well not really, suppose this : I have subclassed pyglet.window.Window and am acting on my on_draw event.
Inside the window.on_draw I put a window.clear(), since this is the first handler it will be called last so in effect clearing everything I have just drawn... Right now i solve it by making the window.on_draw dispatch another event right after clearing the window and I called it "draw" instead of "on_draw". I guess there are other better ways to solve, if so I would like to hear them, but to me a (relatively) simple solution would be to allow inserting push_handlers at a certain index position maybe ? On Feb 3, 1:13 pm, Alex Holkner <[email protected]> wrote: > On Tue, Feb 3, 2009 at 10:50 PM, Red15 <[email protected]> wrote: > > > On a slightly off-topic note: Has there been an argument about > > prepending event handlers to the ones currrently on the stack or is it > > programming wise impossible ? I haven't looked into the source for > > events yet but to me it is something I would appreciate being able to > > push handlers in front of the current handlers. > > I'm pretty sure the current behaviour is what you're after. If A is > currently on the stack, and you push B onto the stack (e.g. with > push_handlers()), then B gets the first go at the event, before A. > > Alex. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pyglet-users" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/pyglet-users?hl=en -~----------~----~----~----~------~----~------~--~---
