+2006-06-09 Thomas Fitzsimmons <fitzsim@redhat.com>
+
+ * gnu/java/awt/peer/gtk/GdkGraphicsEnvironment.java
+ (getDefaultScreenDevice): Remove unnecessary GCJ local hack.
+ * gnu/java/awt/peer/gtk/GtkToolkit.java (getSystemEventQueueImpl):
+ Likewise.
+ * gnu/java/awt/peer/gtk/GdkPixbufDecoder.java (registerFormat):
+ Likewise.
+
2006-06-09 Thomas Fitzsimmons <fitzsim@redhat.com>
* java/lang/String.java, classpath/native/jni/classpath/jcl.h,
if (GraphicsEnvironment.isHeadless ())
throw new HeadlessException ();
- // GCJ LOCAL: workaround a GCJ problem accessing
- // GdkGraphicsEnvironment.class
- try
- {
- synchronized (Class.forName ("gnu.java.awt.peer.gtk.GdkGraphicsEnvironment"))
+ synchronized (GdkGraphicsEnvironment.class)
{
if (defaultDevice == null)
{
defaultDevice = nativeGetDefaultScreenDevice();
}
}
- }
- catch (Exception e)
- {
- e.printStackTrace();
- }
return defaultDevice;
}
public static ImageFormatSpec registerFormat(String name, boolean writable)
{
ImageFormatSpec ifs = new ImageFormatSpec(name, writable);
-
- // GCJ LOCAL: workaround a GCJ problem accessing
- // GdkPixbufDecoder.class
- try
- {
- synchronized(Class.forName ("gnu.java.awt.peer.gtk.GdkPixbufDecoder"))
+ synchronized(GdkPixbufDecoder.class)
{
if (imageFormatSpecs == null)
imageFormatSpecs = new ArrayList();
imageFormatSpecs.add(ifs);
}
- }
- catch (Exception e)
- {
- e.printStackTrace();
- }
-
return ifs;
}
protected EventQueue getSystemEventQueueImpl()
{
- // GCJ LOCAL: workaround a GCJ problem accessing
- // GtkToolkit.class
- try
- {
- synchronized (Class.forName ("gnu.java.awt.peer.gtk.GtkToolkit"))
+ synchronized (GtkToolkit.class)
{
if (q == null)
{
q = new EventQueue();
}
}
- }
- catch (Exception e)
- {
- e.printStackTrace();
- }
-
return q;
}