[Mapbender-commits] r4327 - branches/2.6/conf branches/2.6/http/javascripts trunk/mapbender/conf trunk/mapbender/http/javascripts

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Thu Jul 9 04:44:14 EDT 2009


Author: verenadiewald
Date: 2009-07-09 04:44:14 -0400 (Thu, 09 Jul 2009)
New Revision: 4327

Modified:
   branches/2.6/conf/wfs_additional_spatial_search.conf
   branches/2.6/http/javascripts/mod_wfs_gazetteer_client.php
   trunk/mapbender/conf/wfs_additional_spatial_search.conf
   trunk/mapbender/http/javascripts/mod_wfs_gazetteer_client.php
Log:
configure all highlight options (color, zIndex, lineWidth) in conf file

Modified: branches/2.6/conf/wfs_additional_spatial_search.conf
===================================================================
--- branches/2.6/conf/wfs_additional_spatial_search.conf	2009-07-09 08:42:40 UTC (rev 4326)
+++ branches/2.6/conf/wfs_additional_spatial_search.conf	2009-07-09 08:44:14 UTC (rev 4327)
@@ -101,6 +101,11 @@
 // --------------------------------------------------------
 
 /**
+ * Color of the highlighted geometries
+ */
+var generalHighlightColor = "#cc33cc";
+
+/**
  * z-Index of the highlighted geometries
  */
 var generalHighlightZIndex = 90;

Modified: branches/2.6/http/javascripts/mod_wfs_gazetteer_client.php
===================================================================
--- branches/2.6/http/javascripts/mod_wfs_gazetteer_client.php	2009-07-09 08:42:40 UTC (rev 4326)
+++ branches/2.6/http/javascripts/mod_wfs_gazetteer_client.php	2009-07-09 08:44:14 UTC (rev 4327)
@@ -74,7 +74,6 @@
 var global_selectedWfsConfId;
 var point_px = 10;
 var resultGeom = null;
-var cw_fillcolor = "#cc33cc";
 var frameName = e_id_css;
 var inputNotEnough = [];
 
@@ -722,7 +721,7 @@
  	if(typeof(wfsPopup)!="undefined"){
  		wfsPopup.destroy();
  	}
-	global_resultHighlight = new parent.Highlight(targetArray, "wfs_gazetteer_highlight", {"position":"absolute", "top":"0px", "left":"0px", "z-index":100}, 2);
+	global_resultHighlight = new parent.Highlight(targetArray, "wfs_gazetteer_highlight", {"position":"absolute", "top":"0px", "left":"0px", "z-index":generalHighlightZIndex}, generalHighlightLineWidth);
 
 	var filterParameterCount = getNumberOfFilterParameters();
 
@@ -1246,15 +1245,15 @@
 		currentGeom = currentGeom.getBBox4();
 	}
 	if (event == "over") {
-		global_resultHighlight.add(currentGeom, cw_fillcolor);
+		global_resultHighlight.add(currentGeom, generalHighlightColor);
 		global_resultHighlight.paint();
 	}
 	else if (event == "out"){
-		global_resultHighlight.del(currentGeom, cw_fillcolor);
+		global_resultHighlight.del(currentGeom, generalHighlightColor);
 		global_resultHighlight.paint();
 	}
 	else if (event == "click"){
-		global_resultHighlight.del(currentGeom, cw_fillcolor);
+		global_resultHighlight.del(currentGeom, generalHighlightColor);
 		var bbox = currentGeom.getBBox();
 		var bufferFloat = parseFloat(global_wfsConfObj[global_selectedWfsConfId].g_buffer);
 		var buffer = new parent.Point(bufferFloat,bufferFloat);
@@ -1262,7 +1261,7 @@
 		bbox[1] = bbox[1].plus(buffer);
 		parent.mb_calculateExtent(targetArray[0], bbox[0].x, bbox[0].y, bbox[1].x, bbox[1].y);
 		parent.zoom(targetArray[0], 'true', 1.0);
-		global_resultHighlight.add(currentGeom, cw_fillcolor);
+		global_resultHighlight.add(currentGeom, generalHighlightColor);
 		global_resultHighlight.paint();
 	}
 	return true;

