Skip to content

Commit d1d5ab9

Browse files
committed
Merge branch '2.12'
2 parents fb1a49e + eb74d93 commit d1d5ab9

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+188
-62
lines changed

examples/all-overlays-google.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
<body onload="init()">
1616
<h1 id="title">All Overlays with Google and OSM</h1>
1717
<div id="tags">
18-
overlay, baselayer, google, osm, openstreetmap
18+
overlay, baselayer, google, osm, openstreetmap, light
1919
</div>
2020
<p id="shortdesc">
2121
Using the Google and OSM layers as overlays.

examples/all-overlays.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161
<body onload="init()">
6262
<h1 id="title">OpenLayers Overlays Only Example</h1>
6363
<div id="tags">
64-
overlay, baselayer
64+
overlay, baselayer, light
6565
</div>
6666
<p id="shortdesc">
6767
Demonstrates a map with overlays only.

examples/attribution.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
<h1 id="title">Attribution Example</h1>
4141

4242
<div id="tags">
43-
copyright, watermark, logo, attribution
43+
copyright, watermark, logo, attribution, light
4444
</div>
4545

4646
<p id="shortdesc">

examples/bing-tiles.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<h1 id="title">Basic Bing Tiles Example</h1>
2121

2222
<div id="tags">
23-
bing tiles
23+
bing tiles, light
2424
</div>
2525

2626
<div id="shortdesc">Use Bing with direct tile access</div>

examples/bing.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848
<h1 id="title">Bing Example</h1>
4949

5050
<div id="tags">
51-
Bing, Microsoft, Virtual Earth
51+
Bing, Microsoft, Virtual Earth, light
5252
</div>
5353

5454
<p id="shortdesc">

examples/boxes-vector.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
<h1 id="title">Boxes Example Vector</h1>
4646

4747
<div id="tags">
48-
box, vector, annotation
48+
box, vector, annotation, light
4949
</div>
5050

5151
<p id="shortdesc">

examples/buffer.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
<h1 id="title">Buffer Example</h1>
3838

3939
<div id="tags">
40-
buffer, performance, tile
40+
buffer, performance, tile, light
4141
</div>
4242

4343
<p id="shortdesc">

examples/click.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ <h1 id="title">Click Event Example</h1>
7070

7171
<div id="tags">
7272
click control, double, doubleclick, double-click, event, events,
73-
propagation
73+
propagation, light
7474
</div>
7575

7676
<p id="shortdesc">

