harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a...@apache.org
Subject svn commit: r572903 - in /harmony/enhanced/classlib/trunk/modules/awt/src/main: java/unix/org/apache/harmony/awt/nativebridge/linux/ java/unix/org/apache/harmony/awt/wtk/linux/ native/x11wrapper/unix/
Date Wed, 05 Sep 2007 09:02:52 GMT
Author: ayza
Date: Wed Sep  5 02:02:51 2007
New Revision: 572903

URL: http://svn.apache.org/viewvc?rev=572903&view=rev
Log:
Apllying improvement patch from HARMONY-4725 ([classlib][awt]Needs to replace XSetStandardProperties
with Xutf8SetWMProperties)

Modified:
    harmony/enhanced/classlib/trunk/modules/awt/src/main/java/unix/org/apache/harmony/awt/nativebridge/linux/X11.java
    harmony/enhanced/classlib/trunk/modules/awt/src/main/java/unix/org/apache/harmony/awt/wtk/linux/LinuxWindow.java
    harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/exports.txt
    harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/org_apache_harmony_awt_nativebridge_linux_X11.cpp
    harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/org_apache_harmony_awt_nativebridge_linux_X11.h

Modified: harmony/enhanced/classlib/trunk/modules/awt/src/main/java/unix/org/apache/harmony/awt/nativebridge/linux/X11.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/unix/org/apache/harmony/awt/nativebridge/linux/X11.java?rev=572903&r1=572902&r2=572903&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/awt/src/main/java/unix/org/apache/harmony/awt/nativebridge/linux/X11.java
(original)
+++ harmony/enhanced/classlib/trunk/modules/awt/src/main/java/unix/org/apache/harmony/awt/nativebridge/linux/X11.java
Wed Sep  5 02:02:51 2007
@@ -4645,6 +4645,66 @@
     }
     public final native int XSetStandardProperties(long param_0, long param_1, long param_2,
long param_3, long param_4, long param_5, int param_6, long param_7);
 
+    public final void Xutf8SetWMProperties(long param_0, long param_1, String param_2, String
param_3, PointerPointer param_4, int param_5, X11.XSizeHints param_6, X11.XWMHints param_7,
PointerPointer param_8) {
+        Int8Pointer _param_2 = null == param_2? null :  nb.createInt8Pointer(param_2, false);
+        long tmp_0 = _param_2 == null ? 0 : _param_2.longLockPointer();
+        Int8Pointer _param_3 = null == param_3? null :  nb.createInt8Pointer(param_3, false);
+        long tmp_1 = _param_3 == null ? 0 : _param_3.longLockPointer();
+        long tmp_2 = param_4 == null ? 0 : param_4.longLockPointer();
+        long tmp_3 = param_6 == null ? 0 : param_6.longLockPointer();
+        long tmp_4 = param_7 == null ? 0 : param_7.longLockPointer();
+        long tmp_5 = param_8 == null ? 0 : param_8.longLockPointer();
+        Xutf8SetWMProperties(param_0, param_1, tmp_0, tmp_1, tmp_2, param_5, tmp_3, tmp_4,
tmp_5);
+        if (_param_2 != null) {
+            _param_2.unlock();
+            _param_2.free();
+        }
+        if (_param_3 != null) {
+            _param_3.unlock();
+            _param_3.free();
+        }
+        if (param_4 != null) {
+            param_4.unlock();
+        }
+        if (param_6 != null) {
+            param_6.unlock();
+        }
+        if (param_7 != null) {
+            param_7.unlock();
+        }
+        if (param_8 != null) {
+            param_8.unlock();
+        }
+    }
+    public final void Xutf8SetWMProperties(long param_0, long param_1, Int8Pointer param_2,
Int8Pointer param_3, PointerPointer param_4, int param_5, X11.XSizeHints param_6, X11.XWMHints
param_7, PointerPointer param_8) {
+        long tmp_0 = param_2 == null ? 0 : param_2.longLockPointer();
+        long tmp_1 = param_3 == null ? 0 : param_3.longLockPointer();
+        long tmp_2 = param_4 == null ? 0 : param_4.longLockPointer();
+        long tmp_3 = param_6 == null ? 0 : param_6.longLockPointer();
+        long tmp_4 = param_7 == null ? 0 : param_7.longLockPointer();
+        long tmp_5 = param_8 == null ? 0 : param_8.longLockPointer();
+        Xutf8SetWMProperties(param_0, param_1, tmp_0, tmp_1, tmp_2, param_5, tmp_3, tmp_4,
tmp_5);
+        if (param_2 != null) {
+            param_2.unlock();
+        }
+        if (param_3 != null) {
+            param_3.unlock();
+        }
+        if (param_4 != null) {
+            param_4.unlock();
+        }
+        if (param_6 != null) {
+            param_6.unlock();
+        }
+        if (param_7 != null) {
+            param_7.unlock();
+        }
+        if (param_8 != null) {
+            param_8.unlock();
+        }
+    }
+    public final native void Xutf8SetWMProperties(long param_0, long param_1, long param_2,
long param_3, long param_4, int param_5, long param_6, long param_7, long param_8);
+
     public final native long XDefaultColormap(long param_0, int param_1);
 
     public final native long XAllocSizeHints();

Modified: harmony/enhanced/classlib/trunk/modules/awt/src/main/java/unix/org/apache/harmony/awt/wtk/linux/LinuxWindow.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/unix/org/apache/harmony/awt/wtk/linux/LinuxWindow.java?rev=572903&r1=572902&r2=572903&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/awt/src/main/java/unix/org/apache/harmony/awt/wtk/linux/LinuxWindow.java
(original)
+++ harmony/enhanced/classlib/trunk/modules/awt/src/main/java/unix/org/apache/harmony/awt/wtk/linux/LinuxWindow.java
Wed Sep  5 02:02:51 2007
@@ -176,8 +176,8 @@
                                      X11Defs.CopyFromParent, 0, 0);
                                      */
         String title = (p.name != null) ? p.name : ""; //$NON-NLS-1$
-        x11.XSetStandardProperties(display, windowID, title, title, 0,
-                null, 0, null);
+        x11.Xutf8SetWMProperties(display, windowID, title, title, null, 0,
+                null, null, null);
         x11.XSelectInput(display, windowID, enabled ? DEFAULT_MASK : DISABLED_MASK);
 
         if (!popup) {
@@ -484,8 +484,8 @@
         if (title == null) {
             title = ""; //$NON-NLS-1$
         }
-        x11.XStoreName(display, windowID, title);
-        x11.XSetIconName(display, windowID, title);
+        x11.Xutf8SetWMProperties(display, windowID, title, title, null, 0,
+                null, null, null);
         x11.XFlush(display);
     }
 

Modified: harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/exports.txt
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/exports.txt?rev=572903&r1=572902&r2=572903&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/exports.txt
(original)
+++ harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/exports.txt
Wed Sep  5 02:02:51 2007
@@ -114,6 +114,7 @@
 Java_org_apache_harmony_awt_nativebridge_linux_X11_XSetInputFocus
 Java_org_apache_harmony_awt_nativebridge_linux_X11_XSetSelectionOwner
 Java_org_apache_harmony_awt_nativebridge_linux_X11_XSetStandardProperties
+Java_org_apache_harmony_awt_nativebridge_linux_X11_Xutf8SetWMProperties
 Java_org_apache_harmony_awt_nativebridge_linux_X11_XSetTransientForHint
 Java_org_apache_harmony_awt_nativebridge_linux_X11_XSetWMHints
 Java_org_apache_harmony_awt_nativebridge_linux_X11_XSetWMNormalHints

Modified: harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/org_apache_harmony_awt_nativebridge_linux_X11.cpp
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/org_apache_harmony_awt_nativebridge_linux_X11.cpp?rev=572903&r1=572902&r2=572903&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/org_apache_harmony_awt_nativebridge_linux_X11.cpp
(original)
+++ harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/org_apache_harmony_awt_nativebridge_linux_X11.cpp
Wed Sep  5 02:02:51 2007
@@ -774,6 +774,15 @@
     return (jint) (* p_nbridge_XSetStandardProperties)((void *) param_0, (long) param_1,
(void *) param_2, (void *) param_3, (long) param_4, (void *) param_5, (int) param_6, (void
*) param_7);
 }
 
+void (* p_nbridge_Xutf8SetWMProperties) (void *, long, void *, void *, void *, int, void
*, void*, void*) = NULL;
+
+JNIEXPORT void  JNICALL Java_org_apache_harmony_awt_nativebridge_linux_X11_Xutf8SetWMProperties(
JNIEnv *env, jobject self, jlong param_0, jlong param_1, jlong param_2, jlong param_3, jlong
param_4, jint param_5, jlong param_6, jlong param_7, jlong param_8) {
+    if (p_nbridge_Xutf8SetWMProperties == NULL) {
+        p_nbridge_Xutf8SetWMProperties = (void (*) (void *, long, void *, void *, void*,
int, void*, void*, void*)) FindFunction(libX11, "Xutf8SetWMProperties");
+    }
+   (* p_nbridge_Xutf8SetWMProperties)((void *) param_0, (long) param_1, (void *) param_2,
(void *) param_3, (void *) param_4, (int) param_5, (void *) param_6, (void *) param_7, (void
*) param_8);
+}
+
 unsigned long  (* p_nbridge_XDefaultColormap) (void *, int) = NULL;
 
 JNIEXPORT jlong  JNICALL Java_org_apache_harmony_awt_nativebridge_linux_X11_XDefaultColormap(
JNIEnv *env, jobject self, jlong param_0, jint param_1) {

Modified: harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/org_apache_harmony_awt_nativebridge_linux_X11.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/org_apache_harmony_awt_nativebridge_linux_X11.h?rev=572903&r1=572902&r2=572903&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/org_apache_harmony_awt_nativebridge_linux_X11.h
(original)
+++ harmony/enhanced/classlib/trunk/modules/awt/src/main/native/x11wrapper/unix/org_apache_harmony_awt_nativebridge_linux_X11.h
Wed Sep  5 02:02:51 2007
@@ -195,6 +195,8 @@
 
 JNIEXPORT jint  JNICALL Java_org_apache_harmony_awt_nativebridge_linux_X11_XSetStandardProperties(JNIEnv
*, jobject, jlong, jlong, jlong, jlong, jlong, jlong, jint, jlong);
 
+JNIEXPORT void  JNICALL Java_org_apache_harmony_awt_nativebridge_linux_X11_Xutf8SetWMProperties(JNIEnv
*, jobject, jlong, jlong, jlong, jlong, jlong, jint, jlong, jlong, jlong);
+
 JNIEXPORT jlong  JNICALL Java_org_apache_harmony_awt_nativebridge_linux_X11_XDefaultColormap(JNIEnv
*, jobject, jlong, jint);
 
 JNIEXPORT jlong  JNICALL Java_org_apache_harmony_awt_nativebridge_linux_X11_XAllocSizeHints(JNIEnv
*, jobject);



Mime
View raw message