[jsword-svn] r1374 - trunk/common-swing/src/main/java/org/crosswire/common/config/swing
dmsmith at www.crosswire.org
dmsmith at www.crosswire.org
Fri Jun 1 07:27:05 MST 2007
Author: dmsmith
Date: 2007-06-01 07:27:05 -0700 (Fri, 01 Jun 2007)
New Revision: 1374
Modified:
trunk/common-swing/src/main/java/org/crosswire/common/config/swing/OptionsField.java
Log:
Eliminate a spurious warning.
Modified: trunk/common-swing/src/main/java/org/crosswire/common/config/swing/OptionsField.java
===================================================================
--- trunk/common-swing/src/main/java/org/crosswire/common/config/swing/OptionsField.java 2007-06-01 14:19:10 UTC (rev 1373)
+++ trunk/common-swing/src/main/java/org/crosswire/common/config/swing/OptionsField.java 2007-06-01 14:27:05 UTC (rev 1374)
@@ -136,7 +136,12 @@
}
}
- log.warn("Checked for options without finding: '" + value + "'. Defaulting to first option: " + combo.getSelectedItem()); //$NON-NLS-1$//$NON-NLS-2$
+ // Equate null and empty string
+ Object selected = combo.getSelectedItem();
+ if (value.length() > 0 && selected != null)
+ {
+ log.warn("Checked for options without finding: '" + value + "'. Defaulting to first option: " + selected); //$NON-NLS-1$//$NON-NLS-2$
+ }
}
/**
More information about the jsword-svn
mailing list