Hi folks. I'm having trouble getting started on Xu...
# tornadofx
a
Hi folks. I'm having trouble getting started on Xubuntu 19.04. I keep getting an
UnsupportedOperation
exception:
Copy code
Exception in thread "main" java.lang.UnsupportedOperationException: Internal Error
	at com.sun.glass.ui.gtk.GtkApplication.lambda$new$5(GtkApplication.java:158)
The offending code checks what library to load:
Copy code
int libraryToLoad = _queryLibrary(gtkVersion, gtkVersionVerbose); 

AccessController.doPrivileged((PrivilegedAction<Void>) () -> {
            if (libraryToLoad == QUERY_NO_DISPLAY) {
                throw new UnsupportedOperationException("Unable to open DISPLAY");
            } else if (libraryToLoad == QUERY_USE_CURRENT) {
                if (gtkVersionVerbose) {
                    System.out.println("Glass GTK library to load is already loaded");
                }
            } else if (libraryToLoad == QUERY_LOAD_GTK2) {
                if (gtkVersionVerbose) {
                    System.out.println("Glass GTK library to load is glassgtk2");
                }
                NativeLibLoader.loadLibrary("glassgtk2");
            } else if (libraryToLoad == QUERY_LOAD_GTK3) {
                if (gtkVersionVerbose) {
                    System.out.println("Glass GTK library to load is glassgtk3");
                }
                NativeLibLoader.loadLibrary("glassgtk3");
            } else {
                throw new UnsupportedOperationException("Internal Error");
            }
            return null;
        });
I've got libgtk-2, libgtk-2-dev, libgtk-3 and libgtk-3-dev installed and I'm running on Oracle JDK 8.
Copy code
$ java -version                                                                                                                                             
java version "1.8.0_221"
Java(TM) SE Runtime Environment (build 1.8.0_221-b11)
Java HotSpot(TM) Server VM (build 25.221-b11, mixed mode)
_queryLibrary
is unfortunately a native method. Any pointers to why this is failing would be massively helpful