diff flys-client/src/main/java/de/intevation/flys/client/client/ui/chart/ChartThemePanel.java @ 2442:49ca36baf4ab

Fix issue621 (areas against removed themes). flys-client/trunk@4110 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Fri, 02 Mar 2012 10:26:08 +0000
parents 64e3d4b024b1
children f9a7a5ae914c
line wrap: on
line diff
--- a/flys-client/src/main/java/de/intevation/flys/client/client/ui/chart/ChartThemePanel.java	Thu Mar 01 15:33:29 2012 +0000
+++ b/flys-client/src/main/java/de/intevation/flys/client/client/ui/chart/ChartThemePanel.java	Fri Mar 02 10:26:08 2012 +0000
@@ -348,9 +348,15 @@
         Menu underMenu = new Menu();
         for (int i = 0; i < nThemes; i++)  {
             final Theme theme = themes.getThemeAt(i+1);
+
+            if (theme.getVisible() == 0) {
+                continue;
+            }
+
             if (!areAreaCompatible(facetTheme, theme)) {
                 continue;
             }
+
             MenuItem againster = new MenuItem(theme.getDescription());
             underMenu.addItem(againster);
 
@@ -367,6 +373,9 @@
         Menu overMenu = new Menu();
         for (int i = 0; i < nThemes; i++)  {
             final Theme theme = themes.getThemeAt(i+1);
+            if (theme.getVisible() == 0) {
+                continue;
+            }
             if (!areAreaCompatible(facetTheme, theme)) {
                 continue;
             }
@@ -395,6 +404,9 @@
         Menu betweenMenu = new Menu();
         for (int i = 0; i < nThemes; i++)  {
             final Theme theme = themes.getThemeAt(i+1);
+            if (theme.getVisible() == 0) {
+                continue;
+            }
             if (!areAreaCompatible(facetTheme, theme)) {
                 continue;
             }

http://dive4elements.wald.intevation.org