Mercurial > dive4elements > river
changeset 1369:1fae113b93fd
Issue 118/203.
Lock table for Q input and clear values on input change.
Updated i18n strings.
flys-client/trunk@3074 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Raimund Renkert <raimund.renkert@intevation.de> |
---|---|
date | Tue, 25 Oct 2011 13:32:16 +0000 |
parents | ec0c81f2c7a4 |
children | 9085cffbb7c4 |
files | flys-client/ChangeLog flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.properties flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_de.properties flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_en.properties flys-client/src/main/java/de/intevation/flys/client/client/ui/DoubleArrayPanel.java flys-client/src/main/java/de/intevation/flys/client/client/ui/WQInputPanel.java flys-client/src/main/java/de/intevation/flys/client/client/ui/wq/QDTable.java |
diffstat | 7 files changed, 37 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/flys-client/ChangeLog Tue Oct 25 12:41:16 2011 +0000 +++ b/flys-client/ChangeLog Tue Oct 25 13:32:16 2011 +0000 @@ -1,3 +1,22 @@ +2011-10-25 Raimund Renkert <raimund.renkert@intevation.de> + + Issue 118/203 + + * src/main/java/de/intevation/flys/client/client/ui/wq/QDTable.java: + Added attribute to lock the table if the input rows are hidden. + + * src/main/java/de/intevation/flys/client/client/ui/WQInputPanel.java: + Ignore clicks if the table is locked and clear values on input mehtod + change. + + * src/main/java/de/intevation/flys/client/client/ui/DoubleArrayPanel.java: + Clear the input values if the input array length is 0. + + * src/main/java/de/intevation/flys/client/client/FLYSConstants_en.properties, + src/main/java/de/intevation/flys/client/client/FLYSConstants.properties, + src/main/java/de/intevation/flys/client/client/FLYSConstants_de.properties: + Updated i18n strings. + 2011-10-25 Ingo Weinzierl <ingo@intevation.de> * src/main/java/de/intevation/flys/client/server/LoadArtifactServiceImpl.java,
--- a/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.properties Tue Oct 25 12:41:16 2011 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.properties Tue Oct 25 13:32:16 2011 +0000 @@ -93,7 +93,7 @@ helperPanelTitle = Input Support wqW = W at Gauge [cm] wqQ = Q [m\u00b3/s] -wqQGauge = Q [m\u00b3/s] at Gauge +wqQGauge = Discharge at Gauge wqSingle = Single values wqRange = Range unitWNN = W [NN+m]
--- a/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_de.properties Tue Oct 25 12:41:16 2011 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_de.properties Tue Oct 25 13:32:16 2011 +0000 @@ -94,7 +94,7 @@ helperPanelTitle = Eingabeunterst\u00fctzung wqW = W am Pegel [cm] wqQ = Q [m\u00b3/s] -wqQGauge = Q [m\u00b3/s] am Pegel +wqQGauge = Kennzeichnender Abfluss am Pegel wqSingle = Einzelwerte wqRange = Wertebereich unitWNN = W [NN+m]
--- a/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_en.properties Tue Oct 25 12:41:16 2011 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_en.properties Tue Oct 25 13:32:16 2011 +0000 @@ -88,7 +88,7 @@ helperPanelTitle = Input Support wqW = W at Gauge [cm] wqQ = Q [m³/s] -wqQGauge = Q [m³/s] at Gauge +wqQGauge = Discharge at Gauge wqSingle = Single values wqRange = Range unitWNN = W [NN+m]
--- a/flys-client/src/main/java/de/intevation/flys/client/client/ui/DoubleArrayPanel.java Tue Oct 25 12:41:16 2011 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/ui/DoubleArrayPanel.java Tue Oct 25 13:32:16 2011 +0000 @@ -100,6 +100,10 @@ public void setValues(double[] values) { NumberFormat f = NumberFormat.getDecimalFormat(); + if(values.length == 0) { + ti.clearValue(); + return; + } StringBuilder text = new StringBuilder(); boolean firstItem = true; if (values != null) {
--- a/flys-client/src/main/java/de/intevation/flys/client/client/ui/WQInputPanel.java Tue Oct 25 12:41:16 2011 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/ui/WQInputPanel.java Tue Oct 25 13:32:16 2011 +0000 @@ -167,7 +167,7 @@ protected void initTableListeners() { CellClickHandler handler = new CellClickHandler() { public void onCellClick(CellClickEvent e) { - if (isWMode()) { + if (isWMode() || qdTable.isLocked()) { return; } @@ -1118,6 +1118,8 @@ } else { qdTable.showIconFields(); + double[] empty = {}; + valuesQ = empty; } updatePanels(wqMode, inputMode);
--- a/flys-client/src/main/java/de/intevation/flys/client/client/ui/wq/QDTable.java Tue Oct 25 12:41:16 2011 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/ui/wq/QDTable.java Tue Oct 25 13:32:16 2011 +0000 @@ -22,6 +22,8 @@ /** The interface that provides the image resources. */ private FLYSImages IMAGES = GWT.create(FLYSImages.class); + protected boolean lockClick; + public QDTable() { setWidth100(); setHeight100(); @@ -60,12 +62,18 @@ public void hideIconFields () { hideField("max"); hideField("min"); + lockClick = true; } public void showIconFields() { showField("max"); showField("min"); + lockClick = false; + } + + public boolean isLocked() { + return lockClick; } }