Backport Request: 8058197: AWT fails on generic non-reparenting window managers

Tiago Daitx tiago.daitx at canonical.com
Sun Nov 6 19:30:27 UTC 2016


Hi,

Could you please avail the following patch backport?

As the bug report[1] states, this change has been applied for quite a
while on various linux distros during packaging (although in a slight
longer version).

# HG changeset patch
# User azvegint
# Date 1413970773 -14400
# Node ID a06c13cb2e45792a77992438ee4de02e2ec54b7b
# Parent  be34425400ec479151dbe4f962054a90fc75b1fc
8058197: AWT fails on generic non-reparenting window managers
Reviewed-by: azvegint, serb
Contributed-by: Rohit Agrawal <rohit.agrawal.mn at gmail.com>

diff -r be34425400ec -r a06c13cb2e45 src/solaris/classes/sun/awt/X11/XWM.java
--- openjdk/jdk/src/solaris/classes/sun/awt/X11/XWM.java.orig
+++ openjdk/jdk/src/solaris/classes/sun/awt/X11/XWM.java
@@ -581,8 +581,13 @@
         return isNetWMName("Mutter");
     }

+    static int awtWMNonReparenting = -1;
     static boolean isNonReparentingWM() {
-        return (XWM.getWMID() == XWM.COMPIZ_WM || XWM.getWMID() ==
XWM.LG3D_WM || XWM.getWMID() == XWM.CWM_WM);
+        if (awtWMNonReparenting == -1) {
+            awtWMNonReparenting =
(XToolkit.getEnv("_JAVA_AWT_WM_NONREPARENTING") != null) ? 1 : 0;
+        }
+        return (awtWMNonReparenting == 1 || XWM.getWMID() == XWM.COMPIZ_WM
+                || XWM.getWMID() == XWM.LG3D_WM || XWM.getWMID() ==
XWM.CWM_WM);
     }

     /*


Note: I'm a participant, not a contributor, but I assume the patch and
backport are simple enough to not require a signed OCA.

[1] https://bugs.openjdk.java.net/browse/JDK-8058197


-- 
Tiago Stürmer Daitx
Software Engineer
tiago.daitx at canonical.com

PGP Key: 4096R/F5B213BE (hkp://keyserver.ubuntu.com)
Fingerprint = 45D0 FE5A 8109 1E91 866E  8CA4 1931 8D5E F5B2 13BE


More information about the jdk7u-dev mailing list