diff flys-client/src/main/java/de/intevation/flys/client/client/ui/StyleEditorWindow.java @ 1326:974c6b3700de

Use the theme index to identify the correct style. flys-client/trunk@2968 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Raimund Renkert <raimund.renkert@intevation.de>
date Fri, 14 Oct 2011 08:36:29 +0000
parents a95e82d6bcc1
children 1627a28c4504
line wrap: on
line diff
--- a/flys-client/src/main/java/de/intevation/flys/client/client/ui/StyleEditorWindow.java	Thu Oct 13 16:30:55 2011 +0000
+++ b/flys-client/src/main/java/de/intevation/flys/client/client/ui/StyleEditorWindow.java	Fri Oct 14 08:36:29 2011 +0000
@@ -26,6 +26,7 @@
 import de.intevation.flys.client.shared.model.Style;
 import de.intevation.flys.client.shared.model.StyleSetting;
 import de.intevation.flys.client.shared.model.FacetRecord;
+import de.intevation.flys.client.shared.model.Theme;
 
 import de.intevation.flys.client.client.services.CollectionItemAttributeServiceAsync;
 import de.intevation.flys.client.client.services.CollectionItemAttributeService;
@@ -127,7 +128,8 @@
     protected VLayout createPropertyGrid() {
         VLayout properties = new VLayout();
 
-        Style s = attributes.getStyle(facet.getTheme().getFacet());
+        Theme t = facet.getTheme();
+        Style s = attributes.getStyle(t.getFacet(), t.getIndex());
 
         TextItem name = new TextItem("name", "Name");
         name.setValue(facet.getName());
@@ -265,7 +267,8 @@
     }
 
     protected final void setNewValue(String name, String value) {
-        Style s = attributes.getStyle(facet.getTheme().getFacet());
+        Theme t = facet.getTheme();
+        Style s = attributes.getStyle(t.getFacet(), t.getIndex());
         StyleSetting set = s.getSetting(name);
         if(name.equals("linecolor")) {
             value = htmlToRgb(value);

http://dive4elements.wald.intevation.org