Offset 1, 2 lines modified | Offset 1, 2 lines modified | ||
1 | · | 1 | ·ed0d68076b09c8e93a24f9653872d0fa·706992·javascript·optional·libjs-openlayers_2.13.1+ds2-10_all.deb |
Offset 1, 3 lines modified | Offset 1, 3 lines modified | ||
1 | -rw-r--r--···0········0········0········4·2023-01-14·13:27:41.000000·debian-binary | 1 | -rw-r--r--···0········0········0········4·2023-01-14·13:27:41.000000·debian-binary |
2 | -rw-r--r--···0········0········0·····368 | 2 | -rw-r--r--···0········0········0·····3680·2023-01-14·13:27:41.000000·control.tar.xz |
3 | -rw-r--r--···0········0········0···7 | 3 | -rw-r--r--···0········0········0···703120·2023-01-14·13:27:41.000000·data.tar.xz |
Offset 136, 14 lines modified | Offset 136, 394 lines modified | ||
136 | ·····*·(code) | 136 | ·····*·(code) |
137 | ·····*···<link·rel="stylesheet"·href="/path/to/default/style.css"··type="text/css"> | 137 | ·····*···<link·rel="stylesheet"·href="/path/to/default/style.css"··type="text/css"> |
138 | ·····*·(end·code) | 138 | ·····*·(end·code) |
139 | ·····*/ | 139 | ·····*/ |
140 | ····ImgPath:·'' | 140 | ····ImgPath:·'' |
141 | }; | 141 | }; |
142 | /*·====================================================================== | 142 | /*·====================================================================== |
143 | ····OpenLayers/BaseTypes/Class.js | ||
144 | ···======================================================================·*/ | ||
145 | /*·Copyright·(c)·2006-2013·by·OpenLayers·Contributors·(see·authors.txt·for | ||
146 | ·*·full·list·of·contributors).·Published·under·the·2-clause·BSD·license. | ||
147 | ·*·See·license.txt·in·the·OpenLayers·distribution·or·repository·for·the | ||
148 | ·*·full·text·of·the·license.·*/ | ||
149 | /** | ||
150 | ·*·@requires·OpenLayers/SingleFile.js | ||
151 | ·*/ | ||
152 | /** | ||
153 | ·*·Constructor:·OpenLayers.Class | ||
154 | ·*·Base·class·used·to·construct·all·other·classes.·Includes·support·for· | ||
155 | ·*·····multiple·inheritance.· | ||
156 | ·*····· | ||
157 | ·*·This·constructor·is·new·in·OpenLayers·2.5.··At·OpenLayers·3.0,·the·old· | ||
158 | ·*·····syntax·for·creating·classes·and·dealing·with·inheritance· | ||
159 | ·*·····will·be·removed. | ||
160 | ·*· | ||
161 | ·*·To·create·a·new·OpenLayers-style·class,·use·the·following·syntax: | ||
162 | ·*·(code) | ||
163 | ·*·····var·MyClass·=·OpenLayers.Class(prototype); | ||
164 | ·*·(end) | ||
165 | ·* | ||
166 | ·*·To·create·a·new·OpenLayers-style·class·with·multiple·inheritance,·use·the | ||
167 | ·*·····following·syntax: | ||
168 | ·*·(code) | ||
169 | ·*·····var·MyClass·=·OpenLayers.Class(Class1,·Class2,·prototype); | ||
170 | ·*·(end) | ||
171 | ·*· | ||
172 | ·*·Note·that·instanceof·reflection·will·only·reveal·Class1·as·superclass. | ||
173 | ·* | ||
174 | ·*/ | ||
175 | OpenLayers.Class·=·function()·{ | ||
176 | ····var·len·=·arguments.length; | ||
177 | ····var·P·=·arguments[0]; | ||
178 | ····var·F·=·arguments[len·-·1]; | ||
179 | ····var·C·=·typeof·F.initialize·==·"function"·? | ||
180 | ········F.initialize·: | ||
181 | ········function()·{ | ||
182 | ············P.prototype.initialize.apply(this,·arguments); | ||
183 | ········}; | ||
184 | ····if·(len·>·1)·{ | ||
185 | ········var·newArgs·=·[C,·P].concat( | ||
186 | ············Array.prototype.slice.call(arguments).slice(1,·len·-·1),·F); | ||
187 | ········OpenLayers.inherit.apply(null,·newArgs); | ||
188 | ····}·else·{ | ||
189 | ········C.prototype·=·F; | ||
190 | ····} | ||
191 | ····return·C; | ||
192 | }; | ||
193 | /** | ||
194 | ·*·Function:·OpenLayers.inherit | ||
195 | ·* | ||
196 | ·*·Parameters: | ||
197 | ·*·C·-·{Object}·the·class·that·inherits | ||
198 | ·*·P·-·{Object}·the·superclass·to·inherit·from | ||
199 | ·* | ||
200 | ·*·In·addition·to·the·mandatory·C·and·P·parameters,·an·arbitrary·number·of | ||
201 | ·*·objects·can·be·passed,·which·will·extend·C. | ||
202 | ·*/ | ||
203 | OpenLayers.inherit·=·function(C,·P)·{ | ||
204 | ····var·F·=·function()·{}; | ||
205 | ····F.prototype·=·P.prototype; | ||
206 | ····C.prototype·=·new·F; | ||
207 | ····var·i,·l,·o; | ||
208 | ····for·(i·=·2,·l·=·arguments.length;·i·<·l;·i++)·{ | ||
209 | ········o·=·arguments[i]; | ||
210 | ········if·(typeof·o·===·"function")·{ | ||
211 | ············o·=·o.prototype; | ||
212 | ········} | ||
213 | ········OpenLayers.Util.extend(C.prototype,·o); | ||
214 | ····} | ||
215 | }; | ||
216 | /** | ||
217 | ·*·APIFunction:·extend | ||
218 | ·*·Copy·all·properties·of·a·source·object·to·a·destination·object.··Modifies | ||
219 | ·*·····the·passed·in·destination·object.··Any·properties·on·the·source·object | ||
220 | ·*·····that·are·set·to·undefined·will·not·be·(re)set·on·the·destination·object. | ||
221 | ·* | ||
222 | ·*·Parameters: | ||
223 | ·*·destination·-·{Object}·The·object·that·will·be·modified | ||
224 | ·*·source·-·{Object}·The·object·with·properties·to·be·set·on·the·destination | ||
225 | ·* | ||
226 | ·*·Returns: | ||
227 | ·*·{Object}·The·destination·object. | ||
228 | ·*/ | ||
229 | OpenLayers.Util·=·OpenLayers.Util·||·{}; | ||
230 | OpenLayers.Util.extend·=·function(destination,·source)·{ | ||
231 | ····destination·=·destination·||·{}; | ||
232 | ····if·(source)·{ | ||
233 | ········for·(var·property·in·source)·{ | ||
234 | ············var·value·=·source[property]; | ||
235 | ············if·(value·!==·undefined)·{ | ||
236 | ················destination[property]·=·value; | ||
237 | ············} | ||
238 | ········} | ||
239 | ········/** | ||
240 | ·········*·IE·doesn't·include·the·toString·property·when·iterating·over·an·object's | ||
241 | ·········*·properties·with·the·for(property·in·object)·syntax.··Explicitly·check·if | ||
242 | ·········*·the·source·has·its·own·toString·property. | ||
243 | ·········*/ | ||
244 | ········/* | ||
245 | ·········*·FF/Windows·<·2.0.0.13·reports·"Illegal·operation·on·WrappedNative | ||
246 | ·········*·prototype·object"·when·calling·hawOwnProperty·if·the·source·object | ||
247 | ·········*·is·an·instance·of·window.Event. | ||
248 | ·········*/ | ||
249 | ········var·sourceIsEvt·=·typeof·window.Event·==·"function"·&& | ||
250 | ············source·instanceof·window.Event; | ||
251 | ········if·(!sourceIsEvt·&& | ||
Max diff block lines reached; 5212838/5224165 bytes (99.78%) of diff not shown. |
Offset 263, 14 lines modified | Offset 263, 449 lines modified | ||
263 | ············source.hasOwnProperty·&&·source.hasOwnProperty("toString"))·{ | 263 | ············source.hasOwnProperty·&&·source.hasOwnProperty("toString"))·{ |
264 | ············destination.toString·=·source.toString; | 264 | ············destination.toString·=·source.toString; |
265 | ········} | 265 | ········} |
266 | ····} | 266 | ····} |
267 | ····return·destination; | 267 | ····return·destination; |
268 | }; | 268 | }; |
269 | /*·====================================================================== | 269 | /*·====================================================================== |
270 | ····OpenLayers/Util/vendorPrefix.js | ||
271 | ···======================================================================·*/ | ||
272 | /*·Copyright·(c)·2006-2013·by·OpenLayers·Contributors·(see·authors.txt·for | ||
273 | ·*·full·list·of·contributors).·Published·under·the·2-clause·BSD·license. | ||
274 | ·*·See·license.txt·in·the·OpenLayers·distribution·or·repository·for·the | ||
275 | ·*·full·text·of·the·license.·*/ | ||
276 | /** | ||
277 | ·*·@requires·OpenLayers/SingleFile.js | ||
278 | ·*/ | ||
279 | OpenLayers.Util·=·OpenLayers.Util·||·{}; | ||
280 | /** | ||
281 | ·*·Namespace:·OpenLayers.Util.vendorPrefix | ||
282 | ·*·A·collection·of·utility·functions·to·detect·vendor·prefixed·features | ||
283 | ·*/ | ||
284 | OpenLayers.Util.vendorPrefix·=·(function()·{ | ||
285 | ····"use·strict"; | ||
286 | ····var·VENDOR_PREFIXES·=·["",·"O",·"ms",·"Moz",·"Webkit"], | ||
287 | ········divStyle·=·document.createElement("div").style, | ||
288 | ········cssCache·=·{}, | ||
289 | ········jsCache·=·{}; | ||
290 | ····/** | ||
291 | ·····*·Function:·domToCss | ||
292 | ·····*·Converts·a·upper·camel·case·DOM·style·property·name·to·a·CSS·property | ||
293 | ·····*······i.e.·transformOrigin·->·transform-origin | ||
294 | ·····*······or···WebkitTransformOrigin·->·-webkit-transform-origin | ||
295 | ·····* | ||
296 | ·····*·Parameters: | ||
297 | ·····*·prefixedDom·-·{String}·The·property·to·convert | ||
298 | ·····* | ||
299 | ·····*·Returns: | ||
300 | ·····*·{String}·The·CSS·property | ||
301 | ·····*/ | ||
302 | ····function·domToCss(prefixedDom)·{ | ||
303 | ········if·(!prefixedDom)·{ | ||
304 | ············return·null; | ||
305 | ········} | ||
306 | ········return·prefixedDom. | ||
307 | ········replace(/([A-Z])/g,·function(c)·{ | ||
308 | ············return·"-"·+·c.toLowerCase(); | ||
309 | ········}). | ||
310 | ········replace(/^ms-/,·"-ms-"); | ||
311 | ····} | ||
312 | ····/** | ||
313 | ·····*·APIMethod:·css | ||
314 | ·····*·Detect·which·property·is·used·for·a·CSS·property | ||
315 | ·····* | ||
316 | ·····*·Parameters: | ||
317 | ·····*·property·-·{String}·The·standard·(unprefixed)·CSS·property·name | ||
318 | ·····* | ||
319 | ·····*·Returns: | ||
320 | ·····*·{String}·The·standard·CSS·property,·prefixed·property·or·null·if·not | ||
321 | ·····*··········supported | ||
322 | ·····*/ | ||
323 | ····function·css(property)·{ | ||
324 | ········if·(cssCache[property]·===·undefined)·{ | ||
325 | ············var·domProperty·=·property. | ||
326 | ············replace(/(-[\s\S])/g,·function(c)·{ | ||
327 | ················return·c.charAt(1).toUpperCase(); | ||
328 | ············}); | ||
329 | ············var·prefixedDom·=·style(domProperty); | ||
330 | ············cssCache[property]·=·domToCss(prefixedDom); | ||
331 | ········} | ||
332 | ········return·cssCache[property]; | ||
333 | ····} | ||
334 | ····/** | ||
335 | ·····*·APIMethod:·js | ||
336 | ·····*·Detect·which·property·is·used·for·a·JS·property/method | ||
337 | ·····* | ||
338 | ·····*·Parameters: | ||
339 | ·····*·obj·-·{Object}·The·object·to·test·on | ||
340 | ·····*·property·-·{String}·The·standard·(unprefixed)·JS·property·name | ||
341 | ·····* | ||
342 | ·····*·Returns: | ||
343 | ·····*·{String}·The·standard·JS·property,·prefixed·property·or·null·if·not | ||
344 | ·····*··········supported | ||
345 | ·····*/ | ||
346 | ····function·js(obj,·property)·{ | ||
347 | ········if·(jsCache[property]·===·undefined)·{ | ||
348 | ············var·tmpProp, | ||
349 | ················i·=·0, | ||
350 | ················l·=·VENDOR_PREFIXES.length, | ||
351 | ················prefix, | ||
352 | ················isStyleObj·=·(typeof·obj.cssText·!==·"undefined"); | ||
353 | ············jsCache[property]·=·null; | ||
354 | ············for·(;·i·<·l;·i++)·{ | ||
355 | ················prefix·=·VENDOR_PREFIXES[i]; | ||
356 | ················if·(prefix)·{ | ||
357 | ····················if·(!isStyleObj)·{ | ||
358 | ························//·js·prefix·should·be·lower-case,·while·style | ||
359 | ························//·properties·have·upper·case·on·first·character | ||
360 | ························prefix·=·prefix.toLowerCase(); | ||
361 | ····················} | ||
362 | ····················tmpProp·=·prefix·+·property.charAt(0).toUpperCase()·+·property.slice(1); | ||
363 | ················}·else·{ | ||
364 | ····················tmpProp·=·property; | ||
365 | ················} | ||
366 | ················if·(obj[tmpProp]·!==·undefined)·{ | ||
367 | ····················jsCache[property]·=·tmpProp; | ||
368 | ····················break; | ||
369 | ················} | ||
370 | ············} | ||
371 | ········} | ||
372 | ········return·jsCache[property]; | ||
373 | ····} | ||
374 | ····/** | ||
375 | ·····*·APIMethod:·style | ||
376 | ·····*·Detect·which·property·is·used·for·a·DOM·style·property | ||
377 | ·····* | ||
378 | ·····*·Parameters: | ||
Max diff block lines reached; 1808847/1822283 bytes (99.26%) of diff not shown. |
Offset 62, 14 lines modified | Offset 62, 204 lines modified | ||
62 | ········var·sourceIsEvt·=·typeof·window.Event·==·"function"·&&·source·instanceof·window.Event; | 62 | ········var·sourceIsEvt·=·typeof·window.Event·==·"function"·&&·source·instanceof·window.Event; |
63 | ········if·(!sourceIsEvt·&&·source.hasOwnProperty·&&·source.hasOwnProperty("toString"))·{ | 63 | ········if·(!sourceIsEvt·&&·source.hasOwnProperty·&&·source.hasOwnProperty("toString"))·{ |
64 | ············destination.toString·=·source.toString | 64 | ············destination.toString·=·source.toString |
65 | ········} | 65 | ········} |
66 | ····} | 66 | ····} |
67 | ····return·destination | 67 | ····return·destination |
68 | }; | 68 | }; |
69 | OpenLayers.Util·=·OpenLayers.Util·||·{}; | ||
70 | OpenLayers.Util.vendorPrefix·=·function()·{ | ||
71 | ····"use·strict"; | ||
72 | ····var·VENDOR_PREFIXES·=·["",·"O",·"ms",·"Moz",·"Webkit"], | ||
73 | ········divStyle·=·document.createElement("div").style, | ||
74 | ········cssCache·=·{}, | ||
75 | ········jsCache·=·{}; | ||
76 | ····function·domToCss(prefixedDom)·{ | ||
77 | ········if·(!prefixedDom)·{ | ||
78 | ············return·null | ||
79 | ········} | ||
80 | ········return·prefixedDom.replace(/([A-Z])/g,·function(c)·{ | ||
81 | ············return·"-"·+·c.toLowerCase() | ||
82 | ········}).replace(/^ms-/,·"-ms-") | ||
83 | ····} | ||
84 | ····function·css(property)·{ | ||
85 | ········if·(cssCache[property]·===·undefined)·{ | ||
86 | ············var·domProperty·=·property.replace(/(-[\s\S])/g,·function(c)·{ | ||
87 | ················return·c.charAt(1).toUpperCase() | ||
88 | ············}); | ||
89 | ············var·prefixedDom·=·style(domProperty); | ||
90 | ············cssCache[property]·=·domToCss(prefixedDom) | ||
91 | ········} | ||
92 | ········return·cssCache[property] | ||
93 | ····} | ||
94 | ····function·js(obj,·property)·{ | ||
95 | ········if·(jsCache[property]·===·undefined)·{ | ||
96 | ············var·tmpProp,·i·=·0, | ||
97 | ················l·=·VENDOR_PREFIXES.length, | ||
98 | ················prefix,·isStyleObj·=·typeof·obj.cssText·!==·"undefined"; | ||
99 | ············jsCache[property]·=·null; | ||
100 | ············for·(;·i·<·l;·i++)·{ | ||
101 | ················prefix·=·VENDOR_PREFIXES[i]; | ||
102 | ················if·(prefix)·{ | ||
103 | ····················if·(!isStyleObj)·{ | ||
104 | ························prefix·=·prefix.toLowerCase() | ||
105 | ····················} | ||
106 | ····················tmpProp·=·prefix·+·property.charAt(0).toUpperCase()·+·property.slice(1) | ||
107 | ················}·else·{ | ||
108 | ····················tmpProp·=·property | ||
109 | ················} | ||
110 | ················if·(obj[tmpProp]·!==·undefined)·{ | ||
111 | ····················jsCache[property]·=·tmpProp; | ||
112 | ····················break | ||
113 | ················} | ||
114 | ············} | ||
115 | ········} | ||
116 | ········return·jsCache[property] | ||
117 | ····} | ||
118 | ····function·style(property)·{ | ||
119 | ········return·js(divStyle,·property) | ||
120 | ····} | ||
121 | ····return·{ | ||
122 | ········css:·css, | ||
123 | ········js:·js, | ||
124 | ········style:·style, | ||
125 | ········cssCache:·cssCache, | ||
126 | ········jsCache:·jsCache | ||
127 | ····} | ||
128 | }(); | ||
129 | OpenLayers.Animation·=·function(window)·{ | ||
130 | ····var·requestAnimationFrame·=·OpenLayers.Util.vendorPrefix.js(window,·"requestAnimationFrame"); | ||
131 | ····var·isNative·=·!!requestAnimationFrame; | ||
132 | ····var·requestFrame·=·function()·{ | ||
133 | ········var·request·=·window[requestAnimationFrame]·||·function(callback,·element)·{ | ||
134 | ············window.setTimeout(callback,·16) | ||
135 | ········}; | ||
136 | ········return·function(callback,·element)·{ | ||
137 | ············request.apply(window,·[callback,·element]) | ||
138 | ········} | ||
139 | ····}(); | ||
140 | ····var·counter·=·0; | ||
141 | ····var·loops·=·{}; | ||
142 | ····function·start(callback,·duration,·element)·{ | ||
143 | ········duration·=·duration·>·0·?·duration·:·Number.POSITIVE_INFINITY; | ||
144 | ········var·id·=·++counter; | ||
145 | ········var·start·=·+new·Date; | ||
146 | ········loops[id]·=·function()·{ | ||
147 | ············if·(loops[id]·&&·+new·Date·-·start·<=·duration)·{ | ||
148 | ················callback(); | ||
149 | ················if·(loops[id])·{ | ||
150 | ····················requestFrame(loops[id],·element) | ||
151 | ················} | ||
152 | ············}·else·{ | ||
153 | ················delete·loops[id] | ||
154 | ············} | ||
155 | ········}; | ||
156 | ········requestFrame(loops[id],·element); | ||
157 | ········return·id | ||
158 | ····} | ||
159 | ····function·stop(id)·{ | ||
160 | ········delete·loops[id] | ||
161 | ····} | ||
162 | ····return·{ | ||
163 | ········isNative:·isNative, | ||
164 | ········requestFrame:·requestFrame, | ||
165 | ········start:·start, | ||
166 | ········stop:·stop | ||
167 | ····} | ||
168 | }(window); | ||
169 | OpenLayers.Kinetic·=·OpenLayers.Class({ | ||
170 | ····threshold:·0, | ||
171 | ····deceleration:·.0035, | ||
172 | ····nbPoints:·100, | ||
173 | ····delay:·200, | ||
174 | ····points:·undefined, | ||
175 | ····timerId:·undefined, | ||
176 | ····initialize:·function(options)·{ | ||
177 | ········OpenLayers.Util.extend(this,·options) | ||
178 | ····}, | ||
179 | ····begin:·function()·{ | ||
180 | ········OpenLayers.Animation.stop(this.timerId); | ||
181 | ········this.timerId·=·undefined; | ||
182 | ········this.points·=·[] | ||
Max diff block lines reached; 514909/521221 bytes (98.79%) of diff not shown. |
Offset 17, 14 lines modified | Offset 17, 141 lines modified | ||
17 | ········} | 17 | ········} |
18 | ········return·function()·{ | 18 | ········return·function()·{ |
19 | ············return·l | 19 | ············return·l |
20 | ········} | 20 | ········} |
21 | ····}(), | 21 | ····}(), |
22 | ····ImgPath:·"" | 22 | ····ImgPath:·"" |
23 | }; | 23 | }; |
24 | OpenLayers.Class·=·function()·{ | ||
25 | ····var·len·=·arguments.length; | ||
26 | ····var·P·=·arguments[0]; | ||
27 | ····var·F·=·arguments[len·-·1]; | ||
28 | ····var·C·=·typeof·F.initialize·==·"function"·?·F.initialize·:·function()·{ | ||
29 | ········P.prototype.initialize.apply(this,·arguments) | ||
30 | ····}; | ||
31 | ····if·(len·>·1)·{ | ||
32 | ········var·newArgs·=·[C,·P].concat(Array.prototype.slice.call(arguments).slice(1,·len·-·1),·F); | ||
33 | ········OpenLayers.inherit.apply(null,·newArgs) | ||
34 | ····}·else·{ | ||
35 | ········C.prototype·=·F | ||
36 | ····} | ||
37 | ····return·C | ||
38 | }; | ||
39 | OpenLayers.inherit·=·function(C,·P)·{ | ||
40 | ····var·F·=·function()·{}; | ||
41 | ····F.prototype·=·P.prototype; | ||
42 | ····C.prototype·=·new·F; | ||
43 | ····var·i,·l,·o; | ||
44 | ····for·(i·=·2,·l·=·arguments.length;·i·<·l;·i++)·{ | ||
45 | ········o·=·arguments[i]; | ||
46 | ········if·(typeof·o·===·"function")·{ | ||
47 | ············o·=·o.prototype | ||
48 | ········} | ||
49 | ········OpenLayers.Util.extend(C.prototype,·o) | ||
50 | ····} | ||
51 | }; | ||
52 | OpenLayers.Util·=·OpenLayers.Util·||·{}; | ||
53 | OpenLayers.Util.extend·=·function(destination,·source)·{ | ||
54 | ····destination·=·destination·||·{}; | ||
55 | ····if·(source)·{ | ||
56 | ········for·(var·property·in·source)·{ | ||
57 | ············var·value·=·source[property]; | ||
58 | ············if·(value·!==·undefined)·{ | ||
59 | ················destination[property]·=·value | ||
60 | ············} | ||
61 | ········} | ||
62 | ········var·sourceIsEvt·=·typeof·window.Event·==·"function"·&&·source·instanceof·window.Event; | ||
63 | ········if·(!sourceIsEvt·&&·source.hasOwnProperty·&&·source.hasOwnProperty("toString"))·{ | ||
64 | ············destination.toString·=·source.toString | ||
65 | ········} | ||
66 | ····} | ||
67 | ····return·destination | ||
68 | }; | ||
69 | OpenLayers.Icon·=·OpenLayers.Class({ | ||
70 | ····url:·null, | ||
71 | ····size:·null, | ||
72 | ····offset:·null, | ||
73 | ····calculateOffset:·null, | ||
74 | ····imageDiv:·null, | ||
75 | ····px:·null, | ||
76 | ····initialize:·function(url,·size,·offset,·calculateOffset)·{ | ||
77 | ········this.url·=·url; | ||
78 | ········this.size·=·size·||·{ | ||
79 | ············w:·20, | ||
80 | ············h:·20 | ||
81 | ········}; | ||
82 | ········this.offset·=·offset·||·{ | ||
83 | ············x:·-(this.size.w·/·2), | ||
84 | ············y:·-(this.size.h·/·2) | ||
85 | ········}; | ||
86 | ········this.calculateOffset·=·calculateOffset; | ||
87 | ········var·id·=·OpenLayers.Util.createUniqueID("OL_Icon_"); | ||
88 | ········this.imageDiv·=·OpenLayers.Util.createAlphaImageDiv(id) | ||
89 | ····}, | ||
90 | ····destroy:·function()·{ | ||
91 | ········this.erase(); | ||
92 | ········OpenLayers.Event.stopObservingElement(this.imageDiv.firstChild); | ||
93 | ········this.imageDiv.innerHTML·=·""; | ||
94 | ········this.imageDiv·=·null | ||
95 | ····}, | ||
96 | ····clone:·function()·{ | ||
97 | ········return·new·OpenLayers.Icon(this.url,·this.size,·this.offset,·this.calculateOffset) | ||
98 | ····}, | ||
99 | ····setSize:·function(size)·{ | ||
100 | ········if·(size·!=·null)·{ | ||
101 | ············this.size·=·size | ||
102 | ········} | ||
103 | ········this.draw() | ||
104 | ····}, | ||
105 | ····setUrl:·function(url)·{ | ||
106 | ········if·(url·!=·null)·{ | ||
107 | ············this.url·=·url | ||
108 | ········} | ||
109 | ········this.draw() | ||
110 | ····}, | ||
111 | ····draw:·function(px)·{ | ||
112 | ········OpenLayers.Util.modifyAlphaImageDiv(this.imageDiv,·null,·null,·this.size,·this.url,·"absolute"); | ||
113 | ········this.moveTo(px); | ||
114 | ········return·this.imageDiv | ||
115 | ····}, | ||
116 | ····erase:·function()·{ | ||
117 | ········if·(this.imageDiv·!=·null·&&·this.imageDiv.parentNode·!=·null)·{ | ||
118 | ············OpenLayers.Element.remove(this.imageDiv) | ||
119 | ········} | ||
120 | ····}, | ||
121 | ····setOpacity:·function(opacity)·{ | ||
122 | ········OpenLayers.Util.modifyAlphaImageDiv(this.imageDiv,·null,·null,·null,·null,·null,·null,·null,·opacity) | ||
123 | ····}, | ||
124 | ····moveTo:·function(px)·{ | ||
125 | ········if·(px·!=·null)·{ | ||
126 | ············this.px·=·px | ||
127 | ········} | ||
128 | ········if·(this.imageDiv·!=·null)·{ | ||
129 | ············if·(this.px·==·null)·{ | ||
130 | ················this.display(false) | ||
131 | ············}·else·{ | ||
132 | ················if·(this.calculateOffset)·{ | ||
133 | ····················this.offset·=·this.calculateOffset(this.size) | ||
134 | ················} | ||
135 | ················OpenLayers.Util.modifyAlphaImageDiv(this.imageDiv,·null,·{ | ||
136 | ····················x:·this.px.x·+·this.offset.x, | ||
137 | ····················y:·this.px.y·+·this.offset.y | ||
138 | ················}) | ||
139 | ············} | ||
140 | ········} | ||
141 | ····}, | ||
142 | ····display:·function(display)·{ | ||
143 | ········this.imageDiv.style.display·=·display·?·""·:·"none" | ||
Max diff block lines reached; 2605388/2609682 bytes (99.84%) of diff not shown. |
Offset 263, 14 lines modified | Offset 263, 449 lines modified | ||
263 | ············source.hasOwnProperty·&&·source.hasOwnProperty("toString"))·{ | 263 | ············source.hasOwnProperty·&&·source.hasOwnProperty("toString"))·{ |
264 | ············destination.toString·=·source.toString; | 264 | ············destination.toString·=·source.toString; |
265 | ········} | 265 | ········} |
266 | ····} | 266 | ····} |
267 | ····return·destination; | 267 | ····return·destination; |
268 | }; | 268 | }; |
269 | /*·====================================================================== | 269 | /*·====================================================================== |
270 | ····OpenLayers/Util/vendorPrefix.js | ||
271 | ···======================================================================·*/ | ||
272 | /*·Copyright·(c)·2006-2013·by·OpenLayers·Contributors·(see·authors.txt·for | ||
273 | ·*·full·list·of·contributors).·Published·under·the·2-clause·BSD·license. | ||
274 | ·*·See·license.txt·in·the·OpenLayers·distribution·or·repository·for·the | ||
275 | ·*·full·text·of·the·license.·*/ | ||
276 | /** | ||
277 | ·*·@requires·OpenLayers/SingleFile.js | ||
278 | ·*/ | ||
279 | OpenLayers.Util·=·OpenLayers.Util·||·{}; | ||
280 | /** | ||
281 | ·*·Namespace:·OpenLayers.Util.vendorPrefix | ||
282 | ·*·A·collection·of·utility·functions·to·detect·vendor·prefixed·features | ||
283 | ·*/ | ||
284 | OpenLayers.Util.vendorPrefix·=·(function()·{ | ||
285 | ····"use·strict"; | ||
286 | ····var·VENDOR_PREFIXES·=·["",·"O",·"ms",·"Moz",·"Webkit"], | ||
287 | ········divStyle·=·document.createElement("div").style, | ||
288 | ········cssCache·=·{}, | ||
289 | ········jsCache·=·{}; | ||
290 | ····/** | ||
291 | ·····*·Function:·domToCss | ||
292 | ·····*·Converts·a·upper·camel·case·DOM·style·property·name·to·a·CSS·property | ||
293 | ·····*······i.e.·transformOrigin·->·transform-origin | ||
294 | ·····*······or···WebkitTransformOrigin·->·-webkit-transform-origin | ||
295 | ·····* | ||
296 | ·····*·Parameters: | ||
297 | ·····*·prefixedDom·-·{String}·The·property·to·convert | ||
298 | ·····* | ||
299 | ·····*·Returns: | ||
300 | ·····*·{String}·The·CSS·property | ||
301 | ·····*/ | ||
302 | ····function·domToCss(prefixedDom)·{ | ||
303 | ········if·(!prefixedDom)·{ | ||
304 | ············return·null; | ||
305 | ········} | ||
306 | ········return·prefixedDom. | ||
307 | ········replace(/([A-Z])/g,·function(c)·{ | ||
308 | ············return·"-"·+·c.toLowerCase(); | ||
309 | ········}). | ||
310 | ········replace(/^ms-/,·"-ms-"); | ||
311 | ····} | ||
312 | ····/** | ||
313 | ·····*·APIMethod:·css | ||
314 | ·····*·Detect·which·property·is·used·for·a·CSS·property | ||
315 | ·····* | ||
316 | ·····*·Parameters: | ||
317 | ·····*·property·-·{String}·The·standard·(unprefixed)·CSS·property·name | ||
318 | ·····* | ||
319 | ·····*·Returns: | ||
320 | ·····*·{String}·The·standard·CSS·property,·prefixed·property·or·null·if·not | ||
321 | ·····*··········supported | ||
322 | ·····*/ | ||
323 | ····function·css(property)·{ | ||
324 | ········if·(cssCache[property]·===·undefined)·{ | ||
325 | ············var·domProperty·=·property. | ||
326 | ············replace(/(-[\s\S])/g,·function(c)·{ | ||
327 | ················return·c.charAt(1).toUpperCase(); | ||
328 | ············}); | ||
329 | ············var·prefixedDom·=·style(domProperty); | ||
330 | ············cssCache[property]·=·domToCss(prefixedDom); | ||
331 | ········} | ||
332 | ········return·cssCache[property]; | ||
333 | ····} | ||
334 | ····/** | ||
335 | ·····*·APIMethod:·js | ||
336 | ·····*·Detect·which·property·is·used·for·a·JS·property/method | ||
337 | ·····* | ||
338 | ·····*·Parameters: | ||
339 | ·····*·obj·-·{Object}·The·object·to·test·on | ||
340 | ·····*·property·-·{String}·The·standard·(unprefixed)·JS·property·name | ||
341 | ·····* | ||
342 | ·····*·Returns: | ||
343 | ·····*·{String}·The·standard·JS·property,·prefixed·property·or·null·if·not | ||
344 | ·····*··········supported | ||
345 | ·····*/ | ||
346 | ····function·js(obj,·property)·{ | ||
347 | ········if·(jsCache[property]·===·undefined)·{ | ||
348 | ············var·tmpProp, | ||
349 | ················i·=·0, | ||
350 | ················l·=·VENDOR_PREFIXES.length, | ||
351 | ················prefix, | ||
352 | ················isStyleObj·=·(typeof·obj.cssText·!==·"undefined"); | ||
353 | ············jsCache[property]·=·null; | ||
354 | ············for·(;·i·<·l;·i++)·{ | ||
355 | ················prefix·=·VENDOR_PREFIXES[i]; | ||
356 | ················if·(prefix)·{ | ||
357 | ····················if·(!isStyleObj)·{ | ||
358 | ························//·js·prefix·should·be·lower-case,·while·style | ||
359 | ························//·properties·have·upper·case·on·first·character | ||
360 | ························prefix·=·prefix.toLowerCase(); | ||
361 | ····················} | ||
362 | ····················tmpProp·=·prefix·+·property.charAt(0).toUpperCase()·+·property.slice(1); | ||
363 | ················}·else·{ | ||
364 | ····················tmpProp·=·property; | ||
365 | ················} | ||
366 | ················if·(obj[tmpProp]·!==·undefined)·{ | ||
367 | ····················jsCache[property]·=·tmpProp; | ||
368 | ····················break; | ||
369 | ················} | ||
370 | ············} | ||
371 | ········} | ||
372 | ········return·jsCache[property]; | ||
373 | ····} | ||
374 | ····/** | ||
375 | ·····*·APIMethod:·style | ||
376 | ·····*·Detect·which·property·is·used·for·a·DOM·style·property | ||
377 | ·····* | ||
378 | ·····*·Parameters: | ||
Max diff block lines reached; 1865621/1879057 bytes (99.28%) of diff not shown. |
Offset 62, 14 lines modified | Offset 62, 204 lines modified | ||
62 | ········var·sourceIsEvt·=·typeof·window.Event·==·"function"·&&·source·instanceof·window.Event; | 62 | ········var·sourceIsEvt·=·typeof·window.Event·==·"function"·&&·source·instanceof·window.Event; |
63 | ········if·(!sourceIsEvt·&&·source.hasOwnProperty·&&·source.hasOwnProperty("toString"))·{ | 63 | ········if·(!sourceIsEvt·&&·source.hasOwnProperty·&&·source.hasOwnProperty("toString"))·{ |
64 | ············destination.toString·=·source.toString | 64 | ············destination.toString·=·source.toString |
65 | ········} | 65 | ········} |
66 | ····} | 66 | ····} |
67 | ····return·destination | 67 | ····return·destination |
68 | }; | 68 | }; |
69 | OpenLayers.Util·=·OpenLayers.Util·||·{}; | ||
70 | OpenLayers.Util.vendorPrefix·=·function()·{ | ||
71 | ····"use·strict"; | ||
72 | ····var·VENDOR_PREFIXES·=·["",·"O",·"ms",·"Moz",·"Webkit"], | ||
73 | ········divStyle·=·document.createElement("div").style, | ||
74 | ········cssCache·=·{}, | ||
75 | ········jsCache·=·{}; | ||
76 | ····function·domToCss(prefixedDom)·{ | ||
77 | ········if·(!prefixedDom)·{ | ||
78 | ············return·null | ||
79 | ········} | ||
80 | ········return·prefixedDom.replace(/([A-Z])/g,·function(c)·{ | ||
81 | ············return·"-"·+·c.toLowerCase() | ||
82 | ········}).replace(/^ms-/,·"-ms-") | ||
83 | ····} | ||
84 | ····function·css(property)·{ | ||
85 | ········if·(cssCache[property]·===·undefined)·{ | ||
86 | ············var·domProperty·=·property.replace(/(-[\s\S])/g,·function(c)·{ | ||
87 | ················return·c.charAt(1).toUpperCase() | ||
88 | ············}); | ||
89 | ············var·prefixedDom·=·style(domProperty); | ||
90 | ············cssCache[property]·=·domToCss(prefixedDom) | ||
91 | ········} | ||
92 | ········return·cssCache[property] | ||
93 | ····} | ||
94 | ····function·js(obj,·property)·{ | ||
95 | ········if·(jsCache[property]·===·undefined)·{ | ||
96 | ············var·tmpProp,·i·=·0, | ||
97 | ················l·=·VENDOR_PREFIXES.length, | ||
98 | ················prefix,·isStyleObj·=·typeof·obj.cssText·!==·"undefined"; | ||
99 | ············jsCache[property]·=·null; | ||
100 | ············for·(;·i·<·l;·i++)·{ | ||
101 | ················prefix·=·VENDOR_PREFIXES[i]; | ||
102 | ················if·(prefix)·{ | ||
103 | ····················if·(!isStyleObj)·{ | ||
104 | ························prefix·=·prefix.toLowerCase() | ||
105 | ····················} | ||
106 | ····················tmpProp·=·prefix·+·property.charAt(0).toUpperCase()·+·property.slice(1) | ||
107 | ················}·else·{ | ||
108 | ····················tmpProp·=·property | ||
109 | ················} | ||
110 | ················if·(obj[tmpProp]·!==·undefined)·{ | ||
111 | ····················jsCache[property]·=·tmpProp; | ||
112 | ····················break | ||
113 | ················} | ||
114 | ············} | ||
115 | ········} | ||
116 | ········return·jsCache[property] | ||
117 | ····} | ||
118 | ····function·style(property)·{ | ||
119 | ········return·js(divStyle,·property) | ||
120 | ····} | ||
121 | ····return·{ | ||
122 | ········css:·css, | ||
123 | ········js:·js, | ||
124 | ········style:·style, | ||
125 | ········cssCache:·cssCache, | ||
126 | ········jsCache:·jsCache | ||
127 | ····} | ||
128 | }(); | ||
129 | OpenLayers.Animation·=·function(window)·{ | ||
130 | ····var·requestAnimationFrame·=·OpenLayers.Util.vendorPrefix.js(window,·"requestAnimationFrame"); | ||
131 | ····var·isNative·=·!!requestAnimationFrame; | ||
132 | ····var·requestFrame·=·function()·{ | ||
133 | ········var·request·=·window[requestAnimationFrame]·||·function(callback,·element)·{ | ||
134 | ············window.setTimeout(callback,·16) | ||
135 | ········}; | ||
136 | ········return·function(callback,·element)·{ | ||
137 | ············request.apply(window,·[callback,·element]) | ||
138 | ········} | ||
139 | ····}(); | ||
140 | ····var·counter·=·0; | ||
141 | ····var·loops·=·{}; | ||
142 | ····function·start(callback,·duration,·element)·{ | ||
143 | ········duration·=·duration·>·0·?·duration·:·Number.POSITIVE_INFINITY; | ||
144 | ········var·id·=·++counter; | ||
145 | ········var·start·=·+new·Date; | ||
146 | ········loops[id]·=·function()·{ | ||
147 | ············if·(loops[id]·&&·+new·Date·-·start·<=·duration)·{ | ||
148 | ················callback(); | ||
149 | ················if·(loops[id])·{ | ||
150 | ····················requestFrame(loops[id],·element) | ||
151 | ················} | ||
152 | ············}·else·{ | ||
153 | ················delete·loops[id] | ||
154 | ············} | ||
155 | ········}; | ||
156 | ········requestFrame(loops[id],·element); | ||
157 | ········return·id | ||
158 | ····} | ||
159 | ····function·stop(id)·{ | ||
160 | ········delete·loops[id] | ||
161 | ····} | ||
162 | ····return·{ | ||
163 | ········isNative:·isNative, | ||
164 | ········requestFrame:·requestFrame, | ||
165 | ········start:·start, | ||
166 | ········stop:·stop | ||
167 | ····} | ||
168 | }(window); | ||
169 | OpenLayers.Kinetic·=·OpenLayers.Class({ | ||
170 | ····threshold:·0, | ||
171 | ····deceleration:·.0035, | ||
172 | ····nbPoints:·100, | ||
173 | ····delay:·200, | ||
174 | ····points:·undefined, | ||
175 | ····timerId:·undefined, | ||
176 | ····initialize:·function(options)·{ | ||
177 | ········OpenLayers.Util.extend(this,·options) | ||
178 | ····}, | ||
179 | ····begin:·function()·{ | ||
180 | ········OpenLayers.Animation.stop(this.timerId); | ||
181 | ········this.timerId·=·undefined; | ||
182 | ········this.points·=·[] | ||
Max diff block lines reached; 534480/540792 bytes (98.83%) of diff not shown. |
Offset 33176, 14 lines modified | Offset 33176, 1793 lines modified | ||
33176 | /** | 33176 | /** |
33177 | ·*·Constant:·CORNER_SIZE | 33177 | ·*·Constant:·CORNER_SIZE |
33178 | ·*·{Integer}·5.·Border·space·for·the·RICO·corners. | 33178 | ·*·{Integer}·5.·Border·space·for·the·RICO·corners. |
33179 | ·*/ | 33179 | ·*/ |
33180 | OpenLayers.Popup.AnchoredBubble.CORNER_SIZE·=·5; | 33180 | OpenLayers.Popup.AnchoredBubble.CORNER_SIZE·=·5; |
33181 | /*·====================================================================== | 33181 | /*·====================================================================== |
33182 | ····OpenLayers/Icon.js | ||
33183 | ···======================================================================·*/ | ||
33184 | /*·Copyright·(c)·2006-2013·by·OpenLayers·Contributors·(see·authors.txt·for | ||
33185 | ·*·full·list·of·contributors).·Published·under·the·2-clause·BSD·license. | ||
33186 | ·*·See·license.txt·in·the·OpenLayers·distribution·or·repository·for·the | ||
33187 | ·*·full·text·of·the·license.·*/ | ||
33188 | /** | ||
33189 | ·*·@requires·OpenLayers/BaseTypes/Class.js | ||
33190 | ·*/ | ||
33191 | /** | ||
33192 | ·*·Class:·OpenLayers.Icon | ||
33193 | ·*· | ||
33194 | ·*·The·icon·represents·a·graphical·icon·on·the·screen.··Typically·used·in | ||
33195 | ·*·conjunction·with·a·<OpenLayers.Marker>·to·represent·markers·on·a·screen. | ||
33196 | ·* | ||
33197 | ·*·An·icon·has·a·url,·size·and·position.··It·also·contains·an·offset·which· | ||
33198 | ·*·allows·the·center·point·to·be·represented·correctly.··This·can·be | ||
33199 | ·*·provided·either·as·a·fixed·offset·or·a·function·provided·to·calculate | ||
33200 | ·*·the·desired·offset.· | ||
33201 | ·*· | ||
33202 | ·*/ | ||
33203 | OpenLayers.Icon·=·OpenLayers.Class({ | ||
33204 | ····/**· | ||
33205 | ·····*·Property:·url· | ||
33206 | ·····*·{String}··image·url | ||
33207 | ·····*/ | ||
33208 | ····url:·null, | ||
33209 | ····/**· | ||
33210 | ·····*·Property:·size· | ||
33211 | ·····*·{<OpenLayers.Size>|Object}·An·OpenLayers.Size·or | ||
33212 | ·····*·an·object·with·a·'w'·and·'h'·properties. | ||
33213 | ·····*/ | ||
33214 | ····size:·null, | ||
33215 | ····/**· | ||
33216 | ·····*·Property:·offset· | ||
33217 | ·····*·{<OpenLayers.Pixel>|Object}·distance·in·pixels·to·offset·the | ||
33218 | ·····*·image·when·being·rendered.·An·OpenLayers.Pixel·or·an·object | ||
33219 | ·····*·with·a·'x'·and·'y'·properties. | ||
33220 | ·····*/ | ||
33221 | ····offset:·null, | ||
33222 | ····/**· | ||
33223 | ·····*·Property:·calculateOffset· | ||
33224 | ·····*·{Function}·Function·to·calculate·the·offset·(based·on·the·size) | ||
33225 | ·····*/ | ||
33226 | ····calculateOffset:·null, | ||
33227 | ····/**· | ||
33228 | ·····*·Property:·imageDiv· | ||
33229 | ·····*·{DOMElement}· | ||
33230 | ·····*/ | ||
33231 | ····imageDiv:·null, | ||
33232 | ····/**· | ||
33233 | ·····*·Property:·px· | ||
33234 | ·····*·{<OpenLayers.Pixel>|Object}·An·OpenLayers.Pixel·or·an·object | ||
33235 | ·····*·with·a·'x'·and·'y'·properties. | ||
33236 | ·····*/ | ||
33237 | ····px:·null, | ||
33238 | ····/**· | ||
33239 | ·····*·Constructor:·OpenLayers.Icon | ||
33240 | ·····*·Creates·an·icon,·which·is·an·image·tag·in·a·div.·· | ||
33241 | ·····* | ||
33242 | ·····*·url·-·{String}· | ||
33243 | ·····*·size·-·{<OpenLayers.Size>|Object}·An·OpenLayers.Size·or·an | ||
33244 | ·····*···································object·with·a·'w'·and·'h' | ||
33245 | ·····*···································properties. | ||
33246 | ·····*·offset·-·{<OpenLayers.Pixel>|Object}·An·OpenLayers.Pixel·or·an | ||
33247 | ·····*······································object·with·a·'x'·and·'y' | ||
33248 | ·····*······································properties. | ||
33249 | ·····*·calculateOffset·-·{Function}· | ||
33250 | ·····*/ | ||
33251 | ····initialize:·function(url,·size,·offset,·calculateOffset)·{ | ||
33252 | ········this.url·=·url; | ||
33253 | ········this.size·=·size·||·{ | ||
33254 | ············w:·20, | ||
33255 | ············h:·20 | ||
33256 | ········}; | ||
33257 | ········this.offset·=·offset·||·{ | ||
33258 | ············x:·-(this.size.w·/·2), | ||
33259 | ············y:·-(this.size.h·/·2) | ||
33260 | ········}; | ||
33261 | ········this.calculateOffset·=·calculateOffset; | ||
33262 | ········var·id·=·OpenLayers.Util.createUniqueID("OL_Icon_"); | ||
33263 | ········this.imageDiv·=·OpenLayers.Util.createAlphaImageDiv(id); | ||
33264 | ····}, | ||
33265 | ····/**· | ||
33266 | ·····*·Method:·destroy | ||
33267 | ·····*·Nullify·references·and·remove·event·listeners·to·prevent·circular· | ||
33268 | ·····*·references·and·memory·leaks | ||
33269 | ·····*/ | ||
33270 | ····destroy:·function()·{ | ||
33271 | ········//·erase·any·drawn·elements | ||
33272 | ········this.erase(); | ||
33273 | ········OpenLayers.Event.stopObservingElement(this.imageDiv.firstChild); | ||
33274 | ········this.imageDiv.innerHTML·=·""; | ||
33275 | ········this.imageDiv·=·null; | ||
33276 | ····}, | ||
33277 | ····/**· | ||
33278 | ·····*·Method:·clone | ||
33279 | ·····*· | ||
33280 | ·····*·Returns: | ||
33281 | ·····*·{<OpenLayers.Icon>}·A·fresh·copy·of·the·icon. | ||
33282 | ·····*/ | ||
33283 | ····clone:·function()·{ | ||
33284 | ········return·new·OpenLayers.Icon(this.url, | ||
33285 | ············this.size, | ||
33286 | ············this.offset, | ||
33287 | ············this.calculateOffset); | ||
Max diff block lines reached; 3504577/3558552 bytes (98.48%) of diff not shown. |
Offset 13318, 14 lines modified | Offset 13318, 580 lines modified | ||
13318 | ········var·corner·=·OpenLayers.Bounds.oppositeQuadrant(this.relativePosition); | 13318 | ········var·corner·=·OpenLayers.Bounds.oppositeQuadrant(this.relativePosition); |
13319 | ········OpenLayers.Util.removeItem(corners,·corner); | 13319 | ········OpenLayers.Util.removeItem(corners,·corner); |
13320 | ········return·corners.join("·") | 13320 | ········return·corners.join("·") |
13321 | ····}, | 13321 | ····}, |
13322 | ····CLASS_NAME:·"OpenLayers.Popup.AnchoredBubble" | 13322 | ····CLASS_NAME:·"OpenLayers.Popup.AnchoredBubble" |
13323 | }); | 13323 | }); |
13324 | OpenLayers.Popup.AnchoredBubble.CORNER_SIZE·=·5; | 13324 | OpenLayers.Popup.AnchoredBubble.CORNER_SIZE·=·5; |
13325 | OpenLayers.Icon·=·OpenLayers.Class({ | ||
13326 | ····url:·null, | ||
13327 | ····size:·null, | ||
13328 | ····offset:·null, | ||
13329 | ····calculateOffset:·null, | ||
13330 | ····imageDiv:·null, | ||
13331 | ····px:·null, | ||
13332 | ····initialize:·function(url,·size,·offset,·calculateOffset)·{ | ||
13333 | ········this.url·=·url; | ||
13334 | ········this.size·=·size·||·{ | ||
13335 | ············w:·20, | ||
13336 | ············h:·20 | ||
13337 | ········}; | ||
13338 | ········this.offset·=·offset·||·{ | ||
13339 | ············x:·-(this.size.w·/·2), | ||
13340 | ············y:·-(this.size.h·/·2) | ||
13341 | ········}; | ||
13342 | ········this.calculateOffset·=·calculateOffset; | ||
13343 | ········var·id·=·OpenLayers.Util.createUniqueID("OL_Icon_"); | ||
13344 | ········this.imageDiv·=·OpenLayers.Util.createAlphaImageDiv(id) | ||
13345 | ····}, | ||
13346 | ····destroy:·function()·{ | ||
13347 | ········this.erase(); | ||
13348 | ········OpenLayers.Event.stopObservingElement(this.imageDiv.firstChild); | ||
13349 | ········this.imageDiv.innerHTML·=·""; | ||
13350 | ········this.imageDiv·=·null | ||
13351 | ····}, | ||
13352 | ····clone:·function()·{ | ||
13353 | ········return·new·OpenLayers.Icon(this.url,·this.size,·this.offset,·this.calculateOffset) | ||
13354 | ····}, | ||
13355 | ····setSize:·function(size)·{ | ||
13356 | ········if·(size·!=·null)·{ | ||
13357 | ············this.size·=·size | ||
13358 | ········} | ||
13359 | ········this.draw() | ||
13360 | ····}, | ||
13361 | ····setUrl:·function(url)·{ | ||
13362 | ········if·(url·!=·null)·{ | ||
13363 | ············this.url·=·url | ||
13364 | ········} | ||
13365 | ········this.draw() | ||
13366 | ····}, | ||
13367 | ····draw:·function(px)·{ | ||
13368 | ········OpenLayers.Util.modifyAlphaImageDiv(this.imageDiv,·null,·null,·this.size,·this.url,·"absolute"); | ||
13369 | ········this.moveTo(px); | ||
13370 | ········return·this.imageDiv | ||
13371 | ····}, | ||
13372 | ····erase:·function()·{ | ||
13373 | ········if·(this.imageDiv·!=·null·&&·this.imageDiv.parentNode·!=·null)·{ | ||
13374 | ············OpenLayers.Element.remove(this.imageDiv) | ||
13375 | ········} | ||
13376 | ····}, | ||
13377 | ····setOpacity:·function(opacity)·{ | ||
13378 | ········OpenLayers.Util.modifyAlphaImageDiv(this.imageDiv,·null,·null,·null,·null,·null,·null,·null,·opacity) | ||
13379 | ····}, | ||
13380 | ····moveTo:·function(px)·{ | ||
13381 | ········if·(px·!=·null)·{ | ||
13382 | ············this.px·=·px | ||
13383 | ········} | ||
13384 | ········if·(this.imageDiv·!=·null)·{ | ||
13385 | ············if·(this.px·==·null)·{ | ||
13386 | ················this.display(false) | ||
13387 | ············}·else·{ | ||
13388 | ················if·(this.calculateOffset)·{ | ||
13389 | ····················this.offset·=·this.calculateOffset(this.size) | ||
13390 | ················} | ||
13391 | ················OpenLayers.Util.modifyAlphaImageDiv(this.imageDiv,·null,·{ | ||
13392 | ····················x:·this.px.x·+·this.offset.x, | ||
13393 | ····················y:·this.px.y·+·this.offset.y | ||
13394 | ················}) | ||
13395 | ············} | ||
13396 | ········} | ||
13397 | ····}, | ||
13398 | ····display:·function(display)·{ | ||
13399 | ········this.imageDiv.style.display·=·display·?·""·:·"none" | ||
13400 | ····}, | ||
13401 | ····isDrawn:·function()·{ | ||
13402 | ········var·isDrawn·=·this.imageDiv·&&·this.imageDiv.parentNode·&&·this.imageDiv.parentNode.nodeType·!=·11; | ||
13403 | ········return·isDrawn | ||
13404 | ····}, | ||
13405 | ····CLASS_NAME:·"OpenLayers.Icon" | ||
13406 | }); | ||
13407 | OpenLayers.Rule·=·OpenLayers.Class({ | ||
13408 | ····id:·null, | ||
13409 | ····name:·null, | ||
13410 | ····title:·null, | ||
13411 | ····description:·null, | ||
13412 | ····context:·null, | ||
13413 | ····filter:·null, | ||
13414 | ····elseFilter:·false, | ||
13415 | ····symbolizer:·null, | ||
13416 | ····symbolizers:·null, | ||
13417 | ····minScaleDenominator:·null, | ||
13418 | ····maxScaleDenominator:·null, | ||
13419 | ····initialize:·function(options)·{ | ||
13420 | ········this.symbolizer·=·{}; | ||
13421 | ········OpenLayers.Util.extend(this,·options); | ||
13422 | ········if·(this.symbolizers)·{ | ||
13423 | ············delete·this.symbolizer | ||
13424 | ········} | ||
13425 | ········this.id·=·OpenLayers.Util.createUniqueID(this.CLASS_NAME·+·"_") | ||
13426 | ····}, | ||
13427 | ····destroy:·function()·{ | ||
13428 | ········for·(var·i·in·this.symbolizer)·{ | ||
13429 | ············this.symbolizer[i]·=·null | ||
13430 | ········} | ||
13431 | ········this.symbolizer·=·null; | ||
13432 | ········delete·this.symbolizers | ||
13433 | ····}, | ||
13434 | ····evaluate:·function(feature)·{ | ||
13435 | ········var·context·=·this.getContext(feature); | ||
13436 | ········var·applies·=·true; | ||
13437 | ········if·(this.minScaleDenominator·||·this.maxScaleDenominator)·{ | ||
13438 | ············var·scale·=·feature.layer.map.getScale() | ||
13439 | ········} | ||
13440 | ········if·(this.minScaleDenominator)·{ | ||
13441 | ············applies·=·scale·>=·OpenLayers.Style.createLiteral(this.minScaleDenominator,·context) | ||
13442 | ········} | ||
13443 | ········if·(applies·&&·this.maxScaleDenominator)·{ | ||
13444 | ············applies·=·scale·<·OpenLayers.Style.createLiteral(this.maxScaleDenominator,·context) | ||
Max diff block lines reached; 1824174/1843607 bytes (98.95%) of diff not shown. |