X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=src%2Forg%2Fxwt%2FPlatform.java;h=5b1f0ac1879dc6dbfdd51090bedf549b645db52e;hb=6a96430e10e27fc1de5754cb5add705f929dd109;hp=9216dcb21e519344ac9c9654cca4e24bec77521f;hpb=8235361e8601ae7b36ab707058de3b52225d15a2;p=org.ibex.core.git diff --git a/src/org/xwt/Platform.java b/src/org/xwt/Platform.java index 9216dcb..5b1f0ac 100644 --- a/src/org/xwt/Platform.java +++ b/src/org/xwt/Platform.java @@ -34,7 +34,7 @@ public class Platform { static boolean alreadyDetectedProxy = false; /** the result of proxy autodetection */ - static HTTP.Proxy cachedProxyInfo = null; + static org.xwt.HTTP.Proxy cachedProxyInfo = null; /** the current build */ public static String build = "unknown"; @@ -66,10 +66,9 @@ public class Platform { else if (!version.startsWith("1.0") && !version.startsWith("1.1")) platform_class = "Java2"; /* - // Disable 2d hardware acceleration on Jaguar - if (os_name.equals("Mac OS X") && os_version.equals("10.2")) + // Disable 2d hardware acceleration on Jaguar + if (os_name.equals("Mac OS X") && os_version.startsWith("10.2")) System.setProperty("com.apple.hwaccel", "false"); */ - System.setProperty("com.apple.hwaccel", "false"); if (platform_class != null) { platform = (Platform)Class.forName("org.xwt.plat." + platform_class).newInstance(); @@ -124,7 +123,14 @@ public class Platform { /** creates and returns a picture */ public static Picture createPicture(int[] data, int w, int h) { return platform._createPicture(data, w, h); } + public static Picture createAlphaOnlyPicture(byte[] data, int w, int h) { return platform._createAlphaOnlyPicture(data, w, h); } + protected Picture _createPicture(int[] b, int w, int h) { return null; } + protected Picture _createAlphaOnlyPicture(byte[] b, int w, int h) { + int[] b2 = new int[b.length]; + for(int i=0;i