PreviousNextTracker indexSee it online !

(5/22) 3154382 - MacOSX reopen bug fix

This is a patch for the following bug (on Mac OSX):
1) Modify a buffer
2) Close the window and elect to discard without saving, application goes into background mode
3) Click the jEdit icon in the dock

Expected: A new view is opened.
Actual: Nothing.

Submitted evanpw - 2011-01-10 - 15:49:50z Assigned evanpw
Priority 5 Category general
Status Open Group None
Resolution None Visibility No


2011-02-08 - 20:43:39z
A comment on why this patch fixes the problem: When you hit the "Discard Selected" button, the View is disposed of, but a windowActivated message also gets sent because the dialog is closed, exposing the View. In windowActivated, the (now closed and disposed) View is activated, and then when you attempt to reopen the application, the MacOSX plugin think that there is still an active view, so it just attempts to bring it to the front (even though the window has been disposed) rather than opening a new one, as should happen.

This patch just ignores that extra windowActivated message that occurs after the window is already closed (the fact that it receives one is probably a JVM bug).
2011-09-01 - 12:00:10z
Hi, I see the bug but the patch do not fix it, did I miss something ?
2011-09-02 - 15:11:35z
I've checked it again against the current trunk, and it works for me. I'm using OSX 10.6.7 with Apple's Java version 1.6.0_24-b07-334 64-bit. Does it work correctly if you just close the window and click the icon without the "discard without saving" stuff? That should determine whether this bug is responsible for the problem or if something else is going wrong.
2012-01-29 - 19:20:32z
It works OK for me with latest trunk.
2012-08-21 - 19:07:22z
Evan you can commit it directly now if you want.


2011-01-10 - 15:49:50z