[Webflysuesk-commits] r56 - in webflysuesk/branches/openlayers-integration: . webflys/src/main/webapp webflys/src/main/webapp/WEB-INF webflys/src/main/webapp/pages
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Thu Apr 9 14:14:53 CEST 2009
Author: iweinzierl
Date: 2009-04-09 14:14:52 +0200 (Thu, 09 Apr 2009)
New Revision: 56
Added:
webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/App.js
webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/app.jsp
Modified:
webflysuesk/branches/openlayers-integration/ChangeLog.txt
webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/WEB-INF/struts-config.xml
webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/index.jsp
webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/InteractiveRangeSelection.js
webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/entrance.jsp
webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/main.jsp
webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/style.css
Log:
Wrapper for the three main components (wsplgen panel, map and result panel). WSPLGEN Panel is integrated as iFrame to avoid needless map reloading .
Modified: webflysuesk/branches/openlayers-integration/ChangeLog.txt
===================================================================
--- webflysuesk/branches/openlayers-integration/ChangeLog.txt 2009-04-09 07:30:01 UTC (rev 55)
+++ webflysuesk/branches/openlayers-integration/ChangeLog.txt 2009-04-09 12:14:52 UTC (rev 56)
@@ -1,5 +1,23 @@
2009-04-09 Ingo Weinzierl <ingo.weinzierl at intevation.de>
+
+ * webflys/src/main/webapp/pages/main.jsp: Map and result panel outsourced.
+ * webflys/src/main/webapp/pages/app.jsp: Wrapper for the three components
+ wsplgen panel, map and result panel. The wsplgen panel is integrated as
+ iFrame to avoid reloading the map when the user works with the wsplgen
+ panel.
+
+ * webflys/src/main/webapp/App.js: JavaScript code for the wrapper.
+
+ * webflys/src/main/webapp/index.jsp,
+ webflys/src/main/webapp/pages/entrance.jsp,
+ webflys/src/main/webapp/pages/InteractiveRangeSelection.js,
+ webflys/src/main/webapp/WEB-INF/struts-config.xml,
+ webflys/src/main/webapp/pages/style.css: Changes depending on outsourcing
+ the map and the result panel.
+
+2009-04-09 Ingo Weinzierl <ingo.weinzierl at intevation.de>
+
* webflys/src/main/webapp/images/draw_line_off.png,
webflys/src/main/webapp/images/draw_line_on.png,
webflys/src/main/webapp/images/zoomIn_off.png,
Modified: webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/WEB-INF/struts-config.xml
===================================================================
--- webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/WEB-INF/struts-config.xml 2009-04-09 07:30:01 UTC (rev 55)
+++ webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/WEB-INF/struts-config.xml 2009-04-09 12:14:52 UTC (rev 56)
@@ -73,6 +73,9 @@
<global-forwards>
<forward
+ name="app"
+ path="/pages/app.jsp"/>
+ <forward
name="entrance"
path="/pages/entrance.jsp"/>
<forward
Modified: webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/index.jsp
===================================================================
--- webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/index.jsp 2009-04-09 07:30:01 UTC (rev 55)
+++ webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/index.jsp 2009-04-09 12:14:52 UTC (rev 56)
@@ -19,4 +19,4 @@
You should have received a copy of the GNU Lesser General Public License
along with WebFLYS. If not, see <http://www.gnu.org/licenses/>.
--%><%@ taglib uri="http://struts.apache.org/tags-logic" prefix="logic" %>
-<logic:redirect forward="entrance"/>
+<logic:redirect forward="app"/>
Added: webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/App.js
===================================================================
--- webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/App.js 2009-04-09 07:30:01 UTC (rev 55)
+++ webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/App.js 2009-04-09 12:14:52 UTC (rev 56)
@@ -0,0 +1,11 @@
+function wsplgenLoaded() {
+
+ if($j('#map').css('display') == 'none') {
+
+ $j('#map').show();
+ $j('#rightPanel').show();
+
+ createMapForRiver();
+ resultPanel();
+ }
+}
Modified: webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/InteractiveRangeSelection.js
===================================================================
--- webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/InteractiveRangeSelection.js 2009-04-09 07:30:01 UTC (rev 55)
+++ webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/InteractiveRangeSelection.js 2009-04-09 12:14:52 UTC (rev 56)
@@ -216,17 +216,17 @@
var high = range.highestKm();
if(range.count == 2) {
- $j('#from').val(low);
- $j('#to').val(high);
+ $j('#webflys').contents().find('#from').val(low);
+ $j('#webflys').contents().find('#to').val(high);
}
else if(range.count == 1) {
- var from = $j('#from').val();
- var to = $j('#to').val();
+ var from = $j('#webflys').contents().find('#from').val();
+ var to = $j('#webflys').contents().find('#to').val();
if(low < from)
- $j('#from').val(low);
+ $j('#webflys').contents().find('#from').val(low);
else
- $j('#to').val(low);
+ $j('#webflys').contents().find('#to').val(high);
}
}
// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8:
Added: webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/app.jsp
===================================================================
--- webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/app.jsp 2009-04-09 07:30:01 UTC (rev 55)
+++ webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/app.jsp 2009-04-09 12:14:52 UTC (rev 56)
@@ -0,0 +1,76 @@
+<%--
+ (c) 2008 by Intevation GmbH
+
+ author: Sascha L. Teichmann (teichmann at intevation.de)
+ author: Ingo Weinzierl (ingo.weinzierl at intevation.de)
+
+ This file is part of WebFLYS/UeSK.
+
+ WebFLYS is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ any later version.
+
+ WebFLYS is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with WebFLYS. If not, see <http://www.gnu.org/licenses/>.
+--%>
+<%@ page contentType="text/html;charset=utf-8" pageEncoding="UTF-8" %>
+<%@ taglib uri="http://struts.apache.org/tags-bean" prefix="bean" %>
+<%@ taglib uri="http://struts.apache.org/tags-html" prefix="html" %>
+<%@ taglib uri="http://struts.apache.org/tags-logic" prefix="logic" %>
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+
+<bean:define id="wstsubmit" scope="request">
+ <bean:message key="main.to.wst.upload" />
+</bean:define>
+
+<html:html lang="true">
+ <head>
+ <meta http-equiv="content-type" content="text/html;charset=UTF-8" />
+ <title><bean:message key="main.title"/></title>
+ <link rel="stylesheet" type="text/css" href="style.css" />
+ <html:base/>
+
+ <%-- including needed js libs --%>
+ <script src="OpenLayers/OpenLayers.js"></script>
+ <script src="JQuery/jquery-1.3.2.js"></script>
+ <script src="Wrapper.js"></script>
+ <script src="DrawMarker.js"></script>
+ <script src="karte.js"></script>
+ <script src="Range.js"></script>
+ <script src="InteractiveRangeSelection.js"></script>
+
+ <%-- this snippet is needed to avoid conflicts between OpenLayers and jQuery --%>
+ <script type="text/javascript">
+ <!--
+ var $j = jQuery.noConflict();
+ -->
+ </script>
+ </head>
+
+ <body>
+
+ <div id="leftPanel">
+ <iframe id="webflys" style="border: 0px; height:100%; width:100%;" src="entrance.jsp"></iframe>
+ </div>
+
+ <div id="map" style="display: none;"></div>
+
+ <div style="width: 25px; float: left;"> </div>
+
+ <%-- the panel to show the results --%>
+ <div id="rightPanel" style="display: none;">
+ <fieldset id="resultPanel">
+ <input type="button" value="<bean:message key='wsplgen.refresh.button'/>" onClick="resultPanel();">
+ <legend><bean:message key="wsplgen.result.title"/></legend>
+ <div id="results"></div>
+ </fieldset>
+ </div>
+
+ </body>
+</html:html>
Modified: webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/entrance.jsp
===================================================================
--- webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/entrance.jsp 2009-04-09 07:30:01 UTC (rev 55)
+++ webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/entrance.jsp 2009-04-09 12:14:52 UTC (rev 56)
@@ -30,7 +30,7 @@
<html:html lang="true">
<head>
<title><bean:message key="entrance.title"/></title>
- <link rel="stylesheet" type="text/css" href="pages/style.css" />
+ <link rel="stylesheet" type="text/css" href="style.css" />
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<html:base/>
<%-- <html:javascript formName="entranceSubmit" /> --%>
Modified: webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/main.jsp
===================================================================
--- webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/main.jsp 2009-04-09 07:30:01 UTC (rev 55)
+++ webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/main.jsp 2009-04-09 12:14:52 UTC (rev 56)
@@ -48,13 +48,15 @@
<script type="text/javascript">
<!--
var $j = jQuery.noConflict();
+
+ $j(document.body).ready(function(){
+ parent.wsplgenLoaded();
+ });
-->
</script>
</head>
- <body onLoad="createMapForRiver()">
- <div id="wrapper">
- <div id="wsplgen">
+ <body>
<div id="errormessage">
<html:errors/>
</div>
@@ -180,18 +182,5 @@
<input type="submit"
value="<bean:message key='main.calculation.submit' />" id="button" >
</html:form>
- </div>
-
- <%-- the map --%>
- <div id="map"></div>
- <div style="float: left; width: 75px;"> </div>
-
- <%-- the panel to show the results --%>
- <fieldset id="resultPanel">
- <input type="button" value="<bean:message key='wsplgen.refresh.button'/>" onClick="resultPanel();">
- <legend><bean:message key="wsplgen.result.title"/></legend>
- <div id="results"></div>
- </fieldset>
- </div>
</body>
</html:html>
Modified: webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/style.css
===================================================================
--- webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/style.css 2009-04-09 07:30:01 UTC (rev 55)
+++ webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/style.css 2009-04-09 12:14:52 UTC (rev 56)
@@ -2,16 +2,6 @@
font-size: 8pt;
font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
}
-#wrapper {
- width: 1100px;
- height: 650x;
- padding: 0px;
-}
-#wsplgen {
- width: 400px;
- height: 650px;
- float: left;
-}
#map {
width: 500px;
height: 600px;
@@ -30,6 +20,11 @@
font-size: 8pt;
font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
}
+#leftPanel {
+ float: left;
+ height: 100%;
+ width: 350px;
+}
#table {
width: 100%;
border: 0px;
More information about the Webflysuesk-commits
mailing list