examples/clientzoom.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<link rel="stylesheet" href="../theme/default/style.css" type="text/css"/>
99
<link rel="stylesheet" href="style.css" type="text/css">
1010
<script src="../lib/Firebug/firebug.js"></script>
11-
<script src="../lib/OpenLayers.js"></script>
11+
<script src="../lib/OpenLayers.js"></script>
1212
<script src="clientzoom.js"></script>
1313
<style>
1414
.olControlAttribution {

examples/custom-control.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
<h1 id="title">Custom Control Example</h1>
5151

5252
<div id="tags">
53-
control, panel, rectangle
53+
control, panel, rectangle, light
5454
</div>
5555

5656
<p id="shortdesc">

examples/example.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
</head>
1111
<body>
1212
<h1 id="title">OpenLayers Example</h1>
13-
<div id="tags">simple, basic</div>
13+
<div id="tags">simple, basic, light</div>
1414
<p id="shortdesc">
1515
Demonstrate a simple map with an overlay that includes layer switching controls.
1616
</p>

examples/geojson.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
<h1 id="title">GeoJSON Example</h1>
6464

6565
<div id="tags">
66-
JSON, GeoJSON
66+
JSON, GeoJSON, light
6767
</div>
6868

6969
<p id="shortdesc">

examples/google-static.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
<body>
1212
<h1 id="title">Google (Static Maps API) Grid Layer Example</h1>
1313
<div id="tags">
14-
Google, grid, static, GMaps
14+
Google, grid, static, GMaps, light
1515
</div>
1616
<p id="shortdesc">
1717
Using the Google Static Maps API with a Grid Layer.

examples/google-v3-alloverlays.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
<body onload="init()">
1616
<h1 id="title">Google (v3) allOverlays Layer Example</h1>
1717
<div id="tags">
18-
Google, overlay
18+
Google, overlay, light
1919
</div>
2020
<p id="shortdesc">
2121
Demonstrate use the Google Maps v3 API with allOverlays set to true on the map.

examples/google-v3.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
<body onload="init()">
1616
<h1 id="title">Google (v3) Layer Example</h1>
1717
<div id="tags">
18-
Google, api key, apikey
18+
Google, api key, apikey, light
1919
</div>
2020
<p id="shortdesc">
2121
Demonstrate use the Google Maps v3 API.

examples/graphic-name.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
<body onload="init();">
1515
<h1 id="title">Named Graphics Example</h1>
1616
<div id="tags">
17-
vector, named graphic, star, cross, x, square, triangle, circle, style
17+
vector, named graphic, star, cross, x, square, triangle, circle, style, light
1818
</div>
1919
<p id="shortdesc">
2020
Shows how to use well-known graphic names.

examples/gutter.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
<h1 id="title">Gutter Example</h1>
1919

2020
<div id="tags">
21-
gutter, quality, tile
21+
gutter, quality, tile, light
2222
</div>
2323

2424
<p id="shortdesc">

examples/late-render.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
<h1 id="title">Late Rendering</h1>
3030

3131
<div id="tags">
32-
creation, render, div
32+
creation, render, div, light
3333
</div>
3434

3535
<p id="shortdesc">

examples/layer-opacity.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
<h1 id="title">Layer Opacity Example</h1>
7171

7272
<div id="tags">
73-
opacity, transparent, transparency
73+
opacity, transparent, transparency, light
7474
</div>
7575

7676
<p id="shortdesc">

examples/layerLoadMonitoring.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@
112112
<h1 id="title">Layer Load Monitoring Example</h1>
113113

114114
<div id="tags">
115-
monitor, loading
115+
monitor, loading, light
116116
</div>
117117

118118
<p id="shortdesc">

examples/layerswitcher.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
<h1 id="title">Layer Switcher Example</h1>
4343

4444
<div id="tags">
45-
tree, layerswitcher, reposition
45+
tree, layerswitcher, reposition, light
4646
</div>
4747

4848
<p id="shortdesc">

examples/light-basic.html

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
6+
<meta name="apple-mobile-web-app-capable" content="yes">
7+
<title>OpenLayers Light - Basic Popups</title>
8+
<link rel="stylesheet" href="../theme/default/style.css" type="text/css">
9+
<link rel="stylesheet" href="style.css" type="text/css">
10+
<script src="../OpenLayers.light.debug.js"></script>
11+
<script src="light-basic.js"></script>
12+
</head>
13+
<body onload="init()">
14+
<h1 id="title">OpenLayers Light - Basic Popups</h1>
15+
<div id="tags">
16+
light, vector, feature, popup
17+
</div>
18+
<p id="shortdesc">
19+
A basic use case example using the OpenLayers.light version of the library.<br>
20+
Shows popup info bubble when hovering over features on the map
21+
</p>
22+
23+
<div id="map" class="smallmap"></div>
24+
25+
<div id="docs">
26+
<p>
27+
This example uses OpenLayers.light.js to display features and show
28+
popup info bubbles when the feature is hovered over.
29+
</p>
30+
See the <a href="light-basic.js" target="_blank">
31+
light-basic.js source</a> to see how this is done.
32+
</p>
33+
</div>
34+
</body>
35+
</html>

examples/light-basic.js

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
var map;
2+
3+
function init() {
4+
map = new OpenLayers.Map("map",{projection:"EPSG:3857"});
5+
6+
var osm = new OpenLayers.Layer.OSM();
7+
var toMercator = OpenLayers.Projection.transforms['EPSG:4326']['EPSG:3857'];
8+
var center = toMercator({x:-0.05,y:51.5});
9+
10+
/**
11+
* Create 5 random vector features. Your features would typically be fetched
12+
* from the server. The features are given an attribute named "foo".
13+
* The value of this attribute is an integer that ranges from 0 to 100.
14+
*/
15+
var features = [];
16+
for(var i = 0; i < 5; i++) {
17+
features[i] = new OpenLayers.Feature.Vector(
18+
toMercator(new OpenLayers.Geometry.Point(
19+
-0.040 - 0.05*Math.random(),
20+
51.49 + 0.02*Math.random())),
21+
{
22+
foo : 100 * Math.random() | 0
23+
}, {
24+
fillColor : '#008040',
25+
fillOpacity : 0.8,
26+
strokeColor : "#ee9900",
27+
strokeOpacity : 1,
28+
strokeWidth : 1,
29+
pointRadius : 8
30+
});
31+
}
32+
33+
// create the layer with listeners to create and destroy popups
34+
var vector = new OpenLayers.Layer.Vector("Points",{
35+
eventListeners:{
36+
'featureselected':function(evt){
37+
var feature = evt.feature;
38+
var popup = new OpenLayers.Popup.FramedCloud("popup",
39+
OpenLayers.LonLat.fromString(feature.geometry.toShortString()),
40+
null,
41+
"<div style='font-size:.8em'>Feature: " + feature.id +"<br>Foo: " + feature.attributes.foo+"</div>",
42+
null,
43+
true
44+
);
45+
feature.popup = popup;
46+
map.addPopup(popup);
47+
},
48+
'featureunselected':function(evt){
49+
var feature = evt.feature;
50+
map.removePopup(feature.popup);
51+
feature.popup.destroy();
52+
feature.popup = null;
53+
}
54+
}
55+
});
56+
vector.addFeatures(features);
57+
58+
// create the select feature control
59+
var selector = new OpenLayers.Control.SelectFeature(vector,{
60+
autoActivate:true
61+
});
62+
63+
map.addLayers([osm, vector]);
64+
map.addControl(selector);
65+
map.setCenter(new OpenLayers.LonLat(center.x,center.y), 13);
66+
}

examples/multiserver.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
<h1 id="title">Multiple Server URLS</h1>
3232

3333
<div id="tags">
34-
performance, multiple urls, request
34+
performance, multiple urls, request, light
3535
</div>
3636
<p id="shortdesc">
3737
Load your tiles faster by pointing to the same server, but with different urls

examples/navigation-control.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
<h1 id="title">Navigation Control</h1>
2727

2828
<div id="tags">
29-
drag, move, zoom, navigate
29+
drag, move, zoom, navigate, light
3030
</div>
3131

3232
<div id="shortdesc">Demonstrate Navigation Control features</div>

examples/ordering.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@
177177
<h1 id="title">Z-Index/Y-Order Example</h1>
178178

179179
<div id="tags">
180-
stack, stacking, zindex, ordering
180+
stack, stacking, zindex, ordering, light
181181
</div>
182182

183183
<p id="shortdesc">

examples/osm-google.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ <h1 id="title">OSM and Google Together</h1>
1818
Demonstrate use of an OSM layer and a Google layer as base layers.
1919
</p>
2020
<div id="tags">
21-
openstreetmap google
21+
openstreetmap google light
2222
</div>
2323
<div id="map" class="smallmap"></div>
2424
<div id="docs">

examples/osm-grayscale.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@
5959
<h1 id="title">Grayscale OSM Example</h1>
6060

6161
<div id="tags">
62-
openstreetmap canvas grayscale
62+
openstreetmap canvas grayscale light
6363
</div>
6464

6565
<div id="shortdesc">Show an OSM Map in grayscale</div>

examples/osm.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
<h1 id="title">Basic OSM Example</h1>
2828

2929
<div id="tags">
30-
openstreetmap basic
30+
openstreetmap basic light
3131
</div>
3232

3333
<div id="shortdesc">Show a Simple OSM Map</div>

examples/resize-features.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@
8585
<body onload="init()">
8686
<h1 id="title">Resize Features Programatically</h1>
8787
<div id="tags">
88-
vector, feature, resizing, resize
88+
vector, feature, resizing, resize, light
8989
</div>
9090
<p id="shortdesc">
9191
Demonstration of how to use the geometry resize methods to

examples/restricted-extent.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
<body onload="init()">
4343
<h1 id="title">OpenLayers Restricted Extent Example</h1>
4444
<div id="tags">
45-
map, restrict, restrictedextent, extent
45+
map, restrict, restrictedextent, extent, light
4646
</div>
4747
<p id="shortdesc">
4848
Don't let users drag outside the map extent: instead, limit dragging such

examples/rotate-features.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@
9999
<h1 id="title">Rotate vector features</h1>
100100

101101
<div id="tags">
102-
vector, feature, rotating, rotation, rotate, advanced
102+
vector, feature, rotating, rotation, rotate, advanced, light
103103
</div>
104104
<p id="shortdesc">
105105
Details on how to create and rotate vector features programmatically

examples/select-feature-multilayer.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@
117117
<body onload="init()">
118118
<h1 id="title">OpenLayers Select Feature on Multiple Layers Example</h1>
119119
<div id="tags">
120-
vector, feature, selecting, selection, advanced
120+
vector, feature, selecting, selection, advanced, light
121121
</div>
122122
<p id="shortdesc">
123123
Select a feature on click with the Control.SelectFeature on multiple

examples/single-tile.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
</head>
1111
<body>
1212
<h1 id="title">Single Tile Example</h1>
13-
<div id="tags">tile, ratio, singleTile, performance</div>
13+
<div id="tags">tile, ratio, singleTile, performance, light</div>
1414
<p id="shortdesc">
1515
Use the singleTile option on gridded layers to request a single tile.
1616
</p>

examples/style-rules.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
<body onload="init()">
1414
<h1 id="title">Rule Based Style</h1>
1515
<div id="tags">
16-
vector, feature, stylemap, filter, comparison
16+
vector, feature, stylemap, filter, comparison, light
1717
</div>
1818
<p id="shortdesc">
1919
Use rule based styling to use different symbolizers for different

0 commit comments

Comments
 (0)