<AWT Dev> [8] Review request for 7033533: realSync() doesn't work with Xfce

Oleg Pekhovskiy oleg.pekhovskiy at oracle.com
Thu Sep 26 00:56:52 PDT 2013

Hi Leonid,

I did it mostly logically, because my fix added one more service event 
(SelectionRequest), that should be excluded from the number of 
dispatched native events.
IMHO, the previous number "2" should have been commented, but, that did 
not happen.


On 25.09.2013 18:11, Leonid Romanov wrote:
> Hi,
> I'm not an expert in X11 programming, so I can't comment about the fix
> in general, but I think the line 2436, "return getEventNumber() -
> event_number > 3", really asks for a comment.
> On 9/25/2013 16:38, Oleg Pekhovskiy wrote:
>> Hi all,
>> please review the fix
>> http://cr.openjdk.java.net/~bagiras/7033533.1/
>> for
>> https://bugs.openjdk.java.net/browse/JDK-7033533
>> Previous implementation of XToolkit.syncNativeQueue() relied upon
>> WM_S0 atom existence and that it was owned by current window manager.
>> But several WMs (like XFCE and LXDE) don't send SelectionNotify event
>> to the client on XConvertSelection() for that atom. That led
>> XToolkit.syncNativeQueue() to hang until TimeOutException.
>> I decided to keep XConvertSelection() usage, but make root toolkit
>> window as an owner for selection atom (with another name), and handle
>> SelectionRequest event from X Server, sending SelectionNotify in
>> response (as window manager is supposed to do).
>> Tested on both XFCE and LXDE.
>> Thanks,
>> Oleg

More information about the awt-dev mailing list