Revision 47790 trunk/org.gvsig.desktop/org.gvsig.desktop.plugin/org.gvsig.app/org.gvsig.app.mainplugin/src/main/java/org/gvsig/app/project/ProjectPreferences.java
ProjectPreferences.java | ||
---|---|---|
26 | 26 |
import javax.swing.UIManager; |
27 | 27 |
import org.apache.commons.lang.StringUtils; |
28 | 28 |
import org.apache.commons.lang3.BooleanUtils; |
29 |
|
|
30 | 29 |
import org.cresques.cts.IProjection; |
31 | 30 |
import org.gvsig.andami.PluginServices; |
32 | 31 |
import org.gvsig.andami.PluginsLocator; |
... | ... | |
58 | 57 |
private final IProjection defaultFactoryProjection |
59 | 58 |
= MapContextLocator.getMapContextManager().getDefaultCRS(); |
60 | 59 |
|
61 |
private Color defaultSelectionColor = Color.YELLOW;
|
|
60 |
private Color defaultSelectionColor = MapContext.DEFAULT_SELECTION_COLOR;
|
|
62 | 61 |
|
63 | 62 |
private Color defaultViewBackColor = null; // Color.WHITE; |
64 | 63 |
|
... | ... | |
130 | 129 |
* @param color |
131 | 130 |
*/ |
132 | 131 |
public void setDefaultSelectionColor(Color color) { |
132 |
if(color == null){ |
|
133 |
return; |
|
134 |
} |
|
133 | 135 |
defaultSelectionColor = color; |
134 | 136 |
XMLEntity xml = plugin.getPersistentXML(); |
135 | 137 |
xml.putProperty("DefaultSelectionColor", StringUtilities.color2String(color)); |
... | ... | |
147 | 149 |
defaultSelectionColor = StringUtilities.string2Color(xml |
148 | 150 |
.getStringProperty("DefaultSelectionColor")); |
149 | 151 |
} |
152 |
if(defaultSelectionColor == null) { |
|
153 |
this.defaultSelectionColor = MapContext.DEFAULT_SELECTION_COLOR; |
|
154 |
} |
|
150 | 155 |
return defaultSelectionColor; |
151 | 156 |
} |
152 | 157 |
|
Also available in: Unified diff