JDK-7033533 : realSync() doesn't work with Xfce
  • Type: Bug
  • Component: client-libs
  • Sub-Component: java.awt
  • Affected Version: 6,7,8
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • OS: linux
  • CPU: x86,x86_64
  • Submitted: 2011-04-04
  • Updated: 2016-06-07
  • Resolved: 2014-02-07
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6 JDK 7 JDK 8 JDK 9
6u95Fixed 7u80Fixed 8u40Fixed 9 b06Fixed
Related Reports
Duplicate :  
Duplicate :  
Duplicate :  
Duplicate :  
Relates :  
Relates :  
Description
((SunToolkit)Toolkit.getDefaultToolkit()).realSync() fails with timeout if a test with it is called under Xfce. Apparently  in syncNativeQueue() in XToolkit a root window doesn't receive a necessary SelectionNotify event.

To test this, use any realSync() test: you'll see timeout. Take for instance this: closed/java/awt/Window/GetWindowsTest.

So far it's the only non-working thing in Xfce vs Gnome that I know. Also I know Xfce is not a supported platform and never will be but it's good, mature lightweight gtk-based system, so if you have a chance please take a look.

Comments
I investigated the order of different events and found that ConfigureNotify event goes through event queues the same way as SelectionNotify. Moreover it works with and without window manager. Please look at the native test and its log file. Thus it could unify the way XToolkit.syncNativeQueue() marks the block of not handled events. There are several XLib functions that make X server generate ConfigureNotify event: XConfigureWindow(), XLowerWindow(), XRaiseWindow(), XRestackWindows(), XMoveWindow(), XResizeWindow(), XMoveResizeWindow(), XMapRaised(), XSetWindowBorderWidth(). Invisible XAWTRootWindow could be used as a target for ConfigureNotify events. None of mentioned above functions are used for this window and it never becomes visible. These functions generate only one event (ConfigureNotify), contrary to XConvertSelection function which generates two (PropertyNotify, SelectionNotify). I chose XMoveWindow(), moving XAWTRootWindow back and forth by 1 pixel to avoid system optimization.
22-01-2014

Test run log
22-01-2014

Native Events Order Test
22-01-2014

These are all approved for deferral to JDK 9 so you can update the FixVersion to state JDK 9. Kind regards, Mathias
29-08-2013

These are all approved for deferral to JDK 9 so you can update the FixVersion to state JDK 9. Kind regards, Mathias
29-08-2013

These are all approved for deferral to JDK 9 so you can update the FixVersion to state JDK 9. Kind regards, Mathias
29-08-2013

Converted "8-client-defer-candidate" label to "8-defer-request" by SQE' OK.
15-08-2013

*This is anti-deferral criteria list*: - P2 -------------- Engineering's Criteria ------------------------------------- - tck-red labeled - conformance labeled - P3 regressions reported/labeled against jdk8 - findbugs, parfait, eht labeled bugs - CAP <1 year reported - netbeans <1 year reported Victor ----------------- SQE's OK --------------------------------- Yes, we are ok with that thanks, Mikhail
15-08-2013

8-defer-request: This is the issue reproduced from 7 GA, this is not a regression in 8, requesting to defer because there are no customer escalations on this issue.
17-06-2013