[Dive4elements-commits] [PATCH 2 of 2] flys1225/4: Absolute height axis label with wstunits
Wald Commits
scm-commit at wald.intevation.org
Tue May 28 17:46:06 CEST 2013
# HG changeset patch
# User Felix Wolfsteller <felix.wolfsteller at intevation.de>
# Date 1369756457 -7200
# Node ID 036b02fc0c81eda435713df91c5e6482822c186c
# Parent d83f1e7b66815fc66aca954f65a8f41faf618b0f
flys1225/4: Absolute height axis label with wstunits.
diff -r d83f1e7b6681 -r 036b02fc0c81 artifacts/src/main/java/org/dive4elements/river/exports/minfo/BedDiffHeightYearGenerator.java
--- a/artifacts/src/main/java/org/dive4elements/river/exports/minfo/BedDiffHeightYearGenerator.java Tue May 28 17:53:27 2013 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/exports/minfo/BedDiffHeightYearGenerator.java Tue May 28 17:54:17 2013 +0200
@@ -148,7 +148,9 @@
@Override
protected String getDefaultXAxisLabel() {
- return msg(I18N_XAXIS_LABEL, I18N_XAXIS_LABEL_DEFAULT);
+ return msg(I18N_XAXIS_LABEL,
+ I18N_XAXIS_LABEL_DEFAULT,
+ new Object[] { getRiverName() });
}
@Override
diff -r d83f1e7b6681 -r 036b02fc0c81 artifacts/src/main/java/org/dive4elements/river/exports/minfo/BedDifferenceEpochGenerator.java
--- a/artifacts/src/main/java/org/dive4elements/river/exports/minfo/BedDifferenceEpochGenerator.java Tue May 28 17:53:27 2013 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/exports/minfo/BedDifferenceEpochGenerator.java Tue May 28 17:54:17 2013 +0200
@@ -29,6 +29,7 @@
import org.dive4elements.river.jfree.RiverAnnotation;
import org.dive4elements.river.jfree.StyledXYSeries;
import org.dive4elements.river.utils.DataUtil;
+import org.dive4elements.river.utils.RiverUtils;
public class BedDifferenceEpochGenerator
@@ -196,7 +197,11 @@
label = msg(I18N_YAXIS_LABEL, I18N_YAXIS_LABEL_DEFAULT);
}
else if (pos == YAXIS.H.idx) {
- label = msg(I18N_SECOND_YAXIS_LABEL, I18N_SECOND_YAXIS_LABEL_DEFAULT);
+ D4EArtifact flys = (D4EArtifact) master;
+ label = msg(I18N_SECOND_YAXIS_LABEL,
+ I18N_SECOND_YAXIS_LABEL_DEFAULT,
+ new Object[]
+ { RiverUtils.getRiver(flys).getWstUnit().getName() });
}
else if (pos == YAXIS.dW.idx) {
return msg(I18N_DW_YAXIS_LABEL, I18N_DW_YAXIS_LABEL_DEFAULT);
diff -r d83f1e7b6681 -r 036b02fc0c81 artifacts/src/main/java/org/dive4elements/river/exports/minfo/BedDifferenceYearGenerator.java
--- a/artifacts/src/main/java/org/dive4elements/river/exports/minfo/BedDifferenceYearGenerator.java Tue May 28 17:53:27 2013 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/exports/minfo/BedDifferenceYearGenerator.java Tue May 28 17:54:17 2013 +0200
@@ -14,6 +14,7 @@
import org.dive4elements.artifactdatabase.state.ArtifactAndFacet;
import org.dive4elements.artifactdatabase.state.Facet;
+import org.dive4elements.river.artifacts.D4EArtifact;
import org.dive4elements.river.artifacts.model.FacetTypes;
import org.dive4elements.river.artifacts.model.WKms;
import org.dive4elements.river.artifacts.model.minfo.BedDiffYearResult;
@@ -29,6 +30,7 @@
import org.dive4elements.river.jfree.RiverAnnotation;
import org.dive4elements.river.jfree.StyledXYSeries;
import org.dive4elements.river.utils.DataUtil;
+import org.dive4elements.river.utils.RiverUtils;
public class BedDifferenceYearGenerator
@@ -247,7 +249,11 @@
label = msg(I18N_SECOND_YAXIS_LABEL, I18N_SECOND_YAXIS_LABEL_DEFAULT);
}
else if (pos == YAXIS.H.idx) {
- label = msg(I18N_THIRD_YAXIS_LABEL, I18N_THIRD_YAXIS_LABEL_DEFAULT);
+ D4EArtifact flys = (D4EArtifact) master;
+ label = msg(I18N_THIRD_YAXIS_LABEL,
+ I18N_THIRD_YAXIS_LABEL_DEFAULT,
+ new Object[]
+ { RiverUtils.getRiver(flys).getWstUnit().getName() });
}
else if (pos == YAXIS.dW.idx) {
label = msg(I18N_DW_YAXIS_LABEL, I18N_DW_YAXIS_LABEL_DEFAULT);
More information about the Dive4elements-commits
mailing list