Modified: trunk/mapbender/conf/wfs_additional_spatial_search.conf
===================================================================
--- trunk/mapbender/conf/wfs_additional_spatial_search.conf	2009-07-09 08:42:40 UTC (rev 4326)
+++ trunk/mapbender/conf/wfs_additional_spatial_search.conf	2009-07-09 08:44:14 UTC (rev 4327)
@@ -94,7 +94,6 @@
  */
 var arrangeResultsText = '<?php echo _mb("Arranging search results...");?>';
 
-
 // --------------------------------------------------------
 //
 // Result geometry highlight settings
@@ -102,6 +101,11 @@
 // --------------------------------------------------------
 
 /**
+ * Color of the highlighted geometries
+ */
+var generalHighlightColor = "#cc33cc";
+
+/**
  * z-Index of the highlighted geometries
  */
 var generalHighlightZIndex = 90;

Modified: trunk/mapbender/http/javascripts/mod_wfs_gazetteer_client.php
===================================================================
--- trunk/mapbender/http/javascripts/mod_wfs_gazetteer_client.php	2009-07-09 08:42:40 UTC (rev 4326)
+++ trunk/mapbender/http/javascripts/mod_wfs_gazetteer_client.php	2009-07-09 08:44:14 UTC (rev 4327)
@@ -74,7 +74,6 @@
 var global_selectedWfsConfId;
 var point_px = 10;
 var resultGeom = null;
-var cw_fillcolor = "#cc33cc";
 var frameName = e_id_css;
 var inputNotEnough = [];
 
@@ -726,7 +725,7 @@
  	if(typeof(wfsPopup)!="undefined"){
  		wfsPopup.destroy();
  	}
-	global_resultHighlight = new parent.Highlight(targetArray, "wfs_gazetteer_highlight", {"position":"absolute", "top":"0px", "left":"0px", "z-index":100}, 2);
+	global_resultHighlight = new parent.Highlight(targetArray, "wfs_gazetteer_highlight", {"position":"absolute", "top":"0px", "left":"0px", "z-index":generalHighlightZIndex}, generalHighlightLineWidth);
 
 	var filterParameterCount = getNumberOfFilterParameters();
 	
@@ -1256,15 +1255,15 @@
 		currentGeom = currentGeom.getBBox4();
 	}
 	if (event == "over") {
-		global_resultHighlight.add(currentGeom, cw_fillcolor);
+		global_resultHighlight.add(currentGeom, generalHighlightColor);
 		global_resultHighlight.paint();
 	}
 	else if (event == "out"){
-		global_resultHighlight.del(currentGeom, cw_fillcolor);
+		global_resultHighlight.del(currentGeom, generalHighlightColor);
 		global_resultHighlight.paint();
 	}
 	else if (event == "click"){
-		global_resultHighlight.del(currentGeom, cw_fillcolor);
+		global_resultHighlight.del(currentGeom, generalHighlightColor);
 		var bbox = currentGeom.getBBox();
 		var bufferFloat = parseFloat(global_wfsConfObj[global_selectedWfsConfId].g_buffer);
 		var buffer = new parent.Point(bufferFloat,bufferFloat);
@@ -1272,7 +1271,7 @@
 		bbox[1] = bbox[1].plus(buffer);
 		parent.mb_calculateExtent(targetArray[0], bbox[0].x, bbox[0].y, bbox[1].x, bbox[1].y);
 		parent.zoom(targetArray[0], 'true', 1.0);
-		global_resultHighlight.add(currentGeom, cw_fillcolor);
+		global_resultHighlight.add(currentGeom, generalHighlightColor);
 		global_resultHighlight.paint();
 	}
 	return true;



More information about the Mapbender_commits mailing list