<AWT Dev> [9] Review request for 8134917 [macosx] JOptionPane doesn't receive mouse events when opened from a drop event

Sergey Bylokhov Sergey.Bylokhov at oracle.com
Mon Sep 28 13:12:35 UTC 2015


On 24.09.15 16:13, Alexander Scherbatiy wrote:
>> Right, it overrides the sendEvent and for some
>> subtype="ExecuteBlockEvent" it tries to call a block. It means that if
>> LWCToolkit.nextEventMatchingMask gets an event which is related to a
>> deallocation it will later call release(which is inside the block) in
>> the sendEvent. And the previous fix was an attempt to eliminate this
>> situation of deallocation inside the nested loop.
>
>      Then I do not have an idea why the crash has been fixed. May be an
> author of the fix 8068886 or reviewers can provide  the real explanation.

     The crash was fixed because the nativeCFRelease() now use events 
instead of selectors for resources deallocation. And even with an 
incorrect mask in the nextEventMatchingMask(), we work properly, because 
in most of the time we start our nested event loop with 
processEvents=false. Which means that we simply block all events 
including events for deallocation. But the crash still be possible in 
case of dnd where we proceed the events.
The fix looks fine to me.

-- 
Best regards, Sergey.


More information about the awt-dev mailing list