1
0
mirror of https://github.com/moparisthebest/davmail synced 2024-12-13 11:12:22 -05:00

Do not try to set Nimbus Look And Feel on Linux with Gtk

git-svn-id: http://svn.code.sf.net/p/davmail/code/trunk@652 3d1905a2-6b24-0410-a738-b14d5a86fcbd
This commit is contained in:
mguessan 2009-08-06 23:41:10 +00:00
parent a4843fe9a3
commit ff4c2c2392

View File

@ -144,17 +144,8 @@ public class SwtGatewayTray implements DavGatewayTrayInterface {
String lafClassName = UIManager.getSystemLookAndFeelClassName();
// workaround for bug when SWT and AWT both try to access Gtk
if (lafClassName.indexOf("gtk") > 0) {
// try to set Nimbus LAF
for (UIManager.LookAndFeelInfo laf : UIManager.getInstalledLookAndFeels()) {
if ("Nimbus".equals(laf.getName())) {
lafClassName = laf.getClassName();
}
}
// failover to default
if (lafClassName == null) {
lafClassName = UIManager.getCrossPlatformLookAndFeelClassName();
}
}
UIManager.setLookAndFeel(lafClassName);
} catch (Exception e) {
DavGatewayTray.warn(new BundleMessage("LOG_UNABLE_TO_SET_LOOK_AND_FEEL"));