changeset 3988:090fea205d1d

Fixing Delta W/t chart: reference period area can now switched to invisible (#877)
author Christian Lins <christian.lins@intevation.de>
date Sun, 30 Sep 2012 15:32:47 +0200
parents b328da465fe9
children ccac1279eb41
files flys-artifacts/ChangeLog flys-artifacts/src/main/java/de/intevation/flys/exports/fixings/FixDeltaWtGenerator.java
diffstat 2 files changed, 39 insertions(+), 32 deletions(-) [+]
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog	Sun Sep 30 15:12:39 2012 +0200
+++ b/flys-artifacts/ChangeLog	Sun Sep 30 15:32:47 2012 +0200
@@ -1,9 +1,14 @@
 2012-09-30	Christian Lins	<christian.lins@intevation.de>
 
-	* flys-artifacts/src/main/resources/messages.properties,
-	  flys-artifacts/src/main/resources/messages_de.properties,
-	  flys-artifacts/src/main/resources/messages_de_DE.properties,
-	  flys-artifacts/src/main/resources/messages_en.properties:
+	* src/main/java/de/intevation/flys/exports/fixings/FixDeltaWtGenerator.java:
+	  Fixing Delta W/t chart: reference period area can now switched to invisible (#877).
+
+2012-09-30	Christian Lins	<christian.lins@intevation.de>
+
+	* src/main/resources/messages.properties,
+	  src/main/resources/messages_de.properties,
+	  src/main/resources/messages_de_DE.properties,
+	  src/main/resources/messages_en.properties:
 	  Correct i18n for fixation outlier widget (state.fixation.preprocess) (#873).
 
 2012-09-30	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
@@ -28,8 +33,8 @@
 
 2012-09-29	Christian Lins	<christian.lins@intevation.de>
 
-	* flys-artifacts/doc/conf/themes.xml,
-	  flys-artifacts/src/main/java/de/intevation/flys/exports/TimeseriesChartGenerator.java:
+	* doc/conf/themes.xml,
+	  src/main/java/de/intevation/flys/exports/TimeseriesChartGenerator.java:
 	  Manual Points working in Fixing Delta W/t chart (#462).
 
 2012-09-29	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
--- a/flys-artifacts/src/main/java/de/intevation/flys/exports/fixings/FixDeltaWtGenerator.java	Sun Sep 30 15:12:39 2012 +0200
+++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/fixings/FixDeltaWtGenerator.java	Sun Sep 30 15:32:47 2012 +0200
@@ -1,5 +1,22 @@
 package de.intevation.flys.exports.fixings;
 
+import de.intevation.artifactdatabase.state.ArtifactAndFacet;
+import de.intevation.artifacts.CallContext;
+import de.intevation.flys.artifacts.FLYSArtifact;
+import de.intevation.flys.artifacts.access.FixAnalysisAccess;
+import de.intevation.flys.artifacts.model.DateRange;
+import de.intevation.flys.artifacts.model.FacetTypes;
+import de.intevation.flys.artifacts.model.QWDDateRange;
+import de.intevation.flys.artifacts.model.fixings.QWD;
+import de.intevation.flys.artifacts.resources.Resources;
+import de.intevation.flys.exports.TimeseriesChartGenerator;
+import de.intevation.flys.jfree.CollisionFreeXYTextAnnotation;
+import de.intevation.flys.jfree.FLYSAnnotation;
+import de.intevation.flys.jfree.StyledDomainMarker;
+import de.intevation.flys.jfree.StyledTimeSeries;
+import de.intevation.flys.jfree.StyledValueMarker;
+import de.intevation.flys.utils.ThemeUtil;
+
 import java.io.OutputStream;
 import java.text.NumberFormat;
 import java.util.ArrayList;
@@ -17,23 +34,6 @@
 import org.jfree.data.time.TimeSeriesCollection;
 import org.w3c.dom.Document;
 
-import de.intevation.artifactdatabase.state.ArtifactAndFacet;
-import de.intevation.artifacts.CallContext;
-import de.intevation.flys.artifacts.FLYSArtifact;
-import de.intevation.flys.artifacts.access.FixAnalysisAccess;
-import de.intevation.flys.artifacts.model.DateRange;
-import de.intevation.flys.artifacts.model.FacetTypes;
-import de.intevation.flys.artifacts.model.QWDDateRange;
-import de.intevation.flys.artifacts.model.fixings.QWD;
-import de.intevation.flys.artifacts.resources.Resources;
-import de.intevation.flys.exports.TimeseriesChartGenerator;
-import de.intevation.flys.jfree.CollisionFreeXYTextAnnotation;
-import de.intevation.flys.jfree.FLYSAnnotation;
-import de.intevation.flys.jfree.StyledDomainMarker;
-import de.intevation.flys.jfree.StyledTimeSeries;
-import de.intevation.flys.jfree.StyledValueMarker;
-import de.intevation.flys.utils.ThemeUtil;
-
 
 /**
  * Generator for Delta W(t) charts.
@@ -226,16 +226,18 @@
     {
         logger.debug("doReferencePeriodsOut()");
 
-        FixAnalysisAccess access = new FixAnalysisAccess(artifact);
-        DateRange refRange  = access.getReferencePeriod();
+        if (visible) {
+            FixAnalysisAccess access = new FixAnalysisAccess(artifact);
+            DateRange refRange  = access.getReferencePeriod();
 
-        RegularTimePeriod start = new Day(refRange.getFrom());
-        RegularTimePeriod end = new Day(refRange.getTo());
-        StyledDomainMarker marker = new StyledDomainMarker(
-                start.getMiddleMillisecond(),
-                end.getMiddleMillisecond(),
-                theme);
-        domainMarker.add(marker);
+            RegularTimePeriod start = new Day(refRange.getFrom());
+            RegularTimePeriod end = new Day(refRange.getTo());
+            StyledDomainMarker marker = new StyledDomainMarker(
+                    start.getMiddleMillisecond(),
+                    end.getMiddleMillisecond(),
+                    theme);
+            domainMarker.add(marker);
+        }
     }
 
 

http://dive4elements.wald.intevation.org