X-Git-Url: http://git.nikiroo.be/?a=blobdiff_plain;f=src%2Fbe%2Fnikiroo%2Futils%2Fui%2FUIUtils.java;h=6c4038977d9ed001934944128c8632dbb6dfe301;hb=919bbc354cd2555eb0955be0ef2dcf338047d022;hp=547ff6c3d40fb42e14f45c42d1b65ae02578898e;hpb=86057589d5211fbad4b7cdbcd4dd0f1e3777d4c1;p=nikiroo-utils.git diff --git a/src/be/nikiroo/utils/ui/UIUtils.java b/src/be/nikiroo/utils/ui/UIUtils.java deleted file mode 100644 index 547ff6c..0000000 --- a/src/be/nikiroo/utils/ui/UIUtils.java +++ /dev/null @@ -1,32 +0,0 @@ -package be.nikiroo.utils.ui; - -import javax.swing.UIManager; -import javax.swing.UnsupportedLookAndFeelException; - -/** - * Some Java Swing utilities. - * - * @author niki - */ -public class UIUtils { - /** - * Set a fake "native look & feel" for the application if possible - * (check for the one currently in use, then try GTK). - *

- * Must be called prior to any GUI work. - */ - static public void setLookAndFeel() { - // native look & feel - try { - String noLF = "javax.swing.plaf.metal.MetalLookAndFeel"; - String lf = UIManager.getSystemLookAndFeelClassName(); - if (lf.equals(noLF)) - lf = "com.sun.java.swing.plaf.gtk.GTKLookAndFeel"; - UIManager.setLookAndFeel(lf); - } catch (InstantiationException e) { - } catch (ClassNotFoundException e) { - } catch (UnsupportedLookAndFeelException e) { - } catch (IllegalAccessException e) { - } - } -}