[bknr-cvs] hans changed trunk/projects/bos/payment-website/static/poi-ms/poi-ms.

BKNR Commits bknr at bknr.net
Tue Dec 9 21:47:02 UTC 2008


Revision: 4125
Author: hans
URL: http://bknr.net/trac/changeset/4125

Maps tweaks

U   trunk/projects/bos/payment-website/static/poi-ms/poi-ms.css
U   trunk/projects/bos/payment-website/static/poi-ms/poi-ms.html
U   trunk/projects/bos/payment-website/static/poi-ms/poi-ms.js

Modified: trunk/projects/bos/payment-website/static/poi-ms/poi-ms.css
===================================================================
--- trunk/projects/bos/payment-website/static/poi-ms/poi-ms.css	2008-12-09 20:04:01 UTC (rev 4124)
+++ trunk/projects/bos/payment-website/static/poi-ms/poi-ms.css	2008-12-09 21:47:02 UTC (rev 4125)
@@ -143,6 +143,6 @@
 	height: 505px;
 }
 #map.small {
-	width: 400px;
-	height: 150px;
+	width: 505px;
+	height: 200px;
 }

Modified: trunk/projects/bos/payment-website/static/poi-ms/poi-ms.html
===================================================================
--- trunk/projects/bos/payment-website/static/poi-ms/poi-ms.html	2008-12-09 20:04:01 UTC (rev 4124)
+++ trunk/projects/bos/payment-website/static/poi-ms/poi-ms.html	2008-12-09 21:47:02 UTC (rev 4125)
@@ -23,9 +23,10 @@
         </div>
       </div>
       <div id="content">
+        <h1 id="title"></h1>
+        <div id="map"><img src="fake-map.jpg" width="505" height="505"/></div>
    	<div id="content-body">
         </div>
-        <div id="map"><img src="fake-map.jpg" width="505" height="505"/></div>
       </div>
     </div>
   </body>

Modified: trunk/projects/bos/payment-website/static/poi-ms/poi-ms.js
===================================================================
--- trunk/projects/bos/payment-website/static/poi-ms/poi-ms.js	2008-12-09 20:04:01 UTC (rev 4124)
+++ trunk/projects/bos/payment-website/static/poi-ms/poi-ms.js	2008-12-09 21:47:02 UTC (rev 4125)
@@ -79,6 +79,8 @@
     var poi = e.data[0];
     var medium = e.data[1];
 
+    mainMap.hide();
+
     /* Work around jQuery bug when trying to remove applet from DOM with IE. */
     var applet = $("#applet")[0];
     if (applet) {
@@ -88,10 +90,10 @@
     $('#media-list *').removeClass('active');
     $(e.target).addClass('active');
 
+    $('#title').text(poi.title);
     $('#content-body')
     .empty()
-    .append(H1(null, poi.title),
-            H2(null, medium.title),
+    .append(H2(null, medium.title),
             mediaHandlers[medium.mediumType].makeViewer(medium),
             H3(null, medium.subtitle),
             P(null, medium.description));
@@ -134,6 +136,8 @@
         poi = poi.data;
     }
 
+    mainMap.poiDetail(poi.x, poi.y);
+
     $('#back').css('visibility', 'inherit');
     $('#left-bar')
     .empty()
@@ -142,10 +146,11 @@
 
     document.title = poi.title;
 
+    $('#title').text(poi.title);
+            
     $('#content-body')
     .empty()
-    .append(H1(null, poi.title),
-            H2(null, poi.subtitle),
+    .append(H2(null, poi.subtitle),
             P(null, poi.description));
     map(function (medium) {
         if (mediaHandlers[medium.mediumType]) {
@@ -158,7 +163,6 @@
         }
     }, poi.media.sort(compareMedia));
 
-    mainMap.hide();
 }
 
 function pointToPath(point, level) {
@@ -175,9 +179,11 @@
 
 function showOverview() {
     $('#back').css('visibility', 'hidden');
+
+    $('#title').text(NLS('Ãœbersicht'));
+
     $('#content-body')
-    .empty()
-    .append(H1(null, NLS('Ãœbersicht')));
+    .empty();
 
     $('#left-bar')
     .empty()
@@ -282,16 +288,16 @@
         $('#map').removeClass('small');
         $('#map').addClass('large');
         this.addControls();
+        this.map.checkResize();
         this.map.setCenter(projection.fromPixelToLatLng(new GPoint(6500, 6350), 6), 2, customMap);
-        this.map.checkResize();
     }
 
     this.poiDetail = function (x, y) {
         $('#map').removeClass('large');
         $('#map').addClass('small');
         this.removeControls();
+        this.map.checkResize();
         this.map.setCenter(projection.fromPixelToLatLng(new GPoint(x, y), 6), 6);
-        this.map.checkResize();
     }
 
     this.zoomTo = function (x, y, level) {





More information about the Bknr-cvs mailing list