Mercurial > dive4elements > river
changeset 2772:5e8e42a36a90
Minor refactoring.
flys-artifacts/trunk@4511 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Felix Wolfsteller <felix.wolfsteller@intevation.de> |
---|---|
date | Fri, 25 May 2012 07:49:11 +0000 |
parents | e22469664c20 |
children | ea03f26a7d50 |
files | flys-artifacts/ChangeLog flys-artifacts/src/main/java/de/intevation/flys/exports/CrossSectionGenerator.java flys-artifacts/src/main/java/de/intevation/flys/exports/XYChartGenerator.java |
diffstat | 3 files changed, 16 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog Fri May 25 07:32:18 2012 +0000 +++ b/flys-artifacts/ChangeLog Fri May 25 07:49:11 2012 +0000 @@ -1,4 +1,12 @@ -2012-05-24 Raimund Renkert <raimund.renkert@intevation.de> +2012-05-25 Felix Wolfsteller <felix.wolfsteller@intevation.de> + + * src/main/java/de/intevation/flys/exports/XYChartGenerator.java: + Moved parameter of addAnnotations out, renamed to addVisibleAnnotation. + + * src/main/java/de/intevation/flys/exports/CrossSectionGenerator.java: + Adjusted. + +2012-05-25 Raimund Renkert <raimund.renkert@intevation.de> * doc/conf/themes.xml: Added concrete themes for areas.
--- a/flys-artifacts/src/main/java/de/intevation/flys/exports/CrossSectionGenerator.java Fri May 25 07:32:18 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/CrossSectionGenerator.java Fri May 25 07:49:11 2012 +0000 @@ -258,7 +258,9 @@ } // Actual Styling is done in XYChartGenerator. - addAnnotations(new FLYSAnnotation(seriesName, null, zones, theme), visible); + if (visible) { + addVisibleAnnotations(new FLYSAnnotation(seriesName, null, zones, theme)); + } }
--- a/flys-artifacts/src/main/java/de/intevation/flys/exports/XYChartGenerator.java Fri May 25 07:32:18 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/XYChartGenerator.java Fri May 25 07:49:11 2012 +0000 @@ -413,11 +413,7 @@ /** * Adds annotations to list (if visible is true). */ - public void addAnnotations(FLYSAnnotation annotation, boolean visible) { - if (!visible) { - return; - } - + public void addVisibleAnnotations(FLYSAnnotation annotation) { if (annotations == null) { annotations = new ArrayList<FLYSAnnotation>(); } @@ -1024,7 +1020,9 @@ "This should never happen!"); } - addAnnotations(annotations, visible); + if (visible) { + addVisibleAnnotations(annotations); + } }