From 6c0f11da673ea66628bc4f0d55dba20ea6e465f7 Mon Sep 17 00:00:00 2001 From: fredj Date: Mon, 17 Oct 2011 15:00:16 +0200 Subject: [PATCH 01/13] remove unneeded activate and deactivate functions --- lib/OpenLayers/Control/WMSGetFeatureInfo.js | 29 --------------------- 1 file changed, 29 deletions(-) diff --git a/lib/OpenLayers/Control/WMSGetFeatureInfo.js b/lib/OpenLayers/Control/WMSGetFeatureInfo.js index 82c37d6e69..2093575d97 100644 --- a/lib/OpenLayers/Control/WMSGetFeatureInfo.js +++ b/lib/OpenLayers/Control/WMSGetFeatureInfo.js @@ -210,35 +210,6 @@ OpenLayers.Control.WMSGetFeatureInfo = OpenLayers.Class(OpenLayers.Control, { } }, - /** - * Method: activate - * Activates the control. - * - * Returns: - * {Boolean} The control was effectively activated. - */ - activate: function () { - if (!this.active) { - this.handler.activate(); - } - return OpenLayers.Control.prototype.activate.apply( - this, arguments - ); - }, - - /** - * Method: deactivate - * Deactivates the control. - * - * Returns: - * {Boolean} The control was effectively deactivated. - */ - deactivate: function () { - return OpenLayers.Control.prototype.deactivate.apply( - this, arguments - ); - }, - /** * Method: getInfoForClick * Called on click From 7ad7e4d57ca1a6893bae90beaae7bd6897ab6777 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89ric=20Lemoine?= Date: Fri, 21 Oct 2011 09:35:30 +0200 Subject: [PATCH 02/13] better comments for Layer.Grid.getServerResolution, no functional change --- lib/OpenLayers/Layer/Grid.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/OpenLayers/Layer/Grid.js b/lib/OpenLayers/Layer/Grid.js index 6cbac3b2e9..30021877cb 100644 --- a/lib/OpenLayers/Layer/Grid.js +++ b/lib/OpenLayers/Layer/Grid.js @@ -291,15 +291,15 @@ OpenLayers.Layer.Grid = OpenLayers.Class(OpenLayers.Layer.HTTPRequest, { /** * Method: getServerResolution - * Return the server-supported resolution that is the closest to - * the resolution passed as a parameter. If no resolution is - * passed the map resolution is used. + * Return the closest highest server-supported resolution. Throw an + * exception if none is found in the serverResolutions array. * * Parameters: - * resolution - {Number} The base resolution. + * resolution - {Number} The base resolution. If undefined the + * map resolution is used. * * Returns: - * {Number} The closest server supported resolution. + * {Number} The closest highest server resolution value. */ getServerResolution: function(resolution) { resolution = resolution || this.map.getResolution(); From 155108f10b982d54fab5476b647bfad4febd3f78 Mon Sep 17 00:00:00 2001 From: Bart van den Eijnden Date: Fri, 21 Oct 2011 13:52:50 +0200 Subject: [PATCH 03/13] OpenLayers.Format.WPSExecute fails with WFS references, p=ahocevar,me r=ahocevar (closes #3448) --- lib/OpenLayers/Format/Filter/v1.js | 8 ++-- lib/OpenLayers/Format/WFST/v1.js | 2 +- lib/OpenLayers/Format/WFST/v1_1_0.js | 2 +- lib/OpenLayers/Format/WPSExecute.js | 1 + tests/Format/WPSExecute.html | 59 ++++++++++++++++++++++++++++ 5 files changed, 66 insertions(+), 6 deletions(-) diff --git a/lib/OpenLayers/Format/Filter/v1.js b/lib/OpenLayers/Format/Filter/v1.js index 7fd9830451..76b0c5743f 100644 --- a/lib/OpenLayers/Format/Filter/v1.js +++ b/lib/OpenLayers/Format/Filter/v1.js @@ -297,7 +297,7 @@ OpenLayers.Format.Filter.v1 = OpenLayers.Class(OpenLayers.Format.XML, { "Filter": function(filter) { var node = this.createElementNSPlus("ogc:Filter"); if (filter.type === "FID") { - this.writeFeatureIdNodes(filter, node); + OpenLayers.Format.Filter.v1.prototype.writeFeatureIdNodes.call(this, filter, node); } else { this.writeNode(this.getFilterType(filter), filter, node); } @@ -314,7 +314,7 @@ OpenLayers.Format.Filter.v1 = OpenLayers.Class(OpenLayers.Format.XML, { for (var i=0, ii=filter.filters.length; i' + + ' gs:Bounds' + + ' ' + + ' ' + + ' features' + + ' ' + + ' ' + + ' ' + + ' ' + + ' ' + + ' ' + + ' ' + + ' ' + + ' ' + + ' ' + + ' ' + + ' ' + + ' ' + + ' ' + + ' ' + + ' bounds' + + ' ' + + ' ' + + ''; + + result = new OpenLayers.Format.WPSExecute().write({ + identifier: 'gs:Bounds', + dataInputs: [{ + identifier: 'features', + reference: { + mimeType: 'text/xml', + href: 'http://geoserver/wfs', + method: 'POST', + body: { + wfs: { + featureType: 'foo:bar', + version: '1.0.0', + filter: new OpenLayers.Filter.FeatureId({fids: [123]}) + } + } + } + }], + responseForm: { + rawDataOutput: { + identifier: 'bounds' + } + } + }); + t.xml_eq(result, expected, 'WPS Execute written out correctly with a FID filter'); + } + From 3ad5db431ae4aa013239f38bcd0a1c48ef48ed9b Mon Sep 17 00:00:00 2001 From: rda Date: Sat, 22 Oct 2011 23:59:28 +0700 Subject: [PATCH 04/13] Delete last comma in object literal --- tests/Layer/WMTS.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Layer/WMTS.html b/tests/Layer/WMTS.html index 98bb6cdb07..5b87d32e49 100644 --- a/tests/Layer/WMTS.html +++ b/tests/Layer/WMTS.html @@ -272,7 +272,7 @@ style: "blue_marble", matrixSet: "arcgis_online", tileSize: new OpenLayers.Size(512, 512), - requestEncoding: "REST", + requestEncoding: "REST" }); map.addLayer(layer); map.setCenter(new OpenLayers.LonLat(0,0), 5); From b97d0b28c1fba2bec3998022f41abc27705e314d Mon Sep 17 00:00:00 2001 From: rda Date: Sun, 23 Oct 2011 00:05:13 +0700 Subject: [PATCH 05/13] Fix CSS errors --- examples/strategy-cluster.html | 2 +- examples/style.mobile.css | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/strategy-cluster.html b/examples/strategy-cluster.html index 49344230ab..bebbfddc82 100644 --- a/examples/strategy-cluster.html +++ b/examples/strategy-cluster.html @@ -53,7 +53,7 @@ right: 80px; } #photos ul li { - padding 10px; + padding: 10px; margin: 0; list-style: none; display: inline; diff --git a/examples/style.mobile.css b/examples/style.mobile.css index d9e9425310..31c27ffd92 100644 --- a/examples/style.mobile.css +++ b/examples/style.mobile.css @@ -1,5 +1,5 @@ div.olControlZoomPanel { - height: 108px + height: 108px; width: 36px; position: absolute; top: 20px; From b4a42c8446a01cbabd77cb4767f289190d86d392 Mon Sep 17 00:00:00 2001 From: rda Date: Sun, 23 Oct 2011 07:53:41 +0700 Subject: [PATCH 06/13] Fix CSS errrors --- examples/example-list.html | 2 +- examples/game-accel-ball.html | 2 +- examples/popups.html | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/example-list.html b/examples/example-list.html index 2d3530fff9..dbc67a73c3 100644 --- a/examples/example-list.html +++ b/examples/example-list.html @@ -64,7 +64,7 @@ } .ex_classes{ font-size: .7em; - color: grey; + color: gray; display: none; } #toc { diff --git a/examples/game-accel-ball.html b/examples/game-accel-ball.html index 75aa1460e7..40bb02d791 100644 --- a/examples/game-accel-ball.html +++ b/examples/game-accel-ball.html @@ -74,7 +74,7 @@
Simple acceleration demo; roll a vector feature around on a map. (Only tested on iOS 4.)
-
+

Demo works best when device is locked in portrait mode.

diff --git a/examples/popups.html b/examples/popups.html index 36200438f0..640c44e57b 100644 --- a/examples/popups.html +++ b/examples/popups.html @@ -124,7 +124,7 @@
click to add a Marker with an AnchoredBubble popup
click to modify popup's attributes
click to remove the popup from map
-
click to remove the markers layer
+
click to remove the markers layer
marker.onscreen()?
click to destroy the popup from map
From 81fd4adb4fe7c0ae0a8423d6f460aa1d457f5e5d Mon Sep 17 00:00:00 2001 From: rda Date: Sun, 23 Oct 2011 14:24:30 +0700 Subject: [PATCH 07/13] Fix unterminated statements --- examples/KMLParser.html | 4 +- examples/WMSDescribeLayerParser.html | 2 +- examples/animator.js | 40 +++++----- examples/buffer.html | 2 +- examples/donut.js | 2 +- examples/editing-methods.js | 14 ++-- examples/example-list.html | 6 +- examples/filter-strategy.js | 2 +- examples/getfeatureinfo-control.html | 2 +- examples/gutter.html | 2 +- examples/layerLoadMonitoring.html | 2 +- examples/mapguide.html | 4 +- examples/mobile-layers.js | 2 +- examples/mvs.html | 2 +- examples/ordering.html | 2 +- examples/osm-layer.html | 6 +- examples/overviewmap.html | 2 +- examples/point-grid.js | 8 +- examples/popupMatrix.html | 112 +++++++++++++-------------- examples/protocol-gears.html | 4 +- examples/restricted-extent.html | 4 +- examples/snap-grid.js | 6 +- examples/snapping.html | 2 +- examples/styles-unique.html | 4 +- examples/wmts-capabilities.js | 2 +- examples/xyz-esri.html | 2 +- lib/Firebug/firebug.js | 2 +- lib/OpenLayers/Format/Context.js | 2 +- 28 files changed, 122 insertions(+), 122 deletions(-) diff --git a/examples/KMLParser.html b/examples/KMLParser.html index a6ec027f02..7b36ec389d 100644 --- a/examples/KMLParser.html +++ b/examples/KMLParser.html @@ -10,7 +10,7 @@ diff --git a/examples/donut.js b/examples/donut.js index 01ae57d2cb..067be62b80 100644 --- a/examples/donut.js +++ b/examples/donut.js @@ -31,7 +31,7 @@ function updateOutput(event) { map.layers[1].events.on({ sketchmodified: updateOutput, sketchcomplete: updateOutput -}) +}); // add behavior to UI elements function toggleControl(element) { diff --git a/examples/editing-methods.js b/examples/editing-methods.js index 6986a9944e..6c139a276d 100644 --- a/examples/editing-methods.js +++ b/examples/editing-methods.js @@ -29,7 +29,7 @@ $("insertXY").onclick = function() { if (values != null) { draw.insertXY(values[0], values[1]); } -} +}; $("insertDeltaXY").onclick = function() { var values = parseInput( window.prompt( @@ -39,7 +39,7 @@ $("insertDeltaXY").onclick = function() { if (values != null) { draw.insertDeltaXY(values[0], values[1]); } -} +}; $("insertDirectionLength").onclick = function() { var values = parseInput( window.prompt( @@ -49,7 +49,7 @@ $("insertDirectionLength").onclick = function() { if (values != null) { draw.insertDirectionLength(values[0], values[1]); } -} +}; $("insertDeflectionLength").onclick = function() { var values = parseInput( window.prompt( @@ -59,13 +59,13 @@ $("insertDeflectionLength").onclick = function() { if (values != null) { draw.insertDeflectionLength(values[0], values[1]); } -} +}; $("cancel").onclick = function() { draw.cancel(); -} +}; $("finishSketch").onclick = function() { draw.finishSketch(); -} +}; function parseInput(text) { var values = text.split(","); @@ -80,4 +80,4 @@ function parseInput(text) { } } return values; -} \ No newline at end of file +} diff --git a/examples/example-list.html b/examples/example-list.html index 2d3530fff9..1b9622e61f 100644 --- a/examples/example-list.html +++ b/examples/example-list.html @@ -169,7 +169,7 @@ var words = text.split(/\W+/); var scores = {}; for(var i=0; i diff --git a/examples/filter-strategy.js b/examples/filter-strategy.js index 9f8d3942d9..cacdf8daa6 100644 --- a/examples/filter-strategy.js +++ b/examples/filter-strategy.js @@ -24,7 +24,7 @@ function startAnimation() { } else { stopAnimation(true); } - } + }; animationTimer = window.setInterval(next, interval * 1000); } diff --git a/examples/getfeatureinfo-control.html b/examples/getfeatureinfo-control.html index 96993ff326..cb0bec10e4 100644 --- a/examples/getfeatureinfo-control.html +++ b/examples/getfeatureinfo-control.html @@ -105,7 +105,7 @@ }, queryVisible: true }) - } + }; map.addLayers([political, roads, cities, water, highlightLayer]); for (var i in infoControls) { diff --git a/examples/gutter.html b/examples/gutter.html index ea538546ce..f284f3445e 100644 --- a/examples/gutter.html +++ b/examples/gutter.html @@ -19,7 +19,7 @@ window.onload = function() { options = {maxExtent: new OpenLayers.Bounds(-73.5295, 41.2318, -69.9097, 42.8883), - maxResolution: 0.0003} + maxResolution: 0.0003}; map = new OpenLayers.Map('map', options); var roads15 = new OpenLayers.Layer.WMS( "Roads (15px gutter)", "http://boston.freemap.in/cgi-bin/mapserv?map=/www/freemap.in/boston/map/gmaps.map&", diff --git a/examples/layerLoadMonitoring.html b/examples/layerLoadMonitoring.html index a8a17685c3..281fd7894f 100644 --- a/examples/layerLoadMonitoring.html +++ b/examples/layerLoadMonitoring.html @@ -71,7 +71,7 @@ layer.logEvent = function(event) { eventsLog.innerHTML += "
(" + getTimeStamp() + ") " + this.name + ": " + event; - } + }; layer.events.register("loadstart", layer, function() { this.logEvent("Load Start"); diff --git a/examples/mapguide.html b/examples/mapguide.html index 5ecc8b2913..e8ffd0bf90 100644 --- a/examples/mapguide.html +++ b/examples/mapguide.html @@ -54,10 +54,10 @@ var params = { mapdefinition: 'Library://Samples/Sheboygan/MapsTiled/Sheboygan.MapDefinition', basemaplayergroupname: "Base Layer Group" - } + }; var options = { singleTile: false - } + }; var layer = new OpenLayers.Layer.MapGuide( "MapGuide OS tiled layer", url, params, options ); map.addLayer(layer); diff --git a/examples/mobile-layers.js b/examples/mobile-layers.js index 05e1f03399..3cb84e08bc 100644 --- a/examples/mobile-layers.js +++ b/examples/mobile-layers.js @@ -40,7 +40,7 @@ function init() { "http://vmap0.tiles.osgeo.org/wms/vmap0", {layers: 'basic'}, {isBaseLayer: true, transitionEffect: 'resize'} - ) + ); var kml = new OpenLayers.Layer.Vector("KML", { projection: map.displayProjection, diff --git a/examples/mvs.html b/examples/mvs.html index e26b0125f0..f3866f5339 100644 --- a/examples/mvs.html +++ b/examples/mvs.html @@ -34,7 +34,7 @@ function runMVS() { // ---- // TODO: Handle all this parsing better. - var safeArgs = {} + var safeArgs = {}; var DEFAULT_LAT = 0; var DEFAULT_LON = 0; diff --git a/examples/ordering.html b/examples/ordering.html index 7cb3f2b584..262c379f34 100644 --- a/examples/ordering.html +++ b/examples/ordering.html @@ -100,7 +100,7 @@ graphicZIndex: useFirst ? FIRST_RED_Z_INDEX : SECOND_RED_Z_INDEX, externalGraphic: "../img/marker.png", pointRadius: 10 - } + }; indexFeatures.push( point diff --git a/examples/osm-layer.html b/examples/osm-layer.html index 58f8158eec..d282a0f8a4 100644 --- a/examples/osm-layer.html +++ b/examples/osm-layer.html @@ -95,9 +95,9 @@ } else { gml = new OpenLayers.Layer.GML("OSM", "xml/cambridgeport.osm", {format: OpenLayers.Format.OSM}); } - } - gml.events.register("loadstart", null, function() { $("status").innerHTML = "Loading..."; }) - gml.events.register("loadend", null, function() { $("status").innerHTML = ""; }) + } + gml.events.register("loadstart", null, function() { $("status").innerHTML = "Loading..."; }); + gml.events.register("loadend", null, function() { $("status").innerHTML = ""; }); map.addLayer(gml); gml.preFeatureInsert = style_osm_feature; var sf = new OpenLayers.Control.SelectFeature(gml, {'onSelect': on_feature_hover}); diff --git a/examples/overviewmap.html b/examples/overviewmap.html index 7ae1ee86c2..2cb9df9fc9 100644 --- a/examples/overviewmap.html +++ b/examples/overviewmap.html @@ -108,7 +108,7 @@ 20037508.34, 20037508.34) }), layers: [jplOverview] - } + }; var overview2 = new OpenLayers.Control.OverviewMap(controlOptions); map2.addControl(overview2); diff --git a/examples/point-grid.js b/examples/point-grid.js index e3a29e89ca..e7b2e2e1b1 100644 --- a/examples/point-grid.js +++ b/examples/point-grid.js @@ -13,7 +13,7 @@ var rotation = document.getElementById("rotation"); rotation.value = String(points.rotation); rotation.onchange = function() { points.setRotation(Number(rotation.value)); -} +}; var dx = document.getElementById("dx"); var dy = document.getElementById("dy"); @@ -21,13 +21,13 @@ dx.value = String(points.dx); dy.value = String(points.dy); dx.onchange = function() { points.setSpacing(Number(dx.value), Number(dy.value)); -} +}; dy.onchange = function() { points.setSpacing(Number(dx.value), Number(dy.value)); -} +}; var max = document.getElementById("max"); max.value = String(points.maxFeatures); max.onchange = function() { points.setMaxFeatures(Number(max.value)); -} +}; diff --git a/examples/popupMatrix.html b/examples/popupMatrix.html index 4a2280ef1d..90b5fc02e3 100644 --- a/examples/popupMatrix.html +++ b/examples/popupMatrix.html @@ -163,25 +163,25 @@ //anchored popup bigger contents autosize ll = new OpenLayers.LonLat(5,20); popupClass = AutoSizeAnchored; - popupContentHTML = '
Popup.Anchored
autosize
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.Anchored
autosize
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML); //anchored popup bigger contents autosize closebox ll = new OpenLayers.LonLat(10,20); popupClass = AutoSizeAnchored; - popupContentHTML = '
Popup.Anchored
autosize
closebox
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.Anchored
autosize
closebox
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML, true); //anchored popup wide short text contents autosize ll = new OpenLayers.LonLat(20,20); popupClass = AutoSizeAnchored; - popupContentHTML = '
Popup.Anchored
autosize - wide short text
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.Anchored
autosize - wide short text
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML); //anchored popup wide short text contents autosize closebox ll = new OpenLayers.LonLat(25,20); popupClass = AutoSizeAnchored; - popupContentHTML = '
Popup.Anchored
autosize - wide short text
closebox
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.Anchored
autosize - wide short text
closebox
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML, true); @@ -214,13 +214,13 @@ //anchored popup wide long fixed contents autosize ll = new OpenLayers.LonLat(65,20); popupClass = AutoSizeAnchored; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML); //anchored popup wide long fixed contents autosize closebox ll = new OpenLayers.LonLat(70,20); popupClass = AutoSizeAnchored; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true); // @@ -282,64 +282,64 @@ //anchored popup bigger contents autosize overflow ll = new OpenLayers.LonLat(5,15); popupClass = AutoSizeAnchored; - popupContentHTML = '
Popup.Anchored
autosize
overflow
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.Anchored
autosize
overflow
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored popup bigger contents autosize closebox overflow ll = new OpenLayers.LonLat(10,15); popupClass = AutoSizeAnchored; - popupContentHTML = '
Popup.Anchored
autosize
overflow
closebox
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.Anchored
autosize
overflow
closebox
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored popup wide short text contents autosize overflow ll = new OpenLayers.LonLat(20,15); popupClass = AutoSizeAnchored; - popupContentHTML = '
Popup.Anchored
autosize
overflow
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.Anchored
autosize
overflow
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored popup wide short text contents autosize closebox overflow ll = new OpenLayers.LonLat(25,15); popupClass = AutoSizeAnchored; - popupContentHTML = '
Popup.Anchored
autosize
overflow
closebox
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.Anchored
autosize
overflow
closebox
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored popup wide short fixed contents autosize overflow ll = new OpenLayers.LonLat(35,15); popupClass = AutoSizeAnchored; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored popup wide short fixed contents autosize closebox overflow ll = new OpenLayers.LonLat(40,15); popupClass = AutoSizeAnchored; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored popup thin long fixed contents autosize overflow ll = new OpenLayers.LonLat(50,15); popupClass = AutoSizeAnchored; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored popup thin long fixed contents autosize closebox overflow ll = new OpenLayers.LonLat(55,15); popupClass = AutoSizeAnchored; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored popup wide long fixed contents autosize overflow ll = new OpenLayers.LonLat(65,15); popupClass = AutoSizeAnchored; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored popup wide long fixed contents autosize closebox overflow ll = new OpenLayers.LonLat(70,15); popupClass = AutoSizeAnchored; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true, true); @@ -402,65 +402,65 @@ //anchored bubble popup bigger contents autosize closebox ll = new OpenLayers.LonLat(5,5); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '
Popup.AnchoredBubble
autosize
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.AnchoredBubble
autosize
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML, false); //anchored bubble popup bigger contents autosize closebox ll = new OpenLayers.LonLat(10,5); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '
Popup.AnchoredBubble
autosize
closebox
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.AnchoredBubble
autosize
closebox
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML, true); //anchored bubble popup wide short text contents autosize ll = new OpenLayers.LonLat(20,5); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '
Popup.AnchoredBubble
autosize - wide short text
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.AnchoredBubble
autosize - wide short text
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML); //anchored bubble popup wide short text contents autosize closebox ll = new OpenLayers.LonLat(25,5); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '
Popup.AnchoredBubble
autosize - wide short text
closebox
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.AnchoredBubble
autosize - wide short text
closebox
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML, true); //anchored bubble popup wide short fixed contents autosize ll = new OpenLayers.LonLat(35,5); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML); //anchored bubble popup wide short fixed contents autosize closebox ll = new OpenLayers.LonLat(40,5); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true); //anchored bubble popup thin long fixed contents autosize ll = new OpenLayers.LonLat(50,5); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML); //anchored bubble popup thin long fixed contents autosize closebox ll = new OpenLayers.LonLat(55,5); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true); //anchored bubble popup wide long fixed contents autosize ll = new OpenLayers.LonLat(65,5); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML); //anchored bubble popup wide long fixed contents autosize closebox ll = new OpenLayers.LonLat(70,5); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true); // @@ -522,65 +522,65 @@ //anchored bubble popup bigger contents autosize closebox ll = new OpenLayers.LonLat(5,0); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '
Popup.AnchoredBubble
autosize
overflow
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.AnchoredBubble
autosize
overflow
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored bubble popup bigger contents autosize closebox ll = new OpenLayers.LonLat(10,0); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '
Popup.AnchoredBubble
autosize
closebox
overflow
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.AnchoredBubble
autosize
closebox
overflow
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored bubble popup wide short contents autosize overflow ll = new OpenLayers.LonLat(20,0); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '
Popup.AnchoredBubble
autosize
overflow
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.AnchoredBubble
autosize
overflow
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored bubble popup wide short contents autosize closebox overflow ll = new OpenLayers.LonLat(25,0); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '
Popup.AnchoredBubble
autosize
overflow
closebox
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.AnchoredBubble
autosize
overflow
closebox
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored bubble popup wide short fixed contents autosize overflow ll = new OpenLayers.LonLat(35,0); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored bubble popup wide short fixed contents autosize closebox overflow ll = new OpenLayers.LonLat(40,0); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored bubble popup thin long fixed contents autosize overflow ll = new OpenLayers.LonLat(50,0); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored bubble popup thin long fixed contents autosize closebox overflow ll = new OpenLayers.LonLat(55,0); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored bubble popup wide long fixed contents autosize overflow ll = new OpenLayers.LonLat(65,0); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored bubble popup wide long fixed contents autosize closebox overflow ll = new OpenLayers.LonLat(70,0); popupClass = AutoSizeAnchoredBubble; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true, true); //FRAMED @@ -644,65 +644,65 @@ //anchored bubble popup bigger contents autosize closebox ll = new OpenLayers.LonLat(5,-15); popupClass = AutoSizeFramedCloud; - popupContentHTML = '
Popup.FramedCloud
autosize
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.FramedCloud
autosize
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML, false); //anchored bubble popup bigger contents autosize closebox ll = new OpenLayers.LonLat(10,-15); popupClass = AutoSizeFramedCloud; - popupContentHTML = '
Popup.FramedCloud
autosize
closebox
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.FramedCloud
autosize
closebox
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML, true); //anchored bubble popup wide short text contents autosize ll = new OpenLayers.LonLat(20,-15); popupClass = AutoSizeFramedCloud; - popupContentHTML = '
Popup.FramedCloud
autosize - wide short text
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.FramedCloud
autosize - wide short text
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML); //anchored bubble popup wide short text contents autosize closebox ll = new OpenLayers.LonLat(25,-15); popupClass = AutoSizeFramedCloud; - popupContentHTML = '
Popup.FramedCloud
autosize - wide short text
closebox
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.FramedCloud
autosize - wide short text
closebox
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML, true); //anchored bubble popup wide short fixed contents autosize ll = new OpenLayers.LonLat(35,-15); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML); //anchored bubble popup wide short fixed contents autosize closebox ll = new OpenLayers.LonLat(40,-15); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true); //anchored bubble popup thin long fixed contents autosize ll = new OpenLayers.LonLat(50,-15); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML); //anchored bubble popup thin long fixed contents autosize closebox ll = new OpenLayers.LonLat(55,-15); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true); //anchored bubble popup wide long fixed contents autosize ll = new OpenLayers.LonLat(65,-15); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML); //anchored bubble popup wide long fixed contents autosize closebox ll = new OpenLayers.LonLat(70,-15); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true); // @@ -764,65 +764,65 @@ //anchored bubble popup bigger contents autosize closebox ll = new OpenLayers.LonLat(5,-20); popupClass = AutoSizeFramedCloud; - popupContentHTML = '
Popup.FramedCloud
autosize
overflow
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.FramedCloud
autosize
overflow
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored bubble popup bigger contents autosize closebox ll = new OpenLayers.LonLat(10,-20); popupClass = AutoSizeFramedCloud; - popupContentHTML = '
Popup.FramedCloud
autosize
closebox
overflow
' + samplePopupContentsHTML + '
' + popupContentHTML = '
Popup.FramedCloud
autosize
closebox
overflow
' + samplePopupContentsHTML + '
'; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored bubble popup wide short contents autosize overflow ll = new OpenLayers.LonLat(20,-20); popupClass = AutoSizeFramedCloud; - popupContentHTML = '
Popup.FramedCloud
autosize
overflow
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.FramedCloud
autosize
overflow
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored bubble popup wide short contents autosize closebox overflow ll = new OpenLayers.LonLat(25,-20); popupClass = AutoSizeFramedCloud; - popupContentHTML = '
Popup.FramedCloud
autosize
overflow
closebox
' + samplePopupContentsHTML_WideShort + '
' + popupContentHTML = '
Popup.FramedCloud
autosize
overflow
closebox
' + samplePopupContentsHTML_WideShort + '
'; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored bubble popup wide short fixed contents autosize overflow ll = new OpenLayers.LonLat(35,-20); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored bubble popup wide short fixed contents autosize closebox overflow ll = new OpenLayers.LonLat(40,-20); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored bubble popup thin long fixed contents autosize overflow ll = new OpenLayers.LonLat(50,-20); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored bubble popup thin long fixed contents autosize closebox overflow ll = new OpenLayers.LonLat(55,-20); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true, true); //anchored bubble popup wide long fixed contents autosize overflow ll = new OpenLayers.LonLat(65,-20); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, false, true); //anchored bubble popup wide long fixed contents autosize closebox overflow ll = new OpenLayers.LonLat(70,-20); popupClass = AutoSizeFramedCloud; - popupContentHTML = '' + popupContentHTML = ''; addMarker(ll, popupClass, popupContentHTML, true, true); diff --git a/examples/protocol-gears.html b/examples/protocol-gears.html index 23799ec83c..052a7c70b7 100644 --- a/examples/protocol-gears.html +++ b/examples/protocol-gears.html @@ -179,7 +179,7 @@ error = true; return; } - modify.selectControl.unselectAll() + modify.selectControl.unselectAll(); if (resp.reqFeatures) { vector.destroyFeatures(resp.reqFeatures); @@ -214,7 +214,7 @@ } var feature = vector.selectedFeatures[0]; if (feature) { - modify.selectControl.unselectAll() + modify.selectControl.unselectAll(); feature.state = OpenLayers.State.DELETE; displayStatus(); } diff --git a/examples/restricted-extent.html b/examples/restricted-extent.html index 5117453758..db5d7ec513 100644 --- a/examples/restricted-extent.html +++ b/examples/restricted-extent.html @@ -16,7 +16,7 @@ function init() { var options = { restrictedExtent: extent - } + }; map = new OpenLayers.Map('map', options); var wms = new OpenLayers.Layer.WMS( @@ -74,4 +74,4 @@ - \ No newline at end of file + diff --git a/examples/snap-grid.js b/examples/snap-grid.js index 81a72dab11..4478c5a1d1 100644 --- a/examples/snap-grid.js +++ b/examples/snap-grid.js @@ -66,16 +66,16 @@ var rotation = document.getElementById("rotation"); rotation.value = String(points.rotation); rotation.onchange = function() { points.setRotation(Number(rotation.value)); -} +}; var spacing = document.getElementById("spacing"); spacing.value = String(points.dx); spacing.onchange = function() { points.setSpacing(Number(spacing.value)); -} +}; var max = document.getElementById("max"); max.value = String(points.maxFeatures); max.onchange = function() { points.setMaxFeatures(Number(max.value)); -} +}; diff --git a/examples/snapping.html b/examples/snapping.html index 6747e899f6..6c735fe3fc 100644 --- a/examples/snapping.html +++ b/examples/snapping.html @@ -208,7 +208,7 @@ sel.value = "poly"; sel.onchange = function() { updateEditable(sel.value); - } + }; var target, type, tog, tol; var types = ["node", "vertex", "edge"]; diff --git a/examples/styles-unique.html b/examples/styles-unique.html index 0d2e1ec500..7135466f72 100644 --- a/examples/styles-unique.html +++ b/examples/styles-unique.html @@ -39,7 +39,7 @@ 0: {externalGraphic: "../img/marker-blue.png"}, 1: {externalGraphic: "../img/marker-green.png"}, 2: {externalGraphic: "../img/marker-gold.png"} - } + }; // add rules from the above lookup table, with the keyes mapped to // the "type" property of the features, for the "default" intent @@ -69,7 +69,7 @@ var context = function(feature) { return feature; - } + }; var styleMap = new OpenLayers.StyleMap(); // create a lookup table with different symbolizers for the different diff --git a/examples/wmts-capabilities.js b/examples/wmts-capabilities.js index 7f138b4d1a..27fa54a9c3 100644 --- a/examples/wmts-capabilities.js +++ b/examples/wmts-capabilities.js @@ -43,7 +43,7 @@ function init() { alert("Trouble getting capabilities doc"); OpenLayers.Console.error.apply(OpenLayers.Console, arguments); } - }) + }); map = new OpenLayers.Map({ div: "map", diff --git a/examples/xyz-esri.html b/examples/xyz-esri.html index dfb5ca1b48..f6855a52ed 100644 --- a/examples/xyz-esri.html +++ b/examples/xyz-esri.html @@ -16,7 +16,7 @@ - - - -

