[Commits] r2436 - sandbox/mapgears/geoext.ux/ux/WMSBrowser/lib/GeoExt.ux/widgets

commits at geoext.org commits at geoext.org
Thu Oct 7 21:13:21 CEST 2010


Author: adube
Date: 2010-10-07 21:13:21 +0200 (Thu, 07 Oct 2010)
New Revision: 2436

Modified:
   sandbox/mapgears/geoext.ux/ux/WMSBrowser/lib/GeoExt.ux/widgets/WMSBrowser.js
Log:
#242, WMSBrowser fix in mapgears sandbox, right panel now 50% width

Modified: sandbox/mapgears/geoext.ux/ux/WMSBrowser/lib/GeoExt.ux/widgets/WMSBrowser.js
===================================================================
--- sandbox/mapgears/geoext.ux/ux/WMSBrowser/lib/GeoExt.ux/widgets/WMSBrowser.js	2010-10-07 17:54:00 UTC (rev 2435)
+++ sandbox/mapgears/geoext.ux/ux/WMSBrowser/lib/GeoExt.ux/widgets/WMSBrowser.js	2010-10-07 19:13:21 UTC (rev 2436)
@@ -281,6 +281,12 @@
      */
     gridPanel: null,
 
+    /** private: prperty[infoPanel]
+     *  :class:`Ext.Panel`  The panel where the description and map are
+     *                      displayed
+     */
+    infoPanel: null,
+
     /** private: property[centerPanel]
      *  :class:`Ext.form.FormPanel`  The panel used as a 'center' container
      */
@@ -399,25 +405,32 @@
             Ext.apply(this, {plugins: [new GeoExt.ux.plugins.WMSBrowserAlerts()]});
         }
 
+        this.infoPanel = new Ext.Panel({
+            anchor: '50% 100%',
+            x: '50%',
+            y: '0',
+                    region: 'east',
+                    width: '50%',
+            layout: 'border',
+            border: true,
+            items: [
+                this.createFormPanel(), 
+                this.mapPanelPreview
+            ]
+        });
+
         var centerPanel = new Ext.form.FormPanel({
             tbar: this.statusBar,
             region: 'center',
-            layout: 'absolute',
+            layout: 'border',
             border: false,
-            items: [
-                this.gridPanel, {
-                anchor: '50% 100%',
-                x: '50%',
-                y: '0',
-                layout: 'border',
-                border: true,
-                items: [
-                    this.createFormPanel(), 
-                    this.mapPanelPreview
-                ]
-            }]
+            items: [this.gridPanel, this.infoPanel]
         });
 
+        centerPanel.on('bodyresize', function(){
+            this.infoPanel.setWidth('50%');
+        }, this);
+
         this.centerPanel = centerPanel;
 
         Ext.apply(this, {items: [northPanel, centerPanel]});
@@ -496,6 +509,7 @@
             layout: 'absolute',
             x: 0,
             y: 0,
+            region: 'center',
             anchor: '50% 100%',
             store: this.capStore,
             columns: columns,



More information about the Commits mailing list