[PATCH] DistancePanel Berechnungsstrecke->Darstellungsbereich Refactoring

Wald Commits scm-commit at wald.intevation.org
Mon Jun 25 17:58:25 CEST 2018


# HG changeset patch
# User gernotbelger
# Date 1529942291 -7200
# Node ID 34dc0163ad2d3d1829a38be51cd6c6f506081576
# Parent  06bb3e94a927275f9401e7a16674d49d1a0fc2a8
DistancePanel Berechnungsstrecke->Darstellungsbereich Refactoring

diff -r 06bb3e94a927 -r 34dc0163ad2d artifacts/doc/conf/artifacts/uinfo.xml
--- a/artifacts/doc/conf/artifacts/uinfo.xml	Mon Jun 25 16:07:41 2018 +0200
+++ b/artifacts/doc/conf/artifacts/uinfo.xml	Mon Jun 25 17:58:11 2018 +0200
@@ -19,6 +19,12 @@
       <data name="ld_from" type="Double" />
       <data name="ld_to" type="Double" />
     </state>
+
+    <state id="state.uinfo.inundationduration.distance_only" description="state.uinfo.inundationduration.distance_only" state="org.dive4elements.river.artifacts.states.DistanceOnlyInundationDurSelect" helpText="help.state.uinfo.distance_only">
+      <data name="ld_from" type="Double" />
+      <data name="ld_to" type="Double" />
+    </state>
+
     <state id="state.uinfo.distance" description="state.uinfo.distance" state="org.dive4elements.river.artifacts.states.DistanceSelect" helpText="help.state.uinfo.distance_only">
       <data name="ld_from" type="Double" />
       <data name="ld_to" type="Double" />
@@ -113,12 +119,12 @@
 
     <transition transition="org.dive4elements.river.artifacts.transitions.ValueCompareTransition">
       <from state="state.uinfo.calculation_mode" />
-      <to state="state.uinfo.distance_only" />
+      <to state="state.uinfo.inundationduration.distance_only" />
       <condition data="calculation_mode" value="uinfo_inundation_duration" operator="equal" />
     </transition>
 
     <transition transition="org.dive4elements.river.artifacts.transitions.ValueCompareTransition">
-      <from state="state.uinfo.distance_only" />
+      <from state="state.uinfo.inundationduration.distance_only" />
       <to state="state.uinfo.year_totalepoch" />
       <condition data="calculation_mode" value="uinfo_inundation_duration" operator="equal" />
     </transition>
@@ -145,7 +151,7 @@
     <state id="state.uinfo.load.year" description="state.uinfo.load.year" state="org.dive4elements.river.artifacts.states.LoadSingleYearSelectState" helpText="help.state.uinfo.load.year">
       <data name="singleyear" type="String" />
     </state>
-  
+
 
     <transition transition="org.dive4elements.river.artifacts.transitions.ValueCompareTransition">
       <from state="state.uinfo.load.year" />
diff -r 06bb3e94a927 -r 34dc0163ad2d artifacts/src/main/java/org/dive4elements/river/artifacts/states/ComputationRangeState.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/states/ComputationRangeState.java	Mon Jun 25 16:07:41 2018 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/states/ComputationRangeState.java	Mon Jun 25 17:58:11 2018 +0200
@@ -40,7 +40,9 @@
 
         final Element label = ProtocolUtils.createArtNode(cr, "label", null, null);
 
-        label.setTextContent(Resources.getMsg(context.getMeta(), getID(), getID()));
+        final String msg = getTitle(context);
+
+        label.setTextContent(msg);
         // VORHER: data.getName(), data.getName())) (entsprach "ld_from", "ld_to" - unterschied zu jetzt: description wird
         // anders gesetzt ("Wahl der Berechnungsstrecke")
         // label bleibt "ld_from", "ld_to"; unklar, wo das gesetzt wird. unklar, warum das Element "label" die Description
@@ -54,6 +56,16 @@
         return select;
     }
 
+    // REMARK: allows to overwrite the titel which is shown on the client side.
+    // TODO: instead of a fixed string, we should translate the 'id', but in that case we need to change all old workflows
+    // (reason is, that we have different texts for the title and the 'old' title, which in turn is the translation of
+    // 'description').
+
+    protected String getTitle(final CallContext context) {
+        // REMARK: that is how it should be: return Resources.getMsg(context.getMeta(), getID());
+        return Resources.getMsg(context.getMeta(), "state.title.distance_state");
+    }
+
     @Override
     protected Element[] createItems(final XMLUtils.ElementCreator cr, final Artifact artifact, final String name, final CallContext context) {
         final double[] minmax = getMinMax(artifact);
diff -r 06bb3e94a927 -r 34dc0163ad2d artifacts/src/main/java/org/dive4elements/river/artifacts/states/DistanceOnlyPartSelect.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/states/DistanceOnlyPartSelect.java	Mon Jun 25 16:07:41 2018 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/states/DistanceOnlyPartSelect.java	Mon Jun 25 17:58:11 2018 +0200
@@ -9,6 +9,8 @@
 package org.dive4elements.river.artifacts.states;
 
 import org.apache.log4j.Logger;
+import org.dive4elements.artifacts.CallContext;
+import org.dive4elements.river.artifacts.resources.Resources;
 
 public class DistanceOnlyPartSelect extends DistanceOnlySelect {
 
@@ -19,4 +21,10 @@
         return "distance_only_part_panel";
     }
 
+    @Override
+    protected String getTitle(final CallContext context) {
+        // REMARK: that is how it should be: return Resources.getMsg(context.getMeta(), getID());
+        return Resources.getMsg(context.getMeta(), "state.title.distance_part_state");
+    }
+
 }
diff -r 06bb3e94a927 -r 34dc0163ad2d artifacts/src/main/java/org/dive4elements/river/artifacts/states/LocationDistanceSelect.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/states/LocationDistanceSelect.java	Mon Jun 25 16:07:41 2018 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/states/LocationDistanceSelect.java	Mon Jun 25 17:58:11 2018 +0200
@@ -9,23 +9,18 @@
 package org.dive4elements.river.artifacts.states;
 
 import org.apache.log4j.Logger;
-
+import org.dive4elements.artifactdatabase.data.StateData;
 import org.dive4elements.artifacts.Artifact;
-
-import org.dive4elements.artifactdatabase.data.StateData;
-
+import org.dive4elements.artifacts.CallContext;
 import org.dive4elements.river.artifacts.D4EArtifact;
 import org.dive4elements.river.artifacts.WINFOArtifact;
-
 import org.dive4elements.river.artifacts.access.RangeAccess;
-
+import org.dive4elements.river.artifacts.resources.Resources;
 
 /**
  * @author <a href="mailto:ingo.weinzierl at intevation.de">Ingo Weinzierl</a>
  */
