On Oct 1, 4:28 pm, "Edward K. Ream" <[email protected]> wrote:
> The fix was simply to execute k.keyboardQuit at idle time, using > g.app.gui.runAtIdle. I didn't investigate what the proximate > cause of the problem was... > I just realized that the problem persists for keystrokes. Presumably > a similar fix will work for them too. I'll fix this immediately. Indeed, rev 4514 contains a similar *set* of changes that appear to fully fix the problem. This was tricky, even the second time around, and I did indeed have to investigate exactly what the problem was. To give a flavor of the complexities, here is the checkin log. QQQQQ Changed mouseReleaseEvent, showStateAndMode, onFocusIn and onFocusOut so that "dangerous" code is executed outside of event handlers at idle time. Note: it *is* now safe for mouseReleaseEvent to call k.keyboardQuit, because the only unsafe part of k.keyboardQuit is showStateAndMode, which is now done at idle time. All unit tests pass with Python2 and Python3, but note: unitTestGui.runAtIdle is a do-nothing. QQQQQ You could say that the new code is simple enough, but just barely. It is just a bit disconcerting that k.showStateAndMode must be done at idle time, but apparently that can't be helped. Anyway, the code is about as simple as before, with the added benefit that it works :-) Or so I say now. Please report any problems immediately. Edward -- You received this message because you are subscribed to the Google Groups "leo-editor" 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/leo-editor?hl=en.
