Include None in default colours
authoramwaterhouse <Andrew Waterhouse>
Mon, 29 Aug 2005 17:22:17 +0000 (17:22 +0000)
committeramwaterhouse <Andrew Waterhouse>
Mon, 29 Aug 2005 17:22:17 +0000 (17:22 +0000)
src/jalview/gui/Preferences.java

index bec82a5..be1455b 100755 (executable)
@@ -93,21 +93,14 @@ public class Preferences extends GPreferences
         quality.setSelected(Cache.getDefault("SHOW_QUALITY", true));\r
         identity.setSelected(Cache.getDefault("SHOW_IDENTITY", true));\r
 \r
-        for (int i = 0; i < 12; i++)\r
+        for (int i = 0; i < 13; i++)\r
         {\r
             colour.addItem(ColourSchemeProperty.getColourName(i));\r
         }\r
 \r
-        String string = Cache.getProperty("DEFAULT_COLOUR");\r
+        String string = Cache.getDefault("DEFAULT_COLOUR", "None");\r
 \r
-        if (string != null)\r
-        {\r
-            colour.setSelectedItem(string);\r
-        }\r
-        else\r
-        {\r
-            colour.setSelectedIndex(11);\r
-        }\r
+        colour.setSelectedItem(string);\r
 \r
         String[] fonts = java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment()\r
                                                      .getAvailableFontFamilyNames();\r