moved disabled freetext color into themeable preferences
authorn.hoffmann <n.hoffmann@localhost>
Wed, 5 Jan 2011 13:45:12 +0000 (13:45 +0000)
committern.hoffmann <n.hoffmann@localhost>
Wed, 5 Jan 2011 13:45:12 +0000 (13:45 +0000)
taxeditor-store/plugin.xml
taxeditor-store/src/main/java/eu/etaxonomy/taxeditor/parser/ParseHandler.java
taxeditor-store/src/main/java/eu/etaxonomy/taxeditor/preference/Resources.java

index df6cbed461743107644df44e6d714832d922b1e5..e1099da50bfd25b3d7209a620eaceb1967fd5ea6 100644 (file)
             label="Parse Error"
             value="255,0,0">
       </colorDefinition>
+      <colorDefinition
+            categoryId="eu.etaxonomy.taxeditor.preferences.themeElementCategory.nameEditor"
+            id="eu.etaxonomy.taxeditor.preferences.colorDefinition.disabledEditor"
+            label="Disabled Name Editor Field"
+            value="105,114,124">
+      </colorDefinition>
       </extension>
 <extension
       point="org.eclipse.core.expressions.propertyTesters">
index dddcba75dde6ef77efd5ebdca653c85ee3633e02..6e97acb17efdc3271c2809d3683a69285c96ebbc 100644 (file)
@@ -143,17 +143,17 @@ public class ParseHandler{
         *
         * @return      The parsed NonViralName object
         */
-       public NonViralName parse(){
+       public NonViralName parse(String unparsedNameString){
                
-               String unparsedNameString = "";
-               try {
-                       Method getText;
-                       getText = textWidget.getClass().getDeclaredMethod("getText", null);
-                       unparsedNameString = (String) getText.invoke(textWidget, null);
-               } catch (Exception e) {
-                       // we should never get here
-                       StoreUtil.error(this.getClass(), "Error trying to invoke getText method", e);
-               }
+//             String unparsedNameString = "";
+//             try {
+//                     Method getText;
+//                     getText = textWidget.getClass().getDeclaredMethod("getText", null);
+//                     unparsedNameString = (String) getText.invoke(textWidget, null);
+//             } catch (Exception e) {
+//                     // we should never get here
+//                     StoreUtil.error(this.getClass(), "Error trying to invoke getText method", e);
+//             }
                
                
                nonViralNameParser.parseReferencedName(name, unparsedNameString,
@@ -177,9 +177,9 @@ public class ParseHandler{
         *
         * @return      The parsed NonViralName object
         */
-       public NonViralName parseAndResolveDuplicates(){
+       public NonViralName parseAndResolveDuplicates(String unparsedNameString){
                
-               NonViralName parsedName = parse();
+               NonViralName parsedName = parse(unparsedNameString);
                
                MatchMatrix matchMatrix = findMatches(parsedName);
                
index 3def92a16fc38708326a1b9b8dfef191a4e3b715..11f0948fad91aea12bf830d08363e58007a1045f 100644 (file)
@@ -76,7 +76,10 @@ public interface Resources {
        public static final String COLOR_LIST_EVEN = "eu.etaxonomy.taxeditor.preferences.colorDefinition.listBackgroundEven";
        /** Constant <code>COLOR_LIST_ODD="eu.etaxonomy.taxeditor.preferences.colo"{trunked}</code> */
        public static final String COLOR_LIST_ODD = "eu.etaxonomy.taxeditor.preferences.colorDefinition.listBackgroundOdd";
+       
        public static final String COLOR_PARSE_ERROR = "eu.etaxonomy.taxeditor.preferences.colorDefinition.parseError";
        
+       public static final String COLOR_DISABLED_EDITOR = "eu.etaxonomy.taxeditor.preferences.colorDefinition.disabledEditor";
+       
        
 }