# HG changeset patch # User Felix Wolfsteller # Date 1372322741 -7200 # Node ID cce8c5f59053d94ca53f08836fe455f915156b52 # Parent 5de3388c59788860d756f50b32b137017e85bee9 ExtremeWQCurveGenerator: Fix axis labels. diff -r 5de3388c5978 -r cce8c5f59053 artifacts/src/main/java/org/dive4elements/river/exports/extreme/ExtremeWQCurveGenerator.java --- a/artifacts/src/main/java/org/dive4elements/river/exports/extreme/ExtremeWQCurveGenerator.java Thu Jun 27 10:44:59 2013 +0200 +++ b/artifacts/src/main/java/org/dive4elements/river/exports/extreme/ExtremeWQCurveGenerator.java Thu Jun 27 10:45:41 2013 +0200 @@ -200,7 +200,13 @@ @Override protected String getDefaultYAxisLabel(int pos) { - return msg(I18N_YAXIS_LABEL, I18N_YAXIS_LABEL_DEFAULT); + D4EArtifact flys = (D4EArtifact) master; + + String unit = RiverUtils.getRiver(flys).getWstUnit().getName(); + if (pos == 0 && getCurrentGaugeDatum() != 0) + unit = "cm"; + + return msg(I18N_YAXIS_LABEL, I18N_YAXIS_LABEL_DEFAULT, new Object[] { unit }); } } // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :