# Patch GeoMOOSE State Demo layer to work with MapServer 6.x
# Patches are submitted upstream and will likely be included
# (or their equivlent) in GeoMOOSE 2.6.

diff -r fce79dd88951 maps/geomoose_globals.map
--- a/maps/geomoose_globals.map	Thu Jul 28 13:10:36 2011 -0500
+++ b/maps/geomoose_globals.map	Thu Jul 28 13:29:01 2011 -0500
@@ -6,6 +6,7 @@
 
 	TRANSPARENT TRUE
 
+	# Does this stuff even need to be set in MS 6.x?  JSK
 	OUTPUTFORMAT
 		NAME 'agg/png'
 		DRIVER AGG/PNG
@@ -15,13 +16,16 @@
 
 	OUTPUTFORMAT
 		NAME 'agg/jpeg'
-		DRIVER GD/JPEG
+		DRIVER AGG/JPEG
 		IMAGEMODE RGB
 		FORMATOPTION "TRANSPARENT=FALSE"
 	END
 
 	# One day, when the death of IE6 is confirmed, I would love for this
 	# to default to agg/png
-	IMAGETYPE GIF
+	#IMAGETYPE GIF
 
+	# IE6 is dead. Microsoft says so, Google says so, Facebook says so, I say so.
+	IMAGETYPE agg/png
+	
 	IMAGECOLOR 255 255 255
diff -r fce79dd88951 maps/symbols/symbol.sym
--- a/maps/symbols/symbol.sym	Thu Jul 28 13:10:36 2011 -0500
+++ b/maps/symbols/symbol.sym	Thu Jul 28 13:29:01 2011 -0500
@@ -7,7 +7,7 @@
     TYPE TRUETYPE
     FONT 'Tahoma'
     CHARACTER '|'
-    GAP 10
+    #GAP 10
   END
 
 Symbol
@@ -106,7 +106,7 @@
     TYPE ELLIPSE
     FILLED TRUE
     POINTS 1 1 END
-    STYLE 5 5 END
+    #STYLE 5 5 END
   END
 
 #LINESET
@@ -116,7 +116,7 @@
   TYPE ELLIPSE
   POINTS 1 1 END
   FILLED TRUE
-  STYLE 2 4 END
+  #STYLE 2 4 END
 END
 
 Symbol
@@ -124,7 +124,7 @@
   TYPE ELLIPSE
   POINTS 1 1 END
   FILLED TRUE
-  STYLE 7 5 END
+  #STYLE 7 5 END
 END
 
 Symbol
@@ -132,7 +132,7 @@
   TYPE ELLIPSE
   POINTS 1 1 END
   FILLED TRUE
-  STYLE 6 2 1 1 1 2 6 END
+  #STYLE 6 2 1 1 1 2 6 END
 END
 
 Symbol
@@ -140,7 +140,7 @@
   TYPE ELLIPSE
   POINTS 1 1 END
   FILLED TRUE
-  STYLE 3 3 3 3 END
+  #STYLE 3 3 3 3 END
 END
 
 SYMBOL
@@ -148,7 +148,7 @@
    TYPE ELLIPSE
    FILLED TRUE
    POINTS 1 1 END
-   STYLE 5 5 END
+   #STYLE 5 5 END
 END
 
 Symbol
@@ -156,7 +156,7 @@
   TYPE VECTOR
    POINTS 0 5 5 0 END
    FILLED TRUE
-   STYLE 6 6 6 6 END
+   #STYLE 6 6 6 6 END
 END
 
 Symbol
@@ -226,4 +226,4 @@
 Points 1 1 END
 END 
 
-END #Symbolset
\ No newline at end of file
+END #Symbolset
diff -r ce66e188ed26 htdocs/php/feature_report.php
--- a/htdocs/php/feature_report.php	Thu Jul 28 13:43:34 2011 -0500
+++ b/htdocs/php/feature_report.php	Thu Jul 28 13:44:05 2011 -0500
@@ -64,7 +64,7 @@
 $layer->queryByRect($mapObj->extent);
 $layer->open();
 $result = $layer->getResult(0);
-$shape = $layer->getFeature($result->shapeindex, $result->tileindex);
+$shape = $layer->getShape($result);
 $layer->close();
 
 # Open the PDF Template
