<Swing Dev> Swing dev>[10] Review request for JDK-8189253: [macos] JPopupMenu is inadvertently shown when using setComponentPopupMenu

Semyon Sadetsky semyon.sadetsky at oracle.com
Tue Jan 2 18:00:53 UTC 2018


Hi Manajit,

JDK-8080729 bug was Mac OS specific issue and its fix changed the Mac OS 
code only. Nevertheless you are suggesting to fix the regression in 
generic code. This need to be explained somehow.

--Semyon

On 12/25/2017 02:42 AM, Manajit Halder wrote:
> Hi Semyon,
>
> Regression is cause by JDK-8080729 
> <https://bugs.openjdk.java.net/browse/JDK-8080729>. The fix can’t be 
> reversed since it is the choice between addChildWindow or orderWindow. 
> Went through code flow related to the issue but didn’t find any other 
> better place in code to handle this issue. The best way to fix the 
> issue would be to avoid retargeting of events (MOUSE_ENTER and 
> MOUSE_EXIT) between MOUSE_PRESS and MOUSE_RELEASE on the parent window 
> (when the mouse is actually on the child window). Therefore request 
> you to review the webrev.00.
>
> Regards,
> Manajit
>
>> On 08-Dec-2017, at 9:55 PM, semyon.sadetsky at oracle.com 
>> <mailto:semyon.sadetsky at oracle.com> wrote:
>>
>> Hi Manajit,
>>
>> Can you provide information which fix caused the regression?
>>
>> --Semyon
>>
>>
>> On 12/8/17 5:53 AM, Manajit Halder wrote:
>>> Hi All,
>>>
>>> Kindly review the following Swing fix.
>>>
>>> Bug: https://bugs.openjdk.java.net/browse/JDK-8189253
>>> Webrev: http://cr.openjdk.java.net/~mhalder/8189253/webrev.00/ 
>>> <http://cr.openjdk.java.net/%7Emhalder/8189253/webrev.00/>
>>>
>>> Cause:
>>> Issue was due to retargeting of mouse enter exit events.
>>> MOUSE_ENTER and MOUSE_EXIT events were sent on the parent window 
>>> (JFrame) in between MOUSE_PRESS and MOUSE_RELEASE events on the 
>>> modeless JDialog.
>>>
>>> Fix:
>>> Retargeting of events is not done in-between MOUSE_PRESS and 
>>> MOUSE_RELEASE.
>>>
>>> Regards,
>>> Manajit
>>>
>>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/swing-dev/attachments/20180102/79aa7e6d/attachment.html>


More information about the swing-dev mailing list