errael commented on PR #4739:
URL: https://github.com/apache/netbeans/pull/4739#issuecomment-1271042906

   I'm just taking another look at `DialogDisplayerImpl`. I may have 
unfoundedly disparaged `KeyboardFocusManager` returns; I had thought that 
perhaps it was being called when the focus owner was not in the "same context 
as the calling thread" (not sure that's possible as a desktop app).
   
   But now I notice the use of `noParent` in `DialogDisplayerImpl` which may 
get set if `runDelayed` is involved and gives a null parent.
   
   Null is just not the right choice in a multiscreen environment. I'm 
wondering about, in `showDialog`, using MainWindow instead of null parent. 
Another possibility would be to use the "preferred screen" from #4714. I lean 
towards MainWindow. Which handles both noParent and KeyboardFocusManager. 
Perhaps something a bit more complicated, determine the screen, eg MainWindow, 
but leave the parent null and move the dialog to the center of the chosen 
screen, (if there are cases where you don't want the dialog to have a parent?). 
Comments?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to