-public class LocationDistanceSelect
-extends      ComputationRangeState
-{
+public class LocationDistanceSelect extends ComputationRangeState {
 
     /** The log used in this class. */
     private static Logger log = Logger.getLogger(LocationDistanceSelect.class);
@@ -36,55 +31,46 @@
     /** The name of the 'locations' field. */
     public static final String LOCATIONS = "ld_locations";
 
-
     /**
      * The default constructor that initializes an empty State object.
      */
     public LocationDistanceSelect() {
     }
 
-
     @Override
     protected String getUIProvider() {
         return "location_distance_panel";
     }
 
-
     /** Validates the range (or location). */
     @Override
-    public boolean validate(Artifact artifact)
-    throws IllegalArgumentException
-    {
+    public boolean validate(final Artifact artifact) throws IllegalArgumentException {
         log.debug("LocationDistanceSelect.validate");
 
-        D4EArtifact flys = (D4EArtifact)artifact;
-        StateData mode = getData(flys, MODE);
-        String mValue = mode != null ? (String)mode.getValue() : null;
+        final D4EArtifact flys = (D4EArtifact) artifact;
+        final StateData mode = getData(flys, MODE);
+        final String mValue = mode != null ? (String) mode.getValue() : null;
         if (mValue != null) {
             if (mValue.equals("distance")) {
                 return super.validate(flys);
-            }
-            else {
+            } else {
                 return validateLocations(flys);
             }
         }
         return false;
     }
 
-
     /** Validate selected locations. */
-    protected boolean validateLocations(D4EArtifact flys)
-    throws    IllegalArgumentException
-    {
-        StateData dValues = getData(flys, LOCATIONS);
-        String    values  = dValues != null ? (String)dValues.getValue() : null;
+    protected boolean validateLocations(final D4EArtifact flys) throws IllegalArgumentException {
+        final StateData dValues = getData(flys, LOCATIONS);
+        final String values = dValues != null ? (String) dValues.getValue() : null;
 
         if (values == null || values.length() == 0) {
             throw new IllegalArgumentException("error_empty_state");
         }
 
-        double[] absMinMax = getMinMax(flys);
-        double[] relMinMax = getMinMaxFromString(values);
+        final double[] absMinMax = getMinMax(flys);
+        final double[] relMinMax = getMinMaxFromString(values);
 
         if (relMinMax[0] < absMinMax[0] || relMinMax[0] > absMinMax[1]) {
             throw new IllegalArgumentException("error_feed_from_out_of_range");
@@ -97,45 +83,46 @@
         return true;
     }
 
-
     /**
      * Extracts the min/max values from String <i>s</i>. An
      * IllegalArgumentException is thrown if there is a value that throws a
      * NumberFormatException.
      *
-     * @param s String that contains whitespace separated double values.
+     * @param s
+     *            String that contains whitespace separated double values.
      *
      * @return a 2dmin array [min,max].
      */
-    public static double[] getMinMaxFromString(String s)
-    throws IllegalArgumentException
-    {
-        String[] values = s.split(" ");
+    public static double[] getMinMaxFromString(final String s) throws IllegalArgumentException {
+        final String[] values = s.split(" ");
 
-        double[] minmax = new double[] {
-            Double.MAX_VALUE,
-            -Double.MAX_VALUE };
+        final double[] minmax = new double[] { Double.MAX_VALUE, -Double.MAX_VALUE };
 
-        for (String v: values) {
+        for (final String v : values) {
             try {
-                double value = Double.valueOf(v);
+                final double value = Double.valueOf(v);
 
                 minmax[0] = minmax[0] < value ? minmax[0] : value;
                 minmax[1] = minmax[1] > value ? minmax[1] : value;
             }
-            catch (NumberFormatException nfe) {
-                throw new IllegalArgumentException(
-                    "error_invalid_double_value");
+            catch (final NumberFormatException nfe) {
+                throw new IllegalArgumentException("error_invalid_double_value");
             }
         }
 
         return minmax;
     }
 
-
-    public static double[] getLocations(WINFOArtifact flys) {
-        RangeAccess ra = new RangeAccess(flys);
+    public static double[] getLocations(final WINFOArtifact flys) {
+        final RangeAccess ra = new RangeAccess(flys);
         return ra.getLocations();
     }
+
+    @Override
+    protected String getTitle(final CallContext context) {
+        // REMARK: that is how it should be: return Resources.getMsg(context.getMeta(), getID());
+        return Resources.getMsg(context.getMeta(), "state.title.location_distance_state");
+    }
+
 }
 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf-8 :
diff -r 06bb3e94a927 -r 34dc0163ad2d artifacts/src/main/java/org/dive4elements/river/artifacts/states/minfo/SedimentLoadDistanceSelect.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/states/minfo/SedimentLoadDistanceSelect.java	Mon Jun 25 16:07:41 2018 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/states/minfo/SedimentLoadDistanceSelect.java	Mon Jun 25 17:58:11 2018 +0200
@@ -10,12 +10,12 @@
 
 import org.dive4elements.river.artifacts.states.DistanceOnlySelect;
 
-
-public class SedimentLoadDistanceSelect
-extends DistanceOnlySelect
-{
+public class SedimentLoadDistanceSelect extends DistanceOnlySelect {
     @Override
     protected String getUIProvider() {
         return "minfo.sedimentload_distance_select";
     }
+
+    // title müsste distance_state sein; schon in CompuatationRange
+
 }
diff -r 06bb3e94a927 -r 34dc0163ad2d artifacts/src/main/resources/messages.properties
--- a/artifacts/src/main/resources/messages.properties	Mon Jun 25 16:07:41 2018 +0200
+++ b/artifacts/src/main/resources/messages.properties	Mon Jun 25 17:58:11 2018 +0200
@@ -1067,7 +1067,8 @@
 state.uinfo.distance_only_part = Teilabschnitt
 help.state.uinfo.distance_only_part = ${help.url}/OnlineHilfe/SINFO#help.state.sinfo.distance_only_part 
 
-state.uinfo.distance_only = Wahl des Darstellungsbereichs
+state.uinfo.distance_only = Choose calculation range [km]
+state.uinfo.inundationduration.distance_only = Wahl des Darstellungsbereichs
 help.state.uinfo.distance_only = ${help.url}/OnlineHilfe/UINFO#help.state.uinfo.distance_only
 uinfo_salix_line = Salix-Linie
 uinfo_inundation_duration = \u00dcberflutungsdauern Aue
@@ -1165,4 +1166,9 @@
 common.client.ui.from = from
 common.client.ui.to = to
 
-chart.subtitle.metadata = FLYS-Version: {0} - Bearbeiter: {1} - Datum der Erstellung: {2}
\ No newline at end of file
+chart.subtitle.metadata = FLYS-Version: {0} - Bearbeiter: {1} - Datum der Erstellung: {2}
+
+state.title.distance_state = Choose calculation range [km]
+state.title.location_distance_state = Choose calculation location(s) / range [km] 
+state.title.distance_part_state = Choose calculation subregion [km] 
+state.title.distance_only_inundationduration_state = Darstellungsbereich w\u00e4hlen [km]
\ No newline at end of file
diff -r 06bb3e94a927 -r 34dc0163ad2d artifacts/src/main/resources/messages_de.properties
--- a/artifacts/src/main/resources/messages_de.properties	Mon Jun 25 16:07:41 2018 +0200
+++ b/artifacts/src/main/resources/messages_de.properties	Mon Jun 25 17:58:11 2018 +0200
@@ -1067,7 +1067,8 @@
 state.uinfo.distance_only_part = Teilabschnitt
 help.state.uinfo.distance_only_part = ${help.url}/OnlineHilfe/SINFO#help.state.sinfo.distance_only_part 
 
-state.uinfo.distance_only = Wahl des Darstellungsbereichs
+state.uinfo.distance_only = Wahl der Berechnungsstrecke
+state.uinfo.inundationduration.distance_only = Wahl des Darstellungsbereichs
 help.state.uinfo.distance_only = ${help.url}/OnlineHilfe/SINFO#help.state.sinfo.distance_only
 uinfo_salix_line = Salix-Linie
 uinfo_inundation_duration = \u00dcberflutungsdauern Aue
@@ -1165,4 +1166,9 @@
 common.client.ui.from = von
 common.client.ui.to = bis
 
-chart.subtitle.metadata = FLYS-Version: {0} - Bearbeiter: {1} - Datum der Erstellung: {2}
\ No newline at end of file
+chart.subtitle.metadata = FLYS-Version: {0} - Bearbeiter: {1} - Datum der Erstellung: {2}
+
+state.title.distance_state = Berechnungsstrecke w\u00e4hlen [km]
+state.title.location_distance_state = Berechnungsort(e) / strecke w\u00e4hlen [km] 
+state.title.distance_part_state = Teilstrecke w\u00e4hlen [km] 
+state.title.distance_only_inundationduration_state = Darstellungsbereich w\u00e4hlen [km]
\ No newline at end of file
diff -r 06bb3e94a927 -r 34dc0163ad2d gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.java
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.java	Mon Jun 25 16:07:41 2018 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.java	Mon Jun 25 17:58:11 2018 +0200
@@ -175,1371 +175,1365 @@
 
     String uesk_profile_distance();
 
-    String location_distance_state();
-
-    String distance_state();
-
-    String distance_part_state();
+    String location();
+
+    String locations();
+
+    String single_location();
+
+    String distance();
+
+    String unitFrom();
+
+    String unitTo();
+
+    String dpLabelFrom();
+
+    String dpUnitFrom();
+
+    String dpLabelTo();
+
+    String dpUnitTo();
+
+    String dpLabelStep();
+
+    String dpUnitStep();
+
+    String wgLabelFrom();
+
+    String wgUnitFrom();
+
+    String wgLabelTo();
+
+    String wgUnitTo();
+
+    String wgLabelStep();
+
+    String wgUnitStep();
+
+    String unitWidth();
+
+    String unitFromInM();
+
+    String unitToInM();
+
+    String unitDiffInM();
+
+    String unitLocation();
+
+    String wrongFormat();
+
+    String toShouldNotBeNegative();
+
+    String atLeastOneValue();
+
+    String missingInput();
+
+    String too_many_values();
+
+    String from();
+
+    String to();
+
+    String riverside();
+
+    String calcTableTitle();
+
+    String helperPanelTitle();
+
+    String gaugePanelTitle();
+
+    String measurementStationPanelTitle();
+
+    String wqTitle();
+
+    String wqadaptedTitle();
+
+    String noMainValueAtGauge();
+
+    String wqHistorical();
+
+    String unitWNN();
+
+    String wqWFree();
+
+    String wqW();
+
+    String wqQ();
+
+    String wqQatGauge();
+
+    String wqQGauge();
+
+    String wqSingle();
+
+    String wqRange();
+
+    String unitWSingle();
+
+    String unitWFree();
+
+    String unitWFrom();
+
+    String unitWTo();
+
+    String unitWStep();
+
+    String unitQSingle();
+
+    String unitQFrom();
+
+    String unitQTo();
+
+    String unitQStep();
+
+    String main_channel();
+
+    String total_channel();
+
+    String footerHome();
+
+    String footerContact();
+
+    String footerImpressum();
+
+    String projectListMin();
+
+    String projectListAdd();
+
+    String buttonNext();
+
+    String imageBack();
+
+    String imageSave();
+
+    String search();
+
+    String properties();
+
+    String activateTheme();
+
+    String deactivateTheme();
+
+    String removeTheme();
+
+    String manageThemes();
+
+    String label_ok();
+
+    String label_cancel();
+
+    String cancelCalculationLabel();
+
+    String calculationCanceled();
+
+    String flysLogo();
+
+    String bfgLogo();
+
+    String bfgLogoSmall();
+
+    String downloadPNG();
+
+    String downloadPDF();
+
+    String downloadSVG();
+
+    String downloadCSV();
+
+    String downloadAT();
+
+    String downloadWST();
+
+    String loadingImg();
+
+    String cancelCalculation();
+
+    String markerRed();
+
+    String markerGreen();
+
+    String riverMap();
+
+    String range();
+
+    String description();
+
+    String resultCount();
+
+    String bfg_id();
+
+    String start_year();
+
+    String end_year();
+
+    String period();
+
+    String gauge_class();
+
+    String eventselect();
+
+    String events();
+
+    String kmchart();
+
+    String addPointsTooltip();
+
+    String addWSPTooltip();
+
+    String downloadPNGTooltip();
+
+    String downloadPDFTooltip();
+
+    String downloadSVGTooltip();
+
+    String downloadCSVTooltip();
+
+    String zoomToMaxExtentTooltip();
+
+    String zoomOutTooltip();
+
+    String historyBackTooltip();
+
+    String panControlTooltip();
+
+    String zoomboxTooltip();
+
+    String chartPropertiesTooltip();
+
+    String year();
+
+    String sedimentload_ls();
+
+    // Gauges
+
+    String gauge_mnq();
+
+    String gauge_mq();
+
+    String gauge_mhq();
+
+    String gauge_hq5();
+
+    // Elevation window
+
+    String ele_window_title();
+
+    String ele_window_label();
+
+    String ele_window_x_col();
+
+    String ele_window_y_col();
+
+    String ele_window_z_col();
+
+    String ele_window_ok_button();
+
+    String ele_window_cancel_button();
+
+    String ele_window_format_error();
+
+    String ele_window_save_error();
+
+    String ele_window_geometry_error();
+
+    // OUTPUT TYPES
+
+    String discharge_curve_gaugeless();
+
+    String discharge_curve();
+
+    String gauge_discharge_curve();
+
+    String computed_discharge_curve();
+
+    String computed_discharge_curves();
+
+    String longitudinal_section();
+
+    String duration_curve();
+
+    String reference_curve();
+
+    String reference_curves();
+
+    String reference_curve_normalized();
+
+    String reference_endpoint();
+
+    String reference_startpoint();
+
+    String name();
+
+    String type();
+
+    String starttime();
+
+    String stoptime();
+
+    String wq_table_w();
+
+    String wq_waterlevel_label();
+
+    String wq_table_q();
+
+    String wq_value_w();
+
+    String wq_value_q();
+
+    String discharge_longitudinal_section();
+
+    String floodmap();
+
+    String cross_section();
+
+    String cross_sections();
+
+    String w_differences();
+
+    String historical_discharge();
+
+    String historical_discharge_wq();
+
+    String extreme_wq_curve();
+
+    String showextramark();
+
+    String fix_wq_curve();
+
+    String fix_deltawt_curve();
+
+    String fix_longitudinal_section_curve();
+
+    String fix_derivate_curve();
+
+    String fix_vollmer_wq_curve();
+
+    // EXPORTS
+
+    String waterlevel_export();
+
+    String waterlevel_report();
+
+    String computed_dischargecurve_at_export();
+
+    String discharge_longitudinal_section_export();
+
+    String discharge_longitudinal_section_report();
+
+    String computed_dischargecurve_export();
+
+    String computed_dischargecurve_report();
+
+    String durationcurve_export();
+
+    String durationcurve_report();
+
+    String dataexport();
+
+    String reference_curve_export();
+
+    String w_differences_export();
+
+    String historical_discharge_export();
+
+    String csv();
+
+    String wst();
+
+    String at();
+
+    String pdf();
+
+    String chart_themepanel_header_themes();
+
+    String chart_themepanel_header_actions();
+
+    String chart_themepanel_synchron();
+
+    String chart_themepanel_asynchron();
+
+    String chart_themepanel_set_master();
+
+    String chart_themepanel_new_area();
+
+    String chart_themepanel_area_under();
+
+    String chart_themepanel_area_over();
+
+    String chart_themepanel_area_between();
+
+    String against_x_axis();
+
+    String discharge();
+
+    String flow_velocity();
+
+    String flow_velocities();
+
+    String flow_velocity_export();
+
+    String bedheight_middle();
+
+    String bedheight_middle_export();
+
+    String bed_longitudinal_section();
+
+    String bed_longitudinal_section_export();
+
+    String sq_relation_a();
+
+    String sq_relation_b();
+
+    String sq_relation_c();
+
+    String sq_relation_d();
+
+    String sq_relation_e();
+
+    String sq_relation_f();
+
+    String sq_relation_g();
+
+    String sq_relation_export();
+
+    String sq_relations();
+
+    String exportATTooltip();
+
+    String load_diameter();
+
+    String bed_diameter();
+
+    String soundings();
+
+    String soundings_width();
+
+    String porosities();
+
+    String bed_difference_year();
+
+    String bed_difference_epoch();
+
+    String bed_difference_height_year();
+
+    String bedheight_difference_export();
+
+    String fix_waterlevel_export();
+
+    // ERRORS
+
+    String error_years_wrong();
+
+    String error_read_minmax_values();
+
+    String error_validate_range();
+
+    String error_validate_date_range();
+
+    String error_validate_date_range_invalid();
+
+    String error_validate_lower_range();
+
+    String error_validate_upper_range();
+
+    String error_validate_positive();
+
+    String error_create_artifact();
+
+    String error_describe_artifact();
+
+    String error_feed_data();
+
+    String error_advance_artifact();
+
+    String error_add_artifact();
+
+    String error_remove_artifact();
+
+    String error_create_collection();
+
+    String error_describe_collection();
+
+    String error_no_rivers_found();
+
+    String error_no_gaugeoverviewinfo_found();
+
+    String error_no_such_user();
+
+    String error_no_users();
+
+    String error_no_waterlevel_pair_selected();
+
+    String error_same_waterlevels_in_pair();
+
+    String error_not_logged_in();
+
+    String error_load_parameterization();
+
+    String error_feed_no_data();
+
+    String error_feed_from_out_of_range();
+
+    String error_feed_to_out_of_range();
+
+    String error_feed_from_bigger_to();
+
+    String error_feed_invalid_wq_mode();
+
+    String error_feed_number_format_float();
+
+    String error_feed_invalid_calculation_mode();
+
+    String error_feed_no_calculation_mode();
+
+    String error_feed_no_such_river();
+
+    String error_feed_no_river_selected();
+
+    String error_feed_no_wq_mode_selected();
+
+    String error_feed_q_values_invalid();
+
+    String error_feed_w_values_invalid();
+
+    String error_no_meta_data_found();
+
+    String error_chart_info_service();
+
+    String error_invalid_double_value();
+
+    String error_load_artifact();
+
+    String error_no_calc_result();
+
+    String error_no_theme_styles_found();
+
+    String error_no_feature_selected();
+
+    String error_no_map_config();
+
+    String error_no_map_output_type();
+
+    String error_no_module_found();
+
+    String warning_use_first_feature();
+
+    String warning_select_two_values();
+
+    String error_no_valid_gfi_url();
+
+    String error_gfi_req_failed();
+
+    String error_gfi_parsing_failed();
+
+    String error_gc_req_failed();
+
+    String error_gc_doc_not_valid();
+
+    String error_malformed_url();
+
+    String error_no_dgm_selected();
+
+    String error_invalid_dgm_selected();
+
+    String error_bad_dgm_range();
+
+    String error_bad_dgm_river();
+
+    String error_dialog_not_valid();
+
+    String error_invalid_date();
+
+    String error_wrong_date();
+
+    String bottom_edge();
+
+    String top_edge();
+
+    String error_same_location();
+
+    String error_contains_same_location();
+
+    String error_update_collection_attribute();
+
+    String error_values_needed();
+
+    // MAP RELATED STRINGS
+
+    String digitize();
+
+    String pipe1();
+
+    String pipe2();
+
+    String ditch();
+
+    String dam();
+
+    String ring_dike();
+
+    String selectFeature();
+
+    String removeFeature();
+
+    String getFeatureInfo();
+
+    String getFeatureInfoTooltip();
+
+    String getFeatureInfoWindowTitle();
+
+    String addWMS();
+
+    String printMapSettings();
+
+    String addWMSTooltip();
+
+    String adjustElevation();
+
+    String adjustElevationTooltip();
+
+    String measureLine();
+
+    String measurePolygon();
+
+    String step();
+
+    String calculationStarted();
+
+    String zoomMaxExtent();
+
+    String zoomIn();
+
+    String zoomOut();
+
+    String zoomLayer();
+
+    String moveMap();
+
+    String digitizeObjects();
+
+    String selectObject();
+
+    String removeObject();
+
+    String measureDistance();
+
+    String measureArea();
+
+    String map_themepanel_header_style();
+
+    String zoomToLayer();
+
+    String requireDGM();
+
+    String upload_file();
+
+    String shape_file_upload();
+
+    // data cage
+
+    String historical_discharges();
+
+    String waterlevels();
+
+    String waterlevels_discharge();
+
+    String waterlevels_fix();
+
+    String waterlevels_fix_vollmer();
+
+    String waterlevels_ls();
+
+    String beddifferences();
+
+    String bedheight_differences();
+
+    String middle_bedheights();
+
+    String vollmer_waterlevels();
+
+    String old_calculations();
+
+    String officiallines();
+
+    String datacageAdd();
+
+    String fixations();
+
+    String flood_protections();
+
+    String columns();
+
+    String basedata();
+
+    String heightmarks();
+
+    String annotation();
+
+    String annotations();
+
+    String all_annotations();
+
+    String flowvelocitymeasurement();
+
+    String flowvelocitymodel();
+
+    String bed_quality();
+
+    String additionals();
+
+    String differences();
+
+    String kilometrage();
+
+    String riveraxis();
+
+    String km();
+
+    String qps();
+
+    String hws();
+
+    String catchments();
+
+    String catchment_wms();
+
+    String floodplain();
+
+    String lines();
+
+    String buildings();
+
+    String fixpoints();
+
+    String uesk();
+
+    String calculations();
+
+    String current();
+
+    String bfg();
+
+    String land();
+
+    String potential();
+
+    String rastermap();
+
+    String background();
+
+    String discharge_tables_chart();
+
+    String discharge_table_nn();
+
+    String discharge_table_gauge();
+
+    String mainvalue();
+
+    String mainvalues();
+
+    String wmainvalue();
+
+    String qmainvalue();
+
+    String show_mainvalues();
+
+    String dems();
+
+    String hydrboundaries();
+
+    String gaugelocations();
+
+    String single();
+
+    String epoch();
+
+    String bedheights();
+
+    String morph_width();
+
+    String datacage();
+
+    String datacage_add_pair();
+
+    String delta_w();
+
+    String delta_w_cm();
+
+    String delta_w_cma();
+
+    String wlevel();
+
+    String sedimentloads();
+
+    String sources_sinks();
+
+    String years();
+
+    String epochs();
+
+    String off_epochs();
+
+    String densities();
+
+    String sediment_load();
+
+    String sediment_load_ls();
+
+    String measurement_stations();
+
+    String coarse();
+
+    String fine_middle();
+
+    String sand();
+
+    String susp_sand();
+
+    String susp_sand_bed();
+
+    String suspended_sediment();
+
+    String total();
+
+    String bed_load();
+
+    String suspended_load();
+
+    // Capabilities Information Panel
+
+    String addwmsInputTitle();
+
+    String addwmsInfoTitle();
+
+    String addwmsLayerTitle();
+
+    String addwmsBack();
+
+    String addwmsContinue();
+
+    String addwmsCancel();
+
+    String addwmsInvalidURL();
+
+    String capabilitiesHint();
+
+    String capabilitiesTitle();
+
+    String capabilitiesURL();
+
+    String capabilitiesAccessConstraints();
+
+    String capabilitiesFees();
+
+    String capabilitiesContactInformation();
+
+    String capabilitiesEmail();
+
+    String capabilitiesPhone();
+
+    String chart();
+
+    String export();
+
+    String width();
+
+    String height();
+
+    String visibility();
+
+    String upper();
+
+    String lower();
+
+    String fixation();
+
+    String font_size();
+
+    String label();
+
+    String subtitle();
+
+    String display_grid();
+
+    String display_logo();
+
+    String logo_placeh();
+
+    String logo_placev();
+
+    String top();
+
+    String bottom();
+
+    String center();
+
+    String left();
+
+    String right();
+
+    String none();
+
+    String notselected();
+
+    String linetype();
+
+    String textstyle();
+
+    String linecolor();
+
+    String showhorizontalline();
+
+    String showverticalline();
+
+    String horizontal();
+
+    String vertical();
+
+    String textcolor();
+
+    String textsize();
+
+    String font();
+
+    String showborder();
+
+    String showpoints();
+
+    String showbackground();
+
+    String textshowbg();
+
+    String backgroundcolor();
+
+    String bandwidthcolor();
+
+    String textbgcolor();
+
+    String textorientation();
+
+    String linesize();
+
+    String pointsize();
+
+    String bandwidth();
+
+    String pointcolor();
+
+    String showlines();
+
+    String showlinelabel();
+
+    String showpointlabel();
+
+    String labelfontsize();
+
+    String labelfontcolor();
+
+    String labelfontface();
+
+    String labelfontstyle();
+
+    String labelbgcolor();
+
+    String labelshowbg();
+
+    String showwidth();
+
+    String showlevel();
+
+    String showminimum();
+
+    String showmaximum();
+
+    String transparent();
+
+    String transparency();
+
+    String showarea();
+
+    String showarealabel();
+
+    String showmiddleheight();
+
+    String fillcolor();
+
+    String wsplgen_cat1();
+
+    String wsplgen_cat2();
+
+    String wsplgen_cat3();
+
+    String wsplgen_cat4();
+
+    String wsplgen_cat5();
+
+    String areabgcolor();
+
+    String areabgpattern();
+
+    String areashowborder();
+
+    String areashowbg();
+
+    String areabordercolor();
+
+    String areatransparency();
+
+    String attribution();
+
+    // Manual Points editor
+
+    String addpoints();
+
+    String pointname();
+
+    String removepoint();
+
+    String newpoint();
+
+    String standby();
+
+    String points();
+
+    String editpoints();
+
+    String manual_date_points_y();
+
+    // Manual WaterLine (WSP) Editor.
+
+    String addWSPButton();
+
+    String addWSP();
+
+    String selection();
+
+    String fix_deltawt_export();
+
+    String select();
+
+    String add_date();
+
+    String fix_parameters_export();
+
+    String fix_parameters();
+
+    String sq_overview();
+
+    // Gauge Overview Info
+
+    String gauge_zero();
+
+    String gauge_q_unit();
+
+    String gauge_info_link();
+
+    String gauge_river_info_link();
+
+    String gauge_river_url();
+
+    String gauge_url();
+
+    String gauge_curve_link();
+
+    String gauge_discharge_curve_at_export();
+
+    // Measurement Station Info
+
+    String measurement_station_type();
+
+    String measurement_station_operator();
+
+    String measurement_station_comment();
+
+    String measurement_station_start_time();
+
+    String measurement_station_url();
+
+    String measurement_station_info_link();
+
+    String measurement_station_gauge_name();
+
+    String discharge_timeranges();
+
+    String discharge_chart();
+
+    String projectlist_close();
+
+    String startcolor();
+
+    String endcolor();
+
+    String numclasses();
+
+    String welcome();
+
+    String welcome_open_or_create();
+
+    String official();
+
+    String inofficial();
+
+    String custom_lines();
+
+    String hws_lines();
+
+    String hws_points();
+
+    String hws_fed_unknown();
+
+    String jetties();
+
+    String route_data();
+
+    String other();
+
+    String axis();
+
+    String bfg_model();
+
+    String federal();
+
+    String areas();
+
+    String sobek_areas();
+
+    String sobek_flooded();
+
+    String measurements();
+
+    String floodmarks();
+
+    String pegel_had_measurement_points();
+
+    String gauge_points();
+
+    String gauge_names();
+
+    String gauge_level();
+
+    String gauge_tendency();
+
+    String printTooltip();
+
+    String print();
+
+    String printWindowTitle();
+
+    String mapfish_data_range();
+
+    String mapfish_data_subtitle();
+
+    String mapfish_data_strech();
+
+    String mapfish_data_institution();
+
+    String mapfish_data_source();
+
+    String mapfish_data_creator();
+
+    String mapfish_data_dateplace();
+
+    String mapfish_data_river();
+
+    String mapTitle();
+
+    String mapSubtitle();
+
+    String mapRange();
+
+    String mapStretch();
+
+    String mapCreator();
+
+    String mapInstitution();
+
+    String mapSource();
+
+    String mapDate();
+
+    String mapLogo();
+
+    String wmsURLMenuItem();
+
+    String wmsURLBoxTitle();
+
+    String requireTheme();
+
+    String PATH();
+
+    String DESCRIPTION();
+
+    String KM();
+
+    String Z();
+
+    String LOCATION();
+
+    String HPGP();
+
+    String DIFF();
+
+    String SOURCE();
+
+    String WATERBODY();
+
+    String FEDSTATE_KM();
+
+    String official_regulation();
+
+    String historical_discharge_curves();
+
+    String current_gauge();
+
+    String suggested_label();
+
+    String negative_values_not_allowed_for_to();
+
+    String analyzed_range();
+
+    String minfo_type();
+
+    String river();
+
+    String ld_locations();
+
+    String gauge_name();
+
+    String reference_gauge();
+
+    String station();
+
+    String station_name();
+
+    String lower_time();
+
+    String upper_time();
+
+    String no_data_for_year();
+
+    String no_data_sediment_difference();
+
+    String error_no_sedimentloadinfo_found();
+
+    String error_no_sedimentloadinfo_data();
+
+    String sinfo();
+
+    String sinfo_flowdepth_export();
+
+    String sinfo_flowdepth_report();
+
+    String sinfo_flow_depth();
+
+    String sinfo_flowdepth_twinpanel_no_pair_selected();
+
+    String sinfo_flow_depths();
+
+    String sinfo_flow_depths_minmax();
+
+    String sinfo_flow_depth_minmax();
+
+    String sinfo_flow_depth_developments();
+
+    String sinfo_flow_depth_development();
+
+    String sinfo_flow_depth_development_peryear();
+
+    String sinfo_waterlevel_differences();
+
+    String sinfo_waterlevel_difference();
+
+    String sinfo_bedheight_differences();
+
+    String sinfo_bedheight_difference();
+
+    String sinfo_tkh_export();
+
+    String sinfo_tkh_report();
+
+    String sinfo_tkhs();
+
+    String sinfo_tkk();
+
+    String sinfo_velocities();
+
+    String sinfo_taus();
+
+    String sinfo_bedqualities();
+
+    String sinfo_d50s();
+
+    String sinfo_flowdepthminmax_export();
+
+    String sinfo_flowdepthdevelopment_export();
+
+    String sinfo_additional_ls();
+
+    String sinfo_additional_ls_withQ();
+
+    String sinfo_additional_ls_withoutQ();
+
+    String sinfo_predefined_channel();
+
+    String sinfo_predefined_tkh();
+
+    String predefined_tkh_berechnung();
+
+    String predefined_tkh_messung();
+
+    String sinfo_predefined_depthevol();
+
+    String predefined_depthevol_aktuell();
+
+    String predefined_depthevol_etappe();
+
+    String sinfo_predefined_flowdepths();
+
+    String sinfo_predefined_flowdepth();
+
+    String sinfo_infrastructure();
+
+    String sinfo_collisions();
+
+    String sinfo_collision();
+
+    String uinfo();
+
+    String uinfo_salix_line_export();
+
+    String uinfo_vegetation_zones_export();
+
+    String uinfo_inundation_duration_export();
+
+    String uinfo_vegetation_zone_label();
+
+    String uinfo_vegetation_zones_label();
+
+    String uinfo_vegetation_zones_from();
+
+    String uinfo_vegetation_zones_to();
+
+    String bundu();
+
+    String uinfo_vegetation_zones_validation_empty();
+
+    String uinfo_vegetation_zones_validation_range();
+
+    String uinfo_vegetation_zones_validation_from_greater_to();
+
+    String uinfo_vegetation_zones_invalid_integer();
+
+    String chart_settings_export_metadata();
+
+    String sinfo_flow_depth_development_twin_panel_max_count_msg();
+
+    String sinfo_floodduration_export();
+
+    String sinfo_floodduration_report();
+
+    String export_csv_title();
 
     String waterlevel_ground_state();
-
-    String location();
-
-    String locations();
-
-    String single_location();
-
-    String distance();
-
-    String unitFrom();
-
-    String unitTo();
-
-    String dpLabelFrom();
-
-    String dpUnitFrom();
-
-    String dpLabelTo();
-
-    String dpUnitTo();
-
-    String dpLabelStep();
-
-    String dpUnitStep();
-
-    String wgLabelFrom();
-
-    String wgUnitFrom();
-
-    String wgLabelTo();
-
-    String wgUnitTo();
-
-    String wgLabelStep();
-
-    String wgUnitStep();
-
-    String unitWidth();
-
-    String unitFromInM();
-
-    String unitToInM();
-
-    String unitDiffInM();
-
-    String unitLocation();
-
-    String wrongFormat();
-
-    String toShouldNotBeNegative();
-
-    String atLeastOneValue();
-
-    String missingInput();
-
-    String too_many_values();
-
-    String from();
-
-    String to();
-
-    String riverside();
-
-    String calcTableTitle();
-
-    String helperPanelTitle();
-
-    String gaugePanelTitle();
-
-    String measurementStationPanelTitle();
-
-    String wqTitle();
-
-    String wqadaptedTitle();
-
-    String noMainValueAtGauge();
-
-    String wqHistorical();
-
-    String unitWNN();
-
-    String wqWFree();
-
-    String wqW();
-
-    String wqQ();
-
-    String wqQatGauge();
-
-    String wqQGauge();
-
-    String wqSingle();
-
-    String wqRange();
-
-    String unitWSingle();
-
-    String unitWFree();
-
-    String unitWFrom();
-
-    String unitWTo();
-
-    String unitWStep();
-
-    String unitQSingle();
-
-    String unitQFrom();
-
-    String unitQTo();
-
-    String unitQStep();
-
-    String main_channel();
-
-    String total_channel();
-
-    String footerHome();
-
-    String footerContact();
-
-    String footerImpressum();
-
-    String projectListMin();
-
-    String projectListAdd();
-
-    String buttonNext();
-
-    String imageBack();
-
-    String imageSave();
-
-    String search();
-
-    String properties();
-
-    String activateTheme();
-
-    String deactivateTheme();
-
-    String removeTheme();
-
-    String manageThemes();
-
-    String label_ok();
-
-    String label_cancel();
-
-    String cancelCalculationLabel();
-
-    String calculationCanceled();
-
-    String flysLogo();
-
-    String bfgLogo();
-
-    String bfgLogoSmall();
-
-    String downloadPNG();
-
-    String downloadPDF();
-
-    String downloadSVG();
-
-    String downloadCSV();
-
-    String downloadAT();
-
-    String downloadWST();
-
-    String loadingImg();
-
-    String cancelCalculation();
-
-    String markerRed();
-
-    String markerGreen();
-
-    String riverMap();
-
-    String range();
-
-    String description();
-
-    String resultCount();
-
-    String bfg_id();
-
-    String start_year();
-
-    String end_year();
-
-    String period();
-
-    String gauge_class();
-
-    String eventselect();
-
-    String events();
-
-    String kmchart();
-
-    String addPointsTooltip();
-
-    String addWSPTooltip();
-
-    String downloadPNGTooltip();
-
-    String downloadPDFTooltip();
-
-    String downloadSVGTooltip();
-
-    String downloadCSVTooltip();
-
-    String zoomToMaxExtentTooltip();
-
-    String zoomOutTooltip();
-
-    String historyBackTooltip();
-
-    String panControlTooltip();
-
-    String zoomboxTooltip();
-
-    String chartPropertiesTooltip();
-
-    String year();
-
-    String sedimentload_ls();
-
-    // Gauges
-
-    String gauge_mnq();
-
-    String gauge_mq();
-
-    String gauge_mhq();
-
-    String gauge_hq5();
-
-    // Elevation window
-
-    String ele_window_title();
-
-    String ele_window_label();
-
-    String ele_window_x_col();
-
-    String ele_window_y_col();
-
-    String ele_window_z_col();
-
-    String ele_window_ok_button();
-
-    String ele_window_cancel_button();
-
-    String ele_window_format_error();
-
-    String ele_window_save_error();
-
-    String ele_window_geometry_error();
-
-    // OUTPUT TYPES
-
-    String discharge_curve_gaugeless();
-
-    String discharge_curve();
-
-    String gauge_discharge_curve();
-
-    String computed_discharge_curve();
-
-    String computed_discharge_curves();
-
-    String longitudinal_section();
-
-    String duration_curve();
-
-    String reference_curve();
-
-    String reference_curves();
-
-    String reference_curve_normalized();
-
-    String reference_endpoint();
-
-    String reference_startpoint();
-
-    String name();
-
-    String type();
-
-    String starttime();
-
-    String stoptime();
-
-    String wq_table_w();
-
-    String wq_waterlevel_label();
-
-    String wq_table_q();
-
-    String wq_value_w();
-
-    String wq_value_q();
-
-    String discharge_longitudinal_section();
-
-    String floodmap();
-
-    String cross_section();
-
-    String cross_sections();
-
-    String w_differences();
-
-    String historical_discharge();
-
-    String historical_discharge_wq();
-
-    String extreme_wq_curve();
-
-    String showextramark();
-
-    String fix_wq_curve();
-
-    String fix_deltawt_curve();
-
-    String fix_longitudinal_section_curve();
-
-    String fix_derivate_curve();
-
-    String fix_vollmer_wq_curve();
-
-    // EXPORTS
-
-    String waterlevel_export();
-
-    String waterlevel_report();
-
-    String computed_dischargecurve_at_export();
-
-    String discharge_longitudinal_section_export();
-
-    String discharge_longitudinal_section_report();
-
-    String computed_dischargecurve_export();
-
-    String computed_dischargecurve_report();
-
-    String durationcurve_export();
-
-    String durationcurve_report();
-
-    String dataexport();
-
-    String reference_curve_export();
-
-    String w_differences_export();
-
-    String historical_discharge_export();
-
-    String csv();
-
-    String wst();
-
-    String at();
-
-    String pdf();
-
-    String chart_themepanel_header_themes();
-
-    String chart_themepanel_header_actions();
-
-    String chart_themepanel_synchron();
-
-    String chart_themepanel_asynchron();
-
-    String chart_themepanel_set_master();
-
-    String chart_themepanel_new_area();
-
-    String chart_themepanel_area_under();
-
-    String chart_themepanel_area_over();
-
-    String chart_themepanel_area_between();
-
-    String against_x_axis();
-
-    String discharge();
-
-    String flow_velocity();
-
-    String flow_velocities();
-
-    String flow_velocity_export();
-
-    String bedheight_middle();
-
-    String bedheight_middle_export();
-
-    String bed_longitudinal_section();
-
-    String bed_longitudinal_section_export();
-
-    String sq_relation_a();
-
-    String sq_relation_b();
-
-    String sq_relation_c();
-
-    String sq_relation_d();
-
-    String sq_relation_e();
-
-    String sq_relation_f();
-
-    String sq_relation_g();
-
-    String sq_relation_export();
-
-    String sq_relations();
-
-    String exportATTooltip();
-
-    String load_diameter();
-
-    String bed_diameter();
-
-    String soundings();
-
-    String soundings_width();
-
-    String porosities();
-
-    String bed_difference_year();
-
-    String bed_difference_epoch();
-
-    String bed_difference_height_year();
-
-    String bedheight_difference_export();
-
-    String fix_waterlevel_export();
-
-    // ERRORS
-
-    String error_years_wrong();
-
-    String error_read_minmax_values();
-
-    String error_validate_range();
-
-    String error_validate_date_range();
-
-    String error_validate_date_range_invalid();
-
-    String error_validate_lower_range();
-
-    String error_validate_upper_range();
-
-    String error_validate_positive();
-
-    String error_create_artifact();
-
-    String error_describe_artifact();
-
-    String error_feed_data();
-
-    String error_advance_artifact();
-
-    String error_add_artifact();
-
-    String error_remove_artifact();
-
-    String error_create_collection();
-
-    String error_describe_collection();
-
-    String error_no_rivers_found();
-
-    String error_no_gaugeoverviewinfo_found();
-
-    String error_no_such_user();
-
-    String error_no_users();
-
-    String error_no_waterlevel_pair_selected();
-
-    String error_same_waterlevels_in_pair();
-
-    String error_not_logged_in();
-
-    String error_load_parameterization();
-
-    String error_feed_no_data();
-
-    String error_feed_from_out_of_range();
-
-    String error_feed_to_out_of_range();
-
-    String error_feed_from_bigger_to();
-
-    String error_feed_invalid_wq_mode();
-
-    String error_feed_number_format_float();
-
-    String error_feed_invalid_calculation_mode();
-
-    String error_feed_no_calculation_mode();
-
-    String error_feed_no_such_river();
-
-    String error_feed_no_river_selected();
-
-    String error_feed_no_wq_mode_selected();
-
-    String error_feed_q_values_invalid();
-
-    String error_feed_w_values_invalid();
-
-    String error_no_meta_data_found();
-
-    String error_chart_info_service();
-
-    String error_invalid_double_value();
-
-    String error_load_artifact();
-
-    String error_no_calc_result();
-
-    String error_no_theme_styles_found();
-
-    String error_no_feature_selected();
-
-    String error_no_map_config();
-
-    String error_no_map_output_type();
-
-    String error_no_module_found();
-
-    String warning_use_first_feature();
-
-    String warning_select_two_values();
-
-    String error_no_valid_gfi_url();
-
-    String error_gfi_req_failed();
-
-    String error_gfi_parsing_failed();
-
-    String error_gc_req_failed();
-
-    String error_gc_doc_not_valid();
-
-    String error_malformed_url();
-
-    String error_no_dgm_selected();
-
-    String error_invalid_dgm_selected();
-
-    String error_bad_dgm_range();
-
-    String error_bad_dgm_river();
-
-    String error_dialog_not_valid();
-
-    String error_invalid_date();
-
-    String error_wrong_date();
-
-    String bottom_edge();
-
-    String top_edge();
-
-    String error_same_location();
-
-    String error_contains_same_location();
-
-    String error_update_collection_attribute();
-
-    String error_values_needed();
-
-    // MAP RELATED STRINGS
-
-    String digitize();
-
-    String pipe1();
-
-    String pipe2();
-
-    String ditch();
-
-    String dam();
-
-    String ring_dike();
-
-    String selectFeature();
-
-    String removeFeature();
-
-    String getFeatureInfo();
-
-    String getFeatureInfoTooltip();
-
-    String getFeatureInfoWindowTitle();
-
-    String addWMS();
-
-    String printMapSettings();
-
-    String addWMSTooltip();
-
-    String adjustElevation();
-
-    String adjustElevationTooltip();
-
-    String measureLine();
-
-    String measurePolygon();
-
-    String step();
-
-    String calculationStarted();
-
-    String zoomMaxExtent();
-
-    String zoomIn();
-
-    String zoomOut();
-
-    String zoomLayer();
-
-    String moveMap();
-
-    String digitizeObjects();
-
-    String selectObject();
-
-    String removeObject();
-
-    String measureDistance();
-
-    String measureArea();
-
-    String map_themepanel_header_style();
-
-    String zoomToLayer();
-
-    String requireDGM();
-
-    String upload_file();
-
-    String shape_file_upload();
-
-    // data cage
-
-    String historical_discharges();
-
-    String waterlevels();
-
-    String waterlevels_discharge();
-
-    String waterlevels_fix();
-
-    String waterlevels_fix_vollmer();
-
-    String waterlevels_ls();
-
-    String beddifferences();
-
-    String bedheight_differences();
-
-    String middle_bedheights();
-
-    String vollmer_waterlevels();
-
-    String old_calculations();
-
-    String officiallines();
-
-    String datacageAdd();
-
-    String fixations();
-
-    String flood_protections();
-
-    String columns();
-
-    String basedata();
-
-    String heightmarks();
-
-    String annotation();
-
-    String annotations();
-
-    String all_annotations();
-
-    String flowvelocitymeasurement();
-
-    String flowvelocitymodel();
-
-    String bed_quality();
-
-    String additionals();
-
-    String differences();
-
-    String kilometrage();
-
-    String riveraxis();
-
-    String km();
-
-    String qps();
-
-    String hws();
-
-    String catchments();
-
-    String catchment_wms();
-
-    String floodplain();
-
-    String lines();
-
-    String buildings();
-
-    String fixpoints();
-
-    String uesk();
-
-    String calculations();
-
-    String current();
-
-    String bfg();
-
-    String land();
-
-    String potential();
-
-    String rastermap();
-
-    String background();
-
-    String discharge_tables_chart();
-
-    String discharge_table_nn();
-
-    String discharge_table_gauge();
-
-    String mainvalue();
-
-    String mainvalues();
-
-    String wmainvalue();
-
-    String qmainvalue();
-
-    String show_mainvalues();
-
-    String dems();
-
-    String hydrboundaries();
-
-    String gaugelocations();
-
-    String single();
-
-    String epoch();
-
-    String bedheights();
-
-    String morph_width();
-
-    String datacage();
-
-    String datacage_add_pair();
-
-    String delta_w();
-
-    String delta_w_cm();
-
-    String delta_w_cma();
-
-    String wlevel();
-
-    String sedimentloads();
-
-    String sources_sinks();
-
-    String years();
-
-    String epochs();
-
-    String off_epochs();
-
-    String densities();
-
-    String sediment_load();
-
-    String sediment_load_ls();
-
-    String measurement_stations();
-
-    String coarse();
-
-    String fine_middle();
-
-    String sand();
-
-    String susp_sand();
-
-    String susp_sand_bed();
-
-    String suspended_sediment();
-
-    String total();
-
-    String bed_load();
-
-    String suspended_load();
-
-    // Capabilities Information Panel
-
-    String addwmsInputTitle();
-
-    String addwmsInfoTitle();
-
-    String addwmsLayerTitle();
-
-    String addwmsBack();
-
-    String addwmsContinue();
-
-    String addwmsCancel();
-
-    String addwmsInvalidURL();
-
-    String capabilitiesHint();
-
-    String capabilitiesTitle();
-
-    String capabilitiesURL();
-
-    String capabilitiesAccessConstraints();
-
-    String capabilitiesFees();
-
-    String capabilitiesContactInformation();
-
-    String capabilitiesEmail();
-
-    String capabilitiesPhone();
-
-    String chart();
-
-    String export();
-
-    String width();
-
-    String height();
-
-    String visibility();
-
-    String upper();
-
-    String lower();
-
-    String fixation();
-
-    String font_size();
-
-    String label();
-
-    String subtitle();
-
-    String display_grid();
-
-    String display_logo();
-
-    String logo_placeh();
-
-    String logo_placev();
-
-    String top();
-
-    String bottom();
-
-    String center();
-
-    String left();
-
-    String right();
-
-    String none();
-
-    String notselected();
-
-    String linetype();
-
-    String textstyle();
-
-    String linecolor();
-
-    String showhorizontalline();
-
-    String showverticalline();
-
-    String horizontal();
-
-    String vertical();
-
-    String textcolor();
-
-    String textsize();
-
-    String font();
-
-    String showborder();
-
-    String showpoints();
-
-    String showbackground();
-
-    String textshowbg();
-
-    String backgroundcolor();
-
-    String bandwidthcolor();
-
-    String textbgcolor();
-
-    String textorientation();
-
-    String linesize();
-
-    String pointsize();
-
-    String bandwidth();
-
-    String pointcolor();
-
-    String showlines();
-
-    String showlinelabel();
-
-    String showpointlabel();
-
-    String labelfontsize();
-
-    String labelfontcolor();
-
-    String labelfontface();
-
-    String labelfontstyle();
-
-    String labelbgcolor();
-
-    String labelshowbg();
-
-    String showwidth();
-
-    String showlevel();
-
-    String showminimum();
-
-    String showmaximum();
-
-    String transparent();
-
-    String transparency();
-
-    String showarea();
-
-    String showarealabel();
-
-    String showmiddleheight();
-
-    String fillcolor();
-
-    String wsplgen_cat1();
-
-    String wsplgen_cat2();
-
-    String wsplgen_cat3();
-
-    String wsplgen_cat4();
-
-    String wsplgen_cat5();
-
-    String areabgcolor();
-
-    String areabgpattern();
-
-    String areashowborder();
-
-    String areashowbg();
-
-    String areabordercolor();
-
-    String areatransparency();
-
-    String attribution();
-
-    // Manual Points editor
-
-    String addpoints();
-
-    String pointname();
-
-    String removepoint();
-
-    String newpoint();
-
-    String standby();
-
-    String points();
-
-    String editpoints();
-
-    String manual_date_points_y();
-
-    // Manual WaterLine (WSP) Editor.
-
-    String addWSPButton();
-
-    String addWSP();
-
-    String selection();
-
-    String fix_deltawt_export();
-
-    String select();
-
-    String add_date();
-
-    String fix_parameters_export();
-
-    String fix_parameters();
-
-    String sq_overview();
-
-    // Gauge Overview Info
-
-    String gauge_zero();
-
-    String gauge_q_unit();
-
-    String gauge_info_link();
-
-    String gauge_river_info_link();
-
-    String gauge_river_url();
-
-    String gauge_url();
-
-    String gauge_curve_link();
-
-    String gauge_discharge_curve_at_export();
-
-    // Measurement Station Info
-
-    String measurement_station_type();
-
-    String measurement_station_operator();
-
-    String measurement_station_comment();
-
-    String measurement_station_start_time();
-
-    String measurement_station_url();
-
-    String measurement_station_info_link();
-
-    String measurement_station_gauge_name();
-
-    String discharge_timeranges();
-
-    String discharge_chart();
-
-    String projectlist_close();
-
-    String startcolor();
-
-    String endcolor();
-
-    String numclasses();
-
-    String welcome();
-
-    String welcome_open_or_create();
-
-    String official();
-
-    String inofficial();
-
-    String custom_lines();
-
-    String hws_lines();
-
-    String hws_points();
-
-    String hws_fed_unknown();
-
-    String jetties();
-
-    String route_data();
-
-    String other();
-
-    String axis();
-
-    String bfg_model();
-
-    String federal();
-
-    String areas();
-
-    String sobek_areas();
-
-    String sobek_flooded();
-
-    String measurements();
-
-    String floodmarks();
-
-    String pegel_had_measurement_points();
-
-    String gauge_points();
-
-    String gauge_names();
-
-    String gauge_level();
-
-    String gauge_tendency();
-
-    String printTooltip();
-
-    String print();
-
-    String printWindowTitle();
-
-    String mapfish_data_range();
-
-    String mapfish_data_subtitle();
-
-    String mapfish_data_strech();
-
-    String mapfish_data_institution();
-
-    String mapfish_data_source();
-
-    String mapfish_data_creator();
-
-    String mapfish_data_dateplace();
-
-    String mapfish_data_river();
-
-    String mapTitle();
-
-    String mapSubtitle();
-
-    String mapRange();
-
-    String mapStretch();
-
-    String mapCreator();
-
-    String mapInstitution();
-
-    String mapSource();
-
-    String mapDate();
-
-    String mapLogo();
-
-    String wmsURLMenuItem();
-
-    String wmsURLBoxTitle();
-
-    String requireTheme();
-
-    String PATH();
-
-    String DESCRIPTION();
-
-    String KM();
-
-    String Z();
-
-    String LOCATION();
-
-    String HPGP();
-
-    String DIFF();
-
-    String SOURCE();
-
-    String WATERBODY();
-
-    String FEDSTATE_KM();
-
-    String official_regulation();
-
-    String historical_discharge_curves();
-
-    String current_gauge();
-
-    String suggested_label();
-
-    String negative_values_not_allowed_for_to();
-
-    String analyzed_range();
-
-    String minfo_type();
-
-    String river();
-
-    String ld_locations();
-
-    String gauge_name();
-
-    String reference_gauge();
-
-    String station();
-
-    String station_name();
-
-    String lower_time();
-
-    String upper_time();
-
-    String no_data_for_year();
-
-    String no_data_sediment_difference();
-
-    String error_no_sedimentloadinfo_found();
-
-    String error_no_sedimentloadinfo_data();
-
-    String sinfo();
-
-    String sinfo_flowdepth_export();
-
-    String sinfo_flowdepth_report();
-
-    String sinfo_flow_depth();
-
-    String sinfo_flowdepth_twinpanel_no_pair_selected();
-
-    String sinfo_flow_depths();
-
-    String sinfo_flow_depths_minmax();
-
-    String sinfo_flow_depth_minmax();
-
-    String sinfo_flow_depth_developments();
-
-    String sinfo_flow_depth_development();
-
-    String sinfo_flow_depth_development_peryear();
-
-    String sinfo_waterlevel_differences();
-
-    String sinfo_waterlevel_difference();
-
-    String sinfo_bedheight_differences();
-
-    String sinfo_bedheight_difference();
-
-    String sinfo_tkh_export();
-
-    String sinfo_tkh_report();
-
-    String sinfo_tkhs();
-
-    String sinfo_tkk();
-
-    String sinfo_velocities();
-
-    String sinfo_taus();
-
-    String sinfo_bedqualities();
-
-    String sinfo_d50s();
-
-    String sinfo_flowdepthminmax_export();
-
-    String sinfo_flowdepthdevelopment_export();
-
-    String sinfo_additional_ls();
-
-    String sinfo_additional_ls_withQ();
-
-    String sinfo_additional_ls_withoutQ();
-
-    String sinfo_predefined_channel();
-
-    String sinfo_predefined_tkh();
-
-    String predefined_tkh_berechnung();
-
-    String predefined_tkh_messung();
-
-    String sinfo_predefined_depthevol();
-
-    String predefined_depthevol_aktuell();
-
-    String predefined_depthevol_etappe();
-
-    String sinfo_predefined_flowdepths();
-
-    String sinfo_predefined_flowdepth();
-
-    String sinfo_infrastructure();
-
-    String sinfo_collisions();
-
-    String sinfo_collision();
-
-    String uinfo();
-
-    String uinfo_salix_line_export();
-
-    String uinfo_vegetation_zones_export();
-
-    String uinfo_inundation_duration_export();
-
-    String uinfo_vegetation_zone_label();
-
-    String uinfo_vegetation_zones_label();
-
-    String uinfo_vegetation_zones_from();
-
-    String uinfo_vegetation_zones_to();
-
-    String bundu();
-
-    String uinfo_vegetation_zones_validation_empty();
-
-    String uinfo_vegetation_zones_validation_range();
-
-    String uinfo_vegetation_zones_validation_from_greater_to();
-
-    String uinfo_vegetation_zones_invalid_integer();
-
-    String chart_settings_export_metadata();
-
-    String sinfo_flow_depth_development_twin_panel_max_count_msg();
-
-    String sinfo_floodduration_export();
-
-    String sinfo_floodduration_report();
-
-    String export_csv_title();
 }
\ No newline at end of file
diff -r 06bb3e94a927 -r 34dc0163ad2d gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.properties
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.properties	Mon Jun 25 16:07:41 2018 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.properties	Mon Jun 25 17:58:11 2018 +0200
@@ -59,11 +59,7 @@
 databasket_loading = Loading Databasket content
 fix = Fixing
 fixanalysis = Fixing Analysis
-next = Next
-location_distance_state = Choose calculation location(s) / range [km]
-distance_state = Choose calculation range [km]
-distance_part_state = Choose calculation subregion [km]
-waterlevel_ground_state = Choose differences betweeen waterlevel and ground [m]
+next = Next  
 location = Location(s)
 locations = Locations
 single_location = Location
@@ -403,6 +399,8 @@
 warning_cannot_parse_date = Invalid date!
 warning_select_two_values = Please select two values!
 
+waterlevel_ground_state = Choose differences betweeen waterlevel and ground [m]
+
 ## map related strings
 digitize = images/digitize.png
 pipe1 = Pipe1
diff -r 06bb3e94a927 -r 34dc0163ad2d gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants_de.properties
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants_de.properties	Mon Jun 25 16:07:41 2018 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants_de.properties	Mon Jun 25 17:58:11 2018 +0200
@@ -59,11 +59,7 @@
 databasket_loading=Lade Datenkorb Inhalt
 fix = Fixierungsanalyse
 fixanalysis = Fixierungsanalyse
-next = Weiter
-location_distance_state = Berechnungsort(e) / strecke w\u00e4hlen [km]
-distance_state = Berechnungsstrecke w\u00e4hlen [km]
-distance_part_state = Teilstrecke w\u00e4hlen [km]
-waterlevel_ground_state = Differenzen zwischen Wasserspiegel und Gel\u00e4nde [m]
+next = Weiter 
 location = Ort(e)
 locations = Orte
 single_location = Ort
@@ -403,6 +399,8 @@
 warning_cannot_parse_date = Datum ist ung\u00fcltig!
 warning_select_two_values = Bitte zwei Werte w\u00e4hlen!
 
+waterlevel_ground_state = Differenzen zwischen Wasserspiegel und Gel\u00e4nde [m]
+
 ## map related strings
 digitize = images/digitize.png
 pipe1 = Rohr1
diff -r 06bb3e94a927 -r 34dc0163ad2d gwt-client/src/main/java/org/dive4elements/river/client/client/ui/DistanceOnlyPartPanel.java
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/DistanceOnlyPartPanel.java	Mon Jun 25 16:07:41 2018 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/DistanceOnlyPartPanel.java	Mon Jun 25 17:58:11 2018 +0200
@@ -13,6 +13,8 @@
 import org.dive4elements.river.client.shared.model.DataItem;
 import org.dive4elements.river.client.shared.model.DataList;
 
+import com.smartgwt.client.widgets.Label;
+
 public class DistanceOnlyPartPanel extends DistanceOnlyPanel {
 
     private static final long serialVersionUID = -5794138573892656947L;
@@ -22,8 +24,11 @@
     }
 
     @Override
-    protected String getLabel() {
-        return this.MSG.distance_part_state();
+    protected Label getLabel(final DataList data) {
+        final Data item = data.get(0);
+        return new Label(item.getDescription());//
+        // TODO: migrate distance_part_state to server
+        // item.getDescription()); // holt das Label vom Server (funktoniert schon sehr oft so!)
     }
 
     @Override
diff -r 06bb3e94a927 -r 34dc0163ad2d gwt-client/src/main/java/org/dive4elements/river/client/client/ui/DistancePanel.java
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/DistancePanel.java	Mon Jun 25 16:07:41 2018 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/DistancePanel.java	Mon Jun 25 17:58:11 2018 +0200
@@ -115,12 +115,9 @@
         return layout;
     }
 
-    private Label getLabel(final DataList data) {
+    protected Label getLabel(final DataList data) {
         final Data item = data.get(0);
-        if (data.getState().contains("uinfo")) { // "Wahl der Berechnungsstrecke/des Darstellungsbereichs" (server) vs. "Berechnungsstrecke wählen" (client)
-            return new Label(item.getDescription()); // holt das Label vom Server (funktoniert schon sehr oft so!)
-        }
-        return new Label(getLabel()); // holt das Label aus den Flys-Constants..
+        return new Label(item.getDescription()); // holt das Label vom Server (funktoniert schon sehr oft so!)
     }
 
     @Override
@@ -166,9 +163,9 @@
         return sb.toString();
     }
 
-    protected String getLabel() {
-        return this.MSG.distance_state();
-    }
+    // protected String getLabel() {
+    // return this.MSG.distance_state();
+    // }
 
     protected String labelFrom() {
         return getLabelFrom() + " [" + getUnitFrom() + "]";
diff -r 06bb3e94a927 -r 34dc0163ad2d gwt-client/src/main/java/org/dive4elements/river/client/client/ui/LocationDistancePanel.java
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/LocationDistancePanel.java	Mon Jun 25 16:07:41 2018 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/LocationDistancePanel.java	Mon Jun 25 17:58:11 2018 +0200
@@ -8,9 +8,28 @@
 
 package org.dive4elements.river.client.client.ui;
 
+import java.util.ArrayList;
+import java.util.LinkedHashMap;
+import java.util.List;
+
+import org.dive4elements.river.client.client.Config;
+import org.dive4elements.river.client.client.FLYSConstants;
+import org.dive4elements.river.client.client.event.FilterHandler;
+import org.dive4elements.river.client.client.event.RangeFilterEvent;
+import org.dive4elements.river.client.client.event.StringFilterEvent;
+import org.dive4elements.river.client.client.services.DistanceInfoService;
+import org.dive4elements.river.client.client.services.DistanceInfoServiceAsync;
+import org.dive4elements.river.client.client.ui.range.DistanceInfoDataSource;
+import org.dive4elements.river.client.shared.model.ArtifactDescription;
+import org.dive4elements.river.client.shared.model.Data;
+import org.dive4elements.river.client.shared.model.DataItem;
+import org.dive4elements.river.client.shared.model.DataList;
+import org.dive4elements.river.client.shared.model.DefaultData;
+import org.dive4elements.river.client.shared.model.DefaultDataItem;
+import org.dive4elements.river.client.shared.model.DistanceInfoObject;
+
 import com.google.gwt.core.client.GWT;
 import com.google.gwt.i18n.client.NumberFormat;
-
 import com.smartgwt.client.data.AdvancedCriteria;
 import com.smartgwt.client.data.Criteria;
 import com.smartgwt.client.data.Criterion;
@@ -44,88 +63,64 @@
 import com.smartgwt.client.widgets.tab.events.TabSelectedEvent;
 import com.smartgwt.client.widgets.tab.events.TabSelectedHandler;
 
-import org.dive4elements.river.client.client.Config;
-import org.dive4elements.river.client.client.FLYSConstants;
-import org.dive4elements.river.client.client.event.FilterHandler;
-import org.dive4elements.river.client.client.event.RangeFilterEvent;
-import org.dive4elements.river.client.client.event.StringFilterEvent;
-import org.dive4elements.river.client.client.services.DistanceInfoService;
-import org.dive4elements.river.client.client.services.DistanceInfoServiceAsync;
-import org.dive4elements.river.client.client.ui.range.DistanceInfoDataSource;
-import org.dive4elements.river.client.shared.model.ArtifactDescription;
-import org.dive4elements.river.client.shared.model.Data;
-import org.dive4elements.river.client.shared.model.DataItem;
-import org.dive4elements.river.client.shared.model.DataList;
-import org.dive4elements.river.client.shared.model.DefaultData;
-import org.dive4elements.river.client.shared.model.DefaultDataItem;
-import org.dive4elements.river.client.shared.model.DistanceInfoObject;
-
-import java.util.ArrayList;
-import java.util.LinkedHashMap;
-import java.util.List;
-
-
 /**
  * This UIProvider creates a widget to enter locations or a distance.
  *
  * @author <a href="mailto:ingo.weinzierl at intevation.de">Ingo Weinzierl</a>
  */
-public class LocationDistancePanel
-extends      AbstractUIProvider
-implements   ChangeHandler, BlurHandler, FilterHandler
-{
+public class LocationDistancePanel extends AbstractUIProvider implements ChangeHandler, BlurHandler, FilterHandler {
     private static final long serialVersionUID = -10820092176039372L;
 
     /** The message class that provides i18n strings. */
     protected FLYSConstants MESSAGES = GWT.create(FLYSConstants.class);
 
     /** The DistanceInfoService used to retrieve locations about rivers. */
-    protected DistanceInfoServiceAsync distanceInfoService =
-        GWT.create(DistanceInfoService.class);
+    protected DistanceInfoServiceAsync distanceInfoService = GWT.create(DistanceInfoService.class);
 
     public static final String FIELD_MODE = "mode";
 
-    /** The constant name of the input field to enter the start of a distance.*/
+    /** The constant name of the input field to enter the start of a distance. */
     public static final String FIELD_FROM = "from";
 
-    /** The constant name of the input field to enter the end of a distance.*/
+    /** The constant name of the input field to enter the end of a distance. */
     public static final String FIELD_TO = "to";
 
-    /** The constant name of the input field to enter locations.*/
+    /** The constant name of the input field to enter locations. */
     public static final String FIELD_VALUE_LOCATION = "location";
 
-    /** The constant name of the input field to enter distance.*/
+    /** The constant name of the input field to enter distance. */
     public static final String FIELD_VALUE_DISTANCE = "distance";
 
-    /** The constant name of the input field to enter the step width of a
-     * distance.*/
+    /**
+     * The constant name of the input field to enter the step width of a
+     * distance.
+     */
     public static final String FIELD_WIDTH = "width";
 
     public static final int WIDTH = 250;
 
-
-    /** The radio group for input mode selection.*/
+    /** The radio group for input mode selection. */
     protected DynamicForm mode;
 
-    /** A container that will contain the location or the distance panel.*/
+    /** A container that will contain the location or the distance panel. */
     protected HLayout container;
 
-    /** The min value for a distance.*/
+    /** The min value for a distance. */
     protected double min;
 
-    /** The max value for a distance.*/
+    /** The max value for a distance. */
     protected double max;
 
-    /** The 'from' value entered in the distance mode.*/
+    /** The 'from' value entered in the distance mode. */
     protected double from;
 
-    /** The 'to' value entered in the distance mode.*/
+    /** The 'to' value entered in the distance mode. */
     protected double to;
 
-    /** The 'step' value entered in the distance mode.*/
+    /** The 'step' value entered in the distance mode. */
     protected double step;
 
-    /** The values entered in the location mode.*/
+    /** The values entered in the location mode. */
     protected double[] values;
 
     /** The input panel for locations. */
@@ -146,7 +141,7 @@
     /** The table data. */
     protected DistanceInfoObject[] tableData;
 
-    /** The table filter.*/
+    /** The table filter. */
     protected TableFilter filterDescription;
     protected RangeTableFilter filterRange;
 
@@ -159,34 +154,34 @@
      * Creates a new LocationDistancePanel instance.
      */
     public LocationDistancePanel() {
-        distanceTable  = new ListGrid();
-        distanceTable.setAutoFetchData(true);
+        this.distanceTable = new ListGrid();
+        this.distanceTable.setAutoFetchData(true);
 
-        locationsTable = new ListGrid();
-        locationsTable.setAutoFetchData(true);
+        this.locationsTable = new ListGrid();
+        this.locationsTable.setAutoFetchData(true);
 
-        distanceTable.setShowHeaderContextMenu(false);
-        locationsTable.setShowHeaderContextMenu(false);
+        this.distanceTable.setShowHeaderContextMenu(false);
+        this.locationsTable.setShowHeaderContextMenu(false);
     }
 
-
     /**
      * This method creates a widget that contains a label, a panel with
      * checkboxes to switch the input mode between location and distance input,
      * and a the mode specific panel.
      *
-     * @param data The data that might be inserted.
+     * @param data
+     *            The data that might be inserted.
      *
      * @return a panel.
      */
     @Override
-    public Canvas create(DataList data) {
-        VLayout layout = new VLayout();
+    public Canvas create(final DataList data) {
+        final VLayout layout = new VLayout();
         layout.setMembersMargin(10);
 
-        Label label   = new Label(MESSAGES.location_distance_state());
-        Canvas widget = createWidget(data);
-        Canvas submit = getNextButton();
+        final Label label = getLabel(data);// new Label(MESSAGES.location_distance_state());
+        final Canvas widget = createWidget(data);
+        final Canvas submit = getNextButton();
         createDistanceInputPanel();
 
         initDefaults(data);
@@ -201,6 +196,12 @@
         return layout;
     }
 
+    protected Label getLabel(final DataList data) {
+        final Data item = data.get(0);
+        return new Label(item.getDescription());//
+        // TODO: migrate distance_part_state to server
+        // item.getDescription()); // holt das Label vom Server (funktoniert schon sehr oft so!)
+    }
 
     /**
      * Setup a table for a DistanceInfoDataSource.
@@ -210,68 +211,67 @@
      * Depending on the value of isDistance the table will
      * have a to and a from column or a single location column.
      *
-     * @param table the ListGrid to set up.
-     * @param doublePins wether or not to have.
-     * @param isDistance wether or not to and from should be included.
+     * @param table
+     *            the ListGrid to set up.
+     * @param doublePins
+     *            wether or not to have.
+     * @param isDistance
+     *            wether or not to and from should be included.
      */
-    protected void setupDistanceInfoTable(ListGrid table,
-                                          boolean doublePins,
-                                          boolean isDistance) {
+    protected void setupDistanceInfoTable(final ListGrid table, final boolean doublePins, final boolean isDistance) {
 
-        String baseUrl = GWT.getHostPageBaseURL();
+        final String baseUrl = GWT.getHostPageBaseURL();
 
         table.setWidth100();
         table.setShowRecordComponents(true);
         table.setShowRecordComponentsByCell(true);
         table.setHeight100();
-        table.setEmptyMessage(MESSAGES.empty_filter());
+        table.setEmptyMessage(this.MESSAGES.empty_filter());
         table.setCanReorderFields(false);
 
-        CellFormatter cf = new CellFormatter() {
+        final CellFormatter cf = new CellFormatter() {
             @Override
-            public String format(
-                Object value,
-                ListGridRecord record,
-                int rowNum, int colNum) {
-                    if (value == null) return null;
-                    try {
-                        NumberFormat nf;
-                        double v = Double.parseDouble((String)value);
-                        nf = NumberFormat.getFormat("###0.00##");
-                        return nf.format(v);
-                    }
-                    catch (Exception e) {
-                        return value.toString();
-                    }
+            public String format(final Object value, final ListGridRecord record, final int rowNum, final int colNum) {
+                if (value == null)
+                    return null;
+                try {
+                    NumberFormat nf;
+                    final double v = Double.parseDouble((String) value);
+                    nf = NumberFormat.getFormat("###0.00##");
+                    return nf.format(v);
+                }
+                catch (final Exception e) {
+                    return value.toString();
+                }
             }
         };
         ListGridField pin1 = null;
         ListGridField pin2 = null;
 
         if (doublePins) {
-            pin1 = new ListGridField ("fromIcon", MESSAGES.from());
-            pin1.setWidth (30);
+            pin1 = new ListGridField("fromIcon", this.MESSAGES.from());
+            pin1.setWidth(30);
         } else {
-            pin1 = new ListGridField ("fromIcon", MESSAGES.selection());
-            pin1.setWidth (60);
+            pin1 = new ListGridField("fromIcon", this.MESSAGES.selection());
+            pin1.setWidth(60);
         }
-        pin1.setType (ListGridFieldType.ICON);
-        pin1.setCellIcon(baseUrl + MESSAGES.markerGreen());
+        pin1.setType(ListGridFieldType.ICON);
+        pin1.setCellIcon(baseUrl + this.MESSAGES.markerGreen());
 
         if (doublePins) {
-            pin2 = new ListGridField ("toIcon", MESSAGES.to());
-            pin2.setType (ListGridFieldType.ICON);
-            pin2.setWidth (30);
-            pin2.setCellIcon(baseUrl + MESSAGES.markerRed());
+            pin2 = new ListGridField("toIcon", this.MESSAGES.to());
+            pin2.setType(ListGridFieldType.ICON);
+            pin2.setWidth(30);
+            pin2.setCellIcon(baseUrl + this.MESSAGES.markerRed());
         }
 
         if (isDistance) {
             /* We have from / to fields */
-            pin1.addRecordClickHandler (new RecordClickHandler () {
+            pin1.addRecordClickHandler(new RecordClickHandler() {
                 @Override
-                public void onRecordClick (RecordClickEvent e) {
-                    Record r = e.getRecord();
-                    if (!isLocationMode ()) {
+                public void onRecordClick(final RecordClickEvent e) {
+                    final Record r = e.getRecord();
+                    if (!isLocationMode()) {
                         /* distance panel and distance mode */
                         setFrom(r.getAttribute("from"));
                         setTo(r.getAttribute("to"));
@@ -283,15 +283,17 @@
                 }
             });
             if (doublePins) {
-                pin2.addRecordClickHandler (new RecordClickHandler () {
+                pin2.addRecordClickHandler(new RecordClickHandler() {
                     @Override
-                    public void onRecordClick (RecordClickEvent e) {
-                        Record r = e.getRecord();
-                        if (isLocationMode ()) {
+                    public void onRecordClick(final RecordClickEvent e) {
+                        final Record r = e.getRecord();
+                        if (isLocationMode()) {
                             appendLocation(r.getAttribute("to"));
                         } else {
-                            /* Distance and double pin behavior is only
-                             * defined for location mode. */
+                            /*
+                             * Distance and double pin behavior is only
+                             * defined for location mode.
+                             */
                             GWT.log("Unhandled input state.");
                         }
                     }
@@ -299,11 +301,11 @@
             }
         } else {
             /* We only have the from field */
-            pin1.addRecordClickHandler (new RecordClickHandler () {
+            pin1.addRecordClickHandler(new RecordClickHandler() {
                 @Override
-                public void onRecordClick (RecordClickEvent e) {
-                    Record r = e.getRecord();
-                    if (!isLocationMode ()) {
+                public void onRecordClick(final RecordClickEvent e) {
+                    final Record r = e.getRecord();
+                    if (!isLocationMode()) {
                         /* Location panel and distance mode */
                         setFrom(r.getAttribute("from"));
                     } else {
@@ -313,15 +315,17 @@
                 }
             });
             if (doublePins) {
-                pin2.addRecordClickHandler (new RecordClickHandler () {
+                pin2.addRecordClickHandler(new RecordClickHandler() {
                     @Override
-                    public void onRecordClick (RecordClickEvent e) {
-                        Record r = e.getRecord();
-                        if (!isLocationMode ()) {
+                    public void onRecordClick(final RecordClickEvent e) {
+                        final Record r = e.getRecord();
+                        if (!isLocationMode()) {
                             setTo(r.getAttribute("from"));
                         } else {
-                            /* Distance and double pin behavior is only
-                             * defined for location mode. */
+                            /*
+                             * Distance and double pin behavior is only
+                             * defined for location mode.
+                             */
                             GWT.log("Unhandled input state.");
                         }
                     }
@@ -329,8 +333,7 @@
             }
         }
 
-        ListGridField ddescr = new ListGridField("description",
-                MESSAGES.description());
+        final ListGridField ddescr = new ListGridField("description", this.MESSAGES.description());
         ddescr.setType(ListGridFieldType.TEXT);
         ddescr.setWidth("*");
 
@@ -338,32 +341,29 @@
         ListGridField to = null;
 
         if (isDistance) {
-            from = new ListGridField("from", MESSAGES.from());
-            to = new ListGridField("to", MESSAGES.to());
+            from = new ListGridField("from", this.MESSAGES.from());
+            to = new ListGridField("to", this.MESSAGES.to());
             to.setType(ListGridFieldType.FLOAT);
             to.setCellFormatter(cf);
 
             to.setWidth("12%");
             to.setAlign(Alignment.LEFT);
         } else {
-            from = new ListGridField("from", MESSAGES.locations());
+            from = new ListGridField("from", this.MESSAGES.locations());
         }
         from.setCellFormatter(cf);
         from.setWidth("12%");
 
-        ListGridField dside = new ListGridField("riverside",
-                MESSAGES.riverside());
+        final ListGridField dside = new ListGridField("riverside", this.MESSAGES.riverside());
         dside.setType(ListGridFieldType.TEXT);
         dside.setWidth("12%");
 
-        ListGridField bottom =
-            new ListGridField("bottom", MESSAGES.bottom_edge());
+        final ListGridField bottom = new ListGridField("bottom", this.MESSAGES.bottom_edge());
         bottom.setType(ListGridFieldType.TEXT);
         bottom.setWidth("10%");
         bottom.setCellFormatter(cf);
 
-        ListGridField top =
-            new ListGridField("top", MESSAGES.top_edge());
+        final ListGridField top = new ListGridField("top", this.MESSAGES.top_edge());
         top.setType(ListGridFieldType.TEXT);
         top.setWidth("10%");
         top.setCellFormatter(cf);
@@ -380,31 +380,30 @@
     }
 
     @Override
-    public Canvas createOld(DataList dataList) {
-        List<Data> items = dataList.getAll();
+    public Canvas createOld(final DataList dataList) {
+        final List<Data> items = dataList.getAll();
 
-        Data       dMode  = getData(items, "ld_mode");
-        DataItem[] dItems = dMode.getItems();
+        final Data dMode = getData(items, "ld_mode");
+        final DataItem[] dItems = dMode.getItems();
 
         boolean rangeMode = true;
         if (dItems != null && dItems[0] != null) {
             rangeMode = FIELD_VALUE_DISTANCE.equals(dItems[0].getStringValue());
         }
 
-        HLayout layout = new HLayout();
+        final HLayout layout = new HLayout();
         layout.setWidth("400px");
 
-        Label   label  = new Label(dataList.getLabel());
+        final Label label = new Label(dataList.getLabel());
         label.setWidth("200px");
 
-        Canvas back = getBackButton(dataList.getState());
+        final Canvas back = getBackButton(dataList.getState());
 
         layout.addMember(label);
 
         if (rangeMode) {
             layout.addMember(getOldRangeSelection(dataList));
-        }
-        else {
+        } else {
             layout.addMember(getOldLocationSelection(dataList));
         }
 
@@ -413,124 +412,116 @@
         return layout;
     }
 
-
     /**
      * Creates a label for the selected range.
      *
-     * @param dataList The DataList containing all values for this state.
+     * @param dataList
+     *            The DataList containing all values for this state.
      *
      * @return A label displaying the selected values.
      */
-    protected Label getOldRangeSelection(DataList dataList) {
-        List<Data> items = dataList.getAll();
+    protected Label getOldRangeSelection(final DataList dataList) {
+        final List<Data> items = dataList.getAll();
 
-        Data dFrom = getData(items, "ld_from");
-        Data dTo   = getData(items, "ld_to");
-        Data dStep = getData(items, "ld_step");
+        final Data dFrom = getData(items, "ld_from");
+        final Data dTo = getData(items, "ld_to");
+        final Data dStep = getData(items, "ld_step");
 
-        DataItem[] from = dFrom.getItems();
-        DataItem[] to   = dTo.getItems();
-        DataItem[] step = dStep.getItems();
+        final DataItem[] from = dFrom.getItems();
+        final DataItem[] to = dTo.getItems();
+        final DataItem[] step = dStep.getItems();
 
-        StringBuilder sb = new StringBuilder();
+        final StringBuilder sb = new StringBuilder();
         sb.append(from[0].getLabel());
-        sb.append(" " + MESSAGES.unitFrom() + " ");
+        sb.append(" " + this.MESSAGES.unitFrom() + " ");
         sb.append(to[0].getLabel());
-        sb.append(" " + MESSAGES.unitTo() + " ");
+        sb.append(" " + this.MESSAGES.unitTo() + " ");
         sb.append(step[0].getLabel());
-        sb.append(" " + MESSAGES.unitWidth());
+        sb.append(" " + this.MESSAGES.unitWidth());
 
-        Label selected = new Label(sb.toString());
+        final Label selected = new Label(sb.toString());
         selected.setWidth("130px");
 
         return selected;
     }
 
-
     /**
      * Creates a label for the selected locations.
      *
-     * @param dataList The DataList containing all values for this state.
+     * @param dataList
+     *            The DataList containing all values for this state.
      *
      * @return A label displaying the selected values.
      */
-    protected Label getOldLocationSelection(DataList dataList) {
-        List<Data> items = dataList.getAll();
+    protected Label getOldLocationSelection(final DataList dataList) {
+        final List<Data> items = dataList.getAll();
 
-        Data       dLocations = getData(items, "ld_locations");
-        DataItem[] lItems     = dLocations.getItems();
+        final Data dLocations = getData(items, "ld_locations");
+        final DataItem[] lItems = dLocations.getItems();
 
-        String[] splitted = lItems[0].getStringValue().split(" ");
+        final String[] splitted = lItems[0].getStringValue().split(" ");
         String value = "";
-        for (int i = 0; i < splitted.length; i++) {
+        for (final String element : splitted) {
             try {
-                NumberFormat nf = NumberFormat.getDecimalFormat();
-                double dv = Double.parseDouble(splitted[i]);
+                final NumberFormat nf = NumberFormat.getDecimalFormat();
+                final double dv = Double.parseDouble(element);
                 value += nf.format(dv) + " ";
             }
-            catch(NumberFormatException nfe) {
-                value += splitted[i] + " ";
+            catch (final NumberFormatException nfe) {
+                value += element + " ";
             }
         }
 
-        Label selected = new Label(value);
+        final Label selected = new Label(value);
         selected.setWidth(130);
 
         return selected;
     }
 
-
     /**
      * This method reads the default values defined in the DataItems of the Data
      * objects in <i>list</i>.
      *
-     * @param list The DataList container that stores the Data objects.
+     * @param list
+     *            The DataList container that stores the Data objects.
      */
-    protected void initDefaults(DataList list) {
-        Data m = getData(list.getAll(), "ld_mode");
-        Data l = getData(list.getAll(), "ld_locations");
-        Data f = getData(list.getAll(), "ld_from");
-        Data t = getData(list.getAll(), "ld_to");
-        Data s = getData(list.getAll(), "ld_step");
+    protected void initDefaults(final DataList list) {
+        final Data m = getData(list.getAll(), "ld_mode");
+        final Data l = getData(list.getAll(), "ld_locations");
+        final Data f = getData(list.getAll(), "ld_from");
+        final Data t = getData(list.getAll(), "ld_to");
+        final Data s = getData(list.getAll(), "ld_step");
 
-        DataItem[] fItems = f.getItems();
-        DataItem[] tItems = t.getItems();
-        DataItem[] sItems = s.getItems();
+        final DataItem[] fItems = f.getItems();
+        final DataItem[] tItems = t.getItems();
+        final DataItem[] sItems = s.getItems();
 
-        min  = Double.valueOf(fItems[0].getStringValue());
-        max  = Double.valueOf(tItems[0].getStringValue());
-        step = Double.valueOf(sItems[0].getStringValue());
+        this.min = Double.valueOf(fItems[0].getStringValue());
+        this.max = Double.valueOf(tItems[0].getStringValue());
+        this.step = Double.valueOf(sItems[0].getStringValue());
 
-        DataItem   mDef   = m.getDefault();
-        DataItem   lDef   = l.getDefault();
-        DataItem   fDef   = f.getDefault();
-        DataItem   tDef   = t.getDefault();
-        DataItem   sDef   = s.getDefault();
+        final DataItem mDef = m.getDefault();
+        final DataItem lDef = l.getDefault();
+        final DataItem fDef = f.getDefault();
+        final DataItem tDef = t.getDefault();
+        final DataItem sDef = s.getDefault();
 
-        String mDefValue = mDef != null ? mDef.getStringValue() : null;
-        String theMode = mDefValue != null && mDefValue.length() > 0
-            ? mDef.getStringValue()
-            : FIELD_VALUE_DISTANCE;
+        final String mDefValue = mDef != null ? mDef.getStringValue() : null;
+        final String theMode = mDefValue != null && mDefValue.length() > 0 ? mDef.getStringValue() : FIELD_VALUE_DISTANCE;
 
-        mode.setValue(FIELD_MODE, theMode);
+        this.mode.setValue(FIELD_MODE, theMode);
 
-        String fDefValue = fDef != null ? fDef.getStringValue() : null;
-        setFrom(fDefValue != null && fDefValue.length() > 0
-            ? Double.valueOf(fDef.getStringValue())
-            : min);
+        final String fDefValue = fDef != null ? fDef.getStringValue() : null;
+        setFrom(fDefValue != null && fDefValue.length() > 0 ? Double.valueOf(fDef.getStringValue()) : this.min);
 
-        String tDefValue = tDef != null ? tDef.getStringValue() : null;
-        setTo(tDefValue != null && tDefValue.length() > 0
-            ? Double.valueOf(tDef.getStringValue())
-            : max);
+        final String tDefValue = tDef != null ? tDef.getStringValue() : null;
+        setTo(tDefValue != null && tDefValue.length() > 0 ? Double.valueOf(tDef.getStringValue()) : this.max);
 
-        String sDefValue = sDef != null ? sDef.getStringValue() : null;
-        setStep(sDefValue != null && sDefValue.length() > 0
-            ? Double.valueOf(sDef.getStringValue())
-            : step);
+        final String sDefValue = sDef != null ? sDef.getStringValue() : null;
+        setStep(sDefValue != null && sDefValue.length() > 0 ? Double.valueOf(sDef.getStringValue()) : this.step);
 
         if (lDef != null) {
-            String lDefValue = lDef != null ? lDef.getStringValue() : null;
+            final String lDefValue = lDef != null ? lDef.getStringValue() : null;
 
             if (lDefValue != null && lDefValue.length() > 0) {
                 setLocationValues(lDef.getStringValue());
@@ -539,309 +530,277 @@
 
         if (theMode.equals(FIELD_VALUE_DISTANCE)) {
             enableDistanceMode();
-            inputTables.selectTab(1);
+            this.inputTables.selectTab(1);
         } else {
             enableLocationMode();
         }
-        currentFiltered = (ListGrid)inputTables.getSelectedTab().getPane();
+        this.currentFiltered = (ListGrid) this.inputTables.getSelectedTab().getPane();
 
-        distancePanel.setValues(getFrom(), getTo(), getStep());
+        this.distancePanel.setValues(getFrom(), getTo(), getStep());
     }
 
+    protected Canvas createWidget(final DataList data) {
+        final VLayout layout = new VLayout();
+        this.container = new HLayout();
+        final Canvas checkboxPanel = createRadioButtonPanel();
 
-    protected Canvas createWidget(DataList data) {
-        VLayout layout       = new VLayout();
-        container            = new HLayout();
-        Canvas checkboxPanel = createRadioButtonPanel();
+        this.locationPanel = new DoubleArrayPanel(this.MESSAGES.unitLocation(), getLocationValues(), this);
 
-        locationPanel = new DoubleArrayPanel(
-                MESSAGES.unitLocation(),
-                getLocationValues(),
-                this);
+        this.distancePanel = new DoubleRangePanel(this.MESSAGES.unitFrom(), this.MESSAGES.unitTo(), this.MESSAGES.unitWidth(), 0, 0, 0, /*
+                                                                                                                                         * initDefaults set the
+                                                                                                                                         * default values for
+                                                                                                                                         * this.
+                                                                                                                                         */
+                400, this);
 
-        distancePanel = new DoubleRangePanel(
-                MESSAGES.unitFrom(), MESSAGES.unitTo(), MESSAGES.unitWidth(),
-                0, 0, 0, /* initDefaults set the default values for this. */
-                400,
-                this);
-
-        container.addMember(locationPanel);
-        container.addMember(distancePanel);
-        container.hideMember(locationPanel);
+        this.container.addMember(this.locationPanel);
+        this.container.addMember(this.distancePanel);
+        this.container.hideMember(this.locationPanel);
 
         layout.addMember(checkboxPanel);
-        layout.addMember(container);
+        layout.addMember(this.container);
 
-        container.setMembersMargin(30);
+        this.container.setMembersMargin(30);
 
-        inputTables   = new TabSet();
-        inputTables.addTabSelectedHandler(new TabSelectedHandler() {
+        this.inputTables = new TabSet();
+        this.inputTables.addTabSelectedHandler(new TabSelectedHandler() {
             @Override
-            public void onTabSelected(TabSelectedEvent evt) {
-                filterDescription.clear();
-                filterRange.clear();
-                filterResultCount.setValue("");
+            public void onTabSelected(final TabSelectedEvent evt) {
+                LocationDistancePanel.this.filterDescription.clear();
+                LocationDistancePanel.this.filterRange.clear();
+                LocationDistancePanel.this.filterResultCount.setValue("");
 
                 // The assumption is that location is tab 0 and distance tab 1
 
-                Canvas c = evt.getTabPane();
-                if(c instanceof ListGrid) {
-                    currentFiltered = (ListGrid)c;
+                final Canvas c = evt.getTabPane();
+                if (c instanceof ListGrid) {
+                    LocationDistancePanel.this.currentFiltered = (ListGrid) c;
                 }
             }
         });
 
-        Tab locations = new Tab(MESSAGES.locations());
-        Tab distances = new Tab(MESSAGES.distance());
+        final Tab locations = new Tab(this.MESSAGES.locations());
+        final Tab distances = new Tab(this.MESSAGES.distance());
 
-        inputTables.setWidth100();
-        inputTables.setHeight100();
+        this.inputTables.setWidth100();
+        this.inputTables.setHeight100();
 
-        locations.setPane(locationsTable);
-        distances.setPane(distanceTable);
+        locations.setPane(this.locationsTable);
+        distances.setPane(this.distanceTable);
 
-        inputTables.addTab(locations);
-        inputTables.addTab(distances);
+        this.inputTables.addTab(locations);
+        this.inputTables.addTab(distances);
 
-        filterResultCount = new StaticTextItem(MESSAGES.resultCount());
-        filterResultCount.setTitleAlign(Alignment.LEFT);
-        filterResultCount.setTitleStyle("color: #000");
+        this.filterResultCount = new StaticTextItem(this.MESSAGES.resultCount());
+        this.filterResultCount.setTitleAlign(Alignment.LEFT);
+        this.filterResultCount.setTitleStyle("color: #000");
 
-        filterDescription = new TableFilter();
-        filterDescription.setHeight("30px");
-        filterDescription.addFilterHandler(this);
+        this.filterDescription = new TableFilter();
+        this.filterDescription.setHeight("30px");
+        this.filterDescription.addFilterHandler(this);
 
-        filterRange = new RangeTableFilter();
-        filterRange.setHeight("30px");
-        filterRange.addFilterHandler(this);
-        filterRange.setVisible(false);
+        this.filterRange = new RangeTableFilter();
+        this.filterRange.setHeight("30px");
+        this.filterRange.addFilterHandler(this);
+        this.filterRange.setVisible(false);
 
-        filterCriteria = new SelectItem();
-        filterCriteria.setShowTitle(false);
-        filterCriteria.setWidth(100);
-        filterCriteria.addChangedHandler(new ChangedHandler() {
+        this.filterCriteria = new SelectItem();
+        this.filterCriteria.setShowTitle(false);
+        this.filterCriteria.setWidth(100);
+        this.filterCriteria.addChangedHandler(new ChangedHandler() {
             @Override
-            public void onChanged(ChangedEvent e) {
-                if(e.getValue().toString().equals("range")) {
-                    filterRange.setVisible(true);
-                    filterDescription.setVisible(false);
-                    filterDescription.clear();
-                    filterResultCount.setValue("");
-                }
-                else {
-                    filterRange.setVisible(false);
-                    filterRange.clear();
-                    filterDescription.setVisible(true);
-                    filterResultCount.setValue("");
+            public void onChanged(final ChangedEvent e) {
+                if (e.getValue().toString().equals("range")) {
+                    LocationDistancePanel.this.filterRange.setVisible(true);
+                    LocationDistancePanel.this.filterDescription.setVisible(false);
+                    LocationDistancePanel.this.filterDescription.clear();
+                    LocationDistancePanel.this.filterResultCount.setValue("");
+                } else {
+                    LocationDistancePanel.this.filterRange.setVisible(false);
+                    LocationDistancePanel.this.filterRange.clear();
+                    LocationDistancePanel.this.filterDescription.setVisible(true);
+                    LocationDistancePanel.this.filterResultCount.setValue("");
                 }
             }
         });
 
-        LinkedHashMap<String, String> filterMap =
-            new LinkedHashMap<String, String>();
-        filterMap.put("description", MESSAGES.description());
-        filterMap.put("range", MESSAGES.range());
-        filterCriteria.setValueMap(filterMap);
-        filterCriteria.setValue("description");
+        final LinkedHashMap<String, String> filterMap = new LinkedHashMap<String, String>();
+        filterMap.put("description", this.MESSAGES.description());
+        filterMap.put("range", this.MESSAGES.range());
+        this.filterCriteria.setValueMap(filterMap);
+        this.filterCriteria.setValue("description");
 
-        DynamicForm form = new DynamicForm();
-        form.setFields(filterCriteria);
-        inputTables.setHeight("*");
-        DynamicForm form2 = new DynamicForm();
-        form2.setFields(filterResultCount);
+        final DynamicForm form = new DynamicForm();
+        form.setFields(this.filterCriteria);
+        this.inputTables.setHeight("*");
+        final DynamicForm form2 = new DynamicForm();
+        form2.setFields(this.filterResultCount);
 
-        VLayout helper = new VLayout();
-        HLayout filterLayout = new HLayout();
+        final VLayout helper = new VLayout();
+        final HLayout filterLayout = new HLayout();
 
         filterLayout.addMember(form);
-        filterLayout.addMember(filterDescription);
-        filterLayout.addMember(filterRange);
+        filterLayout.addMember(this.filterDescription);
+        filterLayout.addMember(this.filterRange);
         filterLayout.setHeight("30px");
-        helper.addMember(inputTables);
+        helper.addMember(this.inputTables);
         helper.addMember(filterLayout);
         helper.addMember(form2);
         helper.setHeight100();
         helper.setWidth100();
 
-        helperContainer.addMember(helper);
+        this.helperContainer.addMember(helper);
         filterLayout.setWidth("200");
 
         return layout;
     }
 
-
     @Override
-    public void onFilterCriteriaChanged(StringFilterEvent event) {
-        String search = event.getFilter();
+    public void onFilterCriteriaChanged(final StringFilterEvent event) {
+        final String search = event.getFilter();
 
         if (search != null && search.length() > 0) {
-            Criteria c = new Criteria("description", search);
+            final Criteria c = new Criteria("description", search);
 
-            locationsTable.filterData(c);
-            distanceTable.filterData(c);
-            filterResultCount.setValue(currentFiltered.getRecords().length);
-        }
-        else {
-            locationsTable.clearCriteria();
-            distanceTable.clearCriteria();
-            filterResultCount.setValue("");
+            this.locationsTable.filterData(c);
+            this.distanceTable.filterData(c);
+            this.filterResultCount.setValue(this.currentFiltered.getRecords().length);
+        } else {
+            this.locationsTable.clearCriteria();
+            this.distanceTable.clearCriteria();
+            this.filterResultCount.setValue("");
         }
     }
 
-
     @Override
-    public void onFilterCriteriaChanged(RangeFilterEvent event) {
-        Float from = event.getFrom() - 0.001f;
-        Float to = event.getTo() + 0.001f;
+    public void onFilterCriteriaChanged(final RangeFilterEvent event) {
+        final Float from = event.getFrom() - 0.001f;
+        final Float to = event.getTo() + 0.001f;
         GWT.log("filtering range: " + from + " to " + to);
 
-
         Criterion combinedFilter = null;
         Criterion locationFilter = null;
         if (from.equals(Float.NaN) && to.equals(Float.NaN)) {
-            locationsTable.clearCriteria();
-            distanceTable.clearCriteria();
-            filterResultCount.setValue("");
+            this.locationsTable.clearCriteria();
+            this.distanceTable.clearCriteria();
+            this.filterResultCount.setValue("");
             return;
+        } else if (from.equals(Float.NaN)) {
+            combinedFilter = new Criterion("to", OperatorId.LESS_OR_EQUAL, to);
+            locationFilter = new Criterion("from", OperatorId.LESS_OR_EQUAL, to);
+            this.locationsTable.filterData(locationFilter);
+            this.distanceTable.filterData(combinedFilter);
+            this.filterResultCount.setValue(this.currentFiltered.getRecords().length);
+            return;
+        } else if (to.equals(Float.NaN)) {
+            combinedFilter = new Criterion("from", OperatorId.GREATER_OR_EQUAL, from);
+            this.locationsTable.filterData(combinedFilter);
+            this.distanceTable.filterData(combinedFilter);
+        } else {
+            final AdvancedCriteria c1 = new AdvancedCriteria(OperatorId.AND,
+                    new Criterion[] { new Criterion("from", OperatorId.GREATER_OR_EQUAL, from), new Criterion("from", OperatorId.LESS_OR_EQUAL, to) });
+
+            final AdvancedCriteria c2 = new AdvancedCriteria(OperatorId.AND,
+                    new Criterion[] { new Criterion("to", OperatorId.GREATER_OR_EQUAL, from), new Criterion("to", OperatorId.LESS_OR_EQUAL, to) });
+
+            final AdvancedCriteria c3 = new AdvancedCriteria(OperatorId.AND,
+                    new Criterion[] { new Criterion("from", OperatorId.LESS_OR_EQUAL, to), new Criterion("to", OperatorId.GREATER_OR_EQUAL, from) });
+
+            combinedFilter = new AdvancedCriteria(OperatorId.OR, new Criterion[] { c1, c2, c3 });
         }
-        else if (from.equals(Float.NaN)) {
-            combinedFilter = new Criterion("to", OperatorId.LESS_OR_EQUAL, to);
-            locationFilter =
-                new Criterion("from", OperatorId.LESS_OR_EQUAL, to);
-            locationsTable.filterData(locationFilter);
-            distanceTable.filterData(combinedFilter);
-            filterResultCount.setValue(currentFiltered.getRecords().length);
-            return;
-        }
-        else if (to.equals(Float.NaN)) {
-            combinedFilter =
-                new Criterion("from", OperatorId.GREATER_OR_EQUAL, from);
-             locationsTable.filterData(combinedFilter);
-            distanceTable.filterData(combinedFilter);
-        }
-        else {
-            AdvancedCriteria c1 =
-                new AdvancedCriteria(OperatorId.AND, new Criterion[] {
-                    new Criterion("from", OperatorId.GREATER_OR_EQUAL, from),
-                    new Criterion("from", OperatorId.LESS_OR_EQUAL, to)
-                });
-
-            AdvancedCriteria c2 =
-                new AdvancedCriteria(OperatorId.AND, new Criterion[] {
-                    new Criterion("to", OperatorId.GREATER_OR_EQUAL, from),
-                    new Criterion("to", OperatorId.LESS_OR_EQUAL, to)
-                });
-
-            AdvancedCriteria c3 =
-                new AdvancedCriteria(OperatorId.AND, new Criterion[] {
-                    new Criterion("from", OperatorId.LESS_OR_EQUAL, to),
-                    new Criterion("to", OperatorId.GREATER_OR_EQUAL, from)
-                });
-
-            combinedFilter =
-                new AdvancedCriteria(OperatorId.OR, new Criterion[] {
-                    c1, c2, c3
-                });
-        }
-        locationsTable.filterData(combinedFilter);
-        distanceTable.filterData(combinedFilter);
-        filterResultCount.setValue(currentFiltered.getRecords().length);
+        this.locationsTable.filterData(combinedFilter);
+        this.distanceTable.filterData(combinedFilter);
+        this.filterResultCount.setValue(this.currentFiltered.getRecords().length);
     }
 
-
     @Override
     public List<String> validate() {
         if (isLocationMode()) {
             return validateLocations();
-        }
-        else {
+        } else {
             return validateRange();
         }
     }
 
-
     protected List<String> validateLocations() {
-        List<String> errors = new ArrayList<String>();
-        NumberFormat nf     = NumberFormat.getDecimalFormat();
+        final List<String> errors = new ArrayList<String>();
+        final NumberFormat nf = NumberFormat.getDecimalFormat();
 
         try {
-            saveLocationValues(locationPanel);
+            saveLocationValues(this.locationPanel);
         }
-        catch (Exception e) {
-            errors.add(MESSAGES.wrongFormat());
+        catch (final Exception e) {
+            errors.add(this.MESSAGES.wrongFormat());
         }
 
-        double[] values = getLocationValues();
-        double[] good   = new double[values.length];
-        int      idx    = 0;
+        final double[] values = getLocationValues();
+        final double[] good = new double[values.length];
+        int idx = 0;
 
-        for (double value: values) {
-            if (value < min || value > max) {
-                String tmp = MESSAGES.error_validate_range();
+        for (final double value : values) {
+            if (value < this.min || value > this.max) {
+                String tmp = this.MESSAGES.error_validate_range();
                 tmp = tmp.replace("$1", nf.format(value));
-                tmp = tmp.replace("$2", nf.format(min));
-                tmp = tmp.replace("$3", nf.format(max));
+                tmp = tmp.replace("$2", nf.format(this.min));
+                tmp = tmp.replace("$3", nf.format(this.max));
                 errors.add(tmp);
-            }
-            else {
+            } else {
                 good[idx++] = value;
             }
         }
 
-        double[] justGood = new double[idx];
+        final double[] justGood = new double[idx];
         for (int i = 0; i < justGood.length; i++) {
             justGood[i] = good[i];
         }
 
         if (!errors.isEmpty()) {
-            locationPanel.setValues(justGood);
+            this.locationPanel.setValues(justGood);
         }
 
         return errors;
     }
 
-
     protected List<String> validateRange() {
-        List<String> errors = new ArrayList<String>();
-        NumberFormat nf     = NumberFormat.getDecimalFormat();
+        final List<String> errors = new ArrayList<String>();
+        final NumberFormat nf = NumberFormat.getDecimalFormat();
 
         try {
-            saveDistanceValues(distancePanel);
+            saveDistanceValues(this.distancePanel);
         }
-        catch (Exception e) {
-            errors.add(MESSAGES.wrongFormat());
+        catch (final Exception e) {
+            errors.add(this.MESSAGES.wrongFormat());
         }
 
         double from = getFrom();
-        double to   = getTo();
-        double step = getStep();
+        double to = getTo();
+        final double step = getStep();
 
-        if (from < min || from > max) {
-            String tmp = MESSAGES.error_validate_range();
+        if (from < this.min || from > this.max) {
+            String tmp = this.MESSAGES.error_validate_range();
             tmp = tmp.replace("$1", nf.format(from));
-            tmp = tmp.replace("$2", nf.format(min));
-            tmp = tmp.replace("$3", nf.format(max));
+            tmp = tmp.replace("$2", nf.format(this.min));
+            tmp = tmp.replace("$3", nf.format(this.max));
             errors.add(tmp);
-            from = min;
+            from = this.min;
         }
 
-        if (to < min || to > max) {
-            String tmp = MESSAGES.error_validate_range();
+        if (to < this.min || to > this.max) {
+            String tmp = this.MESSAGES.error_validate_range();
             tmp = tmp.replace("$1", nf.format(to));
-            tmp = tmp.replace("$2", nf.format(min));
-            tmp = tmp.replace("$3", nf.format(max));
+            tmp = tmp.replace("$2", nf.format(this.min));
+            tmp = tmp.replace("$3", nf.format(this.max));
             errors.add(tmp);
-            to = max;
+            to = this.max;
         }
 
         if (!errors.isEmpty()) {
-            distancePanel.setValues(from, to, step);
+            this.distancePanel.setValues(from, to, step);
         }
 
         return errors;
     }
 
-
     /**
      * This method returns the selected data.
      *
@@ -849,52 +808,46 @@
      */
     @Override
     public Data[] getData() {
-        List<Data> data = new ArrayList<Data>();
+        final List<Data> data = new ArrayList<Data>();
 
         // If we have entered a value and click right afterwards on the
         // 'next' button, the BlurEvent is not fired, and the values are not
         // saved. So, we gonna save those values explicitly.
         if (isLocationMode()) {
-            Canvas member = container.getMember(0);
+            final Canvas member = this.container.getMember(0);
             if (member instanceof DoubleArrayPanel) {
-                DoubleArrayPanel form = (DoubleArrayPanel) member;
+                final DoubleArrayPanel form = (DoubleArrayPanel) member;
                 saveLocationValues(form);
             }
 
-            Data dLocations = getDataLocations();
-            DataItem dFrom  = new DefaultDataItem("ld_from", "ld_from", "");
-            DataItem dTo    = new DefaultDataItem("ld_to", "ld_to", "");
-            DataItem dStep  = new DefaultDataItem("ld_step", "ld_step", "");
+            final Data dLocations = getDataLocations();
+            final DataItem dFrom = new DefaultDataItem("ld_from", "ld_from", "");
+            final DataItem dTo = new DefaultDataItem("ld_to", "ld_to", "");
+            final DataItem dStep = new DefaultDataItem("ld_step", "ld_step", "");
 
             data.add(dLocations);
-            data.add(new DefaultData(
-                "ld_from", null, null, new DataItem[] { dFrom } ));
-            data.add(new DefaultData(
-                "ld_to", null, null, new DataItem[] { dTo } ));
-            data.add(new DefaultData(
-                "ld_step", null, null, new DataItem[] { dStep } ));
-        }
-        else {
-            Canvas member = container.getMember(0);
+            data.add(new DefaultData("ld_from", null, null, new DataItem[] { dFrom }));
+            data.add(new DefaultData("ld_to", null, null, new DataItem[] { dTo }));
+            data.add(new DefaultData("ld_step", null, null, new DataItem[] { dStep }));
+        } else {
+            final Canvas member = this.container.getMember(0);
             if (member instanceof DoubleRangePanel) {
-                DoubleRangePanel form = (DoubleRangePanel) member;
+                final DoubleRangePanel form = (DoubleRangePanel) member;
                 saveDistanceValues(form);
             }
 
-            Data dFrom   = getDataFrom();
-            Data dTo     = getDataTo();
-            Data dStep   = getDataStep();
-            DataItem loc = new DefaultDataItem(
-                "ld_locations", "ld_locations","");
+            final Data dFrom = getDataFrom();
+            final Data dTo = getDataTo();
+            final Data dStep = getDataStep();
+            final DataItem loc = new DefaultDataItem("ld_locations", "ld_locations", "");
 
             data.add(dFrom);
             data.add(dTo);
             data.add(dStep);
-            data.add(new DefaultData(
-                "ld_locations", null, null, new DataItem[] { loc } ));
+            data.add(new DefaultData("ld_locations", null, null, new DataItem[] { loc }));
         }
 
-        Data dMode = getDataMode();
+        final Data dMode = getDataMode();
         if (dMode != null) {
             data.add(dMode);
         }
@@ -902,30 +855,28 @@
         return data.toArray(new Data[data.size()]);
     }
 
-
     /**
      * Returns the Data object for the 'mode' attribute.
      *
      * @return the Data object for the 'mode' attribute.
      */
     protected Data getDataMode() {
-        String   value = mode.getValueAsString(FIELD_MODE);
-        DataItem item  = new DefaultDataItem("ld_mode", "ld_mode", value);
+        final String value = this.mode.getValueAsString(FIELD_MODE);
+        final DataItem item = new DefaultDataItem("ld_mode", "ld_mode", value);
         return new DefaultData("ld_mode", null, null, new DataItem[] { item });
     }
 
-
     protected Data getDataLocations() {
-        double[] locations = getLocationValues();
-        boolean  first     = true;
+        final double[] locations = getLocationValues();
+        boolean first = true;
 
         if (locations == null) {
             return null;
         }
 
-        StringBuilder sb = new StringBuilder();
+        final StringBuilder sb = new StringBuilder();
 
-        for (double l: locations) {
+        for (final double l : locations) {
             if (!first) {
                 sb.append(" ");
             }
@@ -935,210 +886,193 @@
             first = false;
         }
 
-        DataItem item = new DefaultDataItem(
-            "ld_locations",
-            "ld_locations",
-            sb.toString());
+        final DataItem item = new DefaultDataItem("ld_locations", "ld_locations", sb.toString());
 
-        return new DefaultData(
-            "ld_locations",
-            null,
-            null,
-            new DataItem[] { item });
+        return new DefaultData("ld_locations", null, null, new DataItem[] { item });
     }
 
-
     /**
      * Returns the Data object for the 'from' attribute.
      *
      * @return the Data object for the 'from' attribute.
      */
     protected Data getDataFrom() {
-        String value  = Double.valueOf(getFrom()).toString();
-        DataItem item = new DefaultDataItem("ld_from", "ld_from", value);
-        return new DefaultData(
-            "ld_from", null, null, new DataItem[] { item });
+        final String value = Double.valueOf(getFrom()).toString();
+        final DataItem item = new DefaultDataItem("ld_from", "ld_from", value);
+        return new DefaultData("ld_from", null, null, new DataItem[] { item });
     }
 
-
     /**
      * Returns the Data object for the 'to' attribute.
      *
      * @return the Data object for the 'to' attribute.
      */
     protected Data getDataTo() {
-        String value  = Double.valueOf(getTo()).toString();
-        DataItem item = new DefaultDataItem("ld_to", "ld_to", value);
-        return new DefaultData(
-            "ld_to", null, null, new DataItem[] { item });
+        final String value = Double.valueOf(getTo()).toString();
+        final DataItem item = new DefaultDataItem("ld_to", "ld_to", value);
+        return new DefaultData("ld_to", null, null, new DataItem[] { item });
     }
 
-
     /**
      * Returns the Data object for the 'step' attribute.
      *
      * @return the Data object for the 'step' attribute.
      */
     protected Data getDataStep() {
-        String value  = Double.valueOf(getStep()).toString();
-        DataItem item = new DefaultDataItem("ld_step","ld_step", value);
-        return new DefaultData(
-            "ld_step", null, null, new DataItem[] { item });
+        final String value = Double.valueOf(getStep()).toString();
+        final DataItem item = new DefaultDataItem("ld_step", "ld_step", value);
+        return new DefaultData("ld_step", null, null, new DataItem[] { item });
     }
 
-
     /**
      * Determines the current input mode.
      *
      * @return true, if 'location' is the current input mode, otherwise false.
      */
     public boolean isLocationMode() {
-        String inputMode = mode.getValueAsString(FIELD_MODE);
+        final String inputMode = this.mode.getValueAsString(FIELD_MODE);
 
         return inputMode.equals(FIELD_VALUE_LOCATION) ? true : false;
     }
 
-
     /**
      * Activates the location panel.
      */
     protected void enableLocationMode() {
-        mode.setValue(FIELD_MODE, FIELD_VALUE_LOCATION);
-        container.hideMember(distancePanel);
-        container.showMember(locationPanel);
-        setupDistanceInfoTable(locationsTable, false, false);
-        setupDistanceInfoTable(distanceTable, true, true);
-        inputTables.updateTab(0, locationsTable);
-        inputTables.updateTab(1, distanceTable);
+        this.mode.setValue(FIELD_MODE, FIELD_VALUE_LOCATION);
+        this.container.hideMember(this.distancePanel);
+        this.container.showMember(this.locationPanel);
+        setupDistanceInfoTable(this.locationsTable, false, false);
+        setupDistanceInfoTable(this.distanceTable, true, true);
+        this.inputTables.updateTab(0, this.locationsTable);
+        this.inputTables.updateTab(1, this.distanceTable);
     }
 
-
     /**
      * Activates the distance panel.
      */
     protected void enableDistanceMode() {
-        mode.setValue(FIELD_MODE, FIELD_VALUE_DISTANCE);
-        container.hideMember(locationPanel);
-        container.showMember(distancePanel);
-        setupDistanceInfoTable(locationsTable, true, false);
-        setupDistanceInfoTable(distanceTable, false, true);
-        inputTables.updateTab(0, locationsTable);
-        inputTables.updateTab(1, distanceTable);
+        this.mode.setValue(FIELD_MODE, FIELD_VALUE_DISTANCE);
+        this.container.hideMember(this.locationPanel);
+        this.container.showMember(this.distancePanel);
+        setupDistanceInfoTable(this.locationsTable, true, false);
+        setupDistanceInfoTable(this.distanceTable, false, true);
+        this.inputTables.updateTab(0, this.locationsTable);
+        this.inputTables.updateTab(1, this.distanceTable);
     }
 
-
     /**
      * This method switches the input mode between location and distance input.
      *
-     * @param event The click event fired by a RadioButtonGroupItem.
+     * @param event
+     *            The click event fired by a RadioButtonGroupItem.
      */
     @Override
-    public void onChange(ChangeEvent event) {
-        String value = (String) event.getValue();
+    public void onChange(final ChangeEvent event) {
+        final String value = (String) event.getValue();
 
         if (value == null) {
             return;
         }
         if (value.equals(FIELD_VALUE_LOCATION)) {
             enableLocationMode();
-            filterDescription.clear();
-            filterRange.clear();
-            filterResultCount.setValue("");
+            this.filterDescription.clear();
+            this.filterRange.clear();
+            this.filterResultCount.setValue("");
 
             // Bring this tab to front.
-            inputTables.selectTab(0);
-        }
-        else {
+            this.inputTables.selectTab(0);
+        } else {
             enableDistanceMode();
-            filterDescription.clear();
-            filterRange.clear();
-            filterResultCount.setValue("");
+            this.filterDescription.clear();
+            this.filterRange.clear();
+            this.filterResultCount.setValue("");
 
             // Bring the distanceTable tab to front.
-            inputTables.selectTab(1);
+            this.inputTables.selectTab(1);
         }
     }
 
-
     /**
      * This method is used to validate the inserted data in the form fields.
      *
-     * @param event The BlurEvent that gives information about the FormItem that
-     * has been modified and its value.
+     * @param event
+     *            The BlurEvent that gives information about the FormItem that
+     *            has been modified and its value.
      */
     @Override
-    public void onBlur(BlurEvent event) {
-        FormItem item = event.getItem();
-        String  field = item.getFieldName();
+    public void onBlur(final BlurEvent event) {
+        final FormItem item = event.getItem();
+        final String field = item.getFieldName();
 
         if (field == null) {
             return;
         }
 
         if (field.equals(DoubleArrayPanel.FIELD_NAME)) {
-            DoubleArrayPanel p = (DoubleArrayPanel) event.getForm();
+            final DoubleArrayPanel p = (DoubleArrayPanel) event.getForm();
 
             saveLocationValue(p, item);
-        }
-        else {
-            DoubleRangePanel p = (DoubleRangePanel) event.getForm();
+        } else {
+            final DoubleRangePanel p = (DoubleRangePanel) event.getForm();
 
             saveDistanceValue(p, item);
         }
     }
 
-
-
     /**
      * Validates and stores all values entered in the location mode.
      *
-     * @param p The DoubleArrayPanel.
+     * @param p
+     *            The DoubleArrayPanel.
      */
-    protected void saveLocationValues(DoubleArrayPanel p) {
-        FormItem[] formItems = p.getFields();
+    protected void saveLocationValues(final DoubleArrayPanel p) {
+        final FormItem[] formItems = p.getFields();
 
-        for (FormItem item: formItems) {
+        for (final FormItem item : formItems) {
             if (item.getFieldName().equals(DoubleArrayPanel.FIELD_NAME)) {
                 saveLocationValue(p, item);
             }
         }
     }
 
-
     /**
      * Validates and stores all values entered in the distance mode.
      *
-     * @param p The DoubleRangePanel.
+     * @param p
+     *            The DoubleRangePanel.
      */
-    protected void saveDistanceValues(DoubleRangePanel p) {
-        FormItem[] formItems = p.getFields();
+    protected void saveDistanceValues(final DoubleRangePanel p) {
+        final FormItem[] formItems = p.getFields();
 
-        for (FormItem item: formItems) {
+        for (final FormItem item : formItems) {
             saveDistanceValue(p, item);
         }
     }
 
-
     /**
      * Validates and stores a value entered in the location mode.
      *
-     * @param p The DoubleArrayPanel.
-     * @param item The item that needs to be validated.
+     * @param p
+     *            The DoubleArrayPanel.
+     * @param item
+     *            The item that needs to be validated.
      */
-    protected void saveLocationValue(DoubleArrayPanel p, FormItem item) {
+    protected void saveLocationValue(final DoubleArrayPanel p, final FormItem item) {
         if (p.validateForm(item)) {
             setLocationValues(p.getInputValues(item));
         }
     }
 
-
     /**
      * Validates and stores value entered in the distance mode.
      *
-     * @param p The DoubleRangePanel.
-     * @param item The item that needs to be validated.
+     * @param p
+     *            The DoubleRangePanel.
+     * @param item
+     *            The item that needs to be validated.
      */
-    protected void saveDistanceValue(DoubleRangePanel p, FormItem item) {
+    protected void saveDistanceValue(final DoubleRangePanel p, final FormItem item) {
         if (p.validateForm(item)) {
             setFrom(p.getFrom());
             setTo(p.getTo());
@@ -1146,7 +1080,6 @@
         }
     }
 
-
     /**
      * This method creates the panel that contains the checkboxes to switch
      * between the input mode 'location' and 'distance'.
@@ -1154,161 +1087,148 @@
      * @return the checkbox panel.
      */
     protected Canvas createRadioButtonPanel() {
-        mode = new DynamicForm();
+        this.mode = new DynamicForm();
 
-        RadioGroupItem radio = new RadioGroupItem(FIELD_MODE);
+        final RadioGroupItem radio = new RadioGroupItem(FIELD_MODE);
         radio.setShowTitle(false);
         radio.setVertical(false);
         radio.setWrap(false);
 
-        LinkedHashMap<String, String> values =
-            new LinkedHashMap<String, String>();
-        values.put(FIELD_VALUE_LOCATION, MESSAGES.location());
-        values.put(FIELD_VALUE_DISTANCE, MESSAGES.distance());
+        final LinkedHashMap<String, String> values = new LinkedHashMap<String, String>();
+        values.put(FIELD_VALUE_LOCATION, this.MESSAGES.location());
+        values.put(FIELD_VALUE_DISTANCE, this.MESSAGES.distance());
 
-        LinkedHashMap<String, String> initial =
-            new LinkedHashMap<String, String>();
+        final LinkedHashMap<String, String> initial = new LinkedHashMap<String, String>();
         initial.put(FIELD_MODE, FIELD_VALUE_DISTANCE);
 
         radio.setValueMap(values);
         radio.addChangeHandler(this);
 
-        mode.setFields(radio);
-        mode.setValues(initial);
+        this.mode.setFields(radio);
+        this.mode.setValues(initial);
 
-        return mode;
+        return this.mode;
     }
 
+    protected void createDistanceInputPanel() {
+        final Config config = Config.getInstance();
+        final String url = config.getServerUrl();
+        String river = "";
 
-    protected void createDistanceInputPanel() {
-        Config config = Config.getInstance();
-        String url    = config.getServerUrl();
-        String river  = "";
-
-        ArtifactDescription adescr = artifact.getArtifactDescription();
-        DataList[] data = adescr.getOldData();
+        final ArtifactDescription adescr = this.artifact.getArtifactDescription();
+        final DataList[] data = adescr.getOldData();
 
         if (data != null && data.length > 0) {
-            for (int i = 0; i < data.length; i++) {
-                DataList dl = data[i];
+            for (final DataList dl : data) {
                 if (dl.getState().endsWith("river")) {
                     for (int j = 0; j < dl.size(); j++) {
-                        Data d = dl.get(j);
-                        DataItem[] di = d.getItems();
+                        final Data d = dl.get(j);
+                        final DataItem[] di = d.getItems();
                         if (di != null && di.length == 1) {
-                           river = d.getItems()[0].getStringValue();
+                            river = d.getItems()[0].getStringValue();
                         }
                     }
                 }
             }
         }
 
-        distanceTable.setDataSource(new DistanceInfoDataSource(
-            url, river, "distances"));
-        locationsTable.setDataSource(new DistanceInfoDataSource(
-            url, river, "locations"));
+        this.distanceTable.setDataSource(new DistanceInfoDataSource(url, river, "distances"));
+        this.locationsTable.setDataSource(new DistanceInfoDataSource(url, river, "locations"));
     }
 
     protected double getFrom() {
-        return from;
+        return this.from;
     }
 
-    protected void setTo(String to) {
-       try {
-            double toValue = Double.parseDouble(to);
+    protected void setTo(final String to) {
+        try {
+            final double toValue = Double.parseDouble(to);
             setTo(toValue);
         }
-        catch(NumberFormatException nfe) {
+        catch (final NumberFormatException nfe) {
             // Is there anything to do?
         }
     }
 
-    protected void setFrom(String from) {
-       try {
-            double fromValue = Double.parseDouble(from);
+    protected void setFrom(final String from) {
+        try {
+            final double fromValue = Double.parseDouble(from);
             setFrom(fromValue);
         }
-        catch(NumberFormatException nfe) {
+        catch (final NumberFormatException nfe) {
             // Is there anything to do?
         }
     }
 
-    protected void setFrom(double from) {
+    protected void setFrom(final double from) {
         this.from = from;
         /* The doubling should be removed and this.from abolished */
-        distancePanel.setFrom(from);
+        this.distancePanel.setFrom(from);
     }
 
-
     protected double getTo() {
-        return to;
+        return this.to;
     }
 
-
-    protected void setTo(double to) {
+    protected void setTo(final double to) {
         this.to = to;
         /* The doubling should be removed and this.to abolished */
-        distancePanel.setTo(to);
+        this.distancePanel.setTo(to);
     }
 
-
     protected double getStep() {
-        return step;
+        return this.step;
     }
 
-
-    protected void setStep(double step) {
+    protected void setStep(final double step) {
         this.step = step;
     }
 
-
     protected double[] getLocationValues() {
-        return values;
+        return this.values;
     }
 
-    protected void appendLocation(String loc) {
+    protected void appendLocation(final String loc) {
         double[] selected;
         if (getLocationValues() != null) {
-            double[] val = getLocationValues();
+            final double[] val = getLocationValues();
             selected = new double[val.length + 1];
-            for(int i = 0; i < val.length; i++){
+            for (int i = 0; i < val.length; i++) {
                 selected[i] = val[i];
             }
             try {
                 selected[val.length] = Double.parseDouble(loc);
             }
-            catch(NumberFormatException nfe) {
+            catch (final NumberFormatException nfe) {
                 // Is there anything to do here?
             }
-        }
-        else {
+        } else {
             selected = new double[1];
             selected[0] = Double.parseDouble(loc);
         }
         setLocationValues(selected);
     }
 
-    protected void setLocationValues(double[] values) {
+    protected void setLocationValues(final double[] values) {
         this.values = values;
-        locationPanel.setValues(values);
+        this.locationPanel.setValues(values);
     }
 
-
-    protected void setLocationValues(String values) {
-        String[] vs = values.split(" ");
+    protected void setLocationValues(final String values) {
+        final String[] vs = values.split(" ");
 
         if (vs == null) {
             return;
         }
 
-        double[] ds  = new double[vs.length];
-        int      idx = 0;
+        final double[] ds = new double[vs.length];
+        int idx = 0;
 
-        for (String s: vs) {
+        for (final String s : vs) {
             try {
                 ds[idx++] = Double.valueOf(s);
             }
-            catch (NumberFormatException nfe) {
+            catch (final NumberFormatException nfe) {
                 // do nothing
             }
         }
@@ -1316,11 +1236,10 @@
         setLocationValues(ds);
     }
 
-
-    protected void setDistanceValues (double from, double to) {
+    protected void setDistanceValues(final double from, final double to) {
         setFrom(from);
         setTo(to);
-        distancePanel.setValues(from, to, getStep());
+        this.distancePanel.setValues(from, to, getStep());
     }
 }
 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :
diff -r 06bb3e94a927 -r 34dc0163ad2d gwt-client/src/main/java/org/dive4elements/river/client/client/ui/WaterlevelGroundPanel.java
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/WaterlevelGroundPanel.java	Mon Jun 25 16:07:41 2018 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/WaterlevelGroundPanel.java	Mon Jun 25 17:58:11 2018 +0200
@@ -8,6 +8,10 @@
 
 package org.dive4elements.river.client.client.ui;
 
+import org.dive4elements.river.client.shared.model.Data;
+import org.dive4elements.river.client.shared.model.DataList;
+
+import com.smartgwt.client.widgets.Label;
 import com.smartgwt.client.widgets.form.validator.FloatRangeValidator;
 
 public class WaterlevelGroundPanel extends DistancePanel {
@@ -16,116 +20,106 @@
 
     public static final String FIELD_LOWER = "diff_from";
     public static final String FIELD_UPPER = "diff_to";
-    public static final String FIELD_STEP  = "diff_diff";
-
+    public static final String FIELD_STEP = "diff_diff";
 
     public WaterlevelGroundPanel() {
         super("left");
 
-        FloatRangeValidator frv = new FloatRangeValidator();
+        final FloatRangeValidator frv = new FloatRangeValidator();
         frv.setMin(0f);
         frv.setMax(Float.MAX_VALUE);
         frv.setValidateOnChange(true);
-        distancePanel.getToItem().setValidators(frv);
+        this.distancePanel.getToItem().setValidators(frv);
     }
 
-
     @Override
     protected String getLowerField() {
         return FIELD_LOWER;
     }
 
-
     @Override
     protected String getUpperField() {
         return FIELD_UPPER;
     }
 
-
     @Override
     protected String getStepField() {
         return FIELD_STEP;
     }
 
+    @Override
+    protected Label getLabel(final DataList data) {
+        final Data item = data.get(0);
+        return new Label(item.getDescription());//
 
-    @Override
-    protected String getLabel() {
-        return MSG.waterlevel_ground_state();
+        // item.getDescription()); // holt das Label vom Server (funktoniert schon sehr oft so!)
     }
 
+    // @Override
+    // protected String getLabel() {
+    // return MSG.waterlevel_ground_state();
+    // }
 
     @Override
     protected String labelFrom() {
         return getLabelFrom() + " [" + getUnitFrom() + "]";
     }
 
-
     @Override
     protected String getLabelFrom() {
-        return MSG.wgLabelFrom();
+        return this.MSG.wgLabelFrom();
     }
 
-
     @Override
     protected String getUnitFrom() {
-        return MSG.wgUnitFrom();
+        return this.MSG.wgUnitFrom();
     }
 
-
     @Override
     protected String labelTo() {
         return getLabelTo() + " [" + getUnitTo() + "]";
     }
 
-
     @Override
     protected String getLabelTo() {
-        return MSG.wgLabelTo();
+        return this.MSG.wgLabelTo();
     }
 
-
     @Override
     protected String getUnitTo() {
-        return MSG.wgUnitTo();
+        return this.MSG.wgUnitTo();
     }
 
-
     @Override
     protected String labelStep() {
         return getLabelStep() + " [" + getUnitStep() + "]";
     }
 
-
     @Override
     protected String getLabelStep() {
-        return MSG.wgLabelStep();
+        return this.MSG.wgLabelStep();
     }
 
-
     @Override
     protected String getUnitStep() {
-        return MSG.wgUnitStep();
+        return this.MSG.wgUnitStep();
     }
 
-
     @Override
     protected double getDefaultFrom() {
         return 0;
     }
 
-
     @Override
     protected double getDefaultTo() {
         return 2;
     }
 
-
     @Override
     protected double getDefaultStep() {
         return 0.5;
     }
 
-
     @Override
     protected void initHelperPanel() {
         // We don't need a helper panel here. But we have to override this
diff -r 06bb3e94a927 -r 34dc0163ad2d gwt-client/src/main/java/org/dive4elements/river/client/client/ui/minfo/SedLoadDistancePanel.java
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/minfo/SedLoadDistancePanel.java	Mon Jun 25 16:07:41 2018 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/minfo/SedLoadDistancePanel.java	Mon Jun 25 17:58:11 2018 +0200
@@ -10,17 +10,6 @@
 
 import java.util.List;
 
-import com.smartgwt.client.data.Record;
-import com.smartgwt.client.util.SC;
-import com.smartgwt.client.widgets.Canvas;
-import com.smartgwt.client.widgets.Label;
-import com.smartgwt.client.widgets.form.fields.events.BlurEvent;
-import com.smartgwt.client.widgets.form.fields.events.BlurHandler;
-import com.smartgwt.client.widgets.grid.events.CellClickEvent;
-import com.smartgwt.client.widgets.grid.events.CellClickHandler;
-import com.smartgwt.client.widgets.layout.HLayout;
-import com.smartgwt.client.widgets.layout.VLayout;
-
 import org.dive4elements.river.client.client.Config;
 import org.dive4elements.river.client.client.ui.AbstractUIProvider;
 import org.dive4elements.river.client.client.ui.DoubleRangeOnlyPanel;
@@ -34,11 +23,18 @@
 import org.dive4elements.river.client.shared.model.DefaultData;
 import org.dive4elements.river.client.shared.model.DefaultDataItem;
 
+import com.smartgwt.client.data.Record;
+import com.smartgwt.client.util.SC;
+import com.smartgwt.client.widgets.Canvas;
+import com.smartgwt.client.widgets.Label;
+import com.smartgwt.client.widgets.form.fields.events.BlurEvent;
+import com.smartgwt.client.widgets.form.fields.events.BlurHandler;
+import com.smartgwt.client.widgets.grid.events.CellClickEvent;
+import com.smartgwt.client.widgets.grid.events.CellClickHandler;
+import com.smartgwt.client.widgets.layout.HLayout;
+import com.smartgwt.client.widgets.layout.VLayout;
 
-public class SedLoadDistancePanel
-extends AbstractUIProvider
-implements BlurHandler, CellClickHandler
-{
+public class SedLoadDistancePanel extends AbstractUIProvider implements BlurHandler, CellClickHandler {
     public static final String FIELD_LOWER = "ld_from";
     public static final String FIELD_UPPER = "ld_to";
 
@@ -48,14 +44,14 @@
     protected LocationPicker picker;
 
     @Override
-    public Canvas createOld(DataList dataList) {
-        String s = getOldSelectionString(dataList);
-        String l = dataList.getLabel();
+    public Canvas createOld(final DataList dataList) {
+        final String s = getOldSelectionString(dataList);
+        final String l = dataList.getLabel();
 
-        Label label    = new Label(l);
-        Label selected = new Label(s);
+        final Label label = new Label(l);
+        final Label selected = new Label(s);
 
-        HLayout layout = new HLayout();
+        final HLayout layout = new HLayout();
 
         layout.setWidth(400);
         label.setWidth(200);
@@ -68,174 +64,171 @@
         return layout;
     }
 
-    protected String getOldSelectionString(DataList dataList) {
-        List<Data> items = dataList.getAll();
+    protected String getOldSelectionString(final DataList dataList) {
+        final List<Data> items = dataList.getAll();
 
-        Data dFrom = getData(items, FIELD_LOWER);
-        Data dTo   = getData(items, FIELD_UPPER);
+        final Data dFrom = getData(items, FIELD_LOWER);
+        final Data dTo = getData(items, FIELD_UPPER);
 
-        DataItem[] from = dFrom.getItems();
-        DataItem[] to   = dTo.getItems();
+        final DataItem[] from = dFrom.getItems();
+        final DataItem[] to = dTo.getItems();
 
-        StringBuilder sb = new StringBuilder();
+        final StringBuilder sb = new StringBuilder();
         sb.append(from[0].getLabel());
-        sb.append(" " + MSG.dpUnitFrom() + " - ");
+        sb.append(" " + this.MSG.dpUnitFrom() + " - ");
         sb.append(to[0].getLabel());
-        sb.append(" " + MSG.dpUnitTo());
+        sb.append(" " + this.MSG.dpUnitTo());
 
         return sb.toString();
     }
 
     @Override
-    public Canvas create(DataList data) {
-        picker = new LocationPicker(this);
-        distancePanel = new DoubleRangeOnlyPanel(
-            MSG.dpUnitFrom() + " - ",
-            MSG.dpUnitTo(), 0d, 0d, 250, this, "right");
-        VLayout layout = new VLayout();
+    public Canvas create(final DataList data) {
+        this.picker = new LocationPicker(this);
+        this.distancePanel = new DoubleRangeOnlyPanel(this.MSG.dpUnitFrom() + " - ", this.MSG.dpUnitTo(), 0d, 0d, 250, this, "right");
+        final VLayout layout = new VLayout();
         layout.setMembersMargin(10);
 
-        Label label = new Label(MSG.distance_state());
+        final Label label = getLabel(data);
 
-        Canvas submit = getNextButton();
+        final Canvas submit = getNextButton();
 
         label.setHeight(25);
-        distancePanel.setHeight(50);
+        this.distancePanel.setHeight(50);
 
         layout.addMember(label);
-        layout.addMember(distancePanel);
+        layout.addMember(this.distancePanel);
         layout.addMember(submit);
 
         initMinMaxValues(data);
         initDefaultValues(data);
 
+        this.picker.setIsDistance(true);
+        this.picker.getLocationTable().setAutoFetchData(true);
+        this.picker.prepareFilter();
 
-        picker.setIsDistance(true);
-        picker.getLocationTable().setAutoFetchData(true);
-        picker.prepareFilter();
-
-        helperContainer.addMember(picker.getLocationTable());
-        helperContainer.addMember(picker.getFilterLayout());
-        helperContainer.addMember(picker.getResultCountForm());
+        this.helperContainer.addMember(this.picker.getLocationTable());
+        this.helperContainer.addMember(this.picker.getFilterLayout());
+        this.helperContainer.addMember(this.picker.getResultCountForm());
 
         setPickerDataSource();
-        picker.createLocationTable();
+        this.picker.createLocationTable();
 
         return layout;
     }
 
-    protected void initMinMaxValues(DataList data) {
-        Data f = getData(data.getAll(), FIELD_LOWER);
-        Data t = getData(data.getAll(), FIELD_UPPER);
+    protected void initMinMaxValues(final DataList data) {
+        final Data f = getData(data.getAll(), FIELD_LOWER);
+        final Data t = getData(data.getAll(), FIELD_UPPER);
 
-        DataItem[] fItems = f.getItems();
-        DataItem[] tItems = t.getItems();
+        final DataItem[] fItems = f.getItems();
+        final DataItem[] tItems = t.getItems();
 
         try {
-            min = Double.valueOf(fItems[0].getStringValue());
-            max = Double.valueOf(tItems[0].getStringValue());
+            this.min = Double.valueOf(fItems[0].getStringValue());
+            this.max = Double.valueOf(tItems[0].getStringValue());
         }
-        catch (NumberFormatException nfe) {
-            min = -Double.MAX_VALUE;
-            max =  Double.MAX_VALUE;
+        catch (final NumberFormatException nfe) {
+            this.min = -Double.MAX_VALUE;
+            this.max = Double.MAX_VALUE;
         }
     }
 
-    protected void initDefaultValues(DataList data) {
+    protected void initDefaultValues(final DataList data) {
         initDefaultFrom(data);
         initDefaultTo(data);
     }
 
-    protected void initDefaultFrom(DataList data) {
-        Data f = getData(data.getAll(), FIELD_LOWER);
+    private Label getLabel(final DataList data) {
+        final Data item = data.get(0);
+        // if (data.getState().contains("uinfo")) { // "Wahl der Berechnungsstrecke/des Darstellungsbereichs" (server) vs.
+        // "Berechnungsstrecke wählen" (client)
+        return new Label(item.getDescription()); // holt das Label vom Server (funktoniert schon sehr oft so!)
+        // }
+        // return new Label(getLabel()); // holt das Label aus den Flys-Constants..
+    }
+
+    protected void initDefaultFrom(final DataList data) {
+        final Data f = getData(data.getAll(), FIELD_LOWER);
 
         double from = getDefaultFrom();
 
         try {
             from = getDefaultValue(f);
         }
-        catch (NumberFormatException nfe) {
+        catch (final NumberFormatException nfe) {
             // do nothing
         }
 
-        distancePanel.setFrom(from);
+        this.distancePanel.setFrom(from);
     }
 
-
     protected double getDefaultFrom() {
-        return min;
+        return this.min;
     }
 
-
-    protected void initDefaultTo(DataList data) {
-        Data t = getData(data.getAll(), FIELD_UPPER);
+    protected void initDefaultTo(final DataList data) {
+        final Data t = getData(data.getAll(), FIELD_UPPER);
 
         double to = getDefaultTo();
 
         try {
             to = getDefaultValue(t);
         }
-        catch (NumberFormatException nfe) {
+        catch (final NumberFormatException nfe) {
             // do nothing
         }
 
-        distancePanel.setTo(to);
+        this.distancePanel.setTo(to);
     }
 
-
     protected double getDefaultTo() {
-        return max;
+        return this.max;
     }
 
-    protected double getDefaultValue(Data data)
-    throws NumberFormatException
-    {
-        DataItem def      = data.getDefault();
-        String   defValue = def != null ? def.getStringValue() : null;
+    protected double getDefaultValue(final Data data) throws NumberFormatException {
+        final DataItem def = data.getDefault();
+        final String defValue = def != null ? def.getStringValue() : null;
 
         return Double.valueOf(defValue);
     }
 
     /** Hook service to the listgrid with possible input values. */
     protected void setPickerDataSource() {
-        Config config = Config.getInstance();
-        String url    = config.getServerUrl();
-        String river  = "";
+        final Config config = Config.getInstance();
+        final String url = config.getServerUrl();
+        String river = "";
 
-        ArtifactDescription adescr = artifact.getArtifactDescription();
-        DataList[] data = adescr.getOldData();
+        final ArtifactDescription adescr = this.artifact.getArtifactDescription();
+        final DataList[] data = adescr.getOldData();
 
         // Try to find a "river" data item to set the source for the
         // list grid.
         String dataFilter = "locations";
         if (data != null && data.length > 0) {
-            for (int i = 0; i < data.length; i++) {
-                DataList dl = data[i];
+            for (final DataList dl : data) {
                 if (dl.getState().equals("state.minfo.river")) {
                     dataFilter = "measuringpoint";
                 }
-                if (dl.getState().equals("state.winfo.river") ||
-                    dl.getState().equals("state.chart.river") ||
-                    dl.getState().equals("state.minfo.river")) {
+                if (dl.getState().equals("state.winfo.river") || dl.getState().equals("state.chart.river") || dl.getState().equals("state.minfo.river")) {
                     for (int j = 0; j < dl.size(); j++) {
-                        Data d = dl.get(j);
-                        DataItem[] di = d.getItems();
+                        final Data d = dl.get(j);
+                        final DataItem[] di = d.getItems();
                         if (di != null && di.length == 1) {
-                           river = d.getItems()[0].getStringValue();
-                           break;
+                            river = d.getItems()[0].getStringValue();
+                            break;
                         }
                     }
                 }
             }
         }
 
-        picker.getLocationTable().setDataSource(new DistanceInfoDataSource(
-            url, river, dataFilter));
+        this.picker.getLocationTable().setDataSource(new DistanceInfoDataSource(url, river, dataFilter));
     }
 
     @Override
     protected Data[] getData() {
-        Data[] data = new Data[2];
+        final Data[] data = new Data[2];
 
         data[0] = getDataFrom();
         data[1] = getDataTo();
@@ -244,42 +237,45 @@
     }
 
     protected Data getDataFrom() {
-        String value = String.valueOf(distancePanel.getFrom());
-        String field = FIELD_LOWER;
+        final String value = String.valueOf(this.distancePanel.getFrom());
+        final String field = FIELD_LOWER;
 
-        DataItem item = new DefaultDataItem(field, field, value);
-        return new DefaultData(
-            field, null, null, new DataItem[] { item });
+        final DataItem item = new DefaultDataItem(field, field, value);
+        return new DefaultData(field, null, null, new DataItem[] { item });
     }
 
     protected Data getDataTo() {
-        String value = String.valueOf(distancePanel.getTo());
-        String field = FIELD_UPPER;
+        final String value = String.valueOf(this.distancePanel.getTo());
+        final String field = FIELD_UPPER;
 
-        DataItem item = new DefaultDataItem(field, field, value);
-        return new DefaultData(
-            field, null, null, new DataItem[] { item });
+        final DataItem item = new DefaultDataItem(field, field, value);
+        return new DefaultData(field, null, null, new DataItem[] { item });
     }
 
     @Override
-    public void onBlur(BlurEvent event) {
-        distancePanel.validateForm();
+    public void onBlur(final BlurEvent event) {
+        this.distancePanel.validateForm();
     }
 
     @Override
-    public void onCellClick(CellClickEvent e) {
-        Record record = e.getRecord();
-        int ndx = e.getColNum();
-        String from   = record.getAttribute("from");
+    public void onCellClick(final CellClickEvent e) {
+        final Record record = e.getRecord();
+        final int ndx = e.getColNum();
+        final String from = record.getAttribute("from");
         try {
-            double value = Double.valueOf(from);
+            final double value = Double.valueOf(from);
             switch (ndx) {
-                case 0: distancePanel.setFrom(value); break;
-                case 1: distancePanel.setTo(value); break;
+            case 0:
+                this.distancePanel.setFrom(value);
+                break;
+            case 1:
+                this.distancePanel.setTo(value);
+                break;
             }
         }
-        catch(NumberFormatException nfe) {
-            SC.warn(MSG.wrongFormat());
+        catch (final NumberFormatException nfe) {
+            SC.warn(this.MSG.wrongFormat());
         }
     }
+
 }


More information about the Dive4Elements-commits mailing list