diff options
author | Grant Gayed <ggayed> | 2003-12-16 15:06:00 +0000 |
---|---|---|
committer | Grant Gayed <ggayed> | 2003-12-16 15:06:00 +0000 |
commit | 3bfb21e2f41802f1123dd33047e6d8ba6b00da49 (patch) | |
tree | a969271ab2dd32e1959a40f92cace673acabb58c | |
parent | 21949f8262bfbe982e0298261ecd4a94a7dbf5f4 (diff) | |
download | eclipse.platform.swt-3bfb21e2f41802f1123dd33047e6d8ba6b00da49.tar.gz eclipse.platform.swt-3bfb21e2f41802f1123dd33047e6d8ba6b00da49.tar.xz eclipse.platform.swt-3bfb21e2f41802f1123dd33047e6d8ba6b00da49.zip |
45877v2135n
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT PI/motif/org/eclipse/swt/internal/motif/OS.java | 9 | ||||
-rwxr-xr-x | bundles/org.eclipse.swt/Eclipse SWT/motif/org/eclipse/swt/internal/Converter.java | 6 |
2 files changed, 13 insertions, 2 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/motif/org/eclipse/swt/internal/motif/OS.java b/bundles/org.eclipse.swt/Eclipse SWT PI/motif/org/eclipse/swt/internal/motif/OS.java index 0cf527c5e3..9556e6429a 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/motif/org/eclipse/swt/internal/motif/OS.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/motif/org/eclipse/swt/internal/motif/OS.java @@ -35,8 +35,15 @@ public class OS { if (osName.equals ("HP-UX")) isHPUX = true; IsAIX = isAIX; IsSunOS = isSunOS; IsLinux = isLinux; IsHPUX = isHPUX; IsDBLocale = OS.MB_CUR_MAX () != 1; + if (IsLinux) { + CODESET = 14; + } else if (IsHPUX) { + CODESET = 62; + } else { + CODESET = 49; + } } - public static final int CODESET = OS.IsLinux ? 14 : 49; + public static final int CODESET; public static final int LC_CTYPE = OS.IsAIX ? 1 : 0; static final int RESOURCE_LENGTH = 1024 * 3; diff --git a/bundles/org.eclipse.swt/Eclipse SWT/motif/org/eclipse/swt/internal/Converter.java b/bundles/org.eclipse.swt/Eclipse SWT/motif/org/eclipse/swt/internal/Converter.java index a44e223d4d..6ff2cfc9ea 100755 --- a/bundles/org.eclipse.swt/Eclipse SWT/motif/org/eclipse/swt/internal/Converter.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/motif/org/eclipse/swt/internal/Converter.java @@ -47,7 +47,11 @@ public final class Converter { static int BufferTimes4; static { - Unicode = getAsciiBytes("UCS-2"); + if (OS.IsHPUX) { + Unicode = getAsciiBytes("ucs2"); + } else { + Unicode = getAsciiBytes("UCS-2"); + } int length, item = OS.nl_langinfo (OS.CODESET); if (item != 0 && (length = OS.strlen (item)) > 0) { |