On Thu, 6 Jun 2024 23:28:07 GMT, Alisen Chung <ach...@openjdk.org> wrote:

> Add a check for previous focused window on modal unblocking. If the owner of 
> a closing dialog was the last focused window, then the owner of the dialog 
> should regain focus.

src/java.desktop/macosx/classes/sun/lwawt/macosx/CPlatformWindow.java line 1062:

> 1060: 
> 1061:         Window currFocus = 
> LWKeyboardFocusManagerPeer.getInstance().getCurrentFocusedWindow();
> 1062:         if (!blocked && target.equals(currFocus)) {

it is better to use "==" instead of "equals" which might be overridden by the 
app.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/19588#discussion_r1631545097

Reply via email to