changeset 6191:9b521dfb8920

Pass the FLYS instance to the InfoPanel class. It will be needed for the SSO wiki links. Part of flys/issue1265
author Bernhard Herzog <bh@intevation.de>
date Tue, 04 Jun 2013 17:38:35 +0200
parents 7aadc0e2e3fa
children 165020640d7b
files gwt-client/src/main/java/org/dive4elements/river/client/client/ui/stationinfo/GaugePanel.java gwt-client/src/main/java/org/dive4elements/river/client/client/ui/stationinfo/InfoPanel.java gwt-client/src/main/java/org/dive4elements/river/client/client/ui/stationinfo/MeasurementStationPanel.java
diffstat 3 files changed, 9 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/stationinfo/GaugePanel.java	Tue Jun 04 17:35:21 2013 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/stationinfo/GaugePanel.java	Tue Jun 04 17:38:35 2013 +0200
@@ -29,7 +29,7 @@
      * @param flys The FLYS object
      */
     public GaugePanel(FLYS flys) {
-        super(new GaugeListGrid(flys));
+        super(flys, new GaugeListGrid(flys));
     }
 
 
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/stationinfo/InfoPanel.java	Tue Jun 04 17:35:21 2013 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/stationinfo/InfoPanel.java	Tue Jun 04 17:38:35 2013 +0200
@@ -14,6 +14,7 @@
 import com.smartgwt.client.widgets.Canvas;
 import com.smartgwt.client.widgets.layout.SectionStackSection;
 import com.smartgwt.client.widgets.layout.VLayout;
+import org.dive4elements.river.client.client.FLYS;
 import org.dive4elements.river.client.client.FLYSConstants;
 import org.dive4elements.river.client.client.services.RiverInfoService;
 import org.dive4elements.river.client.client.services.RiverInfoServiceAsync;
@@ -26,6 +27,9 @@
  */
 public abstract class InfoPanel extends VLayout {
 
+    /** The instance of FLYS */
+    protected FLYS flys;
+
     /** SectionStackSection where this InfoPanel belongs in*/
     protected SectionStackSection section;
 
@@ -44,7 +48,7 @@
 
     public final static String SECTION_ID = "InfoPanelSection";
 
-    public InfoPanel(InfoListGrid listgrid) {
+    public InfoPanel(FLYS flys, InfoListGrid listgrid) {
         SectionStackSection section = new SectionStackSection();
         section.setExpanded(false);
         section.setTitle(getSectionTitle());
@@ -54,6 +58,8 @@
         setOverflow(Overflow.HIDDEN);
         setStyleName("infopanel");
 
+        this.flys = flys;
+
         section.setHidden(true);
         section.setItems(this);
         this.section = section;
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/stationinfo/MeasurementStationPanel.java	Tue Jun 04 17:35:21 2013 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/stationinfo/MeasurementStationPanel.java	Tue Jun 04 17:38:35 2013 +0200
@@ -27,7 +27,7 @@
      * @param flys The FLYS object
      */
     public MeasurementStationPanel(FLYS flys) {
-        super(new MeasurementStationListGrid(flys));
+        super(flys, new MeasurementStationListGrid(flys));
     }
 
     /**

http://dive4elements.wald.intevation.org