diff -r 9e20e4d2e253 htdocs/php/dynamicSelect.php
--- a/htdocs/php/dynamicSelect.php	Thu Jul 28 17:10:40 2011 -0500
+++ b/htdocs/php/dynamicSelect.php	Thu Jul 28 17:24:22 2011 -0500
@@ -95,12 +95,12 @@
 						$numResults = $queryLayer->getNumResults();
 						if($numResults > 0 and $totalResults == 0) {
 							$res = $queryLayer->getResult(0);
-							$firstResult = $queryLayer->getFeature($res->shapeindex);
+							$firstResult = $queryLayer->getShape($res);
 						}
 						$optionValue = Array();
 						for($rx = 0; $rx < $numResults; $rx++) {
 							$res = $queryLayer->getResult($rx);
-							$optionValue[$rx] = $queryLayer->getFeature($res->shapeindex)->values[$queryItem];
+							$optionValue[$rx] = $queryLayer->getShape($res)->values[$queryItem];
 						}
 						sort($optionValue);
 						foreach($optionValue as $option) {
@@ -131,11 +131,11 @@
 						$numResults = $queryLayer->getNumResults();
 						if($numResults > 0 and $totalResults == 0) {
 							$res = $queryLayer->getResult(0);
-							$firstResult = $queryLayer->getFeature($res->shapeindex);
+							$firstResult = $queryLayer->getShape($res);
 						}
 						for($rx = 0; $rx < $numResults; $rx++) {
 							$res = $queryLayer->getResult($rx);
-							array_push($resultFeatures, $queryLayer->getFeature($res->shapeindex));
+							array_push($resultFeatures, $queryLayer->getShape($res));
 						}
 						$totalResults += $numResults;
 						$queryLayer->close();
diff -r 9e20e4d2e253 htdocs/php/itemquery.php
--- a/htdocs/php/itemquery.php	Thu Jul 28 17:10:40 2011 -0500
+++ b/htdocs/php/itemquery.php	Thu Jul 28 17:24:22 2011 -0500
@@ -103,11 +103,11 @@
 				$numResults = $queryLayer->getNumResults();
 				if($numResults > 0 and $totalResults == 0) {
 					$res = $queryLayer->getResult(0);
-					$firstResult = $queryLayer->getFeature($res->shapeindex);
+					$firstResult = $queryLayer->getShape($res);
 				}
 				for($rx = 0; $rx < $numResults; $rx++) {
 					$res = $queryLayer->getResult($rx);
-					array_push($resultFeatures, $queryLayer->getFeature($res->shapeindex));
+					array_push($resultFeatures, $queryLayer->getShape($res));
 				}
 				$totalResults += $numResults;
 				$queryLayer->close();
diff -r 9e20e4d2e253 htdocs/php/print.php
--- a/htdocs/php/print.php	Thu Jul 28 17:10:40 2011 -0500
+++ b/htdocs/php/print.php	Thu Jul 28 17:24:22 2011 -0500
@@ -103,7 +103,7 @@
 	$layer->queryByRect($mapObj->extent);
 	$layer->open();
 	$result = $layer->getResult(0);
-	$shape = $layer->getFeature($result->shapeindex, $result->tileindex);
+	$shape = $layer->getShape($result);
 	$wkt = $shape->toWkt();
 	$sketches_json[0]['wkt'] = $wkt;
 	$sketches_json[0]['stroke'] = "yellow";
diff -r 9e20e4d2e253 htdocs/php/query.php
--- a/htdocs/php/query.php	Thu Jul 28 17:10:40 2011 -0500
+++ b/htdocs/php/query.php	Thu Jul 28 17:24:22 2011 -0500
@@ -324,11 +324,11 @@
 					$numResults = $queryLayer->getNumResults();
 					if($numResults > 0 and $totalResults == 0) {
 						$res = $queryLayer->getResult(0);
-						$firstResult = $queryLayer->getFeature($res->shapeindex);
+						$firstResult = $queryLayer->getShape($res);
 					}
 					for($rx = 0; $rx < $numResults; $rx++) {
 						$res = $queryLayer->getResult($rx);
-						array_push($resultFeatures, $queryLayer->getFeature($res->shapeindex));
+						array_push($resultFeatures, $queryLayer->getShape($res));
 					}
 					$totalResults += $numResults;
 					$queryLayer->close();
diff -r 9e20e4d2e253 htdocs/php/select.php
--- a/htdocs/php/select.php	Thu Jul 28 17:10:40 2011 -0500
+++ b/htdocs/php/select.php	Thu Jul 28 17:24:22 2011 -0500
@@ -105,7 +105,7 @@
 		$shapeLayersToQuery[$i]->open();
 		for($r = 0; $r < $shapeLayersToQuery[$i]->getNumResults(); $r++) {
 			$result = $shapeLayersToQuery[$i]->getResult($r);
-			array_push($queryShapes, $shapeLayersToQuery[$i]->getFeature($result->shapeindex, $result->tileindex));
+			array_push($queryShapes, $shapeLayersToQuery[$i]->getShape($result));
 		}
 		$shapeLayersToQuery[$i]->close();
 	}
@@ -161,8 +161,8 @@
 	$attributes = $layer->getItems();
 	for($r = 0; $r < $layer->getNumResults(); $r++) {
 		$result = $layer->getResult($r);
-		array_push($foundShapes, $layer->getFeature($result->shapeindex, $result->tileindex));
-		#$sh = $lay->getFeature($res->shapeindex, $res->tileindex);
+		array_push($foundShapes, $layer->getShape($result));
+		#$sh = $lay->getShape($res);
 	}
 	$layer->close();
 }

