archrelease: copy trunk to extra-x86_64
[arch-packages.git] / java7-openjdk / trunk / openjdk7_nonreparenting-wm.diff
blobfb4710c1309fb5d3d085250fcebd7b25b724c85b
1 --- openjdk/jdk/src/solaris/classes/sun/awt/X11/XWM.java.orig 2013-10-16 16:17:14.000000000 +0200
2 +++ openjdk/jdk/src/solaris/classes/sun/awt/X11/XWM.java 2013-10-21 20:57:34.768580842 +0200
3 @@ -105,7 +105,8 @@
4 LG3D_WM = 13,
5 CWM_WM = 14,
6 MUTTER_WM = 15,
7 - MARCO_WM = 16;
8 + MARCO_WM = 16,
9 + OTHER_NONREPARENTING_WM = 17;
10 public String toString() {
11 switch (WMID) {
12 case NO_WM:
13 @@ -591,7 +592,7 @@
14 // TODO: according to wikipedia, compiz is now reparenting. This should
15 // probably be updated.
16 static boolean isNonReparentingWM() {
17 - return (XWM.getWMID() == XWM.COMPIZ_WM || XWM.getWMID() == XWM.LG3D_WM || XWM.getWMID() == XWM.CWM_WM);
18 + return (XWM.getWMID() == XWM.COMPIZ_WM || XWM.getWMID() == XWM.LG3D_WM || XWM.getWMID() == XWM.CWM_WM || XWM.getWMID() == XWM.OTHER_NONREPARENTING_WM);
22 @@ -781,9 +782,17 @@
23 * supports WIN or _NET wm spec.
25 else if (l_net_protocol.active()) {
26 - awt_wmgr = XWM.OTHER_WM;
27 + if (XToolkit.getEnv("_JAVA_AWT_WM_NONREPARENTING") != null) {
28 + awt_wmgr = XWM.OTHER_NONREPARENTING_WM;
29 + } else {
30 + awt_wmgr = XWM.OTHER_WM;
31 + }
32 } else if (win.active()) {
33 - awt_wmgr = XWM.OTHER_WM;
34 + if (XToolkit.getEnv("_JAVA_AWT_WM_NONREPARENTING") != null) {
35 + awt_wmgr = XWM.OTHER_NONREPARENTING_WM;
36 + } else {
37 + awt_wmgr = XWM.OTHER_WM;
38 + }
41 * Check for legacy WMs.
42 @@ -794,6 +803,8 @@
43 awt_wmgr = XWM.MOTIF_WM;
44 } else if (isOpenLook()) {
45 awt_wmgr = XWM.OPENLOOK_WM;
46 + } else if (XToolkit.getEnv("_JAVA_AWT_WM_NONREPARENTING") != null) {
47 + awt_wmgr = XWM.OTHER_NONREPARENTING_WM;
48 } else {
49 awt_wmgr = XWM.OTHER_WM;
51 @@ -1309,6 +1320,7 @@
52 res = new Insets(28, 6, 6, 6);
53 break;
54 case NO_WM:
55 + case OTHER_NONREPARENTING_WM:
56 case LG3D_WM:
57 res = zeroInsets;
58 break;