XYZ Layer with Offset

-
- XYZ, layer, tile -
-
Using a limited set of levels from an XYZ layer with zoomOffset.
- -
- -
-

- The XYZ layer allows a zoomOffset to be set if you want to have - a maximum resolution for the map that differs from the maxiumum - resolution of the cached tiles. This example uses only 6 of the - levels in the cache, starting with the ninth level (index of 8) - in the cache. To do this, the layer is constructed with a - zoomOffset of 8. When the map zoom level is zero, the level - with index 8 will be requested from the cache. -

-

- See the - xyz-offset.js source to see how this is done. -

-
- - diff --git a/examples/xyz-offset.js b/examples/xyz-offset.js deleted file mode 100644 index 251a8c1720..0000000000 --- a/examples/xyz-offset.js +++ /dev/null @@ -1,32 +0,0 @@ -var map, layer; - -// called on body load -function init() { - - var extent = new OpenLayers.Bounds( - -13758743.4295939, 5591455.28887228, -13531302.3472101 , 5757360.4178881 - ); - - map = new OpenLayers.Map({ - div: "map", - maxExtent: new OpenLayers.Bounds( - -128 * 156543.0339, -128 * 156543.0339, - 128 * 156543.0339, 128 * 156543.0339 - ), - restrictedExtent: extent, - maxResolution: 611.496226171875, // corresponds to level 8 in the cache - numZoomLevels: 6, - projection: new OpenLayers.Projection("EPSG:900913"), - units: "m", - layers: [ - new OpenLayers.Layer.XYZ( - "ESRI", - "http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Portland/ESRI_LandBase_WebMercator/MapServer/tile/${z}/${y}/${x}", - {zoomOffset: 8} // since our map maxResolution differs from cache max resolution - ) - ] - }); - - map.zoomToExtent(extent); - -}