[Mapbender-commits] r4511 - branches/2.6/http/javascripts

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Mon Aug 10 08:01:00 EDT 2009


Author: verenadiewald
Date: 2009-08-10 08:00:58 -0400 (Mon, 10 Aug 2009)
New Revision: 4511

Modified:
   branches/2.6/http/javascripts/mod_resize_mapsize.php
Log:
http://trac.osgeo.org/mapbender/ticket/394

Modified: branches/2.6/http/javascripts/mod_resize_mapsize.php
===================================================================
--- branches/2.6/http/javascripts/mod_resize_mapsize.php	2009-08-09 04:31:18 UTC (rev 4510)
+++ branches/2.6/http/javascripts/mod_resize_mapsize.php	2009-08-10 12:00:58 UTC (rev 4511)
@@ -94,16 +94,18 @@
 	midcoordx=parseFloat((parseFloat(coords[2])-parseFloat(coords[0]))/2)+parseFloat(coords[0]);
 	midcoordy=parseFloat((parseFloat(coords[3])-parseFloat(coords[1]))/2)+parseFloat(coords[1]);
 	mb_mapObj[ind].setWidth(mapwidth);
-	mb_mapObj[ind].setHeight(mapheight);
-	mb_mapObj[ind].repaintScale(midcoordx,midcoordy,mb_mapObj[ind].getScale());
+	mb_mapObj[ind].setHeight(mapheight);
+	if (!skipMapRequest) {
+		mb_mapObj[ind].repaintScale(midcoordx,midcoordy,mb_mapObj[ind].getScale());
+	}
 }
 
 function rebuild() {
   	if (width_temp != frameWidth() || height_temp != frameHeight()) window.setTimeout('adjustDimension()', 500);
 }
 
-function control(){
-  	adjustDimension();
+function control(skipMapRequest){
+  	adjustDimension(skipMapRequest);
 	if (!window.width_temp && window.innerWidth) {
   	    window.onresize = rebuild;
   	    width_temp = frameWidth();
@@ -118,6 +120,6 @@
 }
 if (resize_option == 'auto'){
 	eventInit.register(function() {
-		control();
+		control(true);
 	});
 }



More information about the Mapbender_commits mailing list