Compare commits

..

3760 Commits

Author SHA1 Message Date
Éric Lemoine
757ccf148b Merge pull request #858 from elemoine/getzoom
Add ol.View2D#getZoom
2013-07-11 00:51:25 -07:00
Éric Lemoine
3e4d39b228 Export ol.View2D#getZoom 2013-07-11 09:50:31 +02:00
Éric Lemoine
d7e838274e Merge pull request #840 from fredj/zoomcontrol
Add ol.control.Zoom#zoomByDelta function
2013-07-09 21:38:41 -07:00
Éric Lemoine
2cc5c7a776 Merge pull request #857 from elemoine/view2d-docs
Better View2D docs
2013-07-09 06:29:12 -07:00
Éric Lemoine
daa03b5ef7 @class doc for View2D 2013-07-09 15:28:31 +02:00
Éric Lemoine
42abdb308a Better docs for View2DOptions 2013-07-09 15:28:31 +02:00
Frederic Junod
17f0d01e9f Add ol.control.Zoom#zoomByDelta function
To replace ol.control.Zoom#handleIn_ and ol.control.Zoom#handleOut_ callbacks.
2013-07-09 14:21:46 +02:00
Éric Lemoine
f72784dc38 Merge pull request #855 from elemoine/zoom-slider-fix
Zoomslider cannot be added to a map with no target
2013-07-09 04:45:50 -07:00
Éric Lemoine
44a9c181aa handleMapPostrender may get a null frameState 2013-07-09 10:06:01 +02:00
Éric Lemoine
ccf6aa10ac Zoomslider cannot be added to a map with no target
The zoom slider control's initSlider_ function requires that the control's element is inserted in the document. So if initSlider_ is called before the map have a target then the slider isn't correctly initialized. This commit fixes that by defering the slider initialization until the first handleMapPostrender call.
2013-07-09 10:05:15 +02:00
Éric Lemoine
a10d142752 Add ol.View2D#getZoom 2013-07-09 09:30:45 +02:00
Tim Schaub
461d85dfc3 Merge pull request #854 from elemoine/remove-gh-pages
Rename build/gh-pages to build/hosted
2013-07-05 17:09:52 -07:00
Tim Schaub
087b4d04a6 Merge pull request #809 from tschaub/clockwise
Consistent winding order for polygon rings.
2013-07-05 17:04:50 -07:00
Éric Lemoine
3af5e530ca Merge pull request #835 from elemoine/setzoom
Add ol.View2D.prototype.setZoom
2013-07-05 12:31:34 -07:00
Éric Lemoine
d9f554e10d Dir build/gh-pages renamed to build/hosted 2013-07-05 20:45:40 +02:00
Tim Schaub
d482b66af3 Doc typo 2013-07-05 11:48:45 -06:00
Éric Lemoine
7efff5c3cf Merge pull request #833 from elemoine/stop-other-interactions
Remove ol.MapBrowserEvent#stopOtherInteractions
2013-07-04 00:48:35 -07:00
Éric Lemoine
d0e198df93 Use constrainResolution function
Use the constrainResolution function when setting the initial view resolution.
2013-07-04 09:16:04 +02:00
Éric Lemoine
e6efa741d2 More type checking for View2D 2013-07-04 09:13:31 +02:00
Éric Lemoine
552853a3b8 Remove unused createContinuous function 2013-07-04 08:58:33 +02:00
Éric Lemoine
0cf4024194 Add ol.View2D.prototype.setZoom 2013-07-04 08:58:32 +02:00
Frédéric Junod
a071c3521c Merge pull request #848 from fredj/geolocation-example
Update geolocation example to display all the properties
2013-07-01 07:28:06 -07:00
Frédéric Junod
6ae4b28db8 Merge pull request #847 from fredj/apidoc
API doc update.
2013-07-01 07:01:35 -07:00
Frederic Junod
e1f8863bd2 Update geolocation example to display all the properties 2013-07-01 15:48:50 +02:00
Frederic Junod
1c3369a3f6 Add className parameter documentation 2013-07-01 15:04:14 +02:00
Tim Schaub
f2ce4db85a Merge pull request #842 from tschaub/examples
Updates to example markup.
2013-06-28 12:15:53 -07:00
Tim Schaub
949edb694e Duplicated id 2013-06-28 10:43:57 -06:00
Tim Schaub
7ebacba720 Use full grid
The example documentation should not be restricted to 1/3 of the row unless there is something else consuming the other 2/3.
2013-06-28 10:42:42 -06:00
Tim Schaub
12338783cc Load scripts in RAW mode by default
On-the-fly compilation is a frustrating default.
2013-06-28 10:07:02 -06:00
Tim Schaub
82c791f9f5 Merge pull request #839 from tschaub/delete-gh-pages-branch
Delete gh-pages branch
2013-06-28 08:26:00 -07:00
Éric Lemoine
e29d0aa52c Merge pull request #841 from elemoine/fix-ign-example
Fix wmts-ign example when hosted (take 2)
2013-06-28 02:35:00 -07:00
Éric Lemoine
5d5a248344 ol.source.Source#setLogo is not exported 2013-06-28 11:33:02 +02:00
Éric Lemoine
09a50ad442 Merge pull request #838 from elemoine/fix-ign-example
Fix wmts-ign example when hosted
2013-06-28 02:10:17 -07:00
Éric Lemoine
1d6e428e8f ol.source.Source#setAttributions is not exported 2013-06-28 00:10:27 +02:00
Tim Schaub
e1a2c72587 Adjective -> adverb 2013-06-27 16:01:22 -06:00
Tim Schaub
dc246cd45b Correct links to hosted examples (and docs) 2013-06-27 15:59:52 -06:00
Tim Schaub
04bab7e436 The examples and docs are deployed from the openlayers.github.io repo
To deploy the latest docs and examples, see https://github.com/openlayers/openlayers.github.io/blob/build/README.md

tl;dr

    git clone -b build https://github.com/openlayers/openlayers.github.io.git
    cd openlayers.github.io
    npm install
    npm run deploy

Subsequent deploys are simply: `npm run deploy`

This publishes the examples (http://ol3js.org/en/master/examples/) and docs (http://ol3js.org/en/master/apidoc/).

The `build.py gh-pages` target published under different paths (http://ol3js.org/ol3/master/examples/ and http://ol3js.org/ol3/master/apidoc/).  Having two (not always up to date) copies of this content hosted on the same domain is A Bad Idea.
2013-06-27 15:56:11 -06:00
Tim Schaub
cd14753495 Merge pull request #831 from tschaub/kml-example
Nicer KML example
2013-06-27 14:38:57 -07:00
Éric Lemoine
445f85b3e2 Merge pull request #801 from elemoine/ign
Add an IGN WMTS example
2013-06-27 14:19:48 -07:00
Tim Schaub
a2bc986785 Timezone offset in a tooltip 2013-06-27 14:51:04 -06:00
Éric Lemoine
2974c74f1a Export ol.tilegrid.TileGrid#getResolutions 2013-06-27 22:37:27 +02:00
Éric Lemoine
943bad6e17 Add an IGN WMTS example 2013-06-27 22:37:27 +02:00
Éric Lemoine
a19cb9ca64 Sort matrixIds by scaleDenominator
We cannot assume that the matrixIds are ordered in the matrixSet. For example, they're not ordered in http://wxs.ign.fr/cle/geoportail/wmts?SERVICE=WMTS&REQUEST=GetCapabilities.
2013-06-27 21:36:14 +02:00
Éric Lemoine
e6e98a6ca2 Fix WMTS requestEncoding 2013-06-27 21:36:14 +02:00
Tim Schaub
aab5c8472c Update example to use expression parsing 2013-06-27 10:17:40 -06:00
Tim Schaub
b7412552a5 Adding a prettier KML example 2013-06-27 10:17:40 -06:00
Tim Schaub
fa4d2d485d Merge pull request #829 from tschaub/kml
Parse MultiGeometry in KML
2013-06-27 06:35:50 -07:00
Éric Lemoine
6fc4aa68b6 Remove ol.MapBrowserEvent#stopOtherInteractions
and check for false/true in the return from handleMapBrowserEvent. Refs #791.
2013-06-27 14:43:00 +02:00
Frédéric Junod
07d790260c Merge pull request #690 from fredj/layer-options
ol.layer.Layer: default values
2013-06-27 04:35:02 -07:00
Tom Payne
d6f442bbee Merge pull request #820 from twpayne/use-view2dstate-in-interactions
Use view2DState in interactions
2013-06-27 04:06:05 -07:00
Tom Payne
f360dd86a0 Use view2DState in ol.interaction.TouchZoom 2013-06-27 12:25:52 +02:00
Tom Payne
dc9d7e857a Use view2DState in ol.interaction.TouchRotate 2013-06-27 12:25:52 +02:00
Tom Payne
e84c484677 Use view2DState in ol.interaction.TouchPan 2013-06-27 12:25:52 +02:00
Tom Payne
79e0c81301 Use view2DState in ol.interaction.DragRotate 2013-06-27 12:25:50 +02:00
Tom Payne
ec4110ee54 Use view2DState in ol.interaction.DragRotateAndZoom 2013-06-27 12:20:48 +02:00
Tom Payne
8565201c74 Use view2DState in ol.interaction.DragPan 2013-06-27 12:20:46 +02:00
Tom Payne
b555c52013 Use view2DState in ol.interaction.Drag 2013-06-27 12:19:16 +02:00
Tom Payne
a4e8e529c4 Make View2D-only comments more consistent 2013-06-27 12:19:15 +02:00
Tom Payne
d96ea1cb97 Don't invoke interactions if view is not defined 2013-06-27 12:19:15 +02:00
Tim Schaub
a7ca22dde0 Merge pull request #790 from tschaub/expression
Expression parsing
2013-06-26 16:40:08 -07:00
Tim Schaub
71153d26d1 Prefer if/else to switch 2013-06-26 17:01:27 -06:00
Tim Schaub
42aa94de21 KML MultiGeometry may contain other MultiGeometry
As demonstrated in the tests, a MultiGeometry may contain other MultiGeometry nodes.  We can support this with heterogenous GeometryCollection instances - though these are not currently rendered.
2013-06-26 12:31:08 -06:00
Tim Schaub
30d947521d The fromParts factories take geometry instances instead of coords
The MultiLineString case was correct here.  The MultiPoint and MultiPolygon cases should be using the constructor instead of the `fromParts` factories.
2013-06-26 12:23:19 -06:00
Tim Schaub
f06208920f Merge pull request #828 from tschaub/shortdesc
Minor edits to shortdesc in examples
2013-06-26 10:59:58 -07:00
Éric Lemoine
16e23a33fb Merge pull request #823 from elemoine/tilegridbug
Tile has a child if z < maxZoom
2013-06-26 10:10:38 -07:00
Tim Schaub
0958674765 Shortdesc edits 2013-06-26 10:57:36 -06:00
Tim Schaub
e0a3f8ca07 Removing markup from shortdesc element (see #827)
The text in `shortdesc` is shown on the example index page.  It shouldn't have any markup in it.
2013-06-26 10:28:15 -06:00
Frédéric Junod
3800676e97 Merge pull request #812 from fredj/812
INTERACTION view hint ever growing on pinch zoom
2013-06-26 06:42:25 -07:00
Frederic Junod
87dda95b18 Handle ol.ViewHint.INTERACTING in ol.interaction.Touch 2013-06-26 09:27:44 +02:00
Frederic Junod
ae7b342ee9 Handle ol.ViewHint.INTERACTING in ol.interaction.Drag 2013-06-26 09:27:44 +02:00
Éric Lemoine
020d528e73 Tile has a child if z < maxZoom 2013-06-26 07:18:59 +02:00
Tim Schaub
4ccff4e8b6 Merge pull request #817 from tschaub/vector-exports
Proper vector exports to get vector examples working
2013-06-25 18:17:37 -07:00
Tim Schaub
3dc8c4bc7b Properly exporting the transformFeatureInfo option
This was previously called getTransformFeatureInfo, which is a method instead of an option.  In addition, the generate-exports.py script does not properly export properties whose names appear on a different line than the @property annotation.  This makes the vector-layer.html, kml.html, and gpx.html examples work with the built lib.
2013-06-25 13:21:13 -06:00
Tim Schaub
72532b7dd6 Export individual geometry types
This makes the style-rules.html example work with built lib.
2013-06-25 13:21:13 -06:00
Tim Schaub
34acea5366 Merge pull request #821 from tschaub/generated-file-linting
Create separate target for linting generated files
2013-06-25 12:20:45 -07:00
Tim Schaub
4e5ef05e5e Expression for evaluating feature ids 2013-06-25 12:15:34 -06:00
Tim Schaub
1eaf82ead5 Enum for checking built-in lib functions internally 2013-06-25 12:15:34 -06:00
Tim Schaub
70fef73869 Testing operator precedence 2013-06-25 12:15:34 -06:00
Tim Schaub
c81057780a More tests for binary operators 2013-06-25 12:15:34 -06:00
Tim Schaub
1f23a245e4 More tests for unary expression 2013-06-25 12:15:34 -06:00
Tim Schaub
2577d3f7d6 Rename ol.expression to ol.expr 2013-06-25 12:15:34 -06:00
Tim Schaub
9928730bd3 Tests for ol.expression.register() 2013-06-25 12:15:33 -06:00
Tim Schaub
233595ac75 Allow registration of custom functions for expressions 2013-06-25 12:15:33 -06:00
Tim Schaub
8e8b26805f Uniformly support evaluating symbolizers without features
In combination with a (not yet implemented) `Symbolizer#isLiteral` method, calling `Symbolizer#evaluate` without a feature is the fast track for rendering batches of like-styled features.  This change also simplifies the handling of undefined symbolizer literal properties (where stroke or fill properties are optional).
2013-06-25 12:15:33 -06:00
Tim Schaub
cab983f826 We are guarnteed that all TextLiteral properties are defined (see #770)
Instead of using the browser defaults, we use `ol.style.TextDefaults`.
2013-06-25 12:15:33 -06:00
Tim Schaub
c7da7e4c2e Using new expressions in text symbolizer 2013-06-25 12:15:33 -06:00
Tim Schaub
b04a36ede7 Replace use of filter with expressions
The canvas vector layer still has the (API candidate) `getFeatures` method that accepts an arbitrary expression (was filter).  This, and the `getFeaturesObject` method under it are only used in the tests.  The rendering code that was using filters is now calling `layer.getFeaturesObjectForExtent` with an explicit extent and optional geometry type.
2013-06-25 12:15:33 -06:00
Tim Schaub
a663d8fcae Accept an expression string for rule filter 2013-06-25 12:11:50 -06:00
Tim Schaub
38b784d672 Support +/- unary operators for literals 2013-06-25 12:11:50 -06:00
Tim Schaub
d70a9eba01 Lib for well-known functions
This reveals a lexer bug that needs addressing.
2013-06-25 12:11:50 -06:00
Tim Schaub
bd5d9d572e Lint 2013-06-25 12:11:50 -06:00
Tim Schaub
5e309e244b Using ol.expression.parse 2013-06-25 12:11:50 -06:00
Tim Schaub
53abedaada Correct doc and arg order 2013-06-25 12:11:50 -06:00
Tim Schaub
72d32ec71a Correct index for tokens 2013-06-25 12:11:50 -06:00
Tim Schaub
f0567f5053 Expect the unexpected 2013-06-25 12:11:49 -06:00
Tim Schaub
36d10bef11 Custom error for unexpected token
This makes it clearer to the compiler where we are throwing.
2013-06-25 12:11:49 -06:00
Tim Schaub
62eb0dd72b Give token an index and throw unexpected token from a common place 2013-06-25 12:11:49 -06:00
Tim Schaub
bb1b0cba95 Getter for not expression argument 2013-06-25 12:11:49 -06:00
Tim Schaub
c05fb8c61b Getters for member expression properties 2013-06-25 12:11:49 -06:00
Tim Schaub
2528581642 Getters for math expression properties 2013-06-25 12:11:49 -06:00
Tim Schaub
4a617871da Getters for logical expression properties 2013-06-25 12:11:49 -06:00
Tim Schaub
3de330eb99 Getter for literal expression value 2013-06-25 12:11:49 -06:00
Tim Schaub
6d6ec357e1 Getter for identifier expression name 2013-06-25 12:11:48 -06:00
Tim Schaub
582a52849c Getters for comparison expression properties 2013-06-25 12:11:48 -06:00
Tim Schaub
be636d7f46 Getters for call expression properties 2013-06-25 12:11:48 -06:00
Tim Schaub
6458f98996 Describing the extent of support for ES-5 expressions 2013-06-25 12:11:48 -06:00
Tim Schaub
2fd8f4cb00 Integration testing for binary logical operators 2013-06-25 12:11:48 -06:00
Tim Schaub
973606e67a Integration tests for equality operators 2013-06-25 12:11:48 -06:00
Tim Schaub
d5e133b7d8 Satisfy the build/check-requires-timestamp task (see #785)
I think this line should not be required, as `ol.expression.Char` is only used internally in this file.
2013-06-25 12:11:48 -06:00
Tim Schaub
3a3f9bc20b Integration testing for relational operators
No `instanceof` or `in` operator support.
2013-06-25 12:11:47 -06:00
Tim Schaub
9d5424236c Integration testing for additive operators 2013-06-25 12:11:47 -06:00
Tim Schaub
7c2550fefa Integration testing for multiplicative operators 2013-06-25 12:11:47 -06:00
Tim Schaub
2492515e8f Integration testing for unary operators
Only supporting ! at the moment.
2013-06-25 12:11:47 -06:00
Tim Schaub
e6f03c8f22 Confirm whitespace is consumed as expected 2013-06-25 12:11:47 -06:00
Tim Schaub
26a7d907a2 Test unary expression parsing 2013-06-25 12:11:47 -06:00
Tim Schaub
a0bd736948 Left-hand-side expression parsing 2013-06-25 12:11:47 -06:00
Tim Schaub
803b3a3f7d Binary expression parsing 2013-06-25 12:11:46 -06:00
Tim Schaub
40b12410f0 Increment after scanning >= and <= (and expect EOF in tests) 2013-06-25 12:11:46 -06:00
Tim Schaub
379ac82688 Test argument parsing 2013-06-25 12:11:46 -06:00
Tim Schaub
38c8927ae2 Doc and method reorg 2013-06-25 12:11:46 -06:00
Tim Schaub
6d0badcf2a Optional scope (works for expressions without identifiers) 2013-06-25 12:11:46 -06:00
Tim Schaub
d920d8e578 Test left-hand-side expression parsing 2013-06-25 12:11:46 -06:00
Tim Schaub
13d0b8b084 Provide ol.expression.parse method
This is the only method needed in the API.
2013-06-25 12:11:46 -06:00
Tim Schaub
3643ea164f Cast boolean and null before creating literal expression 2013-06-25 12:11:46 -06:00
Tim Schaub
ce67aa2617 Make way for convenience functions in ol.expression package 2013-06-25 12:11:45 -06:00
Tim Schaub
737d669e4a Correct types 2013-06-25 12:11:45 -06:00
Tim Schaub
7a1e69e288 Initial parsing tests 2013-06-25 12:11:45 -06:00
Tim Schaub
cb9725bdfb Provide static method to check for valid operators 2013-06-25 12:11:45 -06:00
Tim Schaub
29b77a2dac Member expressions 2013-06-25 12:11:45 -06:00
Tim Schaub
fbb028e15e Call expressions 2013-06-25 12:11:45 -06:00
Tim Schaub
2f7e74ab35 Create binary expressions when parsing 2013-06-25 12:11:45 -06:00
Tim Schaub
f050546fe2 Logical expressions 2013-06-25 12:11:44 -06:00
Tim Schaub
153df45f95 Math expressions
Just simple binary type expressions supported here.  These can be serialized in a variety of formats.  More complex operations to be supported by call expressions.
2013-06-25 12:11:44 -06:00
Tim Schaub
b2ff793ea1 Comparison expressions 2013-06-25 12:11:44 -06:00
Tim Schaub
c4867bafec Smaller subset of binary operators 2013-06-25 12:11:44 -06:00
Tim Schaub
7800e9b0cc Comments, links, copyrights 2013-06-25 12:11:44 -06:00
Tim Schaub
052b973b39 Reduce to a single literal 2013-06-25 12:11:44 -06:00
Tim Schaub
20b66fc447 Proper specs 2013-06-25 12:11:43 -06:00
Tim Schaub
0abcbb9854 Stray not 2013-06-25 12:11:43 -06:00
Tim Schaub
ed2e21dffa Parsing 2013-06-25 12:11:43 -06:00
Tim Schaub
1f68522837 Utility methods on the lexer 2013-06-25 12:11:43 -06:00
Tim Schaub
a87ebfe97b Specific expression types 2013-06-25 12:11:43 -06:00
Tim Schaub
d7e0d043f3 Consistently number 2013-06-25 12:11:43 -06:00
Tim Schaub
063b461ffd Fewer calls to charCodeAt 2013-06-25 12:11:43 -06:00
Tim Schaub
9edc9ebcc5 Use next instead 2013-06-25 12:11:42 -06:00
Tim Schaub
f272350e00 Expose next and peek methods 2013-06-25 12:11:42 -06:00
Tim Schaub
5baa38b82c Test punctuator scanning 2013-06-25 12:11:42 -06:00
Tim Schaub
957b6db3d7 Skip whitespace 2013-06-25 12:11:42 -06:00
Tim Schaub
50f94911b1 Scan string literals 2013-06-25 12:11:42 -06:00
Tim Schaub
4d62cea700 Escape sequences in our identifiers have already been handled 2013-06-25 12:11:42 -06:00
Tim Schaub
0844df8cc2 Scanning identifiers
This includes code that is likely not necessary.  The escape sequence scanning will likely not be used in our case, but I'm committing it here so it can be brought back if needed later.
2013-06-25 12:11:42 -06:00
Tim Schaub
a748665646 Space and comment 2013-06-25 12:11:42 -06:00
Tim Schaub
040c80a5ad Expectations about token type 2013-06-25 12:11:42 -06:00
Tim Schaub
193cf4de50 Scan numeric literals 2013-06-25 12:11:41 -06:00
Tim Schaub
81b344715a Renaming for clarity 2013-06-25 12:11:41 -06:00
Tim Schaub
a5343161bf Separate lexer 2013-06-25 12:11:41 -06:00
Tim Schaub
84a9fb40ef More char code tests 2013-06-25 12:11:41 -06:00
Tim Schaub
88fd0fda64 Initial bits for parser 2013-06-25 12:11:41 -06:00
Tim Schaub
48130670ca Create separate target for linting generated files
This allows us to ignore specific error codes (e.g. LINE_TOO_LONG) for externs, exports, types, etc. (any auto-generated files).
2013-06-25 10:43:27 -06:00
Tom Payne
ca3e1f0843 Merge pull request #819 from twpayne/fix-819
Drag rotate and zoom example is broken
2013-06-25 08:07:03 -07:00
Tim Schaub
40b10c13dc Merge pull request #802 from tschaub/802-multilinstring-typo
Multiline strings are not rendered correctly due to typo in VectorLayer
2013-06-25 07:33:08 -07:00
Tom Payne
23e54e4543 Stop other interactions when dragging 2013-06-25 15:46:00 +02:00
Tom Payne
38893eaf8c Merge pull request #818 from twpayne/view2d-properties
View2D properties
2013-06-25 04:50:30 -07:00
Frederic Junod
cd13e700ac Pass options to the base class 2013-06-25 13:13:41 +02:00
Tom Payne
fab12b10c1 Handle projection being undefined in getView2DState 2013-06-25 12:26:35 +02:00
Tom Payne
f462adbe53 Set default View2D rotation in constructor and getView2DState instead of in getRotation 2013-06-25 12:19:30 +02:00
Tom Payne
e5d6ccd6ba Use getView2DState instead of getResolution/getRotation in interactions 2013-06-25 12:18:31 +02:00
Tim Schaub
99ba5a0da8 Store rings so exerior is clockwise and interior is counter-clockwise
KML and WKT don't specify a winding order, so we write those out in CW/CCW order (for exterior/interior).  GML references ISO 19107 that specifies CCW/CW, so we serialize in that winding order.

Having hand generated all this GML data the first time around, I reserve the right to modify it for the tests.
2013-06-24 17:46:36 -06:00
Tim Schaub
e292d8fa12 Add method to determine winding order of linear rings 2013-06-24 17:43:22 -06:00
ahocevar
a427719a22 Merge pull request #816 from ahocevar/tilegrid-units
Use ol.Projection#getMetersPerUnit(). r=@tschaub
2013-06-24 16:05:56 -07:00
ahocevar
a14b21d80c Use ol.Projection#.getMetersPerUnit()
As a follow-up to #815, this change makes
ol.tilegrid.createForProjection work in cases where a Proj4
projection does not have units set. For better code readability,
a new variable is used when calculating the resolution.
2013-06-25 00:29:50 +02:00
Tim Schaub
d1eec80324 Merge pull request #815 from tschaub/override
Override for clarity
2013-06-24 14:38:26 -07:00
Tim Schaub
bb915cbf3d Less code
Since out meters per unit conversion table is a bit spare, prefer the configured conversion.
2013-06-24 12:27:36 -06:00
Tim Schaub
129e4d5704 Fix doc bug 2013-06-24 12:21:56 -06:00
Tim Schaub
5a95d606f8 Override for clarity 2013-06-24 12:20:34 -06:00
Tim Schaub
388967d00c Merge pull request #814 from tschaub/814-min-resolution
Fix vector rendering for projections that do not specify units
2013-06-24 11:08:50 -07:00
Tim Schaub
20527ab1f1 Reuse tile range 2013-06-24 11:34:59 -06:00
Tim Schaub
a9f01a4390 Use getMetersPer unit method 2013-06-24 11:34:48 -06:00
Tim Schaub
d10eff97a2 Allow getMetersPerUnit to work without units identifier (see #814) 2013-06-24 11:34:16 -06:00
Tim Schaub
3f169b1751 Merge pull request #810 from tschaub/async-tests
Proper async testing
2013-06-24 09:02:47 -07:00
ahocevar
f697450523 Merge pull request #811 from ahocevar/conditional-click
Click handler called with empty event object on Android. r=@fredj
2013-06-24 03:09:48 -07:00
ahocevar
a405279f34 Click handler called with empty event object on Android
On Android (both native browser and Chrome), the handleTouchEnd_
method is sometimes reached in a state where this.down_ is null.
This check protects against this.click_ being called without
an event object. To see this issue, open any example in Android,
and tap the zoom + or - button.
2013-06-24 10:35:02 +02:00
ahocevar
b30dcdd35a Merge pull request #799 from ahocevar/dynamic-canvas-tilegrid
Do not use a fixed tile grid for vector rendering. r=@elemoine,@tschaub,@twpayne
2013-06-23 11:15:50 -07:00
Tim Schaub
d6be28a7bb Get rid of unnecessary waitsFor function
This was a relic from the Jasmine tests.  Mocha tests have a built-in timeout.  Async tests are registered with a function that takes a callback.
2013-06-23 11:20:57 -06:00
Tim Schaub
7a620de1bf Calling callback in WMS capabilities tests 2013-06-23 11:08:34 -06:00
Tim Schaub
be33fd58b3 Calling callback in GML v3 tests 2013-06-23 11:04:03 -06:00
Tim Schaub
54378f394a Calling callback in GML v2 tests 2013-06-23 11:02:38 -06:00
Tim Schaub
7bf24eb918 Calling callback in kml tests
Also reordering things so we have `expect(got).to.xmleql(expected)`.
2013-06-23 11:00:41 -06:00
ahocevar
5cc3e189eb Need to take units into account 2013-06-23 18:48:21 +02:00
ahocevar
af0764b1ca Simpler tile coord access now that we only have one resolution 2013-06-23 18:47:49 +02:00
ahocevar
27c23f676b Fixing requires 2013-06-23 18:47:00 +02:00
ahocevar
1c5f466e61 Adding comment about MIN_RESOLUTION 2013-06-23 18:31:25 +02:00
ahocevar
61fcbd560e Do not render tiles during animation and interaction 2013-06-23 18:31:25 +02:00
ahocevar
f20e6002cc Tile grid and cache for one resolution only 2013-06-23 18:31:25 +02:00
ahocevar
89c23b5560 Use binaryInsert instead of sort 2013-06-23 18:31:25 +02:00
ahocevar
aa62764d90 Do not add resolutions while interacting 2013-06-23 18:31:25 +02:00
ahocevar
0aacf197bf Separate method for updating the tile cache 2013-06-23 18:31:24 +02:00
ahocevar
3afd8b4242 Do not use a fixed tile grid for vector rendering
Instead, we create a new tile grid whenever renderFrame is
called, no animation is active, and the resolution is not in the
tile grid already. This gives better rendering results because
we get vector tiles at native resolutions.
2013-06-23 18:30:57 +02:00
ahocevar
1826b7a9be Merge pull request #808 from ahocevar/no-empty-tiles
Don't render/cache tiles with no features. r=@tschaub
2013-06-23 09:11:55 -07:00
ahocevar
3fc4fc3eb8 Only render and cache tiles that have features 2013-06-23 15:52:31 +02:00
Frédéric Junod
8fe0027d98 Merge pull request #805 from fredj/cleanup
ol.Geolocation and ol.DeviceOrientation cleanup
2013-06-21 08:07:03 -07:00
Frédéric Junod
2a7b9381bc Merge pull request #807 from fredj/mouse-position
Don't attempt to display the mouse position if the frameState is null
2013-06-21 04:51:57 -07:00
Frederic Junod
23f09937bc Don't attempt to display the mouse position if the frameState is null 2013-06-21 12:27:39 +02:00
Éric Lemoine
04344ed184 Merge pull request #762 from elemoine/controls
Add addControl and removeControl methods to the map
2013-06-21 00:53:12 -07:00
Frederic Junod
9cac8a92df Set default 'tracking' property to false 2013-06-21 09:21:48 +02:00
Frederic Junod
c4ce85c847 Add missing 'undefined' in type cast 2013-06-21 09:14:41 +02:00
Frédéric Junod
f83fe424fb Merge pull request #800 from fredj/control_object
Make ol.control.Control extends ol.Object
2013-06-20 22:44:10 -07:00
Tim Schaub
91a8703852 Correct typo in geometry type (thanks @jystic)
Previously read 'multilinstring' instead of 'multilinestring'.  Letting the compiler check for typos instead now.
2013-06-20 17:57:29 -06:00
Tom Payne
b7a1ada94d Merge pull request #798 from twpayne/fix-layer-setters
Don't attempt to constrain values in setters
2013-06-20 09:52:40 -07:00
Frederic Junod
4217c5e47a Meaningful variable names 2013-06-20 16:56:59 +02:00
Frederic Junod
22adf354e2 Add 'projection' and 'coordinateFormat' to ol.control.MousePosition 2013-06-20 16:50:43 +02:00
Éric Lemoine
b0dde2ecb4 Do not call setMap(null) if control not in map 2013-06-20 16:47:23 +02:00
ahocevar
10f03a360c Merge pull request #770 from ahocevar/text-symbolizer
Basic support for text symbolizers. r=@bartvde,@tschaub
2013-06-20 07:06:38 -07:00
ahocevar
d250f4449c Updating example to use new properties 2013-06-20 15:24:54 +02:00
ahocevar
ba87c2e5ab Adding TODOs 2013-06-20 15:02:12 +02:00
ahocevar
f316b79bcd Proper handling of defaults 2013-06-20 14:57:01 +02:00
Éric Lemoine
be86b83b67 Add addControl and removeControl methods to ol.Map 2013-06-20 14:51:10 +02:00
Frederic Junod
9d63217778 Add 'units' property to ol.control.ScaleLine 2013-06-20 14:50:32 +02:00
Éric Lemoine
b85520f504 The map now has a collection of controls 2013-06-20 14:39:20 +02:00
Tom Payne
11cfcda37c Stop buttons from moving so much when changing values 2013-06-20 05:41:39 +02:00
Tom Payne
61f89bab6e Prevent buttons from setting out-of-range brightness/contrast/saturation values 2013-06-20 05:41:39 +02:00
ahocevar
9e3ca1c13c Changing renderLabels_ method name to renderText_ 2013-06-19 22:14:52 +02:00
ahocevar
cb9f4972df Use 'text' instead of 'name' for the label text 2013-06-19 22:10:44 +02:00
ahocevar
7353e05a90 Fixing merge errors from unmerging #404 2013-06-19 22:01:51 +02:00
ahocevar
c17424deec Basic support for text symbolizers
This adds basic label rendering for points and polygons to the
canvas renderer, and a text symbolizer to the style package.
2013-06-19 22:01:51 +02:00
Frederic Junod
cbf0402471 Make ol.control.Control extends ol.Object 2013-06-19 16:43:59 +02:00
Tom Payne
aa1a71ed96 Don't attempt to constrain values in setters 2013-06-19 13:38:57 +02:00
Frédéric Junod
79980bc7be Merge pull request #795 from fredj/pan_actionbutton
Right click pan
2013-06-18 22:18:57 -07:00
Tim Schaub
56c2b85fce Merge pull request #796 from tschaub/geojson-rename
Use .geojson extension for GeoJSON
2013-06-18 15:54:47 -07:00
Tim Schaub
2ee0805075 Taking advantage of GitHub's rendering of .geojson 2013-06-18 15:39:45 -06:00
Frederic Junod
6adedacaf8 Only pan the map when the mouse action button is pressed 2013-06-18 16:53:03 +02:00
Tom Payne
bf9b0b4dd2 Merge pull request #779 from twpayne/ch-projection
Add native support for Swiss projections
2013-06-18 06:36:29 -07:00
Frédéric Junod
81a167ef01 Merge pull request #791 from fredj/mapbrowserevent
ol.MapBrowserEvent: call browserEvent.{preventDefault|stopPropagation}
2013-06-18 06:25:43 -07:00
Frédéric Junod
517b4b27d7 Merge pull request #688 from fredj/mouse-position
Add ol.control.MousePosition.setProjection
2013-06-18 06:04:08 -07:00
Frederic Junod
fd5f4f3dd8 API doc strings for preventDefault and stopPropagation
thanks @elemoine
2013-06-18 15:02:42 +02:00
Frederic Junod
bed44dd82c Add ol.MapBrowserEvent.stopOtherInteractions
When called, stops the interaction chain.
2013-06-18 13:02:17 +02:00
Frederic Junod
2bd87313cd ol.MapBrowserEvent: call browserEvent.{preventDefault|stopPropagation} 2013-06-18 11:31:44 +02:00
Frederic Junod
f99fd26386 Add ol.control.MousePosition.getProjection 2013-06-18 11:20:19 +02:00
Frederic Junod
916dde0045 Add ol.control.MousePosition.setProjection 2013-06-18 11:12:20 +02:00
ahocevar
4392feef1b Merge pull request #794 from ahocevar/simplify-ranges
Simplifying ranges structure by adding compiler hints. r=@tschaub,@twpayne,@elemoine
2013-06-18 01:27:24 -07:00
Frédéric Junod
153fea538a Merge pull request #788 from fredj/mapevent
Remove defaultPrevented attribut from ol.MapEvent
2013-06-17 09:24:12 -07:00
ahocevar
c54d81258a Merge pull request #793 from ahocevar/proj-no-extent
Making extent optional for projections. r=@twpayne
2013-06-17 08:40:22 -07:00
ahocevar
11cbbab901 Simplifying ranges structure by adding compiler hints
In JavaScript, keys of object literals are always strings, and
internal type conversions are performed. Now if we tell the
compiler that keys are numbers, we get inconsistent types when
iterating through keys. So instead we set the key type to string
and do a type cast to make the compiler happy. Note that we
could also do toString() instead of a type cast, but it would
add a performance penalty (see
http://jsperf.com/internal-type-conversion-vs-tostring-for-object-keys).
2013-06-17 17:37:48 +02:00
ahocevar
b71bf9607c Do not set center constraint
This change slipped in accidently. Thanks @twpayne for catching
this.
2013-06-17 16:46:47 +02:00
Tom Payne
7b9ac53ace Merge pull request #749 from openlayers/webgl-vector
Skeleton WebGL vector support
2013-06-17 07:08:33 -07:00
Bruno Binet
be0149e478 Merge pull request #763 from bbinet/cleanup-attribution-control
Cleanup attribution control
2013-06-17 07:01:00 -07:00
ahocevar
24953e5f0e Making it clear that Proj4js is used 2013-06-17 15:28:05 +02:00
ahocevar
29b5af9c87 New example using a projection unknown to the client 2013-06-17 15:27:06 +02:00
ahocevar
caefacac35 Serve WMS tiles for sources without specified extent
With this change, WMS sources do not need an extent configured.
The result is that the WMS will be queried for tiles for any
extent.
2013-06-17 15:26:23 +02:00
ahocevar
37b369e0d7 Making extent optional for projections
The projection validity extent is used to generate a sensible
set of default resolutions and a sensible default tile grid.
By making it optional, we can still generate defaults - with
zoom levels that are similar to the default web mercator zoom
levels (based on fitting the world on a single tile, even if the
projection is not available for the whole world).
2013-06-17 15:24:37 +02:00
Tom Payne
cbf88de606 Don't include Swiss projections in default build 2013-06-17 12:23:29 +02:00
Tom Payne
941432af75 Use rigorous Swiss grid / EPSG:4326 transforms 2013-06-17 12:23:29 +02:00
Tom Payne
826556775c Add ol.ellipsoid.BESSEL1841 2013-06-17 12:23:29 +02:00
Tom Payne
0968e2b00b Add ol.proj.EPSG2056 and factor out common code 2013-06-17 12:23:29 +02:00
Tom Payne
c02e2530f1 Add ol.proj.EPSG21781 2013-06-17 12:23:28 +02:00
Bruno Binet
6b904573a0 Hide attribution instead of DOM removal
The reasons are:

 - It minimizes DOM updates (most changes to the attribution are just toggling
   visibility, not the more expensive creation, insertion and removal of DOM
   elements)
 - The order of attributions remains stable as layer visibilities are toggled
   and the user interacts with the map
2013-06-14 00:23:01 +02:00
Bruno Binet
950b53f6dc Clean up attribution control
Do not use map.getLayers() anymore, but get layers from frameState.layersArray.
2013-06-14 00:22:47 +02:00
Bart van den Eijnden
d552d27a35 Merge pull request #783 from bartvde/apidoc2
Add more content for the API doc (r=@twpayne,@tschaub,@fredj)
2013-06-12 11:05:07 -07:00
Bart van den Eijnden
0237675711 address review comments 2013-06-12 20:03:57 +02:00
Frederic Junod
ba8684b585 Remove defaultPrevented attribut from ol.MapEvent
already defined in parent class: http://docs.closure-library.googlecode.com/git/class_goog_events_Event.html
2013-06-12 16:50:12 +02:00
Tom Payne
b08a086a11 Merge pull request #787 from twpayne/proj-related-clean-ups
Projection-related clean ups
2013-06-12 07:44:52 -07:00
Tim Schaub
489879eb0d Merge pull request #784 from tschaub/missing-detail
More useful detail in log messages on the check for missing requires.
2013-06-12 07:21:27 -07:00
Tom Payne
e0dd15567c Add ol.Ellipsoid#e and #eSquared 2013-06-12 16:05:00 +02:00
Tom Payne
1e9ccab806 Make ol.Ellipsoid properties constant 2013-06-12 16:05:00 +02:00
Tom Payne
9751bde8d1 Clean up whitespace 2013-06-12 16:05:00 +02:00
Frédéric Junod
3fab93fc4a Merge pull request #786 from fredj/contextmenu-events
Relay contextmenu browser event
2013-06-12 06:06:53 -07:00
Frederic Junod
1de3ffe57e Relay contextmenu browser event 2013-06-12 14:14:25 +02:00
Tim Schaub
bb980abe8c And the proper syntax 2013-06-11 16:53:55 -06:00
Tim Schaub
9726be64c6 More useful detail in log messages
One line per missing require.  Include line number of last use.  Include proper syntax for adding requires.
2013-06-11 16:42:39 -06:00
ahocevar
f7fd1cf2b0 Merge pull request #404 from ahocevar/canvas-transform
Vector features disappear completely as you zoom in (r=@tschaub)
2013-06-11 12:07:14 -07:00
ahocevar
ea02626c28 Reducing number of default zoom levels
To avoid issues with long segments, we accept scaled tiles for
now. Further workarounds and browser tickets reporting our
issues are needed.
2013-06-11 21:06:18 +02:00
Bart van den Eijnden
8dc97790bc Add more content for the API doc
Involves additions to (there will be subsequent pull requests for other
classes):
- ol.Attribution
- ol.Collection
- ol.Expression
- ol.Feature
- ol.Geolocation
- ol.Map
- ol.Object
- ol.Overlay
- ol.Projection
- ol.View2D
- ol.control.Attribution
- ol.control.Control
- ol.control.FullScreen
- ol.control.Logo
- ol.control.MousePosition
- ol.control.ScaleLine
- ol.control.Zoom
- ol.control.ZoomSlider
- ol.dom.Input
- ol.filter.Filter
- ol.filter.Geometry
- ol.filter.Logical
2013-06-11 20:56:04 +02:00
Frédéric Junod
55b3cbaf17 Merge pull request #552 from fredj/deviceorientation
Add ol.DeviceOrientation
2013-06-11 02:09:38 -07:00
Tim Schaub
9647567704 Merge pull request #776 from tschaub/proj-test
Rename spec to be like src
2013-06-10 10:21:30 -07:00
Tim Schaub
e56a791d41 Merge pull request #774 from tschaub/test-deps
Test dependencies in a common place
2013-06-10 09:08:57 -07:00
Tim Schaub
e7d6bae0ad Providing proj in ol.test 2013-06-10 09:34:43 -06:00
Tim Schaub
a631c50979 Rename spec to be like src 2013-06-10 09:29:00 -06:00
Tim Schaub
2964cc922c Test dependencies in a common place 2013-06-10 09:19:02 -06:00
Tom Payne
bbb95e15fa Fix line collection arguments in tests, thanks @ahocevar 2013-06-10 14:43:01 +02:00
Tom Payne
fc79a0ef3b Merge pull request #771 from ahocevar/leaner-webgl-vector
Removing canvas renderer stub for VectorLayer2
2013-06-10 05:11:19 -07:00
ahocevar
e8ab4f9f0c Removing canvas renderer stub for VectorLayer2
Setting the renderer of the ten-thousand-points example to
WebGL should remove the need for this stub. This is basically
the same approach we took for all vector examples in master,
where we set the renderer to Canvas.
2013-06-10 11:22:32 +02:00
Frédéric Junod
526c38a698 Merge pull request #769 from fredj/export-supported
Export ol.Geolocation.SUPPORTED
2013-06-10 01:37:23 -07:00
ahocevar
489459f313 Apply transform to coordinates rather than the canvas
Credit goes to @jystic for figuring out this approach.
2013-06-09 20:20:53 +02:00
Frederic Junod
4d4a654a8e Export ol.DeviceOrientation.SUPPORTED 2013-06-08 09:53:06 +02:00
Frederic Junod
79f99485c1 Export ol.Geolocation.SUPPORTED 2013-06-08 09:32:39 +02:00
Frederic Junod
ea8c970d6e Better device orientation example 2013-06-07 16:26:45 +02:00
Frederic Junod
9b00967df0 Replace 'changed' with 'change' (see #694) 2013-06-07 16:16:02 +02:00
Frederic Junod
b66b0be8b4 Add options to ol.DeviceOrientation constructor 2013-06-07 16:16:02 +02:00
Frederic Junod
15e5242611 Add 'heading' property to ol.DeviceOrientation 2013-06-07 16:16:02 +02:00
Frederic Junod
c431cc7f63 Add 'tracking' property to ol.DeviceOrientation 2013-06-07 16:16:02 +02:00
Frederic Junod
448e300a03 Add ol.DeviceOrientation 2013-06-07 16:16:02 +02:00
ahocevar
7cd5266d39 Merge pull request #744 from ahocevar/getfeature
getFeatures method and featureInfo templates. r=@bartvde
2013-06-07 07:06:00 -07:00
ahocevar
f83fedb9e1 API doc improvements 2013-06-07 15:34:14 +02:00
ahocevar
3a6c7cf204 Renaming featureInfoFunction to transformFeatureInfo 2013-06-07 15:34:13 +02:00
ahocevar
77d22c4038 getFeatures method and featureInfo templates
To avoid surprises for application developers, this change
creates a new getFeatures method. So it is clear now beforehand
whether features or feature info markup is returned. The result
is now also grouped by layer, so application developers always
have a link between a layer and the feature info it returns.

To make getFeatureInfo return markup for vector layers, this
change also adds a featureInfoFunction property to the vector
layer, which gives developers full control over how features are
rendered to feature info markup.
2013-06-07 15:34:13 +02:00
Frédéric Junod
34becd6871 Merge pull request #768 from fredj/mouseout
Relay mouseout browser event
2013-06-07 01:18:23 -07:00
Frederic Junod
d05bb872f3 Relay mouseout browser event 2013-06-07 09:48:15 +02:00
Tom Payne
85ca39cf0c Add warnings about internal classes and functions 2013-06-06 18:36:40 +02:00
Tom Payne
a858664035 Add warning about internal API to example 2013-06-06 18:36:00 +02:00
Frédéric Junod
286438ae0e Merge pull request #766 from fredj/cleanup
Cleanup
2013-06-06 05:12:17 -07:00
Frederic Junod
ece2a4b64c Store listener keys into an array instead of individual variables 2013-06-06 12:08:32 +02:00
Frédéric Junod
fd62963ad2 Merge pull request #760 from fredj/issue-758
Fix viewportPosition attributes access (closes #758)
2013-06-03 02:28:11 -07:00
Frederic Junod
4f0e09c00e Fix viewportPosition attributes access (closes #758) 2013-06-03 10:40:13 +02:00
ahocevar
461d2a1ba8 Merge pull request #756 from ahocevar/extent-equals
Use ol.extent.equals, removing TODO. r=@elemoine
2013-06-01 15:14:20 -07:00
ahocevar
57e36f4eda Use ol.extent.equals, removing TODO 2013-06-01 11:11:13 -06:00
Tom Payne
5850dff254 Use long LineString in ten-thousand-points example 2013-06-01 18:16:44 +02:00
Tom Payne
45572931a1 Draw LineStrings using drawElements
This enables drawing of LineStrings with more than two coordinates.
2013-06-01 18:16:43 +02:00
Tom Payne
e260255ce8 Return Uint16Array from ol.geom2.LineStringCollection#getIndices 2013-06-01 18:16:43 +02:00
Tom Payne
38c0e24bcd Add Assertion#arreql
Needed because expect.js's eql does not support typed arrays.
2013-06-01 18:16:43 +02:00
Tom Payne
3225a07f6f Add ol.geom2.LineStringCollection#getIndices 2013-06-01 18:16:43 +02:00
Tom Payne
db2f805ed9 Return split values in a single interleaved Float32Array 2013-06-01 18:16:43 +02:00
Tom Payne
42f15f000b Add ol.structs.Buffer#getSplit32 2013-06-01 18:16:43 +02:00
Tom Payne
f61edacb5c Activate ol.renderer.canvas.VectorLayer2 bare skeleton 2013-06-01 18:16:43 +02:00
Tom Payne
674468268e Add ol.renderer.canvas.VectorLayer2 bare skeleton 2013-06-01 18:16:43 +02:00
Tom Payne
f55fed9bc3 Add ten thousand points example 2013-06-01 18:16:42 +02:00
Tom Payne
2484cf2c55 Add line string rendering 2013-06-01 18:16:42 +02:00
Tom Payne
8f86288614 Add line string collections to ol.source.VectorSource2 2013-06-01 18:16:42 +02:00
Tom Payne
1690cb9cae Add ol.geom2.LineStringCollection 2013-06-01 18:16:42 +02:00
Tom Payne
4cc5441579 Activate ol.renderer.webgl.VectorLayer2 2013-06-01 18:16:42 +02:00
Tom Payne
e4b5ec8f0b Add ol.renderer.webgl.VectorLayer2 2013-06-01 18:16:42 +02:00
Tom Payne
bed8c44859 Add ol.layer.VectorLayer2 2013-06-01 18:09:29 +02:00
Tom Payne
ac48fae0af Add ol.source.VectorSource2 2013-06-01 18:09:29 +02:00
Tom Payne
93ba55d357 Add ol.geom2.PointCollection 2013-06-01 18:09:29 +02:00
Tom Payne
d51cdc0e48 Add ol.geom2 utility functions 2013-06-01 18:09:29 +02:00
Tom Payne
7fd2e1ffca Factor out ol.structs.Buffer#allocate 2013-06-01 18:09:29 +02:00
Tom Payne
bcf7707b01 Factor out ol.structs.Buffer#markDirty 2013-06-01 18:09:28 +02:00
Frédéric Junod
07694c52b0 Merge pull request #753 from fredj/size-as-array
Redefine ol.Size to be Array.<number>
2013-06-01 08:40:35 -07:00
Frederic Junod
a1a7e21f92 Redefine ol.Size to be Array.<number> 2013-06-01 10:22:06 +02:00
ahocevar
5560829695 Merge pull request #755 from ahocevar/newline
Fixing linter error
2013-05-31 19:07:46 -07:00
ahocevar
b746116a20 Fixing linter error 2013-05-31 20:07:04 -06:00
ahocevar
4d5149a35f Merge pull request #754 from ahocevar/geom-doc
Exposing ol.geom.GeometryType
2013-05-31 14:05:22 -07:00
ahocevar
56ac30de91 Exposing ol.geom.GeometryType
This is necessary for using ol.filter.Geometry.
2013-05-31 15:04:55 -06:00
Frédéric Junod
1d7ca27e61 Merge pull request #478 from fredj/pixel-as-array
Redefine ol.Pixel to be Array.<number>
2013-05-31 07:26:54 -07:00
Éric Lemoine
a2316e6e14 Merge pull request #752 from elemoine/color-examples
Add color filter values to buttons
2013-05-31 07:22:53 -07:00
Frederic Junod
be081fd44e Redefine ol.Pixel to be Array.<number> 2013-05-31 15:53:04 +02:00
Éric Lemoine
93fd685ca7 Display hue/saturation value in button text 2013-05-31 15:47:17 +02:00
Éric Lemoine
84b1886666 Display brightness/contrast value in button text 2013-05-31 15:45:40 +02:00
Tom Payne
075f4aadc7 Merge pull request #748 from twpayne/rename-projection-to-proj
Rename ol.projection to ol.proj
2013-05-31 04:34:22 -07:00
Frédéric Junod
e9adc06bee Merge pull request #694 from fredj/backbone-model
Change ol.Object event name syntax
2013-05-31 04:33:51 -07:00
Frederic Junod
984002a7ec Change ol.Object event name syntax
'changed' to 'change' and '<attribute>_changed' to 'change:<attribute>'.
2013-05-31 12:38:37 +02:00
Tom Payne
46553c719c Rename ol.projection to ol.proj 2013-05-30 18:55:58 +02:00
Tim Schaub
5e5d8e5b17 Merge pull request #739 from tschaub/attribution-style
Style for attribution control
2013-05-30 08:00:21 -07:00
Tim Schaub
7e20ea160c Simplify style 2013-05-30 08:59:31 -06:00
Tim Schaub
3d0f7f3b70 Merge pull request #738 from tschaub/allow-stop
Allow user to stop map at the end of a drag
2013-05-30 06:15:05 -07:00
Bart van den Eijnden
317281b37b Merge pull request #729 from bartvde/wktsingleton
static read and write methods on ol.parser.WKT (r=@ahocevar)
2013-05-30 00:29:53 -07:00
Tom Payne
795ea69982 Merge pull request #722 from twpayne/unused-variable-check
More rigorous linting
2013-05-28 08:06:30 -07:00
Tom Payne
11672db967 Use === and !== for comparisons with 0 2013-05-28 16:07:48 +02:00
Tom Payne
c0cfc7872e Add missing semicolons 2013-05-28 16:03:32 +02:00
Tom Payne
e744a1b6e9 Enable all gjslint errors 2013-05-28 16:01:34 +02:00
Tom Payne
975e180b26 Fix typo in ol.style.Icon 2013-05-28 16:01:34 +02:00
Tom Payne
7046ebe261 Remove unused variables in tile range 2013-05-28 16:01:34 +02:00
Tom Payne
f4d54ace1d Remove unused variables in structs 2013-05-28 16:01:34 +02:00
Tom Payne
8b539cd4cc Remove unused variables in sphere 2013-05-28 16:01:34 +02:00
Tom Payne
20982bba31 Remove unused variables in sources 2013-05-28 16:01:33 +02:00
Tom Payne
f64e35e8bb Remove unused variables in renderers 2013-05-28 16:01:33 +02:00
Tom Payne
268c18988b Remove unused variables in parsers 2013-05-28 16:01:33 +02:00
Tom Payne
42b6ed5d2a Remove unused variables in interactions 2013-05-28 16:01:33 +02:00
Tom Payne
b021bfd70f Remove unused variables in geom 2013-05-28 16:01:33 +02:00
Tom Payne
6900c90bc5 Remove unused variables in examples 2013-05-28 15:15:49 +02:00
Tom Payne
1c77fb2357 Merge pull request #740 from twpayne/rtree-clean-ups
R-tree clean-ups
2013-05-28 06:14:57 -07:00
Frédéric Junod
c28f64efde Merge pull request #742 from fredj/geolocation
Dispatch an error on Geolocation failure
2013-05-27 04:36:42 -07:00
Frederic Junod
82d2fa373a Dispatch an error on Geolocation failure 2013-05-27 12:46:36 +02:00
Bart van den Eijnden
9968a5feda Merge pull request #734 from bartvde/xml-ie9
Fix XML serialize and xml_eql in IE9 (r=@ahocevar)
2013-05-27 02:28:48 -07:00
Bart van den Eijnden
0f3c151058 implement review comment by @ahocevar 2013-05-27 11:04:27 +02:00
Bart van den Eijnden
b921bece0e Merge pull request #725 from bartvde/gpx
Implement GPX parser (read/write). (r=@fredj)
2013-05-27 01:42:09 -07:00
Bart van den Eijnden
81bffb464f Merge pull request #737 from bartvde/feature-id
FeatureId support in GML (r/w) and KML (w) (r=@fredj)
2013-05-27 01:39:59 -07:00
Frédéric Junod
e2fa562326 Merge pull request #741 from fredj/export-view-constraints
Export constrainResolution and constrainRotation from ol.View2D
2013-05-26 23:47:59 -07:00
Frederic Junod
dab8c8dcd0 Export constrainResolution and constrainRotation from ol.View2D 2013-05-26 08:56:06 +02:00
Frederic Junod
836700669f Sort exported properties 2013-05-26 08:46:30 +02:00
Tom Payne
a162b6fab3 Use empty extents and refactor for clarity 2013-05-25 20:39:55 -05:00
Tom Payne
f0baf2efc2 Add ol.extent.empty 2013-05-25 20:38:11 -05:00
Tom Payne
18b1789512 Sort methods alphabetically 2013-05-25 19:50:44 -05:00
Tom Payne
d80ded31ee Clean up some comments 2013-05-25 19:46:40 -05:00
Tom Payne
aaa4fec141 Move insert into method 2013-05-25 19:39:51 -05:00
Tom Payne
a871f29e75 Move remove into method 2013-05-25 19:35:59 -05:00
Tom Payne
ea1ee73392 Move search and searchReturningObject into methods 2013-05-25 19:33:46 -05:00
Tom Payne
32c663cf2c Move more functions into private methods 2013-05-25 19:24:45 -05:00
Tom Payne
3cdb9f130b Make minWidth and maxWidth private member variables 2013-05-25 18:27:38 -05:00
Tom Payne
476e35c276 Move makeMBR into private static function 2013-05-25 18:17:38 -05:00
Tom Payne
7f22455eed Move squarifiedRatio into private static function 2013-05-25 18:14:52 -05:00
Tim Schaub
439a8a5330 Style for attribution control 2013-05-24 19:02:43 -05:00
Tim Schaub
fa970f1ae2 Allow user to stop map at the end of a drag
If the time between the last move and now is longer than the configured delay, this means that the user stopped panning before releasing the map.
2013-05-24 18:18:34 -05:00
Bart van den Eijnden
3ee533a9b0 FeatureId support in GML (r/w) and KML (w)
Now that we have FeatureId support (see #733), we can add this back to the
GML parsers (v2 and v3). Also add write support for FeatureId in KML, read
support was already added by @fredj
2013-05-24 17:00:59 +02:00
Bart van den Eijnden
e63423eafe Merge pull request #736 from bartvde/jsdoc2
Add parser.jsdoc file for docs on parser options (p=@ahocevar, r=@bartvde)
2013-05-24 07:02:06 -07:00
Bart van den Eijnden
392d529168 Add parser.jsdoc file for docs on parser options.
Pointer by @ahocevar in #735
2013-05-24 16:00:17 +02:00
ahocevar
5a3ac559be Merge pull request #733 from ahocevar/fid
Store the feature's commonly used id. r=@fredj,@bartvde
2013-05-24 06:15:00 -07:00
ahocevar
111b127bf7 Merge pull request #2 from fredj/fid
Store the KML Placemark identifier
2013-05-24 06:14:29 -07:00
Bart van den Eijnden
9881411090 fix typo in WMTS parser 2013-05-24 14:02:00 +02:00
Bart van den Eijnden
6e80a35960 Static read and write functions on WKT parser
Use a singleton to implement static read and write methods on ol.parser.WKT.
2013-05-24 11:17:21 +02:00
Bart van den Eijnden
d8232bb484 Fix XML serialize and xml_eql in IE9
Use the xml property instead in IE for serializing XML.
The xml_eql tests were failing in IE9 on a difference between null and an
empty string for namespaceURI of attributes, this difference is not
relevant to our testing so make sure we ignore.
2013-05-24 10:53:29 +02:00
Bart van den Eijnden
f8ef902af4 Merge pull request #732 from bartvde/geojson-write
Write support for ol.parser.GeoJSON (r=@tschaub)
2013-05-24 00:38:10 -07:00
Frederic Junod
a452915d8a Store the KML Placemark identifier 2013-05-24 09:29:30 +02:00
ahocevar
8c0f1f979a Store the feature's commonly used id
To not clobber the feature's attributes, this is a separate
member property.
2013-05-23 11:16:17 -05:00
ahocevar
d1beaff8e4 Merge pull request #731 from ahocevar/rtree-api-tests
RTree API improvements and more tests. r=@twpayne
2013-05-23 08:28:56 -07:00
Bart van den Eijnden
4b0c43fb8b Merge pull request #726 from bartvde/kml_serialize
Small fixes for KML write (r=@ahocevar)
2013-05-23 07:36:33 -07:00
Bart van den Eijnden
93b067b6bc Write support for ol.parser.GeoJSON
Also add some convenience with static read and write methods based on the
singleton.
2013-05-23 15:57:11 +02:00
ahocevar
10e3a16f40 RTree API improvements and more tests
This change reverts the RTree API back to the original one (i.e.
insert() instead of put(), search() instead of find()), and
creates a new searchReturningObject() method that returns an
object keyed by UIDs.

It also adds missing tests for type restricted search and
searchReturningObject().
2013-05-22 18:25:40 -05:00
ahocevar
513115ea3b Merge pull request #730 from ahocevar/fix-rtree-tests
Fixing bug in tests
2013-05-22 11:42:22 -07:00
ahocevar
597405c288 Fixing bug in tests
That's what you get from copying and pasting and forgetting to
modify the pasted lines to suit your needs.
2013-05-22 13:41:29 -05:00
Frédéric Junod
2d765a6cf9 Merge pull request #728 from fredj/cleanup
Examples cleanup
2013-05-22 07:57:06 -07:00
Frederic Junod
2991c4ab57 Add a resolution input 2013-05-22 16:13:17 +02:00
Frederic Junod
fc12370765 Remove stray end tag fieldset 2013-05-22 16:03:59 +02:00
Frederic Junod
7ba4045e59 geolocation example: suppresses line breaks in tooltip 2013-05-22 15:53:55 +02:00
Frédéric Junod
cf605f2d52 Merge pull request #727 from fredj/mobile-featureinfo
getFeatureInfo examples: listen to click events
2013-05-22 04:31:33 -07:00
Bart van den Eijnden
0f0ea7e63f make feature info work on touch devices for gpx example see #727 2013-05-22 13:06:56 +02:00
Bart van den Eijnden
969b47c78c address review by @fredj 2013-05-22 13:01:41 +02:00
Frederic Junod
db34b37716 getFeatureInfo examples: listen to click events
This make the examples works on touch devices.
2013-05-22 12:30:31 +02:00
Bart van den Eijnden
3a83f1b861 Small fixes for KML write.
Be a good XML citizen and always write out schemaLocation.
Use serialize on ol.parser.XML so that we don't have to set xmlns manually.
2013-05-22 12:00:58 +02:00
Bart van den Eijnden
dc922b4ffa Implement GPX parser (read/write).
Implement a parser for GPX which supports read and write.
2013-05-22 10:44:36 +02:00
ahocevar
783e6d33d5 Merge pull request #723 from ahocevar/add-features
Export addFeatures. r=@tschaub
2013-05-21 20:47:08 -07:00
ahocevar
32d669ccc8 Export addFeatures
This needs discussion, but it's useful for now to be able to
have applications with programmatically created features.
2013-05-21 22:44:28 -05:00
ahocevar
485245fbfd Merge pull request #719 from ahocevar/fast-rtree
More sophisticated RTree implementation. r=@tschaub
2013-05-21 13:01:16 -07:00
ahocevar
a2927a0dd9 Addressing @tschaub's review comments 2013-05-21 15:00:50 -05:00
Frédéric Junod
77e60f8417 Merge pull request #721 from fredj/cleanup
Pass layers as array instead of ol.Collection
2013-05-21 05:28:43 -07:00
Frederic Junod
7d544e0868 Pass layers as array instead of ol.Collection 2013-05-21 12:35:02 +02:00
ahocevar
0f4a5c09af Porting tests from http://github.com/imbcmdth/RTree/
Also fixes some issues that were revealed by the new tests.
2013-05-20 17:47:04 +02:00
ahocevar
97d48277b5 Making docs more clear 2013-05-20 16:20:41 +02:00
ahocevar
2b410cf2d0 More performance and size optimizations
Not using Math.max and Math.min increases performance, and by
using ol.extent functions instead of RTree's rectangle
structures and calculations we can get rid of several functions.
2013-05-20 16:20:21 +02:00
ahocevar
9dd4dc3730 Better optimization for advanced compilation mode 2013-05-20 08:50:15 +02:00
ahocevar
bf510b570a Making RTree work in advanced compilation mode 2013-05-19 23:59:21 +02:00
ahocevar
958ee7af51 Use strings, like with other indices 2013-05-19 11:16:24 +02:00
ahocevar
2ff2e85fbb Only query RTree if requested geometryType is used 2013-05-19 11:16:02 +02:00
ahocevar
79e4ee2717 More sophisticated RTree implementation
This new implementation is based on
http://github.com/imbcmdth/RTree/, with only a few modifications
to add the optional type and provide the API of the previous
implementation.

There is still room for optimization, but this is such an
improvement over the previous RTree already that it's worth
bringing it in now.
2013-05-19 01:47:21 +02:00
Tim Schaub
dc4ca15430 Merge pull request #718 from tschaub/dirty-frame
Properly reset the dirty flag
2013-05-18 09:27:33 -07:00
Tim Schaub
38752f4700 Properly reset the dirty flag
Currently, the dirty flag is never reset (to false).  This is a bug.  Because renderFrame is called very often (every layer render gets called when every other layer needs to re-render), it is criticial to know when we can bail out early.  The dirty flag is currently the way that the vector layer renderer knows that it needs to do more work.  On an empty cache, the renderFrame method of the vector layer renderer is called ~30 times for a single zoom in the vector layer example (due to tiles loading on other layers).  Without this change, we miss the fast path out and clear/re-render the canvas all 30 times.  With this change, we are only clear the canvas and redraw 6 times in a typical zoom animation.
2013-05-17 23:22:07 -06:00
ahocevar
02ba8a86e6 Merge pull request #715 from ahocevar/rtree-performance
Making RTree's find more efficient. r=@bartvde
2013-05-17 04:06:20 -07:00
ahocevar
ecea771801 Making RTree's find more efficient
By doing the type check before the intersection check, we can
save he intersection check for cases where we don't care about
type or have the specified type in a node.
2013-05-17 12:54:06 +02:00
Bart van den Eijnden
b3ad00da13 Merge pull request #714 from bartvde/gmloptions
GML options not always applied (=r@ahocevar)
2013-05-17 03:51:06 -07:00
Bart van den Eijnden
0aa4fe258e GML options not always applied.
This is a follow-up for https://github.com/openlayers/ol3/pull/711
for the GML parser. Also use goog.array.map instead of map as was
pointed out by @twpayne on the WKT review and update the example data
to use all US states as pointed out by @tschaub on the Google hangout.
2013-05-17 11:48:05 +02:00
Bart van den Eijnden
921aa28b42 Merge pull request #712 from bartvde/wkt
Add WKT parser (r=@ahocevar,@twpayne,@tschaub)
2013-05-17 01:55:42 -07:00
Bart van den Eijnden
3e3b5ab02d move last RegExp into constant 2013-05-17 10:15:22 +02:00
Bart van den Eijnden
585887b04e address review comments by @twpayne 2013-05-17 10:09:40 +02:00
ahocevar
9342ebdc98 Merge pull request #713 from ahocevar/kml-responsetext
Do not rely on responseXML, also use responseText. r=@bartvde
2013-05-16 12:49:51 -07:00
ahocevar
5d7cdd2646 Use goog.isString() instad of typeof check 2013-05-16 21:20:34 +02:00
ahocevar
22c4508c27 Don't rely on responseXML, also use responseText
On servers that report an incorrect content type for XML
documents, responseXML will be empty. In these cases we need to
use responseText instead. This change also prevents readNode
calls with empty data.
2013-05-16 21:11:32 +02:00
ahocevar
e50c314c33 Merge pull request #711 from ahocevar/kml-options
KML options not applied when library built separately from application. r=@bartvde
2013-05-16 07:04:42 -07:00
Bart van den Eijnden
bb16820ab0 add exports for WKT 2013-05-16 15:44:31 +02:00
Bart van den Eijnden
bf8c12d9f7 Add WKT parser.
Add a parser (read/write) for OGC Well-Known-Text (WKT). It deals with
geometries only, not with features, mostly because WKT can only contain a
single geometry (or geometry collection). This can later on be used to
serialize and deserialize geometries in ol3.
2013-05-16 15:29:39 +02:00
ahocevar
3e6cdf8901 trackAttributes is optional 2013-05-16 15:26:54 +02:00
ahocevar
cde4ef435c Adding another option 2013-05-16 15:14:38 +02:00
ahocevar
1929403cda Do not extend the instance with options 2013-05-16 14:37:40 +02:00
ahocevar
c245794e56 Sorting properties 2013-05-16 14:37:27 +02:00
ahocevar
7ed51f97aa Merge pull request #710 from ahocevar/hit-detection
Accurate hit detection. r=@bartvde
2013-05-16 02:10:50 -07:00
ahocevar
8084e20e64 Fixing typo 2013-05-16 10:45:25 +02:00
ahocevar
7a800068ed Fixing typedef 2013-05-16 10:44:22 +02:00
ahocevar
824397e6ba Do not change ol.extent.containsCoordinate 2013-05-16 10:42:28 +02:00
ahocevar
2d5c0df7cd More verbose variable names 2013-05-16 10:14:56 +02:00
Éric Lemoine
b7f0f9ba86 Merge pull request #708 from elemoine/user-extensions
The compilation of ol.js produces a warning
2013-05-16 01:06:36 -07:00
ahocevar
4e7ffc2711 Store symbol sizes by tile
The reason for this change is that symbolSizes and maxSymbolSize
on the instance will be wrong as soon as the resolution changes
and cached tiles are used. It turned out that the approach used
now has several advantages: smaller symbolSizes objects, no need
to merge symbolSizes objects, and cache management for free (no
risk of memory leaks). Note that the symbolSizes and
maxSymbolSize for each tile are not strictly tile specific -
they represent the rendering pass that created the tile. This
has no negative side effects, and it has the advantage that
there is not a single additional loop needed to create these
structures.
2013-05-16 09:57:26 +02:00
ahocevar
037e44e084 Accurate hit detection
With this change, hit detection for lines and points gets very
accurate, because the vector renderer instance keeps track of
line widths and point symbol sizes. After doing a bbox query in
the RTree, returned lines and points are evaluated against the
thresholds of their line width or symbol size. The KML example
with its different symbolizers now has getFeatureInfo too to
show this in action.
2013-05-15 23:44:22 +02:00
Bart van den Eijnden
32ea32521d Merge pull request #709 from bartvde/gmlfresh
GML parser (r=@ahocevar)
2013-05-15 07:08:24 -07:00
Bart van den Eijnden
e8ed1674ea do not specify the source projection in ol.parser.ReadFeaturesOptions anymore 2013-05-15 15:34:11 +02:00
Bart van den Eijnden
2ad3ee6f99 incorporate review from @ahocevar 2013-05-15 14:50:37 +02:00
Bart van den Eijnden
5ad4734c24 GML parser.
This adds a parser (read/write) for GML v2 and v3. GML v3 is limited to the
simple features profile of GML 3.1.1, just like OpenLayers 2 was. This will
be the basis for the WFS parser, but it only makes sense to continue this work
once feature modification (insert, update, delete) is in place in ol3. So the
WFS parser will be another pull request.
2013-05-14 20:12:05 +02:00
Éric Lemoine
124b195d3e handleMapPostrender returns undefined
Without this we get the following warning from the compiler:

JSC_EXPORTED_FUNCTION_UNKNOWN_RETURN_TYPE. Unable to determine return type for exported function ol.control.Control.prototype.handleMapPostrender at ../src/ol/control/control.js line 79 : 51

I'm not sure why explicitely specifying the return type is required here.
2013-05-10 14:04:50 +02:00
Éric Lemoine
42cc4d7683 Merge pull request #706 from elemoine/user-extensions
Custom control framework
2013-05-10 04:47:39 -07:00
Éric Lemoine
4c144c3d5c Merge pull request #700 from elemoine/calculate-extent
Add and export View2D.calculateExtent
2013-05-10 03:57:24 -07:00
Bart van den Eijnden
87b3a3274d Merge pull request #699 from bartvde/kmlxmleql3
Use xmleql in the KML tests (r=@ahocevar)
2013-05-10 03:14:35 -07:00
ahocevar
72fce33956 Merge pull request #703 from ahocevar/getfeatureinfo-async
Asynchronous API for map#getFeatureInfo. r=@elemoine
2013-05-10 02:50:11 -07:00
Éric Lemoine
3a4fc2a99a Use our own null function for handleMapPostrender
If we use ol.control.Control.prototype.handleMapPostrender = goog.nullFunction the API doc doesn't show the mapEvent parameter of the handleMapPostRender function.
2013-05-10 10:56:39 +02:00
Éric Lemoine
88352092ee Externalize Control.handleMapPostrender 2013-05-10 10:45:24 +02:00
Éric Lemoine
c845682ecb Export Control.getMap 2013-05-10 10:24:11 +02:00
Éric Lemoine
4e51888651 Add a custom controls example
Inspired from @cedricmoullet's ZoomExtent example in 3312c37ed0.
2013-05-10 10:24:11 +02:00
Éric Lemoine
9685c87bc9 Create ol.inherits alias, and export it 2013-05-10 10:24:11 +02:00
Éric Lemoine
7a71f107cb Export and externalize Control.setMap 2013-05-10 10:24:11 +02:00
Éric Lemoine
2944b31c69 Merge pull request #707 from elemoine/gjslint
Use new gjslint version (2.3.10)
2013-05-09 22:03:38 -07:00
Éric Lemoine
41fb355804 New gslint doesn't like va_filters 2013-05-10 00:13:15 +02:00
Éric Lemoine
410f35bb44 Use latest gjslint version (2.3.10) 2013-05-10 00:13:05 +02:00
Éric Lemoine
917e78a096 Merge pull request #701 from elemoine/rm-google-exports
Remove google.exports
2013-05-09 15:03:35 -07:00
Éric Lemoine
d71c690794 Merge pull request #705 from elemoine/getextent
Fix typo in View2D:getExtent
2013-05-09 15:02:48 -07:00
Éric Lemoine
c34d637de1 Fix typo in View2D:getExtent 2013-05-09 23:42:55 +02:00
Éric Lemoine
c9299f3b8d Merge pull request #704 from elemoine/no-namespace-export
Export fixes
2013-05-09 14:13:48 -07:00
Éric Lemoine
ca332a3fef Minor fix to the generate-exports.py script
Now that we correctly export the ol.animation.*, ol.easing.* and ol.coordinate.* symbols we can make the generate-exports.py script work for more cases.
2013-05-09 22:46:08 +02:00
Éric Lemoine
4b7f3e85c2 No need to export ol.coordinate 2013-05-09 22:45:20 +02:00
Éric Lemoine
f47ac87f12 No need to export ol.easing 2013-05-09 22:45:11 +02:00
Éric Lemoine
17e779177b ol.easing.* functions are symbols 2013-05-09 22:44:49 +02:00
Éric Lemoine
31930290cf No need to export ol.animation 2013-05-09 22:44:11 +02:00
Éric Lemoine
a96031f435 ol.animation.* functions are symbols 2013-05-09 22:43:04 +02:00
ahocevar
53b85c99ae map#getFeatureInfo does not return anything
Thanks @elemoine for catching this.
2013-05-09 22:32:40 +02:00
ahocevar
7b256c3ec6 Asynchronous API for map#getFeatureInfo
This change allows us to use feature info services on the
server. It will also be useful for the GetFeature control to
get results from a WFS.
2013-05-09 22:26:55 +02:00
Éric Lemoine
fa1eb354f2 Merge pull request #702 from elemoine/closure-linter
Use closure_linter-2.3.9.tar.gz
2013-05-09 12:48:48 -07:00
Éric Lemoine
1d709cc6ac Use closure_linter-2.3.9.tar.gz
closure_linter-latest.tar.gz is no longer available in http://closure-linter.googlecode.com/files/, so use closure_linter-2.3.9.tar.gz.
2013-05-09 21:23:31 +02:00
Éric Lemoine
8779b90f7c Remove google.exports
This .exports file made goog.require be exported as a null function. This was needed to be able to run the ol3 examples uncompiled against the ol.js build. Now that host-examples target removes the goog.require statements from the examples' js files (74b8fea6) we don't need to export goog.require anymore.
2013-05-09 21:13:20 +02:00
Bart van den Eijnden
c69e5c1dba Use xmleql in the KML tests
This also involves some modifications to the xmleql functionality now that
it was tested with a real-life case (KML). Also, some of the input KML files
needed to be changed since we currently cannot roundtrip 100% of the input.
2013-05-08 16:41:45 +02:00
Tom Payne
0b09148fb5 Merge pull request #697 from twpayne/fix-nan-test
Fix NaN test
2013-05-08 05:59:16 -07:00
Tom Payne
9286d63133 Merge pull request #693 from twpayne/class-name
Add className option to control options
2013-05-08 05:35:37 -07:00
Tom Payne
b4598aa5d9 Fix NaN test 2013-05-08 14:32:16 +02:00
ahocevar
96c3a86314 Merge pull request #692 from ahocevar/pnpoly
Point-in-polygon improvements. r=@bartvde
2013-05-08 05:11:16 -07:00
Tom Payne
97510ba0be Use className in mouse position example 2013-05-07 17:33:33 +02:00
Tom Payne
2ad5dea737 Rename ol-mouseposition to ol-mouse-position 2013-05-07 17:31:26 +02:00
Bart van den Eijnden
14e073fb5a Merge pull request #689 from bartvde/xmleql4
Improvements for xmleql (r=@ahocevar)
2013-05-07 08:06:57 -07:00
Tom Payne
b698b1736f Add className option to ol.control.ZoomSlider 2013-05-07 16:36:25 +02:00
Tom Payne
9c59116dd1 Make zoom slider control options optional 2013-05-07 16:31:39 +02:00
Tom Payne
ab9fc9cc71 Inline simple function that is only called once 2013-05-07 16:28:22 +02:00
Tom Payne
b7e2a9b40e Add className option to ol.control.Zoom 2013-05-07 16:19:50 +02:00
Tom Payne
09feaedd00 Add className option to ol.control.ScaleLine 2013-05-07 16:19:21 +02:00
Tom Payne
f31a4f8549 Add className option to ol.control.MousePosition 2013-05-07 16:18:05 +02:00
Tom Payne
525d5c5337 Add className option to ol.control.Logo 2013-05-07 16:17:51 +02:00
Tom Payne
f08814250e Add className option to ol.control.FullScreen 2013-05-07 16:17:35 +02:00
Tom Payne
8c396e5afb Add className option to ol.control.Attribution 2013-05-07 16:17:13 +02:00
ahocevar
019fc86ac5 Entertaining linter and compiler 2013-05-07 14:20:09 +02:00
Éric Lemoine
c105a98443 Merge pull request #691 from elemoine/mouseposition
Add default CSS for mouse position control
2013-05-07 02:48:10 -07:00
ahocevar
666a010e3b Point-in-polygon improvements
As suggested by @tschaub in #674, geom.pointInPoly is not needed
if we have geom.LinearRing#containsCoordinate. This pull request
also adds tests and documentation on the limitations of the
containsCoordinate method.

I think for now it is ok to keep geometry/topology functions as
simple as possible in ol3. If we decide to not rely on third
party libraries like jsts for topology operations, we can always
refine what we have and e.g. port topology operations over from
ol2.
2013-05-07 10:49:51 +02:00
Frédéric Junod
aa3cc0cec4 Merge pull request #687 from fredj/geolocation
Use ol.projection.identityTransform instead of goog.functions.identity
2013-05-06 08:41:36 -07:00
Bart van den Eijnden
3fc0f2b47d Improvements for xmleql
This adds some improvements for the xmleql test assertion. When passed in a
document, use the documentElement. Also improve error reporting as suggested
by @tschaub.
2013-05-06 15:35:40 +02:00
Thomas
f219393149 Add default CSS style for mouse position
Missing CSS was confirmed with issue #680, this commit is to fix it and change
ol-mouse-position class to ol-mouseposition. I choose for the moment the top
right corner to display the coordinates from mouse position control because of
potential conflict with the scaleline control.
2013-05-06 14:07:13 +02:00
Bart van den Eijnden
10b690b5f9 Merge pull request #661 from bartvde/xmleql
Add Assertion.prototype.xmleql (r=@twpayne,@tschaub,@elemoine)
2013-05-06 02:43:24 -07:00
Bart van den Eijnden
865404a0d3 Add Assertion.prototype.xmleql
This is based on the xml_eq function we had in the OL2 test framework but
adapted to expect.js.
2013-05-06 11:18:49 +02:00
Frederic Junod
fdfe057efe Use ol.projection.identityTransform instead of goog.functions.identity 2013-05-06 10:21:24 +02:00
Tom Payne
331a5260c9 Merge pull request #679 from twpayne/rename-create-empty-extent
Rename ol.extent.createEmptyExtent to ol.extent.createEmpty
2013-05-01 03:45:51 -07:00
Tom Payne
b070b572d0 Rename ol.extent.createEmptyExtent to ol.extent.createEmpty 2013-05-01 12:36:54 +02:00
Tom Payne
70fc6879db Merge pull request #676 from twpayne/testing-clean-ups
Testing clean-ups
2013-05-01 03:25:09 -07:00
Tom Payne
a9b5f003e5 Merge pull request #677 from twpayne/improve-type-checking
Improve type checking
2013-04-30 15:55:34 -07:00
Tim Schaub
c1ddc55a12 Merge pull request #678 from tschaub/once
Rename onOnce to once
2013-04-30 15:10:47 -07:00
Tim Schaub
ffe9105891 Rename onOnce to once (see #678) 2013-04-30 14:58:39 -06:00
Tom Payne
1ab9de8b2c Improve type checking in ol.View2D 2013-04-30 22:00:22 +02:00
Tom Payne
0541053fa9 Improve type checking in ol.TileUrlFunction 2013-04-30 22:00:22 +02:00
Tom Payne
0e69af847e Improve type checking in ol.source.WMTS 2013-04-30 22:00:22 +02:00
Tom Payne
6e1f049456 Improve type checking in ol.source.StaticImage 2013-04-30 22:00:22 +02:00
Tom Payne
65f891a30d Improve type checking in ol.source.BingMaps 2013-04-30 22:00:22 +02:00
Tom Payne
fe9fee1609 Improve type checking in ol.RotationConstraint 2013-04-30 22:00:22 +02:00
Tom Payne
bd9d723315 Improve type checking in ol.ResolutionConstraint 2013-04-30 22:00:22 +02:00
Tom Payne
2690410cbe Improve type checking in ol.renderer.Layer 2013-04-30 22:00:22 +02:00
Tom Payne
070c286c54 Improve type checking in ol.ImageUrlFunction 2013-04-30 22:00:21 +02:00
Tom Payne
539529af59 Improve type checking in ol.coordinate 2013-04-30 21:29:56 +02:00
Tom Payne
d2979fc4ff Improve type checking in ol.animation 2013-04-30 21:29:10 +02:00
Tom Payne
f0df0d7bf2 Display test errors in Chrome's console, thanks @Turbo87 2013-04-30 18:44:09 +02:00
Tom Payne
984121e095 Remove Assertion#equalArray 2013-04-30 18:22:16 +02:00
Tom Payne
efccede678 Use eql instead of equalArray 2013-04-30 18:21:58 +02:00
Tom Payne
fcc079a5f2 Extend expect.js's eql to handle NaNs 2013-04-30 18:20:34 +02:00
Tom Payne
c012afdbae Remove unused Assertion#intersect 2013-04-30 18:08:24 +02:00
Tom Payne
59a4155651 Merge pull request #665 from twpayne/fix-firefox-dom-renderer
Prevent Bootstrap's setting of max-width from infecting map
2013-04-30 06:46:41 -07:00
Tom Payne
2d83003b64 Merge pull request #671 from twpayne/refactor-tile-functions
Refactor tile functions
2013-04-30 06:39:25 -07:00
Frédéric Junod
c3348d1734 Merge pull request #675 from fredj/object-listen
ol.Object.{on|onOnce|un} type can also be an array of string
2013-04-30 06:35:54 -07:00
ahocevar
8fb8a718c3 Merge pull request #674 from ahocevar/getfeatureinfo
Getting feature information for vector layers. r=@twpayne,@fredj
2013-04-30 06:12:47 -07:00
Frederic Junod
6366bd05b3 ol.Object.{on|onOnce|un} type can also be an array of string 2013-04-30 15:03:52 +02:00
ahocevar
00777de581 Do not check for listeners, as suggested by @fredj 2013-04-30 14:45:47 +02:00
ahocevar
d2c81db06a Info box instead of tooltip as suggested by @fredj 2013-04-30 14:15:39 +02:00
ahocevar
58c8b07ab5 Get hit candidates from RTree, then refine result
Now we get exact hits also for lines and polygons.
2013-04-30 13:34:12 +02:00
ahocevar
cc1b70c74b Giving the map a getFeatureInfoForPixel method
This method is an entry point for getting feature information.
Renderers can use a hit canvas or defer to a layer (source) to
get matching features for a pixel.

For now this is only implemented for vector layers, and it uses
a bbox query because we cannot refine the result because of
missing geometry intersection functions yet.
2013-04-30 13:32:16 +02:00
Éric Lemoine
a0340faa63 Merge pull request #673 from elemoine/closure-no-deps
Always set CLOSURE_NO_DEPS to true
2013-04-30 03:30:31 -07:00
Tom Payne
7ed672752d Merge pull request #668 from twpayne/strip-debug-classes
Strip debug classes when compiling
2013-04-30 03:30:05 -07:00
Tom Payne
daa975d01f Prevent user's setting of max-width from infecting map
Thanks @ThomasG77.
2013-04-30 12:26:31 +02:00
Tom Payne
66d95316f1 Merge pull request #666 from twpayne/remove-unused-css-classes
Remove unused CSS classes
2013-04-30 02:33:50 -07:00
Tom Payne
09d245c54b Promote createTileCoordTransform into base class 2013-04-30 11:01:57 +02:00
Tom Payne
7a8d29f5e0 Clip tiles to extent in tile coordinate space 2013-04-30 10:30:50 +02:00
Frédéric Junod
28fcbbf1fe Merge pull request #672 from fredj/export-update-size
Export ol.Map.updateSize
2013-04-30 00:41:08 -07:00
Éric Lemoine
1281d9987a Add and export View2D.calculateExtent 2013-04-30 09:39:09 +02:00
Éric Lemoine
aa5a571ab1 Always set CLOSURE_NO_DEPS to true 2013-04-30 09:25:09 +02:00
Frederic Junod
a723b4e215 Export ol.Map.updateSize 2013-04-30 09:04:35 +02:00
Tom Payne
6976fd96e3 Refactor tile functions
* Add support for minZoom in XYZ tile grids and tile sources
* Factor out common tile coordinate transforms
2013-04-29 19:54:26 +02:00
Tom Payne
1ff8df8936 Log WebGL shader and program errors 2013-04-29 12:51:16 +02:00
Tom Payne
37ef03c956 Re-enable logging 2013-04-29 12:50:37 +02:00
Tom Payne
2447f09128 Merge pull request #670 from twpayne/fix-glsl-escaping
Don't escape HTML characters in shader generation
2013-04-29 02:22:19 -07:00
Tom Payne
14da0cfd11 Don't escape HTML characters in shader generation
This tells Mustache not to escape <, >, &, and " characters.
2013-04-29 11:18:49 +02:00
Tom Payne
ca7081bde3 Merge pull request #669 from twpayne/more-animations
Minor changes to the animation example
2013-04-29 02:15:14 -07:00
Tom Payne
390cc17161 Cosmetic clean-ups 2013-04-28 20:01:44 +02:00
Tom Payne
b666fc49b7 Add spiral to Madrid animation example 2013-04-28 20:01:25 +02:00
Tom Payne
cfa29b0022 Strip debug classes when compiling 2013-04-28 18:00:24 +02:00
Tom Payne
5bfef2805d Merge pull request #663 from twpayne/render-error-tiles-as-empty
Render error tiles as empty
2013-04-28 08:21:51 -07:00
Tom Payne
65a2aef4ed Merge pull request #658 from twpayne/ol-object-events
ol.Object events
2013-04-28 08:20:29 -07:00
Tom Payne
ef915e1cd0 Remove unused CSS classes
The classes ol-layers, ol-layer-image, and ol-layer-tile are not used.
2013-04-28 16:40:17 +02:00
Frédéric Junod
01d06d0a2e Merge pull request #662 from fredj/canvas-draw-image-perf
Possible canvas performance enhancement
2013-04-26 07:40:00 -07:00
Frederic Junod
b3e5ac2717 Optimize canvas renderer.
Only use setTransform when it's needed (ie. when the view is rotated)
2013-04-26 13:32:18 +02:00
Tom Payne
3643908427 Only set center once in mobile full screen example 2013-04-25 19:41:03 +02:00
Tom Payne
e8109919e9 Add ol.Object#onOnce 2013-04-25 19:41:03 +02:00
Tom Payne
09fe09e42b Add ol.Object#unByKey 2013-04-25 19:41:03 +02:00
Tom Payne
fa2582a2f1 Return listener key from ol.Object#on 2013-04-25 19:41:02 +02:00
Tom Payne
c576b2a34e Treat image tiles with a zero dimension as empty 2013-04-25 15:17:24 +02:00
Tom Payne
d8a4b19b54 Render error tiles as empty 2013-04-25 14:49:55 +02:00
Tom Payne
e7eb07197e Merge pull request #655 from twpayne/scale-tile-queue
Scale tile queue according to number of sources
2013-04-25 05:44:46 -07:00
Frédéric Junod
4828835292 Merge pull request #653 from fredj/background-color
Remove BACKGROUND_COLOR from ol.Map
2013-04-25 02:43:00 -07:00
Frederic Junod
a1af290d18 Add a background image to the example maps
image from http://subtlepatterns.com/
2013-04-24 17:52:43 +02:00
Frederic Junod
4094ace04b Remove BACKGROUND_COLOR from ol.Map
Let the map be transparent, the background color can be set with CSS.
2013-04-24 17:38:25 +02:00
Frédéric Junod
cec47dbfc3 Merge pull request #652 from fredj/ol.feature-jsdoc
Update ol.Feature jsdoc
2013-04-24 05:31:38 -07:00
Frederic Junod
6b74dcf75b Update ol.Feature jsdoc 2013-04-24 12:35:24 +02:00
Tom Payne
9defa59d2d Merge pull request #651 from twpayne/full-screen-drag-rotate-and-zoom
Show off
2013-04-23 16:39:51 -07:00
Tom Payne
bd0512fea7 Show off 2013-04-24 01:38:03 +02:00
Tom Payne
2b48f03e0f Merge pull request #650 from twpayne/fix-out-of-scope-variables
Fix out of scope variables in ol.Map
2013-04-23 14:27:33 -07:00
Tom Payne
51905b54a2 Fix out of scope variables in ol.Map 2013-04-23 22:47:22 +02:00
Tom Payne
43f313cb18 Scale tile queue according to number of sources 2013-04-23 22:18:51 +02:00
Tom Payne
db1ab50938 Merge pull request #639 from twpayne/fix-webgl-map-renderer
Bing Maps example is broken
2013-04-23 08:08:19 -07:00
Tom Payne
1a72e59c54 Fix stray return 2013-04-23 16:42:39 +02:00
Tom Payne
ed5433d290 Merge pull request #649 from twpayne/fix-canvas-tiles-webgl
Use negative frame index as frame marker
2013-04-23 07:16:52 -07:00
Tom Payne
bedfa5e2d3 Merge pull request #640 from twpayne/interaction-options
Interaction options
2013-04-23 07:11:56 -07:00
Éric Lemoine
5842d771fe Merge pull request #646 from elemoine/target
Make it possible to set map target after map creation
2013-04-23 06:33:30 -07:00
Tom Payne
4da61e8ae9 Configure ol.interaction.TouchRotate with options 2013-04-23 15:31:16 +02:00
Tom Payne
9e8d20aee4 Re-use ol.Kinetic object 2013-04-23 15:31:16 +02:00
Tom Payne
2dff59a4d4 Configure ol.interaction.TouchPan with options 2013-04-23 15:31:16 +02:00
Tom Payne
a36b4a0466 Configure ol.interaction.DragPan with options 2013-04-23 15:31:16 +02:00
Tom Payne
3b9699fbc8 Configure ol.interaction.DragZoom with options 2013-04-23 15:31:16 +02:00
Tom Payne
48d4554317 Configure ol.interaction.KeyboardZoom with options 2013-04-23 15:31:16 +02:00
Tom Payne
cc33727fad Configure ol.interaction.KeyboardPan with options 2013-04-23 15:31:16 +02:00
Tom Payne
d1b2e4e483 Add drag rotate and zoom example 2013-04-23 15:31:16 +02:00
Tom Payne
808de79d16 Export ol.interaction.DragRotateAndZoom 2013-04-23 15:31:15 +02:00
Tom Payne
76a9f80545 Update ol.interaction.DragRotateAndZoom 2013-04-23 15:31:15 +02:00
Tom Payne
75ac8a4847 Export ol.interaction.condition.* 2013-04-23 15:31:15 +02:00
Tom Payne
8d29bf3c20 Add ol.interaction.condition.always 2013-04-23 15:31:15 +02:00
Tom Payne
d90f292c71 Initialize all properties in constructor 2013-04-23 15:31:15 +02:00
Tom Payne
003ac5536e Configure ol.interaction.DragRotate with options 2013-04-23 15:31:15 +02:00
Tom Payne
ef17d4f3b8 Rename DblClickZoom to DoubleClickZoom 2013-04-23 15:31:15 +02:00
Tom Payne
eb9f6c027b Avoid duplicate property lookup 2013-04-23 15:29:17 +02:00
Tom Payne
f2836ea111 Configure ol.interaction.DblClickZoom with options 2013-04-23 15:29:17 +02:00
Tom Payne
a4d8e1c4d8 Correct property in ol.interaction.DefaultsOptions 2013-04-23 15:29:17 +02:00
Tom Payne
baf8cc49a1 Avoid generating long lines in exports 2013-04-23 15:29:17 +02:00
Tom Payne
a85363ac03 Use negative frame index as frame marker to avoid conflict with goog.getUid 2013-04-23 15:22:49 +02:00
Tom Payne
c78602ba7a Merge pull request #644 from twpayne/remove-fragile-test
Remove fragile test
2013-04-23 05:56:38 -07:00
Éric Lemoine
d3d0d1e007 Test isElement instead of isDef (thanks @fredj) 2013-04-23 14:44:36 +02:00
Tom Payne
6751c2640d Remove fragile test
The user animation test is sensitive to small timing differences and
randomly fails.  This randomly breaks the integration tests.
2013-04-23 14:24:16 +02:00
Tom Payne
b2987d3054 Merge pull request #643 from twpayne/fix-dispose
Fix dispose
2013-04-23 05:20:05 -07:00
Frédéric Junod
b5076091fa Merge pull request #647 from fredj/wmts.projection
Change ol.source.WMTSOptions.projection type to ol.ProjectionLike
2013-04-23 05:15:47 -07:00
Éric Lemoine
29e69d3833 Simplify teleport example 2013-04-23 14:05:11 +02:00
Éric Lemoine
11efafffd8 Make setTarget accept a string 2013-04-23 14:04:46 +02:00
Frédéric Junod
e9a5eff753 Merge pull request #645 from fredj/ol.object.changed
Remove unused ol.Object.prototype.changed
2013-04-23 04:52:13 -07:00
Frederic Junod
29137b5ad1 Change ol.source.WMTSOptions.projection type to ol.ProjectionLike
Same type as base class.
2013-04-23 13:34:37 +02:00
Frederic Junod
e3bec11d2e Remove unused ol.Object.prototype.changed 2013-04-23 11:06:42 +02:00
Éric Lemoine
8e8804caf1 Add a teleport map example 2013-04-23 10:42:18 +02:00
Éric Lemoine
2dfe36b588 Map target may be undefined 2013-04-23 10:42:18 +02:00
Éric Lemoine
7547b50bd8 Add map property "target" 2013-04-23 10:42:18 +02:00
ahocevar
f681a99ce0 Merge pull request #638 from ahocevar/kml-options
KML rendering in advanced compilation mode. r=@bartvde
2013-04-23 00:09:26 -07:00
Bart van den Eijnden
334b2276cf Merge pull request #641 from bartvde/kmlexample
Add AsyncStringFeatureParser and use plain (r=@ahocevar)
2013-04-22 23:35:21 -07:00
ahocevar
8515e30ad8 Making the linter happy
... although jsdoc files are none of the linter's business.
2013-04-22 22:47:13 +02:00
ahocevar
c16b941909 Exporting KML parser options
This is necessary because application developers need to be able
to configure the KML parser.
2013-04-22 22:37:20 +02:00
Frédéric Junod
0421ad71e8 Merge pull request #642 from fredj/geolocation-export
Fix ol.Geolocation and ol.GeolocationOptions export
2013-04-22 12:42:37 -07:00
Tom Payne
e686eff886 Fix use of dispose in ol.renderer.webgl.ImageLayer tests 2013-04-22 17:16:44 +02:00
Tom Payne
6c369ae907 Fix use of dispose in ol.Map tests 2013-04-22 17:16:44 +02:00
Tom Payne
71e06761f0 Fix use of dispose in ol.layer.Vector tests 2013-04-22 17:16:44 +02:00
Tom Payne
3c541045bb Fix use of dispose in ol.layer.Layer tests 2013-04-22 17:16:43 +02:00
Tom Payne
744f72355b Fix use of dispose in ol.control.ZoomSlider tests 2013-04-22 17:16:30 +02:00
Tom Payne
c2e1623529 Fix use of dispose in ol.control tests 2013-04-22 17:16:22 +02:00
Tom Payne
d8357ae932 Fix use of dispose in ol.parser.KML 2013-04-22 17:14:31 +02:00
Frederic Junod
abbbe3d41b Fix ol.Geolocation and ol.GeolocationOptions export 2013-04-22 16:53:11 +02:00
Bart van den Eijnden
feb6c4c2d7 Add AsyncStringFeatureParser and use plain
XMLHttpRequest in the KML example

Since the content-type on github.io is application/octet-stream we need
to implement an Async string based parser interface in the KML parser.
Also use plain XmlHttpRequest in the example instead of jQuery Ajax since
the vector-features example also uses that.
2013-04-22 16:45:33 +02:00
Tom Payne
d45a63ee5c Merge pull request #637 from twpayne/remove-unused-functions
Remove unused functions
2013-04-22 01:40:04 -07:00
Tom Payne
bc3dc0fd74 Merge pull request #636 from twpayne/cache-length
Cache array length in ol.control.Attribution
2013-04-22 01:34:20 -07:00
Tom Payne
4c42f4e1ba Remove ol.PixelBounds 2013-04-22 10:14:22 +02:00
Tom Payne
ee2e448220 Remove ol.tilegrid.TileGrid#getPixelBoundsForTileCoordAndResolution 2013-04-22 10:11:13 +02:00
Tom Payne
8264343e54 Cache array length in ol.control.Attribution 2013-04-22 10:05:21 +02:00
Éric Lemoine
fe1475105a Merge pull request #635 from elemoine/handletilechange
Remove unused function
2013-04-21 13:49:31 -07:00
Éric Lemoine
9d901d26b2 Merge pull request #634 from elemoine/missing-description
Add missing description for @return tag
2013-04-21 13:49:03 -07:00
Éric Lemoine
a5519c2645 Add missing description for @return tag 2013-04-21 21:51:14 +02:00
Éric Lemoine
4f1b7c70b8 Remove unused function 2013-04-21 21:50:03 +02:00
Tom Payne
e6f354ce7c Merge pull request #632 from twpayne/mobile-full-screen-example
Mobile full screen example
2013-04-21 09:46:48 -07:00
Tom Payne
ddb295cc77 Add full screen example for mobile devices 2013-04-20 16:56:31 +02:00
Tom Payne
be7228f78e Add options to ol.Geolocation constructor 2013-04-20 16:55:26 +02:00
Tom Payne
945d2f6f5d Merge pull request #631 from twpayne/dont-use-foreach-in-loops
Don't use forEach in loops
2013-04-20 03:02:13 -07:00
Tom Payne
ac557d4eca Merge pull request #567 from twpayne/no-events-in-renderers
No events in renderers
2013-04-20 02:52:32 -07:00
Tom Payne
b2cc0c9bd8 Use ii instead of len for array length cache for consistency 2013-04-20 11:34:49 +02:00
Tom Payne
c48b9c5118 Cache array length in ol.TileRange 2013-04-20 11:34:48 +02:00
Tom Payne
ac489c6938 Cache array length in ol.structs.Buffer 2013-04-20 11:34:48 +02:00
Tom Payne
fb0f1fb209 Cache array length in layer renderer 2013-04-20 11:34:48 +02:00
Tom Payne
879d9758c0 Cache array length in WebGL renderer 2013-04-20 11:34:48 +02:00
Tom Payne
72a83b99b7 Cache array length in DOM renderer 2013-04-20 11:34:48 +02:00
Tom Payne
68440e7e0f Cache array length in canvas renderer 2013-04-20 11:34:39 +02:00
Tom Payne
e9b0e2b0e8 Cache array length in ol.Map 2013-04-20 11:27:55 +02:00
Tom Payne
332fd250b4 Cache array length in ol.Collection 2013-04-20 11:27:44 +02:00
Tom Payne
f047e5f6bd Cache array length in ol.Attribution 2013-04-20 11:27:32 +02:00
Tom Payne
7979726327 Avoid creating an ol.Size object 2013-04-19 20:52:40 +02:00
Tom Payne
d964bbc605 Use for loop instead of forEach in WebGL tile layer renderer 2013-04-19 20:41:54 +02:00
Tom Payne
f5611d6cd6 Use for loop instead of forEach in WebGL map renderer 2013-04-19 20:29:24 +02:00
Tom Payne
388e530420 Use for loop instead of forEach in DOM map renderer 2013-04-19 20:22:20 +02:00
Tom Payne
fe5c8a97d4 Add ol.renderer.Map#getLayerRendererByKey 2013-04-19 20:22:01 +02:00
Tom Payne
37d3f7b4c1 Use for loop instead of forEach in canvas map renderer 2013-04-19 20:12:11 +02:00
Tom Payne
72767f5d17 Merge pull request #555 from twpayne/extent-as-array
ol.Extent as Array.<number>
2013-04-19 08:41:19 -07:00
Tom Payne
965776160f Merge pull request #569 from twpayne/define-properties-in-constructor
Define properties in constructor
2013-04-19 01:21:34 -07:00
Tom Payne
a642868cfa Port examples to new extents 2013-04-19 10:03:36 +02:00
Tom Payne
f81658f542 Port parsers to new extents 2013-04-19 10:03:36 +02:00
Tom Payne
953f9c2e7a Port ol.geom to new extents 2013-04-19 10:03:36 +02:00
Tom Payne
01168e805a Port ol.filter.ExtentFilter to new extents 2013-04-19 10:03:35 +02:00
Tom Payne
a413f3046a Port interactions to new extents 2013-04-19 10:03:35 +02:00
Tom Payne
1d4eaf6824 Port ol.structs.RTree to new extents 2013-04-19 10:03:35 +02:00
Tom Payne
305089d84f Port ol.renderer.webgl to new extents 2013-04-19 10:03:35 +02:00
Tom Payne
10d1be695d Port ol.renderer.dom to new extents 2013-04-19 10:03:35 +02:00
Tom Payne
465e24cf4e Port ol.renderer.canvas to new extents 2013-04-19 10:03:35 +02:00
Tom Payne
aff9f5dbf9 Port ol.source.SingleImageWMS to new extents 2013-04-19 10:03:35 +02:00
Tom Payne
583564e484 Port ol.source.StaticImage to new extents 2013-04-19 10:03:34 +02:00
Tom Payne
559e85bc76 Port ol.source.TiledWMS to new extents 2013-04-19 10:03:34 +02:00
Tom Payne
9708fb4ea6 Port ol.source.WMTS to new extents 2013-04-19 10:03:34 +02:00
Tom Payne
10354cf607 Port ol.source.WMS to new extents 2013-04-19 10:03:34 +02:00
Tom Payne
f0c812482f Port ol.source.TileJSON to new extents 2013-04-19 10:03:34 +02:00
Tom Payne
e868954d9c Port ol.source.TileSource to new extents 2013-04-19 10:03:34 +02:00
Tom Payne
c2ff8347d9 Port ol.source.BingMaps to new extents 2013-04-19 10:03:34 +02:00
Tom Payne
e50253e316 Port ol.projection to new extents 2013-04-19 09:32:12 +02:00
Tom Payne
9773314803 Port ol.View2D to new extents 2013-04-19 09:32:12 +02:00
Tom Payne
7d21bd8133 Port ol.Map to new extents 2013-04-19 09:32:12 +02:00
Tom Payne
ca8647c808 Port ol.tilegrid to new extents 2013-04-19 09:32:12 +02:00
Tom Payne
b4f7259c7f Port function types to new extents 2013-04-19 09:32:12 +02:00
Tom Payne
16f70ba1a0 Replace ol.Extent and ol.Rectangle with Array.<number> 2013-04-19 09:32:11 +02:00
Tom Payne
0da8b0ae7f Don't inherit ol.PixelBounds from ol.Rectangle 2013-04-19 09:32:11 +02:00
Tom Payne
1ad7765f2f Don't derive ol.TileRange from ol.Rectangle 2013-04-19 09:32:11 +02:00
Tom Payne
7d610bde7b Initialize all properties in constructor in interactions 2013-04-18 21:02:53 +02:00
Tom Payne
b24c46dd19 Initialize all properties in constructor in ol.Geolocation 2013-04-18 21:02:18 +02:00
Tom Payne
43cfc2a4cd Initialize all properties in constructor in controls 2013-04-18 21:01:58 +02:00
Tom Payne
669d47e8d2 Merge pull request #568 from twpayne/fix-dom-layer-visibility
Fix DOM layer visibility
2013-04-18 10:52:45 -07:00
Tom Payne
8831d25929 Remove DOM layer in render, not in dispose 2013-04-18 19:25:49 +02:00
Tom Payne
f7c0c26bed Update layer visibility in DOM renderer 2013-04-18 19:21:06 +02:00
Tom Payne
d291d23092 ol.renderer.Layer no longer needs to inherit from ol.Object 2013-04-18 18:59:22 +02:00
Tom Payne
85a95a0036 Call render and requestRenderFrame directly instead of using changed events 2013-04-18 18:58:59 +02:00
Tom Payne
f274cc99f6 Don't call event handlers in constructor 2013-04-18 16:35:06 +02:00
Tom Payne
87358296f4 Merge pull request #564 from twpayne/frame-index
Frame index
2013-04-18 06:16:30 -07:00
Tom Payne
bc9f702d84 Merge pull request #563 from twpayne/single-image-load-render
Render instead of requestRenderFrame when single image loads
2013-04-18 06:05:44 -07:00
Tom Payne
75bc61c0e0 Use index instead of time as frame marker 2013-04-18 14:47:27 +02:00
Tom Payne
8fef7b9edd Add index to frame state 2013-04-18 14:47:27 +02:00
Tom Payne
1c4d2956ac Merge pull request #562 from twpayne/renderer-fixes
Renderer fixes
2013-04-18 05:09:58 -07:00
Tom Payne
302e65e140 Render instead of requestRenderFrame when single image loads 2013-04-18 13:24:25 +02:00
Tom Payne
2f5797bc16 Always create layer renderer, even when layer is invisible or not ready
This is necessary because it is the layer renderer that is responsible
for triggering a render when a layer loads or becomes visible.
2013-04-18 12:52:45 +02:00
Tom Payne
77841bb8eb Merge pull request #542 from twpayne/simplify-renderer-events
Create and remove layer renderers in renderFrame
2013-04-18 02:14:39 -07:00
Frédéric Junod
a0ed2afa88 Merge pull request #561 from fredj/bingkey
Update Bing Maps key, see #554
2013-04-18 01:55:02 -07:00
Frederic Junod
51d14e95d7 Update Bing Maps key, see #554 2013-04-18 10:10:31 +02:00
Éric Lemoine
5d86674b32 Merge pull request #553 from elemoine/fix-zoomslider
ZoomSlider example is broken
2013-04-17 11:41:36 -07:00
Éric Lemoine
f476726aff Merge pull request #554 from elemoine/bing-maps-key
Bing Maps key has expired
2013-04-17 04:47:38 -07:00
Éric Lemoine
6d282e939d Update Bing Maps key (Expiration Date: 07/16/2013) 2013-04-17 13:23:16 +02:00
Éric Lemoine
6f34595312 ZoomSlider uses non-existing View2D functions 2013-04-17 10:53:23 +02:00
Tom Payne
a07e70ea32 Handle obscure edge case where deferred post render function receives a null frame state 2013-04-16 23:40:48 +02:00
Tom Payne
328a1bcda5 Merge pull request #556 from twpayne/consistent-and-unique-filenames
Consistent and unique filenames
2013-04-16 11:12:30 -07:00
Tom Payne
f174ffc2ad Rename projection files for consistency 2013-04-16 19:59:54 +02:00
Tom Payne
9f0004e17d Rename test files to match source files 2013-04-16 19:59:53 +02:00
Tom Payne
b19b753c1b Give wgs84.js files unique filenames 2013-04-16 19:20:19 +02:00
Tom Payne
3867d0cd28 Give defaults.{js,exports} unique filenames 2013-04-16 19:18:14 +02:00
Tom Payne
a68656ad33 Rename wms.js to wmssource.js 2013-04-16 19:15:00 +02:00
Tom Payne
bc10446b0e Track changes to layers in the map 2013-04-16 18:31:59 +02:00
Tom Payne
07fe17924b Remove layer renderers in post render function 2013-04-16 18:16:08 +02:00
Frédéric Junod
4e911fc34b Merge pull request #550 from fredj/keyboard
Add a condition param to the KeyboardPan and KeyboardZoom interactions.
2013-04-15 22:48:03 -07:00
Frédéric Junod
52b4a8f71f Merge pull request #551 from fredj/ol.interaction.Keyboard
Remove ol.interaction.Keyboard
2013-04-15 22:47:28 -07:00
Éric Lemoine
96690845eb Merge pull request #548 from elemoine/zoom-css
Bigger + and - zoom buttons on touch devices
2013-04-15 03:44:47 -07:00
Éric Lemoine
7351ef038f Merge pull request #549 from elemoine/pan-interaction-fix
Pan interaction fix
2013-04-15 03:44:20 -07:00
Frederic Junod
a5e0f06a8e Remove ol.interaction.Keyboard 2013-04-15 12:33:09 +02:00
Frederic Junod
fd6f4a0622 Add a condition param to the KeyboardPan and KeyboardZoom interactions.
By default, the action is ignored if a modifier key is pressed.
2013-04-15 11:04:09 +02:00
Éric Lemoine
49bf204c13 pan interactions call requestRenderFrame on dragend 2013-04-15 10:46:55 +02:00
Éric Lemoine
61204d10d8 setHint returns new hint value 2013-04-15 10:46:30 +02:00
Éric Lemoine
ca8d033fb0 Merge pull request #547 from elemoine/touch-anchor
Anchors are incorrect in touch interactions
2013-04-14 14:54:10 -07:00
Éric Lemoine
b501230164 Bigger + and - zoom buttons on touch devices 2013-04-14 23:28:45 +02:00
Éric Lemoine
71fb6087fe Merge pull request #546 from elemoine/view2d
View2D - more consistency and configuration flexibility
2013-04-14 13:50:10 -07:00
Éric Lemoine
74feabb4c4 Fix rotation anchor for touch rotate interation 2013-04-14 22:47:52 +02:00
Éric Lemoine
4b395c72fa Fix zoom anchor for touch zoom interaction 2013-04-14 22:47:05 +02:00
Éric Lemoine
78b2983fdf maxZoom 18 in localized-openstreetmap example 2013-04-14 22:14:05 +02:00
Éric Lemoine
48f0e7e2ec More View2D configuration flexibility 2013-04-14 22:12:12 +02:00
Éric Lemoine
778aec45d8 View2D option "numZoomLevels" changed to "maxZoom"
This is to be consistent with ol.source.XYZ and ol.tilegrid.XYZ.
2013-04-14 22:00:09 +02:00
ahocevar
aee6b8333b Merge pull request #545 from ahocevar/no-container
Docs align better with examples when not using a container
2013-04-14 00:20:39 -07:00
ahocevar
f9281ac619 Docs align better with examples when not using a container 2013-04-14 09:19:40 +02:00
ahocevar
605ee491c4 Merge pull request #544 from ahocevar/no-timestamp
Removing the timestamp
2013-04-13 09:24:11 -07:00
ahocevar
6440ce5ea0 Removing the timestamp
When auto-generating the website using grunt in the
openlayers.github.io repo, we do not need to publish new docs
every time grunt is run, just because the timestamp is updated.
2013-04-13 18:23:31 +02:00
ahocevar
4a1f13ad0a Merge pull request #543 from ahocevar/jsdoc-typo
container-fluid is a class, not an id
2013-04-12 11:56:51 -07:00
ahocevar
bbc20f505b container-fluid is a class, not an id 2013-04-12 20:55:57 +02:00
Tom Payne
4e69b2bb8b Create and remove layer renderers in renderFrame
Previously, the map renderer would listen for layers being added and
removed from the layers collection, and would create and remove layer
renderers in response to these events.

With this change, layer renderers are only created or removed when
renderFrame is called, which leads to somewhat simpler code.

We still need to listen to changes to the layers collection, but now
these only trigger a new render.

This new approach also has an advantage when layers change order.
Swapping the order of two layers involves removing one and re-inserting
it elsewhere.  With the old approach, this would cause the deletion and
re-creation of the layer renderer.  With this new approach, the layer
renderer is preserved.
2013-04-12 17:50:38 +02:00
Éric Lemoine
cd5d2c7144 Merge pull request #541 from elemoine/canvas-comments
Fix bug in canvas.TileLayer comments
2013-04-12 08:44:21 -07:00
Éric Lemoine
1fe3091f43 Fix bug in canvas.TileLayer comments 2013-04-12 17:40:28 +02:00
Éric Lemoine
6e3b8d2f40 Merge pull request #540 from elemoine/canvas-comments
Add comments to ol.renderer.canvas.TileLayer
2013-04-12 08:31:19 -07:00
Éric Lemoine
6cc019c031 Add comments to ol.renderer.canvas.TileLayer 2013-04-12 17:27:40 +02:00
Bart van den Eijnden
aa69b4bae8 Merge pull request #539 from bartvde/wmscapstests
Use afterLoadXml in WMSCapabilities parser tests (r=@twpayne)
2013-04-12 04:03:14 -07:00
Tom Payne
7c9a1acc2a Merge pull request #535 from twpayne/renderer-clean-ups
Renderer clean-ups
2013-04-12 02:49:56 -07:00
Bart van den Eijnden
8fafe63553 Use afterLoadXml in WMSCapabilities parser tests
The WMS Capabilities parser tests were created before the afterLoadXml
utility functions were created. This is now corrected.
2013-04-12 11:25:08 +02:00
Bart van den Eijnden
d1d18ad325 Merge pull request #517 from bartvde/kmlfresh3
Add a parser for reading and writing KML (r=@tschaub,@fredj,@twpayne)
2013-04-11 23:50:44 -07:00
Tom Payne
be629a7ed8 Sort jsdoc comments alphabetically 2013-04-12 00:48:55 +02:00
Tom Payne
0371b891a6 Tighten up permission on layer renderers 2013-04-12 00:48:35 +02:00
Tom Payne
d855a35446 Make renderer layer management private 2013-04-12 00:33:37 +02:00
Tom Payne
f0106f391a Make ol.renderer.Map.map property private 2013-04-12 00:33:37 +02:00
Tom Payne
ee817ba4a2 Clean up ol.renderer.webgl.Map.createLayerRenderer 2013-04-12 00:33:37 +02:00
Tom Payne
df6e13bdc0 Clean up ol.renderer.dom.Map.createLayerRenderer 2013-04-12 00:33:33 +02:00
Tom Payne
db15c53f95 Merge pull request #521 from openlayers/full-screen-control
Full screen control
2013-04-11 10:12:12 -07:00
Frederic Junod
7b0e036b83 Hide the control if the Fullscreen API is not supported 2013-04-11 18:25:31 +02:00
Frederic Junod
8206cf111f Fix full screen button state 2013-04-11 18:25:31 +02:00
Tim Schaub
93041becbe Toggle css class and use css content for anchor 2013-04-11 18:25:31 +02:00
Tom Payne
0bd11d0a70 Use full screen control in full screen example 2013-04-11 18:25:31 +02:00
Tom Payne
cef6fe4930 Add full screen control 2013-04-11 18:25:31 +02:00
Éric Lemoine
055a4da761 Merge pull request #518 from elemoine/canvas
Canvas tile layer renderer occasionally glitches when panning fast
2013-04-11 08:14:04 -07:00
Tom Payne
ac40769155 Clear tiles that are not fully covered 2013-04-11 15:50:32 +02:00
Éric Lemoine
d1021b6ee0 Refactor and fix canvas tile layer renderer 2013-04-11 09:26:57 +02:00
Éric Lemoine
a344e4af8c Merge pull request #528 from elemoine/touch
Touch interactions should use requestRenderFrame
2013-04-10 22:44:27 -07:00
ahocevar
37ca407e50 Merge pull request #529 from ahocevar/global
Don't use window and document
2013-04-10 13:56:05 -07:00
Tim Schaub
d71da50fb9 Merge pull request #532 from tschaub/update-size
Add an updateSize method.  Application code should call this when the map viewport size changes by some method other than a window resize.
2013-04-10 13:40:58 -07:00
Tim Schaub
b499f71d97 Add an updateSize method
We need a non-private/protected method to call when the map viewport size changes.
2013-04-10 12:47:06 -06:00
ahocevar
a437bea61f Use no browser globals at all 2013-04-10 16:53:45 +02:00
Éric Lemoine
b6a6ba95cc Touch zoom interaction requests render frames 2013-04-10 16:15:58 +02:00
Éric Lemoine
703842a021 Touch rotate interaction requests render frames 2013-04-10 16:15:58 +02:00
Éric Lemoine
1e3e7fb0c1 Touch pan interaction request render frames 2013-04-10 16:15:58 +02:00
Éric Lemoine
ce985ba272 Remove extra /** 2013-04-10 16:15:58 +02:00
Éric Lemoine
38914bc95b addPreRenderFunction calls requestRenderFrame
So there's no need to call requestRenderFrame prior to calling addPreRenderFunction.
2013-04-10 16:15:58 +02:00
ahocevar
dc1d7a1aba Don't use window and document
With this change, our JavaScript can also be executed by
non-brower engines.
2013-04-10 15:48:17 +02:00
ahocevar
ae5d1cee1e Merge pull request #527 from ahocevar/jsdoc-filtered
Only document the exported API, not every symbol. r=@elemoint
2013-04-10 06:28:25 -07:00
Éric Lemoine
3bb476e752 Merge pull request #526 from elemoine/OSM
OpenStreetMap to OSM renaming
2013-04-10 06:27:04 -07:00
ahocevar
12cd3672bc Remove "Inherited from" for non-API parents 2013-04-10 15:06:12 +02:00
Éric Lemoine
091cc10f08 Merge pull request #520 from elemoine/view2d
The view does not know about the map
2013-04-10 05:12:36 -07:00
Éric Lemoine
7a488be89e Merge pull request #524 from elemoine/check
Compile entire code base on build check
2013-04-10 05:08:46 -07:00
ahocevar
71c32d3554 Don't use the undocumented property before it is set
This actually avoids addition of params of symbols that are not
part of the API.
2013-04-10 13:59:32 +02:00
ahocevar
7a50295c49 Making @elemoine and GitHub happy
Reminder to self: everyone wants a new line at the end of a
file.
2013-04-10 13:18:22 +02:00
ahocevar
1e0e30a9ed Use a public return type for a public function 2013-04-10 11:34:03 +02:00
ahocevar
8acfa08766 Making the linter happy
Although *.jsdoc files are none of the linter's business...
2013-04-10 11:24:27 +02:00
ahocevar
9cb85ea9a9 Adding the projection namespace 2013-04-10 11:18:23 +02:00
ahocevar
423ba5c0e4 A few lines explaining what the exports.js plugin does 2013-04-10 11:04:39 +02:00
ahocevar
6f94ec6fe7 Adding params of API symbols to the API
This makes the API docs complete. What still needs to be
documented is API events, but this deserves a separate pull
request.
2013-04-10 10:57:36 +02:00
Bart van den Eijnden
8cc70f35d9 use goog.global, restructure to have ol.parser.KML instead of ol.parser.ogc.KML 2013-04-10 10:17:28 +02:00
Éric Lemoine
a694661793 OpenStreetMap to OSM renaming
OSM is a well-known name, and is shorter than OpenStreetMap.
2013-04-10 10:07:49 +02:00
Éric Lemoine
4e4d22b4e2 Target "check" depends on ol-all.js 2013-04-10 09:15:15 +02:00
Éric Lemoine
14e066ac78 Add exports.js as an input to ol-all 2013-04-10 09:14:51 +02:00
Éric Lemoine
2d5381ae41 Move zoom from View2D to Interaction 2013-04-10 08:52:07 +02:00
Éric Lemoine
dbca68650c Move rotate from View2D to Interaction 2013-04-10 08:52:06 +02:00
Éric Lemoine
51094139a8 Move pan function from View2D to Interaction 2013-04-10 08:27:47 +02:00
ahocevar
551a5f06ff Nicer way to fix @inheritDoc 2013-04-10 01:45:21 +02:00
ahocevar
2fd185c966 Only document the exported API, not every symbol
There is more work to be done, because this filters out more
than desired, and we don't have events documented yet.
2013-04-10 01:44:40 +02:00
Tom Payne
ee987bc951 Merge pull request #438 from twpayne/boost-tile-limits
Tile limits are too low
2013-04-09 13:16:09 -07:00
Tom Payne
5a2483e224 Increase default tile cache size 2013-04-09 22:14:54 +02:00
Tom Payne
29b78a32e8 Merge pull request #519 from twpayne/tile-garbage-clean-ups
Tile garbage clean-ups
2013-04-09 13:12:01 -07:00
Éric Lemoine
32560e8699 Merge pull request #516 from elemoine/no-getview2d-in-examples
Do not use getView2D in the examples
2013-04-09 11:13:40 -07:00
Tom Payne
680b31c5e0 Eliminate an ol.TileCoord allocation 2013-04-09 19:54:15 +02:00
Tom Payne
fe03ebe99c Re-use ol.Extent objects 2013-04-09 19:19:45 +02:00
Tom Payne
ee8e565be2 Enable ol.Extent re-use 2013-04-09 19:19:45 +02:00
Tom Payne
e08d19ac55 Add ol.Extent.createOrUpdate 2013-04-09 19:19:44 +02:00
Tom Payne
e556c87a7c Re-use ol.TileRange objects 2013-04-09 19:19:20 +02:00
Tom Payne
e30109913e Enable ol.TileRange re-use 2013-04-09 19:19:20 +02:00
Tom Payne
7a4672d429 Add ol.TileRange.createOrUpdate 2013-04-09 19:19:19 +02:00
Tom Payne
5bd67e1325 Re-use ol.TileCoord objects 2013-04-09 19:19:11 +02:00
Tom Payne
5a4033db7a Enable ol.TileCoord re-use 2013-04-09 19:19:11 +02:00
Tom Payne
7b58685462 Add ol.TileCoord.createOrUpdate 2013-04-09 19:19:11 +02:00
Tim Schaub
2ecaf2bc69 Merge pull request #501 from tschaub/logical
Logical filter touch-ups
2013-04-09 09:21:13 -07:00
Éric Lemoine
396ee5ce3d Add constrainResolution|Rotation to ol.View2D 2013-04-09 17:06:18 +02:00
Éric Lemoine
6bb36452cb Add calculateCenterZoom|Rotation to ol.View2D 2013-04-09 16:50:48 +02:00
Bart van den Eijnden
577ebd6abe move examples/kml to examples/data/kml 2013-04-09 16:17:36 +02:00
Tom Payne
aa12232ec3 Merge pull request #509 from twpayne/use-high-resolution-tiles
Use high resolution tiles
2013-04-09 06:34:45 -07:00
Bart van den Eijnden
ed9861317f Add a parser for reading and writing KML.
This adds ol.parser.ogc.KML which can be used to read and write KML documents.
NetworkLinks are retrieved asynchronously.
Current caveats of the implementation are:

* LabelStyle not yet implemented. Missing support in renderers.
* When using shared structures the parser needs to be configured with
  dimension 2.
* We need a better way to disable fill, currently we use opacity as a
  workaround.
* We cannot really roundtrip documents, since some of the info is not
  preserved in the ol structures. But we can write out most of the important
  info.
2013-04-09 15:34:03 +02:00
Éric Lemoine
572055127c Do not use getView2D in the examples 2013-04-09 15:28:20 +02:00
ahocevar
38b1a59574 Merge pull request #511 from ahocevar/examples-data
Copying data folder to hosted examples directory. r=@elemoine
2013-04-09 05:07:31 -07:00
ahocevar
97f7eb3db3 Re-adding accidently removed line
This brings back the previous way to copy the data directory,
as suggested by @elemoine.
2013-04-09 13:22:04 +02:00
ahocevar
cdb90a79ee Merge pull request #512 from ahocevar/export-getpixel
Export the pixel location of the MapBrowserEvent. r=@fredj,@twpayne
2013-04-09 04:16:09 -07:00
Tom Payne
e732a67382 Propagate return value 2013-04-09 13:15:16 +02:00
Tom Payne
cdc67a141a Remove preload from examples that don't need it 2013-04-09 13:15:16 +02:00
Tom Payne
66f0e0d8e8 Add optimized version of getTileCoordChildTileRange for ol.tilegrid.XYZ 2013-04-09 13:15:16 +02:00
Tom Payne
c5748f1fd7 Store maxZoom in ol.tilegrid.XYZ 2013-04-09 13:15:16 +02:00
Tom Payne
1b7ee36680 Use high resolution tiles in DOM renderer 2013-04-09 13:15:16 +02:00
Tom Payne
8da1f3400b Use high resolution tiles in Canvas renderer 2013-04-09 13:15:16 +02:00
Tom Payne
4d6e060052 Use high resolution tiles in WebGL renderer 2013-04-09 13:15:16 +02:00
Tom Payne
7a7ea8a072 Add ol.tilegrid.TileGrid.getTileCoordChildTileRange 2013-04-09 13:15:16 +02:00
Tom Payne
e39aae6662 Merge pull request #514 from twpayne/remove-stray-comment
Remove stray comment
2013-04-09 04:14:34 -07:00
Tom Payne
52893f1ba2 Remove stray comment 2013-04-09 13:07:02 +02:00
Tom Payne
e68f744ad1 Merge pull request #513 from twpayne/fix-tilequeue-assert
Remove incorrect assert, thanks @elemoine
2013-04-09 03:41:49 -07:00
Tom Payne
e12b30ba91 Remove incorrect assert, thanks @elemoine 2013-04-09 12:18:04 +02:00
ahocevar
964ae5b58b Export the pixel location of the MapBrowserEvent
This is useful for getting the pixel coordinate relative to the
map viewport, which is used e.g. for WMS GetFeatureInfo.
2013-04-09 11:08:04 +02:00
ahocevar
696fc8c4f7 Copying data folder to hosted examples directory
We need to copy all of the examples directory, because we need
the data subdirectory.
2013-04-09 10:52:21 +02:00
Tom Payne
eee24870b5 Merge pull request #506 from twpayne/refactor-webgl-shaders
Refactor WebGL shaders
2013-04-08 11:11:47 -07:00
Tom Payne
1f679bbd1c Merge pull request #508 from twpayne/remove-matrix-filter
Remove references to Matrix Filter
2013-04-08 11:10:28 -07:00
Tom Payne
60a33a86bb Remove references to Matrix Filter 2013-04-08 19:43:41 +02:00
Tom Payne
ba3746a8d9 Merge pull request #507 from twpayne/asserts
Clean up use of goog.asserts
2013-04-08 10:39:55 -07:00
Tom Payne
a6a60149f1 Merge pull request #494 from twpayne/use-goog-base
Use Closure type identification functions
2013-04-08 10:16:52 -07:00
Tom Payne
e132943eef Use goog.asserts.fail 2013-04-08 19:14:16 +02:00
Tom Payne
098bddb72f Use goog.asserts.assertInstanceof 2013-04-08 19:03:49 +02:00
Tom Payne
667f3de6d9 Remove unused constants 2013-04-08 16:40:53 +02:00
Tom Payne
ee54aaaea4 Use simpler, faster shader when brightness, contrast, hue and saturation are unchanged 2013-04-08 16:40:53 +02:00
Tom Payne
f7f799be27 Use automatically generated locations in WebGL tile layer renderer 2013-04-08 16:40:53 +02:00
Tom Payne
aa5ce41cb5 Automatically generate uniform and attribute locations 2013-04-08 16:40:49 +02:00
Tom Payne
c6cd3e0227 Refactor glsl-unit templates
This abuses the template system to allow both a single anonymous shader
and multiple named shaders to be defined in a namespace.
2013-04-08 15:57:26 +02:00
Tom Payne
24cfd8a9be Merge pull request #496 from twpayne/check-whitespace
Check whitespace
2013-04-08 06:06:15 -07:00
Éric Lemoine
879ea4f488 Merge pull request #473 from elemoine/value-resolution
Exponential scaling to ZoomSlider
2013-04-08 05:22:38 -07:00
Tom Payne
9d38b21831 Check for whitespace errors in jsdoc files 2013-04-08 13:40:13 +02:00
Tom Payne
a103b5acd7 Fix whitespace errors in jsdoc 2013-04-08 13:25:01 +02:00
Tom Payne
7b2c2369ae Check for whitespace errors in lint 2013-04-08 13:25:01 +02:00
Tom Payne
f1cc5b87da Fix whitespace errors in JavaScript source 2013-04-08 13:25:01 +02:00
Tom Payne
a4763e0b69 Fix whitespace errors in exports 2013-04-08 13:25:01 +02:00
Tom Payne
81712a28a3 Fix whitespace errors in examples 2013-04-08 13:24:10 +02:00
ahocevar
8117b1650b Merge pull request #504 from ahocevar/shuffle-jsdoc
Shuffling jsdoc files, as suggested by @elemoine
2013-04-08 04:16:49 -07:00
ahocevar
0a540578a2 Moving ol.jsdoc and layer.jsdoc 2013-04-08 13:09:05 +02:00
Tom Payne
220dc2eab6 Merge pull request #499 from twpayne/fix-openstreetmap-licenses
OpenStreetMap licenses are inconsistent
2013-04-08 03:59:44 -07:00
Éric Lemoine
fb5ca531d0 Do not assume map.getView returns an ol.View2D 2013-04-08 12:55:00 +02:00
Tom Payne
75c1642c82 Merge pull request #498 from twpayne/boost-tile-loading
Boost tile loading
2013-04-08 03:54:53 -07:00
Éric Lemoine
8c9153ffca ZoomSlider animates to final resolution 2013-04-08 12:51:29 +02:00
Éric Lemoine
516f21eb17 Make ZoomSlider use View2D value/resolution funcs 2013-04-08 12:51:14 +02:00
Éric Lemoine
6163f05b2b ZoomSlider setMap deals with undefined resolution 2013-04-08 12:50:12 +02:00
Tom Payne
0221998120 Fix OpenStreetMap attributions 2013-04-08 12:32:03 +02:00
Éric Lemoine
631afb07ab Add value/resolution functions to View2D 2013-04-08 12:28:37 +02:00
Tom Payne
01440b484b Only manage the tile queue if it is not empty and improve comment 2013-04-08 12:14:33 +02:00
Tom Payne
6f49cb8abe Assert that loadMoreTiles is only called when more tiles will be loaded 2013-04-08 12:12:25 +02:00
ahocevar
949a4a59fa Shuffling jsdoc files, as suggested by @elemoine 2013-04-08 11:16:08 +02:00
Frédéric Junod
123e84de17 Merge pull request #502 from fredj/misc
Fix bootstrap.min.js path in overlay example
2013-04-08 01:10:48 -07:00
Frederic Junod
abf3896a71 Fix bootstrap.min.js path in overlay example 2013-04-08 10:01:38 +02:00
Tim Schaub
f0c62294f9 Doc fixes 2013-04-07 17:42:52 -06:00
Tim Schaub
27e23cce9c Convenient factories for logical filters 2013-04-07 17:37:31 -06:00
Tim Schaub
ceb9541031 Correcting or and adding not
Previously, OR filters always returned true (fixes #500).
2013-04-07 17:36:54 -06:00
Tom Payne
09110098ae Merge pull request #497 from openlayers/doc-objectliterals
Documentation for exported object literals
2013-04-07 13:03:26 -07:00
Tom Payne
60a913aef3 Compute number of new tiles to load exactly 2013-04-07 19:12:40 +02:00
Tom Payne
5b133d40d9 Only reprioritize tile queue when more tiles will be loaded 2013-04-07 18:31:56 +02:00
Tom Payne
b93283e8f3 Boost number of loading tiles when not animating or interacting 2013-04-07 18:25:19 +02:00
Tom Payne
da6f4cc764 Make maximum number of tiles loading a parameter to loadMoreTiles 2013-04-07 18:10:19 +02:00
Tom Payne
1d5431226e Use objectliterals.jsdoc instead of objectliterals.exports 2013-04-07 18:00:11 +02:00
Tom Payne
b83352549e Correct typos in objectliterals.jsdoc 2013-04-07 18:00:11 +02:00
ahocevar
c832a47575 Documentation for exported object literals
This adds the infrastructure that we need for documenting
exported object literals. This is best done by using *.jsdoc
files, which are parsed by JSDoc but not the Closure Compiler.
In addition to adding the documentation of the objects literal
properties, the respective namespaces must also be annotated.

Restricting the API docs to the exported API will be added as a
separate pull request.
2013-04-07 18:00:10 +02:00
Tom Payne
5f817476c2 Merge pull request #495 from twpayne/logo-control-exports
Add ol.control.Logo exports
2013-04-07 04:18:05 -07:00
Tom Payne
f724e40179 Add ol.control.Logo exports 2013-04-07 12:53:52 +02:00
Tom Payne
7a2ad8c506 Use Closure type identification functions 2013-04-07 12:31:54 +02:00
Tom Payne
a90797852e Merge pull request #489 from twpayne/consistent-options
Consistent options
2013-04-07 03:13:07 -07:00
Tom Payne
b74ebcdae5 Be more consistent with view options 2013-04-07 11:44:59 +02:00
Tom Payne
5b104635cf Be more consistent with tilegrid options 2013-04-07 11:44:59 +02:00
Tom Payne
dfc4dcc5f9 Be more consistent with style options 2013-04-07 11:44:58 +02:00
Tom Payne
3f637ec2c4 Be more consistent with overlay options 2013-04-07 11:44:58 +02:00
Tom Payne
f1c6ea4bab Be more consistent with map options 2013-04-07 11:44:58 +02:00
Tom Payne
a537632199 Be more consistent with source options 2013-04-07 11:44:58 +02:00
Tom Payne
042cf9b7a9 Merge pull request #493 from twpayne/correct-example
Update use of ol.Coordinate in example
2013-04-07 02:40:48 -07:00
Tom Payne
99caf9a6fe Update use of ol.Coordinate in example 2013-04-07 11:40:16 +02:00
Tom Payne
81486c261d Merge pull request #491 from twpayne/openstreetmap-options
OpenStreetMap options
2013-04-07 02:09:29 -07:00
Tom Payne
fe6b418cbd Use common attribution for OpenStreetMap 2013-04-07 10:43:04 +02:00
Tom Payne
910ee493e5 Add localized OpenStreetMap example 2013-04-07 10:24:44 +02:00
Tom Payne
93e9b4524b Add OpenStreetMap options 2013-04-06 21:41:01 +02:00
Tom Payne
ac8762b493 Be more consistent with projection options 2013-04-06 20:44:23 +02:00
Tom Payne
ec77455c14 Be more consistent with parser options 2013-04-06 20:44:23 +02:00
Tom Payne
3197e278f8 Be more consistent with layer options 2013-04-06 20:44:23 +02:00
Tom Payne
42c029be84 Be more consistent with interaction options 2013-04-06 20:44:23 +02:00
Tom Payne
85af2bf912 Be more consistent with geolocation options 2013-04-06 20:44:23 +02:00
Tom Payne
ea22f0f8cc Be more consistent with control options 2013-04-06 20:44:23 +02:00
Tom Payne
7e8db559fe Be more consistent with animation options 2013-04-06 19:12:39 +02:00
Tom Payne
027806d114 Merge pull request #488 from twpayne/remove-logger
Remove (mostly unused) logger
2013-04-06 09:11:45 -07:00
Tom Payne
4d1ec1ff90 Remove (mostly unused) logger 2013-04-06 17:32:41 +02:00
Éric Lemoine
f3415f3631 Merge pull request #477 from elemoine/slow-start
Tile loading is slow to start
2013-04-06 06:14:07 -07:00
Tom Payne
d90c871ebb Merge pull request #484 from twpayne/check-goog-requires
Check requires from Closure Library
2013-04-06 05:52:58 -07:00
Éric Lemoine
928906bd17 Do not always limit num of tile loads per frame 2013-04-06 14:43:10 +02:00
Tom Payne
5d36f1de83 Merge pull request #485 from twpayne/no-social-widgets-when-debugging
Remove social widgets when debugging
2013-04-06 05:32:49 -07:00
Tom Payne
1e8a47be13 Speed up requirements checking 2013-04-06 14:28:12 +02:00
Tom Payne
4be8c991f7 Add missing Closure Library requires 2013-04-06 14:28:12 +02:00
Tom Payne
12a6d6b43f Read provides from Closure Library 2013-04-06 14:23:56 +02:00
Tom Payne
f8ea6fefd3 Merge pull request #486 from twpayne/build-py-pep8
Make build.py PEP8 compliant again
2013-04-06 05:22:43 -07:00
Tom Payne
a2bae2d893 Merge pull request #487 from twpayne/update-url
Update examples URL to openlayers.github.io
2013-04-06 05:21:57 -07:00
Tom Payne
8073be7f3a Update examples URL to openlayers.github.io 2013-04-06 14:21:16 +02:00
Tom Payne
764872d619 Remove social widgets when debugging
Social widgets increase load times, add uncontrolled JavaScript code,
and open potential security holes.  None of these are desirable,
especially when debugging.  This commit removes the Twitter and Google
Plus widgets, at least when the window location has a query string
(e.g. "?mode=RAW").
2013-04-06 14:12:03 +02:00
Tom Payne
622ac870fd Merge pull request #482 from twpayne/control-clean-ups
Control clean-ups
2013-04-06 05:10:22 -07:00
Tom Payne
8bf14f8f98 Make build.py PEP8 compliant again 2013-04-06 14:08:56 +02:00
Tom Payne
d3f6691cf1 Merge pull request #483 from twpayne/sort-objectliterals-exports
Sort src/objectliterals.exports
2013-04-05 12:05:45 -07:00
Tom Payne
e068135a66 Sort src/objectliterals.exports 2013-04-05 21:00:40 +02:00
Tom Payne
25eb18d2c8 Handle unlistening in base class 2013-04-05 20:59:16 +02:00
Tom Payne
06bcab8374 Move postrender event listening into base class 2013-04-05 20:59:16 +02:00
Tom Payne
da1e5aadd3 Factor out css.js and fix requires 2013-04-05 20:59:16 +02:00
Tom Payne
4520d81153 Don't lint examples/loader.js 2013-04-05 20:20:13 +02:00
Tom Payne
6cd7acfb8e Merge pull request #480 from twpayne/logo-control
Add logo control
2013-04-05 10:47:49 -07:00
Éric Lemoine
dd68afca5b Merge pull request #449 from elemoine/no-kinetic
Undesired pans after pinching
2013-04-05 10:04:41 -07:00
Tom Payne
2ec13c45f5 Merge pull request #481 from twpayne/attribution-control-clean-ups
Minor attribution control clean-ups
2013-04-05 09:46:35 -07:00
ahocevar
d61b70f696 Merge pull request #444 from ahocevar/jsdoc
Enabling Markdown and other JSDoc improvements. r=@marcjansen,@Turbo87
2013-04-05 09:41:27 -07:00
Tom Payne
cfe5234104 Add logo control by default 2013-04-05 18:38:52 +02:00
Tom Payne
dfed88a8c2 Add ol.control.Logo 2013-04-05 18:38:52 +02:00
Tom Payne
5680b89c48 Update logos in renderers 2013-04-05 18:27:51 +02:00
Tom Payne
cca770097b Add logos to frame state 2013-04-05 18:27:51 +02:00
Tom Payne
0caf5efef6 Configure logo for MapQuest sources 2013-04-05 18:27:45 +02:00
Tom Payne
78abd1b103 Minor attribution control clean-ups 2013-04-05 18:19:20 +02:00
Tom Payne
5b2cbe76f2 Configure logo for Bing Maps source 2013-04-05 18:12:45 +02:00
Tom Payne
a876332f0e Add logo option to ol.source.Source subclasses 2013-04-05 18:12:12 +02:00
Tom Payne
6c90bcc5cd Add logo option to ol.source.Source 2013-04-05 18:11:22 +02:00
Tom Payne
5a2f7f44d4 Merge pull request #448 from kalbermattenm/windows_paths
Windows installation support
2013-04-05 08:57:28 -07:00
Michael Kalbermatten
b9c804d3b3 Windows tests and checkdeps function 2013-04-05 17:25:32 +02:00
Tom Payne
bcdff5a011 Merge pull request #437 from twpayne/throttle-image-loads
Throttle image requests
2013-04-05 07:24:13 -07:00
Tom Payne
3b416c485b Merge pull request #465 from twpayne/coordinate-as-array
Replace ol.Coordinate with Array.<number>
2013-04-05 06:58:20 -07:00
Tom Payne
58a512b52c Remove unused constant 2013-04-05 12:30:38 +02:00
Tom Payne
a8295ba113 Use ol.vec.Mat4.multVec2 2013-04-05 12:30:38 +02:00
Tom Payne
c7ed933c9d Add ol.vec.Mat4.multVec2 2013-04-05 12:30:38 +02:00
Tom Payne
d892ef2b6a Use slice to extract sub-arrays 2013-04-05 12:30:38 +02:00
Tom Payne
02196c94b5 Redefine ol.Coordinate to be Array.<number> 2013-04-05 12:30:37 +02:00
Frédéric Junod
6fc86b81c7 Merge pull request #474 from fredj/misc
Remove unused local variable
2013-04-05 03:19:38 -07:00
Frederic Junod
cade8eaf7e Remove unused local variable 2013-04-05 11:59:07 +02:00
Frédéric Junod
4a5ed629cc Merge pull request #466 from fredj/popover
Use popover from Bootstrap
2013-04-05 01:16:04 -07:00
Éric Lemoine
5f47ee9a9c Disable kinetic when multiple touches on screen 2013-04-05 09:23:05 +02:00
Frederic Junod
73791040c1 Quote object keys to prevent renaming in ADVANCED_OPTIMIZATIONS mode 2013-04-05 09:13:33 +02:00
Frederic Junod
ea97c8687c Update overlay example tags and doc 2013-04-05 08:59:56 +02:00
Tim Schaub
2f829b4aba Merge pull request #471 from tschaub/example-typo
Correct link to example source
2013-04-04 20:42:06 -07:00
Tim Schaub
613b9d7592 Correct link to example source 2013-04-04 21:40:35 -06:00
Tom Payne
0a1b1751f1 Merge pull request #470 from szymonc/error-fix
Add goog.base(this) to the MapBrowserEventHandler's constructor
2013-04-04 15:28:24 -07:00
Tom Payne
4cb9685271 Merge pull request #469 from twpayne/webgl-context-lost
Abort rendering when WebGL context is lost
2013-04-04 15:16:14 -07:00
Tom Payne
b32a2e101c Abort rendering when WebGL context is lost 2013-04-05 00:14:10 +02:00
szymonc
569fb81572 Add goog.base(this) to the MapBrowserEventHandler's constructor 2013-04-05 00:01:16 +02:00
Tom Payne
0e12d16c37 Move configuration of maximum tiles loading into map.js 2013-04-04 23:49:21 +02:00
Tom Payne
71d1207201 Start a maximum of two new tile downloads per frame 2013-04-04 23:33:18 +02:00
Frederic Junod
f806ac5807 Use map.on instead of map.addEventListener 2013-04-04 16:08:45 +02:00
ahocevar
6c5377eebe Creating a resources folder for use by examples and API docs 2013-04-04 15:18:15 +02:00
Frederic Junod
1311464ea6 Use popover from Bootstrap 2013-04-04 14:48:42 +02:00
Frédéric Junod
9f689a0809 Merge pull request #464 from fredj/externs-bootstrap
Lowercase type in externs/bootstrap.js
2013-04-04 05:48:21 -07:00
Frederic Junod
20b8e1e311 Lowercase type in externs/bootstrap.js 2013-04-04 14:26:13 +02:00
ahocevar
b4ce430bfb Making social links work 2013-04-04 14:25:24 +02:00
ahocevar
9f2ff48444 Use bootstrap layout and css from examples
I'm sure this can be made much prettier still, but at least we
have a common theme with the examples now.
2013-04-04 11:53:12 +02:00
ahocevar
e042c5701a Enabling Markdown and other JSDoc improvements
This change enables GitHub flavored markdown for APIdoc
comments. The code example in map.js shows how to use markdown
for code snippets. doc/index.md is now included again as start
page for the docs. Everything in the doc/tutorials directory
will also be added to the docs as tutorial. As an example, I
moved the ol3.md file with the architecture to the tutorials
directory.

Currently properties and methods annotated with @inheritDoc
or @override won't be documented at all. This is a known issue,
so I added a custom JSDoc plugin with a hack to avoid this.
2013-04-04 11:53:12 +02:00
Marc Jansen
19e6569b69 Merge pull request #462 from marcjansen/same-name
Rename *.exports to match their *.js counterparts.
2013-04-04 02:02:21 -07:00
Marc Jansen
6ca21b32a9 More renames as suggested by @elemoine. 2013-04-04 10:25:11 +02:00
Marc Jansen
636a189330 Merge pull request #461 from marcjansen/istanbul
Fix typo in example.
2013-04-03 23:28:03 -07:00
Marc Jansen
523506ef86 Rename *.exports to match their *.js counterparts. 2013-04-04 07:40:16 +02:00
Marc Jansen
66c03f4178 Fix typo in example. 2013-04-04 07:27:53 +02:00
Frédéric Junod
3395319018 Merge pull request #440 from fredj/css-print
css cleanups
2013-04-03 05:41:02 -07:00
Frederic Junod
56afdb31c0 Remove unused ol-renderer-webgl-canvas css class 2013-04-03 14:09:42 +02:00
Frederic Junod
ffa879dad7 Hide the zoom buttons on print 2013-04-03 14:09:42 +02:00
Tom Payne
382caa36b8 Merge pull request #455 from twpayne/update-pake
Update to latest version of pake
2013-04-03 04:05:46 -07:00
Tom Payne
33db796141 Update to latest version of pake 2013-04-03 13:04:37 +02:00
Éric Lemoine
dc67ddc700 Merge pull request #450 from elemoine/projection-null
Do not pass tile grid to getTile and tileUrlFunc
2013-04-03 00:59:05 -07:00
Tom Payne
d8ae60ab85 Merge pull request #454 from twpayne/download-plovr-into-build-dir
Download plovr into build dir
2013-04-02 07:59:04 -07:00
Tom Payne
fe78b49e28 Add logging messages for downloading proj4js 2013-04-02 16:29:11 +02:00
Tom Payne
15b7bb1cdb Add logging messages to indicate when a download is in progress 2013-04-02 16:28:42 +02:00
Tom Payne
69d42f0f94 Download Plovr into build directory
This means that all build artefacts except for the examples are in
build.
2013-04-02 16:16:45 +02:00
Tom Payne
d1c91b9663 Merge pull request #452 from twpayne/limit-post-renderer-set-timeout
Don't schedule a new post render delay if one is already active
2013-04-02 05:49:04 -07:00
Frédéric Junod
6d5cc38265 Merge pull request #453 from fredj/dev
Store kinetic coordinates and time as numbers instead of objects
2013-04-02 05:24:03 -07:00
Frederic Junod
98e3a2b56e Store kinetic coordinates and time as numbers instead of objects 2013-04-02 13:43:01 +02:00
Frédéric Junod
a370a7910b Merge pull request #451 from fredj/dev
Don't recompute delay every loop
2013-04-02 04:30:34 -07:00
Tom Payne
8278b2641b Don't schedule a new post render delay if one is already active 2013-04-02 12:58:11 +02:00
Frederic Junod
5906168bc0 Don't recompute delay every loop 2013-04-02 11:51:59 +02:00
Éric Lemoine
e128bab625 Do not pass tile grid to getTile and tileUrlFunc
getTile and the tileUrlFunc are functions of the source, so they do need to be passed the tile grid. The tile source knows its tile grid, and can get the projection's tile grid if it doesn't have a tile grid.
2013-04-02 11:12:43 +02:00
Éric Lemoine
676bcc6cc7 Merge pull request #445 from elemoine/events
Add on and un methods to ol.Object
2013-03-31 06:40:17 -07:00
Éric Lemoine
ce0836e403 Add on and un methods to ol.Object 2013-03-31 14:14:19 +02:00
Éric Lemoine
660537ed2b Merge pull request #446 from elemoine/build
Put all build artifacts in a single directory
2013-03-29 08:34:20 -07:00
Éric Lemoine
7f85dfbf1c Git can now ignore the entire build dir 2013-03-29 16:32:43 +01:00
Éric Lemoine
dac2a5ad5a Merge pull request #447 from elemoine/wms-test-ns
Correct ns for ol.source.wms tests
2013-03-29 08:23:22 -07:00
Éric Lemoine
b87fcbb4c4 Move hosted examples loader our of build dir
The build dir is now empty, and therefore unexisting for Git.
2013-03-29 16:17:38 +01:00
Éric Lemoine
35fc2882b4 .gitignore clean-up 2013-03-29 16:09:38 +01:00
Éric Lemoine
b40aafc696 Tests requireall.js generated in build dir 2013-03-29 16:05:56 +01:00
Éric Lemoine
5019f9378c Move Plovr json files in specific dir 2013-03-29 16:00:13 +01:00
Éric Lemoine
dbf9ce8844 Correct ns for ol.source.wms tests 2013-03-29 15:58:01 +01:00
Éric Lemoine
15ae6832d4 Remove unneeded test in build.py 2013-03-29 11:34:39 +01:00
Éric Lemoine
4428fe0f5a Examples json and combined.js files in build dir 2013-03-29 11:33:28 +01:00
Tom Payne
dfe30f9feb Merge pull request #423 from twpayne/preemptive-webgl-texture-uploads
White flash occurs when zooming out from initially zoomed in view with WebGL renderer
2013-03-27 16:00:56 -07:00
Tom Payne
7fc3784a0b Merge pull request #443 from twpayne/only-use-glsl-unit-if-available
Only use glsl-unit if it is available
2013-03-27 10:05:23 -07:00
Tom Payne
c13c7a7208 Only use glsl-unit if it is available 2013-03-27 17:53:25 +01:00
Tom Payne
a32c69c8ff Merge pull request #442 from twpayne/fix-types-js-dependency
Fix build/src/external/src/types.js dependency
2013-03-27 09:35:46 -07:00
Tom Payne
13a2848665 Fix build/src/external/src/types.js dependency
The dependencies for build/src/external/src/types.js were wrong, which
meant that build/src/external/src/types.js would always be rebuilt,
which meant that almost everything else would be rebuilt too.
2013-03-27 17:17:04 +01:00
Tom Payne
cbe4d7bd84 Merge pull request #441 from twpayne/dont-install-phantomjs-on-windows
Do not install PhamtomJS on Windows
2013-03-27 08:56:13 -07:00
Tom Payne
8c5b778595 Don't attempt to install PhantomJS on Windows
Instead, assume that phantomjs.exe is already in the user's path. It can
also be overridden on the build.py command line:

  build.py PHANTOMJS=path/to/phantomjs

or with an environment variable:

  set PHANTOMJS=path/to/phantomjs
  build.py
2013-03-27 16:44:44 +01:00
Tom Payne
6b01ff9327 Correct preload example tags, thanks @fredj 2013-03-27 15:10:34 +01:00
Tom Payne
66c6a8a3e0 Make preload a number of levels instead of a boolean 2013-03-27 14:34:29 +01:00
Tom Payne
421135b3e7 Set preload appropriately in examples 2013-03-27 14:34:29 +01:00
Tom Payne
5077413c34 Add preload example 2013-03-27 14:34:29 +01:00
Tom Payne
494d61250e Make tile pre-loading a per-layer option 2013-03-27 14:34:29 +01:00
Tom Payne
1d22d2fdde Tune tile priority functions 2013-03-27 14:34:29 +01:00
Tom Payne
5e8b0de66d Use tile texture queue 2013-03-27 14:34:29 +01:00
Tom Payne
6221680b0b Add tile texture queue 2013-03-27 14:34:29 +01:00
Tom Payne
00b862de10 Store focus in frame state 2013-03-27 14:34:29 +01:00
Tom Payne
96912c271d Add optional per-tile callback to manageTilePyramid 2013-03-27 14:34:28 +01:00
Tom Payne
3e4f1773bc Replace isHeap with assertValid 2013-03-27 14:34:28 +01:00
Tom Payne
27f9e83780 Refactor ol.TileQueue to extend ol.structs.PriorityQueue 2013-03-27 14:34:28 +01:00
Tom Payne
f12f5ccc67 Factor out core elements of ol.TileQueue into ol.structs.PriorityQueue 2013-03-27 14:34:28 +01:00
Éric Lemoine
f62b8a1bfe Merge pull request #383 from elemoine/pinch-direction
One direction pinch zoom
2013-03-27 06:14:42 -07:00
Éric Lemoine
3c03c8beab Increase touch zoom anim duration 2013-03-27 11:52:42 +01:00
Éric Lemoine
de1575e457 One direction pinch zoom 2013-03-27 11:52:42 +01:00
Éric Lemoine
b753e6b6c2 Merge pull request #435 from elemoine/coordinate-z
Use @expose for Coordinate.z
2013-03-26 10:18:55 -07:00
Éric Lemoine
0b62c92cb3 Use @expose for Coordinate.z
By annotating the z property with @expose the compiler does not try to optimize that property in any way. See https://developers.google.com/closure/compiler/docs/js-for-compiler. The doc says that @expose should never be used in library code, but that's the only way I found for our case.
2013-03-26 17:05:54 +01:00
Tom Payne
588e0c1cdc Merge pull request #434 from twpayne/build-clean-ups
Build clean-ups
2013-03-25 05:01:04 -07:00
Tom Payne
c22b971b45 Sort .gitignore 2013-03-25 12:33:27 +01:00
Tom Payne
116370f7f1 Only shallow clone jsdoc
glsl-unit is not shallow cloned because code.google.com returns a 500
Internal Server Error.
2013-03-25 12:33:27 +01:00
Tom Payne
e196a9e68e Clone jsdoc into build/jsdoc 2013-03-25 12:28:04 +01:00
Tom Payne
59f5484cde Rename hostexamples to host-examples 2013-03-25 12:25:37 +01:00
Tom Payne
5a4acc1262 Merge pull request #429 from twpayne/dont-shrink-canvas
Don't shrink canvas
2013-03-25 04:11:35 -07:00
Tom Payne
4e7591394d Merge pull request #433 from twpayne/clean-up-xyz-tests
Move ol.tilegrid.XYZ tests to their proper place
2013-03-25 04:04:48 -07:00
Tom Payne
7a243b310f Move ol.tilegrid.XYZ tests to their proper place 2013-03-25 12:03:13 +01:00
Tom Payne
62877fdf02 Reuse ol.Size object 2013-03-25 11:54:50 +01:00
Tom Payne
4e883b7099 Don't shrink canvas 2013-03-25 11:54:50 +01:00
Tom Payne
b396673932 Fix typo in ol.TileRange.containsTileRange 2013-03-25 11:54:50 +01:00
Tom Payne
6cfe918501 Merge pull request #428 from twpayne/gc-optimizations
GC optimizations
2013-03-25 03:54:15 -07:00
Frédéric Junod
5c7905178c Merge pull request #432 from fredj/uri-url
Rename TileJSONOptions.uri to TileJSONOptions.url
2013-03-25 03:46:26 -07:00
Tom Payne
9906c518a7 Rename useTileZXY to useTile 2013-03-25 11:45:20 +01:00
Tom Payne
658b919d20 Merge pull request #425 from twpayne/glsl-unit
Use glsl-unit for WebGL shaders
2013-03-25 03:42:27 -07:00
Tom Payne
c72fc4476c Merge pull request #431 from twpayne/rename-anchoredelement-to-overlay
Rename AnchoredElement to Overlay
2013-03-25 03:36:57 -07:00
Tom Payne
f7cc8fa738 Remove ol.TileRange.clone 2013-03-25 11:33:06 +01:00
Frederic Junod
415e7a6dd4 Rename TileJSONOptions.uri to TileJSONOptions.url 2013-03-25 10:17:37 +01:00
Tom Payne
65e6ed3485 Rename getTileZXY to getTile 2013-03-25 10:10:03 +01:00
ahocevar
560f645384 Merge pull request #420 from ahocevar/icon-defer
Don't create tile if rendering needs to be deferred. r=@bartvde
2013-03-25 02:04:50 -07:00
Tom Payne
69d06a6e18 Add comment about automatically generated files 2013-03-25 10:04:32 +01:00
Tom Payne
096d48b4e8 Rename AnchoredElement to Overlay 2013-03-24 20:30:12 +01:00
Tom Payne
25e1211621 Merge pull request #430 from twpayne/fix-bing-maps-scope
Fix use of this in ol.source.BingMaps
2013-03-24 11:52:50 -07:00
Tom Payne
e62178759c Fix use of this in ol.source.BingMaps 2013-03-24 19:26:34 +01:00
Tom Payne
685f2b6f5f Make time-sensitive test less sensitive 2013-03-24 16:14:04 +01:00
Tom Payne
3a4ef83e79 Tidy up ol.webgl namespace 2013-03-24 15:51:09 +01:00
Tom Payne
dfb631a08f Replace getTile with getTileZXY
This massively reduces the number of temporary ol.TileCoord objects.

Previously an ol.TileCoord object was generated for every potentially
visible tile at the current zoom level and lower, every frame.  This
commit eliminates all of those.  Now new ol.TileCoord objects are only
allocated when a new tile is created.
2013-03-24 15:24:49 +01:00
Tom Payne
247fc8f031 Make reverseIntersection argument mandatory 2013-03-24 13:59:35 +01:00
Tom Payne
aeeaa79393 Avoid creating ol.Coordinate objects to call getTileCoordForCoordAndResolution_ 2013-03-24 13:56:23 +01:00
Tom Payne
e023e6fa2f Avoid creating extra ol.Size object in getPixelBoundsForTileCoordAndResolution 2013-03-24 13:49:47 +01:00
Tom Payne
5771057ae1 Reuse ol.TileRange object in forEachTileCoordParentTileRange 2013-03-24 13:46:23 +01:00
Tom Payne
731fcd3d17 Move shader support code into ol.webgl 2013-03-23 18:29:26 +01:00
Tom Payne
4ec8bf2360 Configure Travis to build shaders with glsl-unit 2013-03-23 18:20:34 +01:00
Tom Payne
711e4be19e Use glsl-unit in WebGL tile layer renderer 2013-03-23 17:47:02 +01:00
Tom Payne
7300051b69 Use glsl-unit in WebGL map renderer 2013-03-23 17:46:38 +01:00
Tom Payne
c48df12a33 Add infrastructure for glsl-unit 2013-03-23 17:45:44 +01:00
Tom Payne
3fbf7b8c20 Merge pull request #357 from twpayne/load-low-resolution-tiles
Load low resolution tiles
2013-03-23 06:00:45 -07:00
Tom Payne
cb1b1b8883 Merge pull request #418 from twpayne/webgl-core-improvements
WebGL core improvements
2013-03-23 05:55:23 -07:00
Tim Schaub
e2d200882a Merge pull request #422 from tschaub/stop-ignoring-global-leaks
Stop ignoring global leaks
2013-03-23 05:34:20 -07:00
Tim Schaub
d9ab545985 Stop ignoring global leaks
The `goog.dom.ViewportSizeMonitor` (used in map.js) creates a global leak by setting `goog.UID_PROPERTY_` on the monitored window.  In order to test that we don't have other global leaks, we preemptively set the property so Mocha can compare the global before and after our tests.
2013-03-23 05:50:54 -06:00
Tim Schaub
53fc6f3989 Merge pull request #421 from tschaub/global-leak
Fix global leak in WebGL image layer test
2013-03-23 03:59:45 -07:00
Tim Schaub
ff28c0b793 Fix global leak in WebGL image layer test 2013-03-23 04:38:12 -06:00
ahocevar
28f29e9d40 Don't create tile if rendering needs to be deferred
Rendering vector tiles with mixed geometry types does not work
as expected, because the tile is created without the geometries
that need another rendering pass because of missing icons. This
was discovered by @bartvde when working on the KML parser, where
mixed geometry types are common.

This change fixes the issue by breaking out from rendering
entirely when renderFeaturesByGeometryType returns a deferred
state. In addition, there was a related bug because icons are
added to the cache regardless of its loaded state. This is also
fixed now.
2013-03-23 11:34:38 +01:00
Tom Payne
80df629319 Premptively load low resolution tiles 2013-03-22 21:02:09 +01:00
Tom Payne
e3abe376f1 Remove ol.source.TileSource.useLowResolutionTiles 2013-03-22 21:02:06 +01:00
Tom Payne
24452b0bcb Use operators instead of Math.max/min 2013-03-22 19:27:52 +01:00
Tom Payne
876fea2fb7 Rename shader variables to match CSS specification 2013-03-22 18:02:31 +01:00
Tom Payne
b7184641b0 Use shorter module name and clean up requires 2013-03-22 17:58:15 +01:00
Tom Payne
72437ff57b Use more compact constants 2013-03-22 17:33:19 +01:00
Tom Payne
69370ce629 Use ol.structs.Buffer.getUsage 2013-03-22 17:33:19 +01:00
Tom Payne
35df0693e0 Add usage to ol.structs.Buffer 2013-03-22 17:33:19 +01:00
Tom Payne
705b71ae2a Track buffer dirty state by map 2013-03-22 17:33:19 +01:00
Tom Payne
ba0e7ae89c Allow a ol.structs.Buffer to update multiple dirty sets 2013-03-22 17:33:19 +01:00
Tom Payne
4ee73bc02f Add ol.structs.IntegerSet.intersectsRange 2013-03-22 17:33:13 +01:00
Tom Payne
35ee45cefc Use local variable for texCoordMatrix 2013-03-22 17:25:58 +01:00
Tom Payne
66efba8824 Promote projectionMatrix and texCoordMatrix into base class 2013-03-22 17:25:53 +01:00
Tom Payne
cc41d720fa Manage buffers in WebGL map renderer 2013-03-22 17:25:47 +01:00
Tom Payne
ecd5158012 Add ol.renderer.webgl.Layer.getWebGLMapRenderer
This improves the type checking.
2013-03-22 17:25:42 +01:00
Tom Payne
f770be297d Use ol.math.roundUpToPowerOfTwo 2013-03-22 17:25:36 +01:00
Tom Payne
57abbddf50 Add ol.math.roundUpToPowerOfTwo 2013-03-22 17:25:31 +01:00
Tom Payne
6c32170a08 Promote texture and framebuffer management into base class 2013-03-22 17:25:27 +01:00
Tom Payne
657f58005e Remove unused function 2013-03-22 17:24:26 +01:00
Tom Payne
69f92615b1 Add missing variable declaration 2013-03-22 17:24:03 +01:00
Tom Payne
c04e9c8870 Add ol.Rectangle.extendXY 2013-03-22 17:23:58 +01:00
Tom Payne
483375ca42 Add ol.Extent.createEmptyExtent 2013-03-22 17:23:50 +01:00
Tom Payne
5186fa44f5 Add ol.Rectangle.isEmpty 2013-03-22 17:23:44 +01:00
Tom Payne
0488612449 Allow rectangles to be empty 2013-03-22 17:23:38 +01:00
Tom Payne
5192c5e64a Reverse order of arguments to set and s/index/offset/ 2013-03-22 17:23:30 +01:00
Tom Payne
713ad2cfb7 Replace unused entries with NaNs 2013-03-22 17:23:25 +01:00
Tom Payne
5169161d93 Extend equalArray to consider NaNs to be equal 2013-03-22 17:23:20 +01:00
Tom Payne
6ab5cfae8c Add ol.structs.IntegerSet.toString 2013-03-22 17:23:15 +01:00
Tom Payne
9047e98889 Add initial ol.structs.Buffer 2013-03-22 17:23:08 +01:00
Tom Payne
1833ec15e2 Refactor ol.structs.IntegerSet to use a packed array 2013-03-22 17:23:03 +01:00
Tom Payne
070b80c28d Add ol.structs.IntegerSet 2013-03-22 17:22:57 +01:00
Éric Lemoine
a12d10e912 Merge pull request #409 from elemoine/tilequeue
Tile renderers needn't listen for tile change
2013-03-22 09:17:46 -07:00
Tom Payne
f4dea053af Merge pull request #417 from twpayne/clean-up-side-by-side-example
Clean up side-by-side example
2013-03-22 07:04:43 -07:00
Tom Payne
422ed4bd43 Clean up side-by-side example 2013-03-22 14:39:17 +01:00
Tom Payne
b0989af9d1 Merge pull request #416 from twpayne/numeric-constant-clean-ups
Use Infinity instead of Number.POSITIVE_INFINITY
2013-03-22 05:05:22 -07:00
Tom Payne
8b5367c947 Use Infinity instead of Number.POSITIVE_INFINITY 2013-03-22 11:34:44 +01:00
ahocevar
9e1b37ada3 Merge pull request #415 from ahocevar/jsdoc-pegged
Use JSDoc master again. r=@elemoine
2013-03-22 03:14:13 -07:00
Éric Lemoine
6d1fff688e Update README and CONTRIBUTING
[ci skip]
2013-03-22 10:59:09 +01:00
ahocevar
77efd352ad Use JSDoc master again
... so we're able to always give the JSDoc project instant
feedback on how it works with code that uses the Closure
library.
2013-03-22 10:50:15 +01:00
Bruno Binet
3d87ecd858 Merge pull request #354 from bbinet/fix-wmts-from-cap-example
wmts-from-capabilities example doesn't work because of referer check
2013-03-22 01:51:46 -07:00
ahocevar
5736765cb7 Merge pull request #414 from hegemonic/master
Remove descriptions from JSDoc/Closure Compiler type tags
2013-03-21 15:32:35 -07:00
Jeff Williams
97879a3572 remove descriptions from JSDoc type tags 2013-03-21 09:54:52 -07:00
Bruno Binet
e9583617f7 Merge pull request #413 from bbinet/pep8-work
Pep8ify build.py (Closes #371)
2013-03-21 09:14:43 -07:00
Bruno Binet
f395064721 Pep8ify build.py
Thanks a lot autopep8!
2013-03-21 16:38:48 +01:00
Marc Jansen
2678c07caf Merge pull request #412 from marcjansen/submittable
Keep the search-filter on submit in example index.
2013-03-21 07:37:59 -07:00
Marc Jansen
10ef5eff8b Keep the search-filter on submit in example index.
When one would hit `ENTER` after filtering the list of examples, the form would
be submitted and the filter would be gone after the page reload. By giving the
main search field the appropriate `name`-attribute, this is being solved.
2013-03-21 15:32:06 +01:00
Bruno Binet
c11193f71d Use Vienna wmts in wmts-from-capabilities example
vienna wmts capabilities url is:
http://maps.wien.gv.at/wmts/1.0.0/WMTSCapabilities.xml
2013-03-21 14:03:09 +01:00
Bruno Binet
7fec1f5208 ArcGis use camelcase 'Style', not lowercase 'style'
The OGC documentation is not so clear if we should use style or Style.
2013-03-21 11:15:35 +01:00
Bruno Binet
932c284a2e ArcGis use RESTful
The OGC documentation is not clear if we should use REST or RESTful.
2013-03-21 11:15:35 +01:00
Éric Lemoine
ef42daedd4 Merge pull request #407 from elemoine/crossorigin
crossOrigin defaults to null
2013-03-21 02:59:05 -07:00
Éric Lemoine
7949cdaa82 crossOrigin defaults to null 2013-03-21 10:37:31 +01:00
Éric Lemoine
1d575309da Tile renderers needn't listen for tile change 2013-03-21 10:29:01 +01:00
Bruno Binet
7038ac0c81 Merge pull request #356 from bbinet/issue-356
Can't parse http://maps.wien.gv.at/wmts/1.0.0/WMTSCapabilities.xml
2013-03-21 02:10:56 -07:00
Frédéric Junod
92a34824e6 Merge pull request #411 from fredj/apidoc
Minor jsdoc fix
2013-03-21 01:27:27 -07:00
Frédéric Junod
c418beb350 Merge pull request #403 from fredj/export-map
Add png output
2013-03-21 01:24:11 -07:00
Frederic Junod
8296a1f134 Minor jsdoc fix 2013-03-21 09:19:23 +01:00
Éric Lemoine
01b97208d8 Merge pull request #408 from elemoine/jsdoc311
Use jsdoc v3.1.1
2013-03-20 15:52:57 -07:00
Tim Schaub
f74940fe2b Using a server that is not down (closes #406) 2013-03-20 16:00:26 -06:00
Éric Lemoine
a3d10e4234 Use jsdoc v3.1.1 2013-03-20 22:36:13 +01:00
Éric Lemoine
0ae47403ee Merge pull request #398 from elemoine/nestedoptions
Support nested options objects
2013-03-20 10:45:37 -07:00
Éric Lemoine
0b403c767a Fix goog.provide for object literals 2013-03-20 18:43:02 +01:00
Éric Lemoine
02d8d9e0bc Support nested options objects
This commit extends the generated Export constructors to support nested options objects. For example, this is now supported:

@exportObjectLiteralProperty ol.MapOptions.view ol.View|ol.View2DOptions|undefined

This specifies that the "view" property in the map options can reference an ol.View instance, an ol.View2DOptions literal object, or undefined. If the "view" property references an ol.View2DOptions literal object the ol.MapExport constructor will create an ol.View2DExport instance, and pass it to the parent constructor, ol.Map. In this way, extern types never cross the external/internal boundary. In other words, translations from non-renamed to renamed objects remain confined to the generated Export constructors.
2013-03-20 18:43:02 +01:00
Frederic Junod
f2b69a2a13 Add png output 2013-03-20 17:00:49 +01:00
Bruno Binet
641e492c95 Update social links in wmts-capabilities example 2013-03-20 15:25:45 +01:00
Bruno Binet
b0c4977811 Add exportSymbol for ol.projection.addCommonProjections 2013-03-20 14:39:14 +01:00
Bruno Binet
30a2b4187c The same projection can be added more than once
So that addCommonProjections can be safely called in our examples.
2013-03-20 14:39:14 +01:00
Bruno Binet
48e142d3f0 Fix wmts-capabilities example
the parsing of the wmts getCapabilities document require proj4js.

Also initialize common ol3 projections with ol.projection.addCommonProjections
so that it won't try to get EPSG:3857 from proj4js.
2013-03-20 14:39:14 +01:00
Bruno Binet
e6450dc313 Add new equivalent projections
for both EPSG:4326 and EPSG:3857.
2013-03-20 14:39:14 +01:00
Bruno Binet
c1db1cd491 Use correct namespaceURI for WGS84BoundingBox reader
(closes #356)
2013-03-20 14:39:14 +01:00
Frederic Junod
2eb5454ac4 Add wmts-capabilities example 2013-03-20 14:39:13 +01:00
ahocevar
baa5500843 Merge pull request #402 from ahocevar/more-context
More convenient url functions for WMS. r=@elemoine,@twpayne
2013-03-20 06:22:36 -07:00
ahocevar
5719160155 Less context
This change removes all changes that were anticipated here for
WMS GetFeatureInfo handling, including the IWMS interface and
the goog.provide for 'ol.tilegrid'. I'll create a separate pull
request for WMS GetFeatureInfo eventually, taking into account
the suggestions from the discussion in #402.
2013-03-20 13:41:36 +01:00
Tom Payne
514d513ca9 Merge pull request #401 from twpayne/coordinate-3d
Optionally extend ol.Coordinate to the third dimension
2013-03-20 05:05:14 -07:00
Tom Payne
7755555cc3 Use NaN as default value for Z 2013-03-20 12:02:40 +01:00
ahocevar
57fdd78a19 Fixing requires 2013-03-20 10:55:58 +01:00
ahocevar
46ca98e484 More context for url functions
With this change, url functions are called in the scope of the
source they are configured for. This allows us to simplify the
url function generation for WMS, using a more generic
createFromParamsFunction factory, and the source's new params
member.

Note that there is also a new url member for WMS sources. This
is the WMS base url (the first one in case there is an array of
urls for faster tile access). This can be used for accessing
other WMS services (especially GetFeatureInfo).
2013-03-20 10:45:54 +01:00
Tom Payne
d3ea5236ef Optionally extend ol.Coordinate to the third dimension
We continue to inherit from goog.math.Vec2 instead of goog.math.Vec3
because goog.math.Vec2 better represents a position in space, with
appropriate functionality, whereas goog.math.Vec3 represents a direction
and magnitude.
2013-03-19 22:10:21 +01:00
Tom Payne
4fe67f09c0 Merge pull request #399 from twpayne/test-typos
Fix some trivial typos
2013-03-19 13:35:25 -07:00
Tom Payne
a1a2ab415f Fix some trivial typos 2013-03-19 21:34:31 +01:00
Tim Schaub
26aefc1f63 The _blank target is an antipattern
The examples all have links back to the index page.  People know how to open links in new tabs/windows when they want to.
2013-03-19 12:18:08 -06:00
Tim Schaub
462659a9fc Use index.html instead of example-list.html
The original decision to avoid index.html was because it only works with a build step.  Since we've all accepted a build step, the more sensible name is index.html.  Without this change, every hosted example has a link to http://openlayers.github.com/ol3/master/examples/example-list.html which 404s.
2013-03-19 12:17:00 -06:00
Tim Schaub
374e436872 Picking a color that shows up more clearly on bluemarble 2013-03-19 11:54:50 -06:00
Tim Schaub
86eb65cc13 Merge pull request #395 from tschaub/no-test-markup
Create test specific markup in the individual tests as needed instead of relying on a common dom structure for all tests.
2013-03-19 09:18:41 -07:00
Tim Schaub
c07be93d25 Merge pull request #325 from tschaub/dirty-animation
Render new vector tiles after animation completes.  This was previously happening during an animated zoom, but not an animated pan.
2013-03-19 09:17:05 -07:00
Tim Schaub
825a6d65e8 Properly maintain dirty state during animation
The previous logic assumed that if there were any tiles to render, the dirty state should be false.  The correct logic is to say that if we don't render during animation, dirty is true.
2013-03-19 07:27:59 -06:00
Tim Schaub
251d6fc488 Example touch-ups
The strokeStyle property is now spelled strokeColor.  There is no sense in setting opacity to 1.5.  Moving map initialization up.
2013-03-19 06:38:50 -06:00
Tom Payne
d48a9407f2 Merge pull request #382 from twpayne/move-files
Use more consistent directory structure
2013-03-19 04:52:36 -07:00
Tom Payne
6cc4cb33d0 Use more consistent directory structure 2013-03-19 12:03:31 +01:00
Tim Schaub
956c31b59d Lint in build.py 2013-03-18 23:40:40 -06:00
Tim Schaub
d9380d0260 Copy social links script for hosted examples 2013-03-18 23:35:26 -06:00
Tim Schaub
27ccd13e48 Create test specific markup in tests
Instead of relying on a shared dom structure, the tests should create (and destroy) elements as needed.
2013-03-18 22:53:04 -06:00
Tim Schaub
fad57a0fe5 Clarifying which var is accesed
This test creates its own zoomslider and doesn't access the one from the closure.
2013-03-18 21:52:01 -06:00
Tim Schaub
928457e174 Correcting test semantics
Despite what the test comment says, the orientation of this slider is horizontal.
2013-03-18 21:50:00 -06:00
Tim Schaub
0fc7ba5bfb Merge pull request #393 from tschaub/social
Make social links more social
2013-03-18 17:17:54 -07:00
Tim Schaub
6b5e251279 Fix global leak
A bit curious that the linter didn't catch this.  My test runner fails with it.
2013-03-18 17:54:36 -06:00
Tom Payne
41eedfaa06 Merge pull request #394 from Turbo87/test-improvements
Mocha improvements
2013-03-18 14:11:04 -07:00
Tobias Bieniek
1d5389a45d test: Deactivate mocha bail option
We don't want mocha to quit on the first failing test. It should continue
and see what other tests are failing.
2013-03-18 20:50:04 +01:00
Tim Schaub
1ac77b1a6f Make social links more social 2013-03-18 13:27:47 -06:00
Tim Schaub
4cec0546c8 Range from -π to π in rotation inputs (see #392) 2013-03-18 12:10:44 -06:00
ahocevar
114d4c6f92 Merge pull request #388 from ahocevar/dblclick
Do not recenter map and zoom on repeated clicks on +/-. r=@elemoine
2013-03-18 11:03:26 -07:00
Frédéric Junod
b5461f8b6b Merge pull request #389 from fredj/dom-object
Add ol.dom.Input
2013-03-18 09:04:33 -07:00
Frederic Junod
7ee9a4c8a3 Add ol.dom.Input 2013-03-18 16:24:31 +01:00
Bruno Binet
07fb27db2c Merge pull request #370 from bbinet/fix-missing-requires
Fix check for missing goog.require directives
2013-03-18 08:16:43 -07:00
ahocevar
f765982654 Do not recenter map and zoom on repeated clicks on +/-
Multiple fast clicks get interpreted as DBLCLICK by the browser,
so it makes sense to stop propagation of DBLCLICK events when
they happen on elements on the overlay container. This is also
a good change because DBLCLICK might have a meaning on other map
overlays as well.
2013-03-18 09:19:10 +01:00
Éric Lemoine
40f2dc6322 Merge pull request #385 from elemoine/385
Rule-based styling does not work in hosted style-rules example
2013-03-17 22:23:15 -07:00
Éric Lemoine
39d55bcf45 Merge pull request #387 from elemoine/expressionexports
Move expression.exports to proper place
2013-03-17 22:22:29 -07:00
Éric Lemoine
0949cb29aa Move expression.exports to proper place 2013-03-17 23:12:43 +01:00
Éric Lemoine
b7fa22c4d4 Add type VectorLayerOptions 2013-03-17 22:33:02 +01:00
Éric Lemoine
b381b28169 Merge pull request #381 from elemoine/countriesjson
The vector-layer example does not work when hosted
2013-03-17 01:36:35 -07:00
Éric Lemoine
392735c823 Merge pull request #384 from elemoine/optional
Exports fixes
2013-03-15 14:26:05 -07:00
Éric Lemoine
1f641c5933 Make the generated Export classes accept undefined
We have constructors, like ol.View2D and ol.control.Attribution, whose "options" argument is optional (opt_options). But currently, we cannot do "new ol.View2D()" in uncompiled code that uses an ol3 build compiled in advanced mode. This commit fixes that by changing the generated Export constructors.
2013-03-15 18:01:53 +01:00
Éric Lemoine
6eaad6a837 Source option "projection" is a ProjectionLike 2013-03-15 17:58:54 +01:00
Éric Lemoine
f86dfc3212 Remove ol.source.SourceOptions typedef
The ol.source.SourceOptions type is already declared in objectliteral.exports, so it should not be declared in the ol/source/source.js file.
2013-03-15 17:56:14 +01:00
Tom Payne
0a9cf1230e Merge pull request #374 from twpayne/functionality-not-form
You can't extend expect.js outside expect.js
2013-03-15 07:55:45 -07:00
Éric Lemoine
51625b8008 Make vector-layer example ignore XHR errors
This is a workaround for our check-example.js PhantomJS script to work with this example. Without this check-example.js fails because xhr.status is 0. I tried to give the explicit file:/// scheme as indicated in https://groups.google.com/d/msg/phantomjs/wFGme0pE-Tk/WUjU5s-27NwJ, but that didn't work for me.
2013-03-15 15:46:40 +01:00
Tom Payne
af6de5582a Add comment to highlight use of modified expect.js
Hat tip @marcjansen
2013-03-15 15:29:16 +01:00
Éric Lemoine
a34adc6f62 Add countries.json to examples data dir
The examples cannot use files located in the test dir, or they won't work when hosted as GitHub pages.
2013-03-15 14:25:05 +01:00
Marc Jansen
6068895a44 Merge pull request #379 from marcjansen/progressbar
Restrict width of progressbar in example-screenshot.js
2013-03-15 04:12:51 -07:00
Marc Jansen
a8457cb736 Merge pull request #378 from marcjansen/examples-file-protocol
Add fallback host when examples are accessed through file:-protocol.
2013-03-15 03:50:48 -07:00
Marc Jansen
92a358967f Restrict progressbar to fixed width.
As more and more examples will be processed with this script, the
progresbar would grow way too long. This commit makes the width of
the bar fixed. Every character in the bar now equals 5% progress,
regardless of the number of examples.
2013-03-15 11:43:50 +01:00
Marc Jansen
24d3c903fe Reformatted and gjslinted example-screenshot.js. 2013-03-15 11:40:55 +01:00
Marc Jansen
3860f806d1 Merge pull request #377 from marcjansen/use-css-constant
Use CSS class constant in zoomslider.
2013-03-15 03:06:43 -07:00
Marc Jansen
2641a1135f Add fallback when examples are opened w/ file://.
When opening an example through the `file:`-protocol, e.g.
`file:///ol3/examples/full-screen.html` our `loader.js` would inject
a `<script>` tag with a `src` pointing to an illegal URL
`http://:9810/compile?mode=ADVANCED&id=full-screen`.

This changes the respective logic, so that in the case that we are accessed
through the `file:`-protocol, we fallback to using `localhost` as hostname
for the plovr-compiler.

The examples that do not use XHR (like e.g. `wms-capabilities.html`) now
work as expected when accessed through `file:`-protocol.
2013-03-15 10:29:01 +01:00
Marc Jansen
8692c42318 Merge pull request #376 from marcjansen/singular-plural
Use correct singular/plural of noun.
2013-03-15 02:03:49 -07:00
Marc Jansen
250e17561a Use CSS class constant in zoomslider. 2013-03-15 10:02:12 +01:00
Marc Jansen
b43f25971b Use correct singular/plural of noun. 2013-03-15 09:35:33 +01:00
Tom Payne
c9f43b4da7 Move equalArray into expect.js 2013-03-15 01:39:11 +01:00
Tom Payne
79c77a6369 Move intersect into expect.js 2013-03-15 01:39:11 +01:00
Tom Payne
7c7c4df3fc Move called into expect.js 2013-03-15 01:17:28 +01:00
Tom Payne
62011dab28 Move roughlyEqual into expect.js 2013-03-15 01:17:28 +01:00
Tom Payne
bddaecbe69 Make it clear that ol3's expect.js is different 2013-03-14 23:33:58 +01:00
ahocevar
31e59d3a8b Merge pull request #373 from ahocevar/origin
Fixing origin for default tile grid. r=@twpayne,@elemoine
2013-03-14 11:47:06 -07:00
ahocevar
e9d86fdfdc Fixing origin for default tile grid
We count tiles from bottom to top, so we want the origin in the
bottom left corner, not the top left corner.
2013-03-14 18:27:18 +01:00
Frédéric Junod
b4317a8f9c Merge pull request #372 from fredj/typecast
Fix typecast
2013-03-14 09:42:46 -07:00
Frederic Junod
bce9e9d0de Fix typecast
Fix JSC_MISPLACED_TYPE_ANNOTATION warnings with the plovr 2013 release
candidate (http://plovr.com/plovr-2013-rc.jar)
2013-03-14 15:59:21 +01:00
Tom Payne
1d002dd4ae Merge pull request #368 from twpayne/equalarray
Add array value equality test
2013-03-14 07:42:40 -07:00
Bruno Binet
28155a4147 Fix check for missing goog.require directives
Take this example:
```
goog.require('ol.projection.addCommonProjections');

ol.projection.addCommonProjections();
```

Without this patch, the build_check_requires_timestamp target would report
that ``ol.projection`` is missing.
This is because ``ol.projection.addCommonProjections();`` would match both
``ol.projection.addCommonProjections and ``ol.projection`` provide
directives.
2013-03-14 15:22:00 +01:00
Bruno Binet
68714e73c3 Merge pull request #369 from bbinet/fix-unusedrequires
Remove unused goog.require directives
2013-03-14 07:21:28 -07:00
Bruno Binet
6cf20ef82f Remove unused goog.require directives
See #367.
2013-03-14 14:57:21 +01:00
Tom Payne
7222464426 Don't use goog.array in ol.Collection tests 2013-03-14 14:50:23 +01:00
Tom Payne
d7b13ab09f Add test for array equality
Hilariously, expect.js does not have one.
2013-03-14 14:49:43 +01:00
Éric Lemoine
4b18d3d89a Merge pull request #367 from elemoine/ratio
Make ratio configurable in WMS single image
2013-03-14 06:37:49 -07:00
Cédric Moullet
8532bc5a4d Make ratio configurable in WMS single image 2013-03-14 14:29:51 +01:00
Éric Lemoine
8ca763cdbd Merge pull request #330 from cedricmoullet/wmscustom
Add single image WMS with custom projection example
2013-03-14 06:21:42 -07:00
Éric Lemoine
453877455f Update CONTRIBUTING.md 2013-03-14 14:20:47 +01:00
Éric Lemoine
a924103335 Update CONTRIBUTING.md 2013-03-14 14:20:30 +01:00
Éric Lemoine
38f1af6204 Merge pull request #366 from elemoine/347
Add ScaleLine control to wms-custom-proj example
2013-03-14 06:15:50 -07:00
Cédric Moullet
d66e67966d Add ScaleLine control to wms-custom-proj example
This requires using Proj4js, and configuring it with an extent.
2013-03-14 14:01:29 +01:00
Bruno Binet
81089b2199 Remove unused goog.require directives 2013-03-14 12:39:51 +01:00
Bruno Binet
15ce80f42e Merge pull request #364 from bbinet/fix-check-requires
Fix check for unused goog.require directives
2013-03-14 04:29:41 -07:00
Marc Jansen
88dd98af8b Merge pull request #345 from marcjansen/zoomslider-own-ui-2
Add a zoomslider control. (r=@twpayne,@elemoine,@fredj)
2013-03-14 04:06:56 -07:00
Bruno Binet
9b1c389c80 Remove unused goog.require directives 2013-03-14 11:39:43 +01:00
Marc Jansen
5059fe0be7 Adjust test syntax. 2013-03-14 11:31:58 +01:00
Bruno Binet
1eabd7f4e6 Fix check for unused goog.require directives 2013-03-14 11:30:05 +01:00
Marc Jansen
1040a082c1 Remove CSS workarounds as suggested by @fredj. 2013-03-14 09:37:36 +01:00
Marc Jansen
9798eb5fa8 Don't use non-exported method in example. 2013-03-14 09:37:36 +01:00
Marc Jansen
e872a49beb Use getContentBoxSize() for slider initialisation.
Initial note to revisit this came from @twpayne; thanks.
2013-03-14 09:37:36 +01:00
Marc Jansen
94d7379ba3 Correct API documentation. 2013-03-14 09:37:35 +01:00
Marc Jansen
220c7bd6f8 More specific argument type of callback method. 2013-03-14 09:37:35 +01:00
Marc Jansen
bc07722816 Unregister previous event listeners, if any.
Thanks for spotting this, @twpayne.
2013-03-14 09:37:35 +01:00
Marc Jansen
d77a8b0a1d Add an assertion to the dragchange handler.
This ensures that the result of resolution calculation stays inside of the
allowed bounds.
2013-03-14 09:37:35 +01:00
Marc Jansen
ce67625b20 Use OSM resolutions as fallback resolutions.
Hat tip to @twpayne for suggesting this change in the defaults.
2013-03-14 09:37:35 +01:00
Marc Jansen
f496471273 Simplify example and let it use real resolutions.
Thanks to @twpayne for the suggestion.
2013-03-14 09:37:35 +01:00
Marc Jansen
8bf71ebb3a Add a zoomslider control. 2013-03-14 09:37:35 +01:00
Éric Lemoine
ac86cc1058 Merge pull request #362 from Turbo87/test-improvements
Test improvements
2013-03-13 10:18:00 -07:00
Bruno Binet
7d675b73b4 Merge pull request #361 from bbinet/factorize-expandurl-code
Factorize code that expand a template url into multiples urls
2013-03-13 09:47:17 -07:00
Tobias Bieniek
47261124fc test: Added expect(spy).to.be.called() syntactic sugar 2013-03-13 17:18:23 +01:00
Tobias Bieniek
93577bd335 test: Moved intersectsWith() testing function into test-extensions.js 2013-03-13 17:11:21 +01:00
Marc Jansen
e1bfc0c9dd Merge pull request #355 from marcjansen/screenshot
Add a screenshot script for our examples. (r=@twpayne,@elemoine)
2013-03-13 08:56:32 -07:00
Bruno Binet
317676a68f Homogenize wmts tileUrlFunction relative to other sources 2013-03-13 16:52:54 +01:00
Bruno Binet
5eaf4baaa4 Try to expand single url for TiledWMS source 2013-03-13 16:52:54 +01:00
Bruno Binet
875ead58ab Remove expandUrl duplicated code from createFromTemplate
and make use of expandUrl function instead.
2013-03-13 16:52:54 +01:00
Bruno Binet
54dfca3419 Move factorizable code in ol.TileUrlFunction.expandUrl 2013-03-13 16:48:22 +01:00
Marc Jansen
2b4545e221 Ignore fewer files and clip correctly. 2013-03-13 16:09:05 +01:00
Marc Jansen
3a863ddf3e Add a screenshot script for our examples.
This script is supposed to be executed via phantomjs. It will generate
screenshots of the html files in the directory specified by a commandline
option when these files are served through a webserver which can also be
specified. The screenshots will be saved in the passed directory.

Example usage:

    user@host:~/ol3/bin $ phantomjs example-screenshot.js \
                          http://localhost:8000/ol3/examples/ \
                          ../examples/

The above command will generate `*html.png` files in `tools/` for all html files
that are served through `http://localhost:8000/ol3/examples/`.

So if there is a file `my-humpty-example.html` inside of the relative folder
`../examples/` which is being served through the webserver so that
`http://localhost:8000/ol3/examples/my-humpty-example.html` is a valid and
reachable URL, this script will generate a screenshot and store it as
`../examples/my-humpty-example.html.png`.

The query string `?mode=raw` will be appended to the generated URL.

Known limitations:

As phantomjs doesn't support WebGL (see e.g.
https://github.com/ariya/phantomjs/wiki/Supported-Web-Standards and
http://code.google.com/p/phantomjs/issues/detail?id=273) This won't render
OpenLayers maps rendered through the webglrenderer.

In parts based upon this gist: https://gist.github.com/crazy4groovy/3160121
2013-03-13 15:50:55 +01:00
Frédéric Junod
c4ab34e4a7 Merge pull request #349 from fredj/bing-getStyle
Add ol.source.BingMaps.getStyle function
2013-03-13 06:16:11 -07:00
Frederic Junod
02e6937db3 Add a basic layer selector in bing-maps example 2013-03-13 13:36:49 +01:00
Éric Lemoine
edc1bd513b Merge pull request #358 from Turbo87/mocha
Replaced jasmine testing framework by mocha, expect.js and sinon
2013-03-13 04:04:17 -07:00
ahocevar
6d8d21b2d5 Merge pull request #360 from ahocevar/demo_dot_opengeo_dot_org
Using a server that is not down. r=@elemoine
2013-03-13 02:01:38 -07:00
ahocevar
14d9ff3b81 Using a server that is not down
fix #353
2013-03-13 09:59:25 +01:00
Bruno Binet
19acefc6d9 Merge pull request #359 from bbinet/useTile-consistent
Be more consistent with useTile parent method
2013-03-13 01:50:54 -07:00
Tobias Bieniek
01f9037782 test: Fixed linter errors 2013-03-13 04:59:20 +01:00
Tobias Bieniek
2245396bda test: Updated README file 2013-03-13 04:55:30 +01:00
Tobias Bieniek
d5d8afc858 Converted "vector" branch unit tests to mocha, expect.js and sinon 2013-03-13 04:48:08 +01:00
Tobias Bieniek
8273d880d5 Merge remote-tracking branch 'origin/master' into mocha
Conflicts:
	test/jasmine-extensions.js
2013-03-13 04:46:16 +01:00
Tobias Bieniek
89ab68cde7 Replaced jasmine testing framework by mocha, expect.js and sinon
as discussed in #319
2013-03-13 04:32:43 +01:00
Bruno Binet
86c05b4d21 Be more consistent with useTile abstract method 2013-03-12 17:58:29 +01:00
ahocevar
76d1a0c30e Merge pull request #218 from openlayers/vector
Vector work. p=@tschaub,@ahocevar; r=@twpayne,@marcjansen,@bartvde
2013-03-12 09:26:46 -07:00
ahocevar
84154d7bb2 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-03-12 13:27:41 +01:00
Tom Payne
f75d3abf7d Merge pull request #297 from twpayne/fix-297
Canvas map is not immediately updated when layers are added or removed
2013-03-12 05:26:25 -07:00
Tom Payne
427c376fc6 Always render map when layers are added or removed 2013-03-12 12:57:22 +01:00
Marc Jansen
06f8d1356d Merge pull request #352 from marcjansen/unselectable-css-const
Use constant for CSS class 'ol-unselectable'.
2013-03-12 03:30:38 -07:00
Marc Jansen
5e5e4d110a Use constant for CSS class 'ol-unselectable'. 2013-03-12 10:34:49 +01:00
ahocevar
acd4f50f15 Making the linter happy 2013-03-12 10:23:38 +01:00
ahocevar
eeecd424bf Moving vector rendering to ol.renderer.canvas.VectorRenderer 2013-03-12 10:05:47 +01:00
ahocevar
bb8755eb68 Recovering from bad merge 2013-03-12 08:48:22 +01:00
ahocevar
15375df7ab Line was too long after previous change 2013-03-12 08:41:41 +01:00
ahocevar
fad036aa53 Merge branch 'master' of github.com:openlayers/ol3 into vector
Conflicts:
	src/objectliterals.exports
2013-03-12 08:39:16 +01:00
ahocevar
b20a2bae94 Moving RTreeNode_ into ol.structs package 2013-03-12 08:35:57 +01:00
ahocevar
f5b53740e6 Define map at the top 2013-03-12 08:28:24 +01:00
ahocevar
47e5b0475b Since #274 we don't need to create an ol.Collection explicitly 2013-03-12 08:24:31 +01:00
Tom Payne
a0b1d74bb5 Merge pull request #337 from Turbo87/polyline
Added ol.parser.polyline module
2013-03-11 13:55:04 -07:00
Tobias Bieniek
1172e58a50 polyline: Replaced "new Array()" by "[]" 2013-03-11 21:41:32 +01:00
Tobias Bieniek
0df5b4cad2 polyline: Improved decoding loops to be more robust 2013-03-11 20:32:25 +01:00
Tobias Bieniek
8330586ee2 test/polyline: Reset testing data manually in encodeFloats test 2013-03-11 20:32:22 +01:00
Tobias Bieniek
8b45637e72 test/polyline: Added missing brackets 2013-03-11 20:32:18 +01:00
Cédric Moullet
d9e1fdf13c Change the way the projection is managed and use ol.projection.configureProj4jsProjection 2013-03-11 20:25:29 +01:00
Tom Payne
f9c080a67d Merge pull request #346 from twpayne/single-map-in-canvas-tiles-example
Use a single map in the canvas tiles example
2013-03-11 09:29:32 -07:00
Tom Payne
2a5d07d929 Use a single map in the canvas tiles example 2013-03-11 17:07:27 +01:00
Tom Payne
8b5194da38 Merge pull request #338 from twpayne/snap-center-to-pixel2
Snap center to pixel
2013-03-11 08:41:28 -07:00
Bruno Binet
837aa7512b Merge pull request #342 from bbinet/wmts
Add WMTS support.
2013-03-11 08:05:25 -07:00
Bruno Binet
61603dacce WMTS from swisstopo now supports CORS headers 2013-03-11 15:47:42 +01:00
ahocevar
a66f26f839 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-03-11 15:21:01 +01:00
Bruno Binet
d14b1c57a9 Remove ImageLayer from wmts-from-capabilities example 2013-03-11 15:15:53 +01:00
Bruno Binet
8638f6d502 s/meters_per_unit/metersPerUnit/ 2013-03-11 15:05:53 +01:00
Tom Payne
a6395cd2f5 Merge pull request #312 from twpayne/speed-up-precommit
precommit target is too slow
2013-03-11 06:47:16 -07:00
Frédéric Junod
a441d9777d Merge pull request #315 from fredj/geolocation-example
Add Geolocation example
2013-03-11 06:44:44 -07:00
Tom Payne
58f1c929ac Merge pull request #324 from twpayne/fix-canvas-renderer-clear
Canvas renderer is not properly cleared
2013-03-11 05:08:54 -07:00
Tom Payne
f4a7d9386b Merge pull request #344 from twpayne/semi-transparent-example
Add semi-transparent layer example
2013-03-11 05:08:12 -07:00
Frederic Junod
de066e10a4 Add geolocation example 2013-03-11 12:54:26 +01:00
Frederic Junod
6d90a9987d Add (incomplete) bootstrap.js externs 2013-03-11 12:54:13 +01:00
Bruno Binet
9e370bf6af Implement ol.source.WMTS.optionsFromCapabilities
and remove related ol.source.WMTS.createFromCapabilities function.
2013-03-11 12:42:14 +01:00
Tom Payne
df6af7cafa Replace precommit with separate check and integration-test targets 2013-03-11 12:21:13 +01:00
Frédéric Junod
7be0203cbe Merge pull request #341 from fredj/jquery-examples
Add jquery 1.7.2 and adapt examples externs
2013-03-11 04:09:42 -07:00
Frédéric Junod
5a70221e4b Merge pull request #306 from fredj/geolocation
Activate / deactivate geolocation
2013-03-11 04:04:04 -07:00
Tom Payne
34803cf78b Add semi-transparent layer example 2013-03-11 12:00:58 +01:00
Tom Payne
2c6d20306f Merge pull request #343 from twpayne/clean-up-fixme-target
Clean up fixme target
2013-03-11 03:54:46 -07:00
Bruno Binet
6f83e50332 Load EPSG:21781 definition from cdnjs. 2013-03-11 11:48:06 +01:00
Bruno Binet
c67e67ee12 Single tileUrlFunction in createFromTileUrlFunctions
In that case, simply return the single tileUrlFunction.
2013-03-11 11:29:40 +01:00
Tom Payne
47f04f9e8b Merge pull request #334 from twpayne/rotation-example
Rotation example
2013-03-11 03:29:14 -07:00
Tom Payne
3934dbbcaf Clean up fixme target
Correct regular expression
Use single quotes consistently
Use format strings
Correct grammar
2013-03-11 10:48:32 +01:00
Bruno Binet
b4cbe0609a Add missing exports
so that wmts-from-capabilities example works.
2013-03-11 10:42:38 +01:00
Bruno Binet
14d5916e67 Add wmts-from-capabilities example
it demonstrates how to create a wmts source by retrieving its configuration
from a wmts getCapabilities.
2013-03-11 10:42:38 +01:00
Bruno Binet
13d0b36a08 Add a ol.source.WMTS.createFromCapabilities function
so that we can create a wmts source directly from a getCapabilities response
(parsed by the wmts parser)
2013-03-11 10:42:37 +01:00
Bruno Binet
dc440a6604 Ensure supportedCRS property won't be renamed
this property was renamed when using wmts parser when built with
ADVANCED_OPTIMIZATIONS
2013-03-11 10:42:37 +01:00
Bruno Binet
0f9f5a25ae Export methods methods for ol.Extent
so that wmts example work (it makes use of extent.getTopLeft() method)
2013-03-11 10:42:37 +01:00
Bruno Binet
56ffb6146d Add example for WMTS source 2013-03-11 10:42:37 +01:00
Bruno Binet
877ce3adcf Add a WMTS source 2013-03-11 10:42:37 +01:00
Bruno Binet
6d78a8340a Add a WMTS tilegrid 2013-03-11 10:42:37 +01:00
Frederic Junod
35ef1c82e6 Add jquery 1.7.2 and adapt examples externs
Add jquery and update the externs for the examples (code from @bartvde).
The lib is saved into the repository to be able to run the examples
and the check-examples target offline.
2013-03-11 09:56:02 +01:00
Frederic Junod
97867738f8 Add new tracking and tracking_options property 2013-03-11 09:02:52 +01:00
Éric Lemoine
5afd61cce6 Merge pull request #339 from elemoine/exports
Export fixes
2013-03-11 00:32:39 -07:00
Éric Lemoine
56f86ae512 Fix SingleImageWMS exports/externs 2013-03-11 08:31:32 +01:00
Éric Lemoine
cee2725afd Fix Stamen exports/externs 2013-03-11 08:31:32 +01:00
Éric Lemoine
0459733883 Fix StaticImage exports/externs 2013-03-11 08:31:32 +01:00
Éric Lemoine
f1949191b1 Fix TiledWMS exports/externs 2013-03-11 08:31:31 +01:00
Éric Lemoine
8121fda6fb Fix TileJSON exports/externs 2013-03-11 08:31:03 +01:00
Éric Lemoine
5ad6ca3aa1 Fix BingMaps exports/externs 2013-03-11 08:31:03 +01:00
Tobias Bieniek
5d492a22fa test/polyline: Fixed linter problems 2013-03-10 21:13:48 +01:00
Tobias Bieniek
5333d00173 test/polyline: Added encodedFlatPoints to testing data variables
DRY...
2013-03-10 21:07:23 +01:00
Tobias Bieniek
f793b69602 test/polyline: Reset testing data before each test
.. instead of using slice()
2013-03-10 21:05:32 +01:00
Tobias Bieniek
4b8a9aaa8f test/polyline: Renamed flat_points variable to flatPoints 2013-03-10 20:59:15 +01:00
Tobias Bieniek
8a34eaa4a4 polyline: Removed extra space in encodeFloats() function 2013-03-10 20:46:29 +01:00
Tobias Bieniek
6f08122398 polyline: Used new *Deltas() functions in *FlatCoordinates() 2013-03-10 20:45:12 +01:00
Tobias Bieniek
aef15947c8 polyline: Added encode/decodeDeltas() functions 2013-03-10 20:44:34 +01:00
Tobias Bieniek
02707401a3 polyline: Added encode/decodeFloats() functions 2013-03-10 20:04:54 +01:00
Tobias Bieniek
cbdaf1035d polyline: Added encode/decodeSignedIntegers() functions 2013-03-10 19:05:14 +01:00
Tobias Bieniek
78278798bb polyline: Added encode/decodeUnsignedIntegers() functions 2013-03-10 18:48:49 +01:00
Tobias Bieniek
ce619871c2 test/polyline: Added two more test cases for unsigned integers
Again taken from the official documentation at Google.
2013-03-10 17:00:37 +01:00
Tobias Bieniek
680f3386ce test/polyline: Added more test cases from official documentation
.. and marked those tests as such. URL of the "Encoded Polyline Algorithm Format" page is https://developers.google.com/maps/documentation/utilities/polylinealgorithm
2013-03-10 16:42:51 +01:00
Tobias Bieniek
395942fe8c polyline: Only declare i variable once
Javascript only has function-wide scoping...
2013-03-10 16:33:44 +01:00
Tobias Bieniek
8bf6627354 polyline: Renamed variables to camelCase convention 2013-03-10 16:28:29 +01:00
Tobias Bieniek
76fc372a14 polyline: Added missing parenthesis for one-line statements 2013-03-10 16:24:30 +01:00
Tom Payne
505c607ccb Use snapCenterToPixel in DOM renderer 2013-03-10 16:14:15 +01:00
Tom Payne
bceb27f4bb Use snapCenterToPixel in WebGL renderer 2013-03-10 16:14:15 +01:00
Tom Payne
c01068642b Use snapCenterToPixel in Canvas renderer 2013-03-10 16:14:01 +01:00
Tom Payne
06463471e1 Add ol.renderer.Layer.snapCenterToPixel 2013-03-10 15:51:08 +01:00
Tom Payne
3a1fcdae0f Optimize ol.Extent.getForView2DAndSize 2013-03-10 15:51:08 +01:00
Tom Payne
08d3120f08 Use ol.Extent.getForView2DAndSize 2013-03-10 15:51:08 +01:00
Tom Payne
ed787ba79c Add ol.Extent.getForView2DAndSize 2013-03-10 15:51:08 +01:00
Tom Payne
e8b4a29254 Fix typo in canvas tiles example 2013-03-10 15:49:46 +01:00
Tobias Bieniek
ea227419a3 polyline: Added encode/decodeFlatCoordinates() functions 2013-03-10 01:25:59 +01:00
Tobias Bieniek
04d764f4f3 polyline: Added encode/decodeFloat() functions 2013-03-09 23:17:29 +01:00
Tobias Bieniek
e802cc3d56 polyline: Added decodeSigned/UnsignedInteger() functions 2013-03-09 22:40:07 +01:00
Tobias Bieniek
36923d6688 Added basic ol.parser.polyline module
This module will contain the low-level functions for Google's "Encoded
Polyline" algorithm.
2013-03-09 22:19:59 +01:00
Tom Payne
65907a6005 Add rotation example 2013-03-09 21:51:09 +01:00
Tom Payne
3910ec0dbb Fix typo in WebGL map renderer 2013-03-09 21:50:10 +01:00
Éric Lemoine
a138b5a5a3 Merge pull request #332 from Turbo87/uppercase
Renamed authors.txt, license.txt and readme.md to uppercase variants
2013-03-09 12:07:16 -08:00
Tobias Bieniek
4f8ffbf2ce Added notes that "./build.py test" requires plovr to be running 2013-03-09 20:05:31 +01:00
Tobias Bieniek
65397eb732 test/README: Updated "make test" to "./build.py test" 2013-03-09 20:00:18 +01:00
Tobias Bieniek
f35e4cd319 test: Renamed readme.md to README.md
.. and updated link in main README.md

(Github supports relative links now AFAIK)
2013-03-09 19:04:58 +01:00
Tobias Bieniek
34ec58a8ad LICENSE: Fixed reference to AUTHORS file 2013-03-09 19:02:05 +01:00
Tobias Bieniek
d708a32094 Converted AUTHORS and LICENSE files to Markdown
.txt files are rendered by Github as plain monospace text. Markdown files
however are rendered with a more readable font and formatting.
2013-03-09 19:00:25 +01:00
Tobias Bieniek
ed9c2eebad Renamed authors.txt, license.txt and readme.md to uppercase variants
This sets the text files apart from the rest of the code files and seems
to be the standard for most projects
2013-03-09 18:47:53 +01:00
Cédric Moullet
0bf9f9a0a7 Fix reference and title according to @erilem comments. 2013-03-09 13:16:56 +01:00
Tom Payne
25fd391edd Merge pull request #329 from twpayne/animation-clean-ups
Animation clean ups
2013-03-09 04:02:29 -08:00
Cédric Moullet
eb6630c3f7 Add single image WMS with custom projection example 2013-03-09 07:50:56 +01:00
Tom Payne
4a7a5fe220 Sort properties alphabetically 2013-03-09 02:38:52 +01:00
Tom Payne
194edc7f26 Sort functions alphabetically 2013-03-09 02:19:35 +01:00
Tom Payne
9d950525bb Default to easing inAndOut for all animations 2013-03-09 02:15:32 +01:00
Tom Payne
77bd279160 Use ol.easing instead of goog.fx.easing 2013-03-09 02:03:59 +01:00
Tom Payne
e12458b32e Expose all goog.fx.easing functions in the ol.easing namespace 2013-03-09 02:02:19 +01:00
Tom Payne
2d7f848223 Merge pull request #321 from twpayne/prettier-hue-saturation-example
Make hue/saturation example prettier
2013-03-08 16:46:24 -08:00
Tom Payne
3981141999 Merge pull request #134 from twpayne/keyboard-interactions
Keyboard Pan interaction should animate
2013-03-08 16:32:34 -08:00
Tom Payne
fe3b8d862d Correct center setting, thanks @elemoine 2013-03-09 01:31:14 +01:00
ahocevar
06de786b98 Adding information about jsdoc3 dependency 2013-03-08 19:19:14 +01:00
ahocevar
b971fc1aae Bringing back the style-rules example
Features are now created programmatically as
GeoJSONFeatureCollection.
2013-03-08 16:26:18 +01:00
ahocevar
389b8d14d7 Support GeoJSON as parsed object
With this change, we can programmatically create
GeoJSONFeatureCollection objects programmatically, without
reading a GeoJSON file.
2013-03-08 16:25:23 +01:00
Tom Payne
2354207b47 Make hue/saturation example prettier 2013-03-08 15:13:26 +01:00
Tom Payne
b729f969a7 Add EMPTY tile state instead of using null for empty tiles 2013-03-08 14:41:14 +01:00
Tom Payne
0a13344668 Merge pull request #320 from twpayne/follow-mouse-position
Prioritize tile loading around mouse position
2013-03-08 04:15:49 -08:00
Tim Schaub
7f62b26c80 New example style 2013-03-07 23:48:23 -07:00
Tim Schaub
ee75c4b90e Use new projection getter 2013-03-07 23:48:10 -07:00
Tim Schaub
895bc4e76c The addFeatures method will be added back later
This needs to be made to take advantage of the shared vertices.
2013-03-07 23:47:41 -07:00
Tim Schaub
85a1599a1a Removing the style rules example for now
The addFeatures method on layer is going to go away temporarily (so all feature adding will take advantage of shared vertices structures).  Later we can accept feature arrays in parseFeatures and rename the method back to addFeatures.
2013-03-07 23:32:56 -07:00
Tim Schaub
4422e3e73b Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-03-07 23:10:06 -07:00
Tim Schaub
4918106a22 Make shared vertices structures accessible 2013-03-07 23:09:23 -07:00
Tim Schaub
faee18bae1 Use fillColor and strokeColor instead of fillStyle and strokeStyle
The color names are more intuitive.  And if we want to support pattern strokes or fills, we'll need additional proerties to represent other pattern properties.
2013-03-07 22:51:14 -07:00
Tim Schaub
5ce114c1b6 Style in example 2013-03-07 22:29:00 -07:00
Tim Schaub
77355ca634 Optional polygon stroke or fill 2013-03-07 22:28:39 -07:00
Tim Schaub
f93bf2ad77 Avoid filling/stroking parts of multi-polygons twice 2013-03-07 21:39:34 -07:00
Tom Payne
d571ef5804 Prioritize tile loading around mouse position 2013-03-08 01:04:35 +01:00
Tom Payne
47f1b8cb0a Cope with rotation in keyboard pan 2013-03-07 20:13:38 +01:00
Tom Payne
cd37031456 Animate keyboard pan 2013-03-07 20:00:31 +01:00
Tom Payne
3d37ba7666 Add ol.View2D.pan 2013-03-07 20:00:31 +01:00
Tom Payne
d4a5bfa015 Avoid creating an unecessary object 2013-03-07 19:39:24 +01:00
Tom Payne
af0bf21e8d Configure keyboard pan with an options object 2013-03-07 19:32:51 +01:00
Tom Payne
c46f1425a0 Make keyboard zoom delta configurable 2013-03-07 19:24:00 +01:00
Tim Schaub
db4e62477d Nicer caps and joins
As mentioned in the TODOs, caps and joins should be user configurable on the symbolizers.
2013-03-07 10:37:48 -07:00
Tim Schaub
b28a1efec6 Export GeoJSON parser 2013-03-07 10:26:15 -07:00
ahocevar
5af71a488a No need to continue rendering when we need to defer 2013-03-07 18:13:22 +01:00
Tim Schaub
5752a69d6b Adding addFeatures back as an API method temporarily
Eventually, parseFeatures and addFeatures should be collapsed.
2013-03-07 10:09:19 -07:00
ahocevar
f4a16e7f57 Collect features before rendering to the sketch canvas
This avoids features being rendered multiple times when they
cross tile borders. Currently this makes the style-rules.html
example extremely slow. Fix for that to come in my next commit.
2013-03-07 16:57:22 +01:00
ahocevar
f0039ee460 Additional index dimension for RTree; use RTree again
The RTree can easily maintain an additional index dimension,
by passing a type with each added item. Now instead of
maintaining an RTree for each geometry type, we have a single
RTree with a type filter. With this change, using the RTree
finally speeds up rendering as expected.
2013-03-07 14:36:09 +01:00
Bart van den Eijnden
1f510d893f Merge pull request #282 from bartvde/wms1_0_0
add WMS GetCapabilities 1.0.0 parser (=r@elemoine)
2013-03-07 05:06:13 -08:00
Tom Payne
1deeaa437c Merge pull request #272 from twpayne/projection-get
allow people to specify projection as a string
2013-03-07 04:59:00 -08:00
Bart van den Eijnden
d56f2bc7aa make Travis happy by adding comment to the constant in the test 2013-03-07 13:57:51 +01:00
Bart van den Eijnden
0dab671072 add WMS 1.0.0 parsing to false by default 2013-03-07 13:53:26 +01:00
Éric Lemoine
abf4d6bf09 Merge pull request #310 from elemoine/wms
NumberFormatException with GeoServer WMS
2013-03-07 04:46:06 -08:00
Tom Payne
21d34f1cc8 Rename projection functions for a friendlier API
The following functions are renamed:

getTransform -> getTransformForProjections
getTransformFromCodes -> getTransform
transform -> transformWithProjections
transformWithCodes -> transform

With this change, the faster functions that avoid projection look-up
have longer names and are used internally, whereas the slower but
friendlier short name functions are available for users.
2013-03-07 13:39:40 +01:00
Éric Lemoine
b487275d5b Round image height and width for WMS 2013-03-07 13:37:48 +01:00
Tom Payne
874583656e Use strings rather than ol.projection.get in examples 2013-03-07 13:31:11 +01:00
Tom Payne
eaa17758bd Allow strings to be used wherever projections are needed 2013-03-07 13:29:40 +01:00
Tom Payne
afcbec469a Rename ol.projection.getFromCode to ol.projection.get 2013-03-07 13:29:39 +01:00
Éric Lemoine
d81d9d7411 Merge pull request #309 from elemoine/attributions
Fix js error when image source has no attributions
2013-03-07 04:28:22 -08:00
Tom Payne
6bcbd25e2f Merge pull request #295 from openlayers/refactor-examples
Refactor examples
2013-03-07 04:27:18 -08:00
Éric Lemoine
251e9a09fa Fix js error when image source has no attributions 2013-03-07 12:41:15 +01:00
Éric Lemoine
3c37e6da56 Make custom proj example use tile layers only 2013-03-07 12:36:09 +01:00
Éric Lemoine
02cbdde333 Add a single image WMS example 2013-03-07 12:29:13 +01:00
Éric Lemoine
d31fb7a0fd Merge pull request #303 from elemoine/tile
Tile loading stops after a while when there are multiple maps
2013-03-07 03:15:37 -08:00
Éric Lemoine
73d06442ec Merge pull request #302 from elemoine/debug
Hosted examples in debug mode
2013-03-07 03:15:09 -08:00
Éric Lemoine
71f06320f6 WMS example renamed to wms-tiled 2013-03-07 12:03:28 +01:00
Bruno Binet
35b6d805df Merge pull request #307 from bbinet/null-extent
Check for not null extent
2013-03-07 02:06:18 -08:00
Éric Lemoine
f55423d575 Register change listeners for loading tiles only
With this commit we register a change listener at a time when we are guaranteed that the listener will be called. In this was we don't need to remove listeners when the tile is dropped from the tile queue. And to avoid busy-polling between IDLE and LOADING we rely on the map to call requestRenderFrame when new tiles change to LOADING from IDLE.
2013-03-07 11:03:20 +01:00
Bruno Binet
41408c0909 Extent cannot be undefined here but it can be null
so we now use !goog.isNull(extent) instead of goog.isDef(extent)
2013-03-07 10:54:06 +01:00
Bruno Binet
129f2bbcb0 Merge pull request #305 from bbinet/check-isglobal
Do not wrap dateline if projection.isGlobal() is false
2013-03-07 01:42:18 -08:00
Éric Lemoine
7fabff5ffa Revert "Remove listeners when dropping tiles"
This reverts commit fd6aaff2f5.
2013-03-07 10:41:23 +01:00
Éric Lemoine
bbc8249e28 Check the examples in raw mode as well 2013-03-07 10:33:40 +01:00
Éric Lemoine
306447fac7 Update readme.md 2013-03-07 10:30:47 +01:00
Éric Lemoine
757401313b Extent hosted loader to support debug mode 2013-03-07 10:30:47 +01:00
Frederic Junod
feb03b8cda Change opacity step value in side-by-side example
Avoid rounding issue (0.1 in binary format). fixes #299
2013-03-07 10:14:39 +01:00
Tim Schaub
f961930823 Render countries from GeoJSON
This reveals a number of issues that still need to be addressed.
2013-03-06 19:24:53 -07:00
Tom Payne
d4b58d489f Correct description in side-by-side example 2013-03-07 03:15:19 +01:00
Tim Schaub
84527c4b56 Disable bbox filtering for now
The RTree doesn't appear to be performing properly
2013-03-06 19:07:26 -07:00
Tim Schaub
2e4dc430e9 Render multi-part geometries
As noted in the comment, filtering/rendering once per geometry type will be replaced by rendering once per symbolizer type.
2013-03-06 19:06:41 -07:00
Tim Schaub
00fa7ff3a9 Listen for layer changes and expire tiles
We need a more flexible event system.  We could have a VectorLayerEvent type and dispatch 'featuresadded' here.  But listeners want features typically and perhaps extent.  This won't be true for all vector layer events (suggesting a more specific VectorFeatureEvent type or something).
2013-03-06 19:05:35 -07:00
Tim Schaub
d7c547f736 Method for parsing features
Shared structures are still per geometry type.  Need to be made per symbolizer type.
2013-03-06 19:02:21 -07:00
Tim Schaub
7c4c3c547c Draw multi-part geometries
Polygons still need holes.
2013-03-06 19:01:16 -07:00
Tom Payne
3c701067b3 Remove animations from side-by-side example 2013-03-07 02:58:00 +01:00
Tom Payne
674eb9b396 Add animation example 2013-03-07 02:56:28 +01:00
Bruno Binet
48c84aaf69 Do not wrap dateline if projection.isGlobal() is false 2013-03-07 02:07:00 +01:00
Tom Payne
50cb6294ee Remove brightness/contrast from side-by-side example 2013-03-07 01:56:41 +01:00
Tom Payne
bea6b644af Add brightness/contrast example 2013-03-07 01:56:41 +01:00
Tom Payne
8ab00689b2 Remove hue/saturation from side-by-side example 2013-03-07 01:56:41 +01:00
Tom Payne
f0466ef9c7 Add hue/saturation example 2013-03-07 01:56:41 +01:00
Bruno Binet
7f9e327a65 Merge pull request #304 from bbinet/projection-improvements
Some projection improvements
2013-03-06 16:53:14 -08:00
Bruno Binet
1e050fe25f Add global=true for both EPSG:4326 and EPSG:3857 2013-03-07 01:36:42 +01:00
Bruno Binet
4415f8ac74 Add test for ol.projection.configureProj4jsProjection 2013-03-07 01:36:41 +01:00
Bruno Binet
b6d57894b4 Add configureProj4jsProjection function
so that we can add extent and global parameter to proj4js projections.
And remove setExtent method which is not relevant.
2013-03-07 01:36:41 +01:00
Bruno Binet
0e53a3f3c9 ol.Proj4jsProjection_ now takes a single argument 2013-03-07 01:36:40 +01:00
Bruno Binet
9d88273161 ol.Projection now takes a single argument
which is called ol.ProjectionOptions.
2013-03-07 01:36:39 +01:00
Bruno Binet
8dd3093f4c Add information on wether the projection is global
so that we know if we can wrap the dateline.
2013-03-07 01:36:39 +01:00
Tom Payne
f942333f48 Add MapQuest example 2013-03-07 01:18:32 +01:00
Tom Payne
31b1f8b5b0 Add missing export 2013-03-06 21:34:18 +01:00
Tom Payne
a686a0a893 Remove two-layers example 2013-03-06 21:29:23 +01:00
Tom Payne
58323bb8fc Add export JPEG example 2013-03-06 21:28:59 +01:00
Tim Schaub
6cddd47d54 Correcting title for example list (see #296) 2013-03-06 15:24:50 -05:00
Tom Payne
479e7fc8dd Make Stamen example prettier 2013-03-06 21:08:06 +01:00
ahocevar
100c8a1cf4 Adding gutter when requesting features for a tile
By doing so, we avoid features being cut off when the symbolizer
causes it to be rendered across tile borders.
2013-03-06 21:06:21 +01:00
ahocevar
2af82abcda Adding missing export 2013-03-06 21:03:57 +01:00
Tom Payne
b07c1cce1f Add mouse position example 2013-03-06 20:57:48 +01:00
Tom Payne
fe7f112c41 Remove mouse position control from side-by-side example 2013-03-06 20:57:48 +01:00
Tom Payne
05c21e6f1c Add scale line example 2013-03-06 20:46:53 +01:00
Tom Payne
09b75f8044 Don't include scale line in default controls 2013-03-06 20:46:52 +01:00
Tom Payne
6dab2cd466 Remove scale line from full screen example 2013-03-06 20:46:52 +01:00
Tom Payne
99870acd19 Add TileJSON example 2013-03-06 20:46:52 +01:00
Tom Payne
3e7cd5fffb Add Bing Maps example 2013-03-06 20:46:52 +01:00
Éric Lemoine
74b8fea679 Extent hostexamples target to copy ol and closure 2013-03-06 20:32:06 +01:00
Tom Payne
818b4a9d5e Remove Bing Maps from two-layers example 2013-03-06 20:21:40 +01:00
Tom Payne
d60a6e943b Don't use ol.Collection in simple example 2013-03-06 20:21:39 +01:00
Tom Payne
65e003db50 Merge pull request #274 from twpayne/map-layers-api
ol.Collection versus array
2013-03-06 10:48:48 -08:00
Éric Lemoine
8ce86ac2c9 Add depswriter scripts
Copied from http://closure-library.googlecode.com/git/closure/bin/build/
2013-03-06 19:16:03 +01:00
Bruno Binet
a10cae6117 Merge pull request #301 from bbinet/projection-setextent
Add a setExtent method to ol.Projection
2013-03-06 09:46:07 -08:00
Tom Payne
6c58da95e6 Merge pull request #300 from twpayne/stamen-unique-attribution
Use a single, shared attribution for Stamen sources
2013-03-06 09:27:44 -08:00
Tom Payne
ad6cb91b73 Merge pull request #296 from fredj/bootstrap
Port example list to Bootstrap
2013-03-06 08:56:43 -08:00
Bruno Binet
93ae4256eb Add a setExtent method to ol.Projection 2013-03-06 17:53:51 +01:00
Tom Payne
e027f9771e Use a single, shared attribution for Stamen sources
This ensures that the attribution only appears once, even if multiple
Stamen layers are used in the same map.
2013-03-06 17:53:33 +01:00
Bruno Binet
d1762a06f8 Merge pull request #290 from bbinet/projection_stuff
Add a getMetersPerUnit instance method to ol.Projection class
2013-03-06 08:50:47 -08:00
Frederic Junod
4c50b8ff31 Add tags in full screen example
Used to generate example-list.html
2013-03-06 17:31:48 +01:00
Frederic Junod
11f338f9fe Fit map to projection extent in full screen example
see: 5b0af9152a
2013-03-06 17:25:59 +01:00
Tom Payne
c48e281c68 Add ol.Map.removeLayer 2013-03-06 17:17:32 +01:00
Frederic Junod
aacee357c0 Port example list to Bootstrap 2013-03-06 17:08:34 +01:00
Tom Payne
fcbd758f48 Add ol.Map.addLayer 2013-03-06 17:00:17 +01:00
Tom Payne
441092dad6 Don't use ol.Collection in examples 2013-03-06 17:00:16 +01:00
Tom Payne
61982646ba Allow layers to be passed as an array when creating a map 2013-03-06 16:59:09 +01:00
Tom Payne
388eac3838 Merge pull request #293 from twpayne/fix-293
Build error
2013-03-06 07:56:23 -08:00
Tom Payne
61552e6664 Merge pull request #294 from twpayne/collection
Collection improvements
2013-03-06 07:49:53 -08:00
Frédéric Junod
d60491093b Merge pull request #291 from openlayers/bootstrap
Use Bootstrap for examples
2013-03-06 07:28:17 -08:00
Tom Payne
220beb5177 Simple and whitespace builds use internal, not external, source 2013-03-06 16:00:15 +01:00
Tom Payne
3e7c913c44 Add ol.Collection.remove 2013-03-06 15:53:11 +01:00
Tom Payne
0a38f2f7a7 Don't export ol.Collection.getArray 2013-03-06 15:50:07 +01:00
Tom Payne
905a0059db Remove unused insert_at, set_at, and remove_at events 2013-03-06 15:50:03 +01:00
Frederic Junod
eab160de67 Add github and twitter links in examples 2013-03-06 15:20:25 +01:00
Frederic Junod
2b238c68c7 Add Font Awesome 3.0.2 2013-03-06 15:20:25 +01:00
Frederic Junod
e4863f3ce8 Add missing div close tag 2013-03-06 15:20:24 +01:00
Frederic Junod
6113ca2c59 Port full-screen example to Bootstrap 2013-03-06 15:20:24 +01:00
Frederic Junod
a8ec0c95a0 Fix hostexamples target
Add missing bootstrap dir and examples.css
2013-03-06 15:19:47 +01:00
Frederic Junod
0007ec95de Port stamen example to Bootstrap 2013-03-06 15:19:47 +01:00
Tom Payne
d8a73d12ed Fix navbar link, thanks @fredj 2013-03-06 15:19:47 +01:00
Tom Payne
3b9d500818 Don't store templates in map div 2013-03-06 15:19:47 +01:00
Tom Payne
3491b55fb2 Add missing closing tag 2013-03-06 15:19:47 +01:00
Tom Payne
bcea43dcd6 Don't lint Bootstrap JavaScript 2013-03-06 15:19:47 +01:00
Tom Payne
fa448951d9 Add simple example 2013-03-06 15:19:47 +01:00
Tom Payne
c87aaa3eb1 Port WMS example to Bootstrap 2013-03-06 15:19:47 +01:00
Tom Payne
80da379d60 Port WMS custom projection example to Bootstrap 2013-03-06 15:19:47 +01:00
Tom Payne
ca3f6e0fdf Port WMS capabilities example to Bootstrap 2013-03-06 15:19:47 +01:00
Tom Payne
6af6e355f9 Port two layers example to Bootstrap 2013-03-06 15:19:47 +01:00
Tom Payne
2ca53da9f2 Port side-by-side example to Bootstrap 2013-03-06 15:19:47 +01:00
Tom Payne
f1af80189f Port EPSG:4326 example to Bootstrap 2013-03-06 15:19:47 +01:00
Tom Payne
34c6652ed6 Port canvas tiles example to Bootstrap 2013-03-06 15:19:47 +01:00
Tom Payne
d20aa69f5f Port anchored elements example to Bootstrap 2013-03-06 15:19:47 +01:00
Tom Payne
2d454c429a Add examples.css 2013-03-06 15:19:47 +01:00
Tom Payne
a96fa30e97 Add Bootstrap 2.3.1 2013-03-06 15:19:47 +01:00
Tom Payne
3a7c4bd3bc Merge pull request #273 from twpayne/controls-api
reconsider the way we specify controls on the map
2013-03-06 05:59:31 -08:00
Tom Payne
38eaa9cfb2 Use an array to specify additional interactions 2013-03-06 13:19:50 +01:00
Tom Payne
363cb87e1a Use an array to specify additional controls 2013-03-06 13:19:34 +01:00
Tom Payne
23f0097517 Add ol.Collection.extend 2013-03-06 13:18:34 +01:00
Tom Payne
c9cce57895 Add comment about ugly typecast 2013-03-06 13:06:35 +01:00
Frédéric Junod
c54f38f4c0 Merge pull request #287 from fredj/mapsize
Use goog.style.getSize to compute the map size.
2013-03-06 03:59:51 -08:00
ahocevar
2147674e2f Adding exports for icon and feature 2013-03-06 12:49:06 +01:00
Tom Payne
671ee79c74 Add ol.interaction.defaults 2013-03-06 12:36:49 +01:00
Tom Payne
a94eadf402 Port examples to ol.control.defaults 2013-03-06 12:36:49 +01:00
Tom Payne
8ae009d401 Add ol.control.defaults 2013-03-06 12:36:48 +01:00
ahocevar
345bb55f98 Respect width and height from symbolizer 2013-03-06 12:29:20 +01:00
Bruno Binet
1ff3c79ff6 Use correct value to convert from foot to meters
(was using value for converting to inches).
Thanks @twpayne
2013-03-06 12:26:30 +01:00
Bruno Binet
f4aa08ee90 Use ol.sphere.NORMAL.radius instead of 6378000
to be consistent.
2013-03-06 12:18:37 +01:00
Tom Payne
48852aa3ea Merge pull request #284 from twpayne/full-screen-fit-projection-extent
Fit map to projection extent in full screen example
2013-03-06 02:50:46 -08:00
ahocevar
6ee754abb6 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-03-06 11:20:40 +01:00
Bruno Binet
097d59c41a Add test for ol.Projection getMetersPerUnit method 2013-03-06 10:33:03 +01:00
Bruno Binet
1803e7b28d Add getMetersPerUnit instance method to ol.Projection 2013-03-06 10:32:45 +01:00
Bruno Binet
1f30f693b6 Merge pull request #288 from bbinet/projection_stuff
Find proj4js projection even if code is different than srs.
2013-03-06 01:06:38 -08:00
Bruno Binet
bb1cf45c0a Add Proj4js.Proj.srsCode property to Proj4js externs 2013-03-06 02:38:03 +01:00
Tim Schaub
060edb2070 Merge branch 'vector' of github.com:openlayers/ol3 into vector
Conflicts:
	src/ol/style/shape.js
2013-03-06 02:28:33 +01:00
Tim Schaub
ac10bb6ca5 Enforce that either stroke or fill is provided 2013-03-06 02:20:11 +01:00
Tim Schaub
c0c8faaf9f Allow literal from symbolizer without feature 2013-03-06 02:20:11 +01:00
ahocevar
95f3fe535a No projection configuration needed on the layer 2013-03-06 02:20:11 +01:00
Éric Lemoine
5d99ead2b7 View2D NoConstraint methods renamed 2013-03-06 02:20:10 +01:00
Tom Payne
ba78812796 Improve comment parsing when checking for requires 2013-03-06 02:20:10 +01:00
Éric Lemoine
a0ba80bcbb Check the examples against whitespace build first
This is to produce stack traces that are easier to understand when an example fails to load.
2013-03-06 02:20:10 +01:00
Bruno Binet
382022bdb5 Add defaultNamespaceURI and errorProperty properties for WMTS.
Thanks @bartvde.
2013-03-06 02:20:10 +01:00
Éric Lemoine
221c8077e0 Make hostexamples target more robust 2013-03-06 02:20:10 +01:00
ahocevar
2ee19f699a Moving VERSION into params 2013-03-06 02:20:10 +01:00
ahocevar
c1f3a6cc54 WMS GetMap request parameters shall be params
To avoid surprises, we configure everything that is a WMS GetMap
request parameter in the params object, and not as direct
configuration option. This affects the VERSION and TRANSPARENT
params.
2013-03-06 02:20:09 +01:00
ahocevar
a912d48b59 Do not use tiledWMSOptions in closure function
See #269.
2013-03-06 02:20:09 +01:00
Éric Lemoine
5644c27d9e Animate double click/tap zoom 2013-03-06 02:20:09 +01:00
Éric Lemoine
066a81a88a Animate zoom after pinch 2013-03-06 02:20:09 +01:00
Éric Lemoine
a4c47edd9d 2DView refactoring
This refactoring makes animating zoom, as opposed to zoomByDelta, possible.
2013-03-06 02:20:09 +01:00
Éric Lemoine
b9a286fb7a Animate rotation when releasing mouse or fingers 2013-03-06 02:20:08 +01:00
Éric Lemoine
33eb13d73b Make animating rotation possible 2013-03-06 02:20:08 +01:00
Éric Lemoine
de8db176ab Do not apply rotation constraint while rotating
This is on par to what the TouchRotate interaction does.
2013-03-06 02:20:08 +01:00
Éric Lemoine
f20cf83c94 Add a snapToZero rotation constraint 2013-03-06 02:20:08 +01:00
Tom Payne
83225916c1 Add Stamen example 2013-03-06 02:20:07 +01:00
Tom Payne
78780fa095 Correct Stamen source 2013-03-06 02:20:07 +01:00
Éric Lemoine
cae2340343 Make TouchRotate interaction use rotateNoConstraint 2013-03-06 02:20:07 +01:00
Éric Lemoine
303520a5e0 Add a rotateNoConstraint View2D method 2013-03-06 02:20:06 +01:00
Éric Lemoine
2c551b0445 Change View2D function names
Also make the TouchZoom interaction no longer use a private View2D function.
2013-03-06 02:20:06 +01:00
Éric Lemoine
ca31cf590c Debounce mousewheel zoom events 2013-03-06 02:20:06 +01:00
Éric Lemoine
673ea079f8 MouseWheelZoom interaction animates zoom 2013-03-06 02:20:06 +01:00
Éric Lemoine
be5967a948 View2D zoom may animate pan 2013-03-06 02:20:06 +01:00
Éric Lemoine
29d3878ea3 zoomFactor defaults to 2 2013-03-06 02:20:06 +01:00
Bruno Binet
f1b72a10bc Tests for cached proj4js projections. 2013-03-06 01:59:35 +01:00
ahocevar
ab19d255c7 Rendering icons from external graphic urls 2013-03-06 01:57:08 +01:00
Bruno Binet
7d1db48836 Find proj4js projection even if code is different than srs. 2013-03-06 01:57:06 +01:00
Tom Payne
1ae20641ef Make mouse position control options argument optional 2013-03-05 18:58:29 +01:00
Tom Payne
f581390655 Make zoom control options argument optional 2013-03-05 18:56:41 +01:00
Tom Payne
c521f92408 Make attribution control options argument optional 2013-03-05 18:56:34 +01:00
Frederic Junod
de168e0fb0 Use goog.style.getSize to compute the map size.
This allows to initialize hidden map (display: none).
Otherwise the size is 0 (clientWidth == clientHeight == 0)
2013-03-05 18:48:02 +01:00
Éric Lemoine
59271ae2d8 Fix typo (thanks @bbinet) 2013-03-05 18:35:21 +01:00
Tim Schaub
4f2523fcf2 Vector related exports 2013-03-05 18:25:07 +01:00
Tim Schaub
9a0e7a96fe Moving the feature management to the layer
The source will be responsible for fetching vector data.
2013-03-05 18:25:07 +01:00
Tim Schaub
e1c3faa53e Vector related exports 2013-03-05 18:13:10 +01:00
Éric Lemoine
2924bf088d Merge pull request #286 from elemoine/droppedtile
Fix tile change event handling
2013-03-05 09:07:53 -08:00
Éric Lemoine
a4afcd533f Add FIXME 2013-03-05 18:06:57 +01:00
Tom Payne
8a66095a4a Export some ol.View2D functions 2013-03-05 17:03:33 +01:00
Éric Lemoine
4e758f87ae Do not register multiple listeners on same tile 2013-03-05 17:01:34 +01:00
Éric Lemoine
fd6aaff2f5 Remove listeners when dropping tiles 2013-03-05 17:01:34 +01:00
Tom Payne
5b0af9152a Fit map to projection extent in full screen example 2013-03-05 16:49:36 +01:00
Marc Jansen
5b258ca23f Merge pull request #283 from marcjansen/test-output
Nicer test output for headless tests
2013-03-05 07:07:25 -08:00
Marc Jansen
aed6e4c1e3 JSHintified, thanks @elemoine. 2013-03-05 16:05:07 +01:00
ahocevar
d8b6d17105 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-03-05 15:48:57 +01:00
Marc Jansen
2c1fa61078 Nicer output of console runner. 2013-03-05 15:30:01 +01:00
Marc Jansen
6600435378 Remove dangling whitespace. 2013-03-05 15:29:47 +01:00
ahocevar
df4f2c4c0a No projection configuration needed on the layer 2013-03-05 15:25:47 +01:00
Bart van den Eijnden
aa4c4ddc48 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-03-05 14:20:32 +01:00
Bart van den Eijnden
dfcdf75449 add WMS 1.0.0 parser 2013-03-05 13:26:04 +01:00
Éric Lemoine
98f9f44877 Merge pull request #261 from elemoine/zoomfactor
Change default zoom delta and animate mousewheel zoom
2013-03-05 03:52:38 -08:00
Éric Lemoine
b884f2f25d View2D NoConstraint methods renamed 2013-03-05 12:51:03 +01:00
Tim Schaub
12bee3178e Moving the feature management to the layer
The source will be responsible for fetching vector data.
2013-03-05 12:46:55 +01:00
Tom Payne
3b29ec610b Merge pull request #280 from twpayne/check-requires-in-comments-fixes
Improve comment parsing when checking for requires
2013-03-05 03:05:52 -08:00
Tom Payne
254a96e036 Improve comment parsing when checking for requires 2013-03-05 11:51:53 +01:00
Tim Schaub
a968a5ca66 The shared vertices structure now works with integer arrays only
Previously, a lookup object containing start indexes was also used.  This allowed us to remove arrays of vertices and properly update the start indexes for remaining coordinate values.  In order to provide callers with stable identifiers and to work with arrays of integers alone, we cannot support a remove method.  I think this is worth revisiting.  Even if the array length cannot be changed in WebGL, we don't need to also impose the restriction outside.  Instead, the WebGL renderer could be notified when array sizes change and update itself accordingly.  I think there is more value in providing geometries with stable identifiers.

This common structure is used to store vertices for all geometry types.  A slight optimization could be made by creating yet another structure to store point vertices - since these don't need to have a counts array (always 1).  Creating a new structure would mean saving memory at the expense of more lib code to transport.  The coordinate value lookups are not negatively impacted by using the same structure for points and higher order geometries.  Since the first change above goes against my instincts, I'm not making this second change (to add another structure for shared point vertices).
2013-03-05 11:47:42 +01:00
Éric Lemoine
403666d875 Merge pull request #279 from elemoine/check-examples
Check the examples against whitespace build first
2013-03-05 02:39:58 -08:00
Éric Lemoine
82c2fc19a1 Check the examples against whitespace build first
This is to produce stack traces that are easier to understand when an example fails to load.
2013-03-05 11:37:30 +01:00
Éric Lemoine
9a64435a65 Merge pull request #275 from elemoine/275
Files in gh-pages examples
2013-03-05 02:31:39 -08:00
Bruno Binet
ade4213dd8 Merge pull request #277 from bbinet/fix-wmts-parser
Add defaultNamespaceURI and errorProperty properties for WMTS.
2013-03-05 02:29:23 -08:00
Bruno Binet
8b3cfda963 Add defaultNamespaceURI and errorProperty properties for WMTS.
Thanks @bartvde.
2013-03-05 11:26:46 +01:00
Éric Lemoine
aa9275b57f Make hostexamples target more robust 2013-03-05 11:26:22 +01:00
Tom Payne
68919b5ee3 Merge pull request #267 from twpayne/stamen-fixes
Stamen fixes
2013-03-05 02:14:21 -08:00
ahocevar
8fd25749c0 Merge pull request #276 from ahocevar/wms-params
WMS GetMap request parameters shall be params. r=@elemoine
2013-03-05 02:13:37 -08:00
ahocevar
19f8692672 Moving VERSION into params 2013-03-05 11:11:41 +01:00
Tim Schaub
54d8d45fc9 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-03-05 10:58:27 +01:00
ahocevar
4bb521db65 WMS GetMap request parameters shall be params
To avoid surprises, we configure everything that is a WMS GetMap
request parameter in the params object, and not as direct
configuration option. This affects the VERSION and TRANSPARENT
params.
2013-03-05 10:54:33 +01:00
ahocevar
2676050d54 Do not use tiledWMSOptions in closure function
See #269.
2013-03-05 10:50:46 +01:00
Tom Payne
985b4f57c1 Merge pull request #260 from twpayne/projections-in-feet
Projections in feet
2013-03-05 01:17:56 -08:00
Frédéric Junod
5c78fff519 Merge pull request #270 from fredj/pretty-print-build
Pretty print the whitespace build
2013-03-05 01:08:16 -08:00
Éric Lemoine
29e610b9f3 Animate double click/tap zoom 2013-03-05 10:08:01 +01:00
Éric Lemoine
e598e4b9b2 Animate zoom after pinch 2013-03-05 10:08:01 +01:00
Éric Lemoine
43b1e11e7a 2DView refactoring
This refactoring makes animating zoom, as opposed to zoomByDelta, possible.
2013-03-05 10:08:01 +01:00
Éric Lemoine
d42d88c198 Animate rotation when releasing mouse or fingers 2013-03-05 10:08:00 +01:00
Éric Lemoine
c431acacca Make animating rotation possible 2013-03-05 10:08:00 +01:00
Éric Lemoine
2f611529dd Do not apply rotation constraint while rotating
This is on par to what the TouchRotate interaction does.
2013-03-05 10:08:00 +01:00
Éric Lemoine
1776d80cb9 Add a snapToZero rotation constraint 2013-03-05 10:08:00 +01:00
Tom Payne
6f2d15bb5f Add Stamen example 2013-03-05 10:05:22 +01:00
Tom Payne
6d6188ea79 Correct Stamen source 2013-03-05 10:05:22 +01:00
Bart van den Eijnden
d587d45a09 Merge pull request #271 from bartvde/epsg4326example
remove unused code from epsg-4326 example
2013-03-05 01:00:00 -08:00
Éric Lemoine
7d6d82519b Make TouchRotate interaction use rotateNoConstraint 2013-03-05 09:59:31 +01:00
Éric Lemoine
178c68868b Add a rotateNoConstraint View2D method 2013-03-05 09:59:31 +01:00
Éric Lemoine
03ae41a68c Change View2D function names
Also make the TouchZoom interaction no longer use a private View2D function.
2013-03-05 09:59:31 +01:00
Éric Lemoine
faef495cfd Debounce mousewheel zoom events 2013-03-05 09:59:31 +01:00
Éric Lemoine
4d486601f9 MouseWheelZoom interaction animates zoom 2013-03-05 09:59:31 +01:00
Éric Lemoine
3ba9a4afd4 View2D zoom may animate pan 2013-03-05 09:59:30 +01:00
Éric Lemoine
57a86353cd zoomFactor defaults to 2 2013-03-05 09:59:30 +01:00
Bart van den Eijnden
68c1651cc5 remove unused code from epsg-4326 example 2013-03-05 09:54:35 +01:00
ahocevar
3803275a1e Merge pull request #269 from ahocevar/wms-extent
Fixing extent check for undefined extents. r=@elemoine
2013-03-05 00:54:12 -08:00
Frederic Junod
9d1d59d54a Pretty print the whitespace build 2013-03-05 09:53:05 +01:00
ahocevar
19aeb04141 Fixing extent check for undefined extents.
Thanks @marcjansen for spotting this. To make the epsg-4326
example work, I also had to change the WMS version to 1.1.1.
2013-03-05 09:47:52 +01:00
ahocevar
3526244e0c Merge pull request #268 from ahocevar/wms-improvements
Support tile sources without configured projection. r=@twpayne
2013-03-04 16:48:09 -08:00
ahocevar
23c09abd3a Calling getTileSize with z argument
Thanks for catching this @twpayne.
2013-03-05 01:47:28 +01:00
ahocevar
66b790294d Merge branch 'master' of github.com:openlayers/ol3 into wms-improvements
Conflicts:
	src/ol/source/tiledwmssource.js
	test/spec/ol/tileurlfunction.test.js
2013-03-05 00:55:52 +01:00
ahocevar
586f393492 Support tile sources without configured projection
This change adds a lot of flexibility to working with tile
layers: Sources where the server projection or tile grid do not
matter can now be constructed without specifying a projection or
tile grid.

The tileUrlFunction/imageUrlFunction now also creates updated
URLs when the params of the layer change, so things like
mergeNewParams in ol2 will be possible.

A nice side effect of this whole change is that there is no more
duplicated code between tiled and single image WMS layers.

While I was at it, I also fixed a WMS 1.1.1 axis order issue
and incorrect STYLES params (STYLES=& instead of STYLES&).
2013-03-05 00:46:58 +01:00
Tom Payne
1bac674eca Merge pull request #263 from twpayne/canvas-renderer-optimizations
Canvas renderer optimizations
2013-03-04 15:21:38 -08:00
Tim Schaub
1d6cd1bd1b Lint-free tests 2013-03-04 21:30:23 +01:00
Tim Schaub
dc19948a85 Get tile size for zoom level (see #258) 2013-03-04 21:30:01 +01:00
Tom Payne
61acce98e3 Merge pull request #266 from twpayne/lint-cleanups
Lint cleanups
2013-03-04 12:07:52 -08:00
Tom Payne
a937083d10 Don't redraw already rendered tiles 2013-03-04 21:07:17 +01:00
Tom Payne
fb668a7fc6 Add opaque flag to ol.source.TileSource 2013-03-04 21:07:17 +01:00
Tim Schaub
c29fabebef Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-03-04 21:06:13 +01:00
Tim Schaub
cae925ad1f Correct spelling (thanks @fredj) 2013-03-04 21:04:59 +01:00
Tom Payne
4eebe5aaf2 Merge spec and src lint targets 2013-03-04 20:51:27 +01:00
Tom Payne
f6fe7bd36c Make spec indentation pass strict mode 2013-03-04 20:47:20 +01:00
Tom Payne
9b122815ce Lint specs with strict mode 2013-03-04 20:46:39 +01:00
Tom Payne
2741daa977 Merge pull request #265 from twpayne/check-requires-in-specs
Check requires in specs
2013-03-04 11:31:37 -08:00
Tim Schaub
8c8ddce290 GeoJSON parser implements StringFeatureParser 2013-03-04 20:31:01 +01:00
Tim Schaub
9c8ec42713 Feature parser interfaces
Parsers that read features from strings, objects, or dom elements should implement the right interface.  Among the read options is a callback that gets called after feature construction and before geometry construction.  This callback is called with the feature and the geometry type and returns a shared vertices structure.  The geometry is then constructed with this shared vertices structure before being added to the feature.
2013-03-04 20:29:42 +01:00
Tim Schaub
9edf63fdb8 Proper bounds 2013-03-04 20:25:18 +01:00
Tom Payne
3f933e01bd Merge pull request #264 from twpayne/webgl-underscores
Rename WebGL variables to match CSS shaders specification
2013-03-04 11:03:21 -08:00
Tom Payne
df5f74b3c0 Add missing requires to specs 2013-03-04 20:02:55 +01:00
Tom Payne
e776371f54 Check for requires in specs 2013-03-04 20:02:28 +01:00
Tom Payne
14e76b3a11 Don't assume that goog.requires are always first 2013-03-04 20:02:16 +01:00
Tom Payne
08dbeed23f Rename WebGL variables to match CSS shaders specification
See https://dvcs.w3.org/hg/FXTF/raw-file/tip/filters/index.htm
2013-03-04 19:45:43 +01:00
Tim Schaub
978527f880 Accept missing properties in symbolizer constructors
Still need to have some discussion about when to apply defaults.
2013-03-04 19:31:11 +01:00
Frédéric Junod
ad17c2ba90 Merge pull request #250 from fredj/BingMapsStyle
Invalid ol.BingMapsStyle
2013-03-04 10:04:29 -08:00
Tim Schaub
fae79dbc0f Fewer function calls during bounds calculation 2013-03-04 18:55:20 +01:00
Tom Payne
44e3e228eb Add canvas map to two layers demo 2013-03-04 18:45:24 +01:00
Tim Schaub
0b05432faa Vector source isn't a tile source 2013-03-04 18:43:46 +01:00
Tim Schaub
0558cfa3ac Add externs for GeoJSON support 2013-03-04 18:41:04 +01:00
Bruno Binet
874481cae5 Merge pull request #262 from bbinet/wmtsparser-resourceurl
Rework the structure of the WMTS resourceUrls property
2013-03-04 08:34:10 -08:00
Bruno Binet
80509a6a62 Fix tests relative to the WMTS resourceUrl(s) object 2013-03-04 17:16:49 +01:00
Bruno Binet
4baf397f77 Rework the structure of the resourceUrls object
and remove duplicated resourceUrl object.
2013-03-04 17:14:16 +01:00
Frederic Junod
eec1aec0e6 Remove ol.BingMapsStyle 2013-03-04 15:14:22 +01:00
Tom Payne
b9a9e84c1b Handle projections in feet in scale line control 2013-03-04 10:40:01 +01:00
Tom Payne
87d6208403 Add international feet to projection units 2013-03-04 10:39:52 +01:00
Tom Payne
06bb6e19f1 Merge pull request #215 from twpayne/scaleline-control
ScaleLine control
2013-03-04 01:27:33 -08:00
Éric Lemoine
2238c9bd6a Update readme.md 2013-03-04 10:15:31 +01:00
Éric Lemoine
b31d5cdb4a Update readme.md 2013-03-04 10:07:00 +01:00
Tom Payne
c35d07d481 Rename minimumWidth to minWidth 2013-03-04 09:58:09 +01:00
Frédéric Junod
cad215e0cc Merge pull request #230 from fredj/touch-navigation
Touch navigation issues
2013-03-04 00:42:59 -08:00
Bruno Binet
cedba8cd60 Merge pull request #258 from bbinet/tilegrid-tilesizes
Add support for multiple tileSizes in the tilegrid
2013-03-03 22:31:33 -08:00
Bruno Binet
07e0fc3a20 Fix tileSize in the canvastilelayerrenderer. 2013-03-04 07:30:33 +01:00
Tom Payne
fd1d2f6aeb Merge pull request #259 from twpayne/more-in-place-transforms
Use more in-place transforms where possible
2013-03-03 15:47:58 -08:00
Tom Payne
f3d01dcbd3 Add scale line to examples 2013-03-04 00:43:38 +01:00
Tom Payne
b663fd69f1 Add scale line control options to map options 2013-03-04 00:43:37 +01:00
Tom Payne
8c2b01948b Add ScaleLine control 2013-03-04 00:43:37 +01:00
Tom Payne
10f1755ad4 Merge pull request #252 from twpayne/point-resolution
Point resolution
2013-03-03 15:36:08 -08:00
Tom Payne
5c6821ce71 Use more in-place transforms where possible 2013-03-04 00:31:36 +01:00
Tom Payne
a8760108d4 Estimate point resolution for Proj4js projections 2013-03-04 00:25:42 +01:00
Tom Payne
343768df6a Implement getPointResolution for EPSG:4326 2013-03-04 00:12:51 +01:00
Tom Payne
98d7391024 Implement getPointResolution for EPSG:3587 2013-03-04 00:12:51 +01:00
Tom Payne
d3e49d0a19 Add ol.Projection.getPointResolution 2013-03-04 00:12:51 +01:00
Tom Payne
e6f08df72c Add the normal sphere 2013-03-04 00:12:51 +01:00
Tom Payne
684ea35673 Add sphere with radius equal to the semi-major axis of the WGS84 ellipsoid 2013-03-04 00:12:51 +01:00
Éric Lemoine
85db5273be Merge pull request #257 from elemoine/verify-examples
Verify hosted examples at precommit time
2013-03-03 15:06:11 -08:00
Tim Schaub
303f2df9e1 Merge pull request #256 from tschaub/transform-arrays
Updating ol.TransformFunction instances so they work with arrays instead of coordinates.
2013-03-03 14:46:22 -08:00
Frédéric Junod
d783df0840 Merge pull request #223 from fredj/touch-click
Click handling broken
2013-03-03 12:43:01 -08:00
Tim Schaub
e9fa08fccb Use in-place transforms where possible 2013-03-03 20:53:13 +01:00
Bruno Binet
93131d6105 Add some tests for the multiple tileSizes in tilegrid. 2013-03-03 20:43:47 +01:00
Bruno Binet
bf325c38b4 Fix tests related to createBboxParam. 2013-03-03 20:43:46 +01:00
Bruno Binet
2816e3256c Add support for multiple tileSizes in the tilegrid.
This is needed by WMTS.
2013-03-03 20:43:46 +01:00
Bruno Binet
7c440d087f Ensure we cannot set both origin and origins in the tilegrid 2013-03-03 20:43:46 +01:00
Bruno Binet
f7a895a823 Remove unused tileGrid.getTileSize() call. 2013-03-03 20:43:45 +01:00
Tim Schaub
40bde4056b Accept a destination array for transforms
This allows in-place transforms.
2013-03-03 20:24:14 +01:00
Éric Lemoine
26cf882d68 Make createLayerRenderer always return a renderer 2013-03-03 19:46:09 +01:00
Éric Lemoine
5202281ce8 Remove references to goog in epsg-4326 example 2013-03-03 19:46:09 +01:00
Éric Lemoine
337fd11a05 Load the examples using PhantomJS
This commit adds a check-examples target to check that the hosted examples load without errors.
2013-03-03 19:46:09 +01:00
Tim Schaub
7a5e6a06d8 Make transform functions work with arrays
Instead of working with ol.Coordinate instances, transform functions work with arrays.  This is in anticipation of using transform functions to transform large arrays of vertex coordinate values.  The ol.projection.transform and ol.projection.transformWithCodes are slightly more convenient functions for dealing with ol.Coordinate instances.  Whether we make this more consistent with the use of functions returned by ol.projection.getTransform is up for discussion.
2013-03-03 19:27:57 +01:00
Bruno Binet
6407b7c1c1 Merge pull request #254 from bbinet/indent-wmscap-example
Better indentation for wms capabilities example
2013-03-03 09:58:16 -08:00
Bruno Binet
d754c34a04 Better indentation for wms capabilities example 2013-03-03 18:57:53 +01:00
ahocevar
f1120287c3 Features can now have symbolizers
If specified, feature symbolizers take precedence over rule
based styling.
2013-03-03 18:55:52 +01:00
ahocevar
44ca6c9ff6 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-03-03 18:37:02 +01:00
Tom Payne
f897c743b1 Merge pull request #255 from twpayne/dont-check-requires-in-comments
Don't check for requires in comments
2013-03-03 09:36:29 -08:00
Tom Payne
b75298e957 Don't check for requires in comments 2013-03-03 18:29:16 +01:00
Bruno Binet
7454314578 Merge pull request #253 from bbinet/gitignore
Ignore ol-simple.js and ol-whitespace.js generated files
2013-03-03 08:59:26 -08:00
Tim Schaub
0df692e159 Lint in the tests 2013-03-03 17:58:03 +01:00
Bruno Binet
88335da8de Ignore ol-simple.js and ol-whitespace.js generated files 2013-03-03 17:55:53 +01:00
Éric Lemoine
bf50828a0d Merge pull request #251 from elemoine/remove-goog-references
Clean up examples
2013-03-03 08:12:57 -08:00
Éric Lemoine
bbc9785b81 IE9 supports addEventListener (thanks @fredj) 2013-03-03 17:10:50 +01:00
Éric Lemoine
d0c0231d98 Add exports for the canvas export feature 2013-03-03 17:10:50 +01:00
Éric Lemoine
bd67a14389 Make wms-capabilities example work when hosted 2013-03-03 17:10:50 +01:00
Tim Schaub
022917e719 Lint free externs 2013-03-03 17:06:15 +01:00
Éric Lemoine
01d49ef9c9 Remove references to goog in examples 2013-03-03 17:01:37 +01:00
ahocevar
d4ecf53801 Adding example for rule based styling
For the first time in the history of OpenLayers, we can render
features with multiple symbolizers now, which is also shown in
this new example.
2013-03-03 17:00:20 +01:00
Tim Schaub
d3c4869917 Work with new ol.projection package 2013-03-03 16:09:00 +01:00
Éric Lemoine
e6a42168d8 Merge pull request #249 from elemoine/playwithbuild
SIMPLE and WHITESPACE builds
2013-03-03 06:53:26 -08:00
Tim Schaub
5a73529da5 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-03-03 15:52:40 +01:00
Tim Schaub
b247031fe2 Test reading with shared vertices 2013-03-03 15:51:24 +01:00
Tim Schaub
4af32560ce Removing abstract methods for now
Later we'll discuss having more specific FeatureParser and readFeatures type methods.
2013-03-03 15:50:33 +01:00
Tom Payne
7126d63db5 Merge pull request #247 from twpayne/hyperbolic-functions
Add hyperbolic functions
2013-03-03 06:47:32 -08:00
Tom Payne
1c5e29f5a7 Merge pull request #246 from twpayne/xyztilegrid-tests
Add ol.tilegrid.XYZ tests
2013-03-03 06:47:16 -08:00
Tom Payne
183df560ad Merge pull request #245 from twpayne/projection-refactoring
Projection refactoring
2013-03-03 06:46:38 -08:00
ahocevar
5535a26d4a Adding unit tests for rule based styling 2013-03-03 15:25:20 +01:00
ahocevar
63c048edb2 Use the actual value, not just the index in the array. 2013-03-03 15:22:52 +01:00
ahocevar
db52ff926e Return an empty array for features without geometry
This ensures that the static applyDefaultStyle() method works
exactly the same way as the instance's apply() method.
2013-03-03 15:22:33 +01:00
Bruno Binet
302ba3a8e1 Merge pull request #248 from bbinet/prefer-canvas
Prefer the canvas renderer over dom.
2013-03-03 06:19:12 -08:00
Bruno Binet
0a462f1254 Prefer the canvas renderer over dom. 2013-03-03 15:11:27 +01:00
Éric Lemoine
6b9e79171b SIMPLE and WHITESPACE builds 2013-03-03 15:05:02 +01:00
Tom Payne
a94418edab Add ol.tilegrid.XYZ tests 2013-03-03 14:48:37 +01:00
Tom Payne
00ce5c6a78 Add hyperbolic functions 2013-03-03 14:47:25 +01:00
Frederic Junod
0a80feccfc Allow touch event (touchstart) to fire click events 2013-03-03 14:45:12 +01:00
Frederic Junod
c72877b33b Listen to both click and touchend events 2013-03-03 14:45:12 +01:00
ahocevar
9d1f737bce ol.Filter is now a (base) class, not an interface any more
ol.Filter can now also be used to provide a simple filter that
just evaluates a user provided filter function against a
feature.
2013-03-03 14:38:04 +01:00
Tim Schaub
5d917ebed6 Helper functions for running tests after xhr 2013-03-03 14:29:22 +01:00
Frédéric Junod
b14912567b Merge pull request #244 from fredj/zoom-control
Zoom control
2013-03-03 04:37:44 -08:00
Tom Payne
bf944e158a Make Proj4js classes and functions private 2013-03-03 13:14:08 +01:00
Tom Payne
fcc620af7d Separate ol.projection module from ol.Projection class 2013-03-03 13:09:13 +01:00
Tom Payne
3e420313a2 Only require things that start with a capital letter 2013-03-03 13:08:34 +01:00
Frederic Junod
0fcc06b8ae Set ol-zoom content in css using :before pseudo class 2013-03-03 12:23:29 +01:00
Tom Payne
f6575f3195 Add EPSG:4326 example 2013-03-03 12:22:24 +01:00
Tom Payne
17bd715495 Cope with axis orientation in single image WMS sources 2013-03-03 12:22:24 +01:00
Tom Payne
66e5b1d736 Cope with axis orientation for tiled WMS sources 2013-03-03 12:22:24 +01:00
Tom Payne
6b26cbfb38 Refactor projection architecture 2013-03-03 12:22:24 +01:00
Frederic Junod
7d79a77052 Remove css size dependent rule (hover color) 2013-03-03 12:10:12 +01:00
Tim Schaub
69b6fae744 Parser base class
GeoJSON is now a parser.  The idea is that we'll want to pass parsers to sources or protocols and want a known type.
2013-03-03 11:50:51 +01:00
Bruno Binet
9053e1dfc8 Merge pull request #237 from bbinet/tilegrid_extent_cleanup
Remove extent property from ol.tilegrid.TileGridOptions
2013-03-03 02:20:52 -08:00
Frederic Junod
66d4c44159 Rename ol.ViewHint.PANNING to ol.ViewHint.INTERACTING 2013-03-03 10:44:58 +01:00
Tim Schaub
93ab45432b Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-03-03 09:46:11 +01:00
Tim Schaub
b52d283641 Allow geometries to use a shared vertex array
The ol.geom.SharedVertices structure represents a flattened array of vertex coordinates.  This is intended to support optimal WebGL rendering.
2013-03-02 18:39:24 +01:00
ahocevar
bdfa2cc88c Fixing return type to make Closure compiler happy 2013-03-02 17:44:15 +01:00
ahocevar
f4a4522eb4 Giving vector layers the style they deserve
Now vector layers can have a style. ol.Style instances have an
apply method to get the symbolizer literals for a feature. If the
layer does not have a style defined, there is also a static
applyDefaultStyle function on ol.Style to get the default
symbolizer literals for a feature. The vector layer also got a
groupFeaturesBySymbolizerLiteral method, which returns an array
with features grouped by symbolizer, as needed by the canvas
renderer.
2013-03-02 17:38:01 +01:00
ahocevar
fcd5804d2d Symbolizer and SymbolizerLiteral as base class, not interface 2013-03-02 14:08:52 +01:00
ahocevar
da7820121f Renaming the 'evaluate' method to 'applies' 2013-03-02 12:50:53 +01:00
Bruno Binet
4bdf59bc6b Remove extent property from ol.tilegrid.TileGridOptions
This follows tilegrid extent_ property removal from #216.
2013-03-02 10:36:11 +01:00
Frédéric Junod
8a66d69d3b Merge pull request #235 from fredj/tilejson-externs
Fix 'grids' type declaration.
2013-03-01 01:17:59 -08:00
Tim Schaub
ff27fd33a1 Merge pull request #232 from tschaub/projection-tests
Projection tests
2013-02-27 21:06:54 -08:00
Frédéric Junod
709b5f2e73 Merge pull request #236 from fredj/exports
Add some missing exports and fix side-by-side example
2013-02-27 12:51:43 -08:00
Frederic Junod
5ccf94a395 Do not use goog.now() in the examples (see #229) 2013-02-27 13:58:30 +01:00
Frederic Junod
90cb0e8fcb Export ol.easing.* 2013-02-27 13:52:39 +01:00
Frederic Junod
dda4060d84 Export ol.animation.zoom 2013-02-27 13:35:32 +01:00
Frederic Junod
7a8b331213 Fix 'grids' type declaration.
grids property is optional.
see: https://github.com/mapbox/tilejson-spec/blob/master/2.0.0/README.md
2013-02-27 10:18:19 +01:00
Frederic Junod
3b74f72c56 Add optional kinetic parameter. 2013-02-26 10:54:15 +01:00
Frederic Junod
20e8eab142 Add missing 'protected' comment for targetTouches prop. 2013-02-26 09:46:24 +01:00
Frederic Junod
585c397a0f Reset position on touch end 2013-02-26 08:58:47 +01:00
Frederic Junod
c0aa50abfc Split TouchRotateAndZoom interaction.
Split TouchRotateAndZoom interaction into two new interaction:
TouchRotate and TouchZoom.
2013-02-26 08:58:47 +01:00
Tim Schaub
52da64564c Tests for getting transforms
These are regression tests for #231.
2013-02-25 11:40:55 -07:00
Tim Schaub
ca85c26537 Method for removing cached transforms 2013-02-25 11:28:14 -07:00
Tim Schaub
940ba8afa7 Stray debugger 2013-02-25 11:26:04 -07:00
Tim Schaub
72ba8c4cbd Smoke test for ol.Projection.getTransformFromCodes 2013-02-25 10:36:21 -07:00
Tim Schaub
48e69f7559 Unused var 2013-02-25 10:36:21 -07:00
Tim Schaub
86262bf17e Space for linter 2013-02-25 10:36:21 -07:00
Tim Schaub
6ceae978bf Merge pull request #231 from probins/projfix
Fix bug/typo in projection.getTransform
2013-02-25 09:33:10 -08:00
Peter Robins
343d52cff1 Fix bug/typo in projection.getTransform
Destination projection is currently using the source projection code
2013-02-25 15:18:51 +00:00
Éric Lemoine
d716a2dec1 Merge pull request #228 from elemoine/fixcomments
Update comments in hosted examples loader
2013-02-22 14:24:20 -08:00
Éric Lemoine
31bcd2832e Update comments in hosted examples loader 2013-02-22 23:23:04 +01:00
Éric Lemoine
a8bb782e99 Merge pull request #227 from elemoine/removestandalone
Remove examples/standalone dir
2013-02-22 14:22:08 -08:00
Éric Lemoine
981c1dcbd7 Remove examples/standalone dir 2013-02-22 23:16:36 +01:00
Tom Payne
6ce3ebba5b Merge pull request #226 from twpayne/preserve-low-resolution-tiles
Preserve low resolution tiles
2013-02-22 02:14:41 -08:00
Tom Payne
c36de098bd Avoid creating a TileCoord object when marking used tiles 2013-02-21 16:52:52 +01:00
Tom Payne
4c9b70fa5c Move useLowResolutionTiles from layer renderer to tile source 2013-02-21 16:47:10 +01:00
Tom Payne
b139757987 Merge pull request #224 from twpayne/jslint-clean-ups
Satisfy JSLint
2013-02-21 07:23:56 -08:00
Tom Payne
47e799ced0 Mark all low resolution tiles as used to prevent cache expiration 2013-02-21 16:19:38 +01:00
Tom Payne
57b446fa0a Implement useTile for image tile sources with caches 2013-02-21 16:14:15 +01:00
Tom Payne
e68c1adbae Add ol.source.TileSource.useTile 2013-02-21 16:13:34 +01:00
Tom Payne
e513b8cc39 Make it explicit that functions operate on tile sources 2013-02-21 16:12:45 +01:00
Frédéric Junod
03e502fba1 Merge pull request #225 from fredj/css-cleanup
Remove CSS color workarounds.
2013-02-21 06:35:29 -08:00
Frederic Junod
9eeea82338 Remove CSS color workarounds. 2013-02-21 15:21:17 +01:00
Tom Payne
fabcb313f1 Satisfy JSLint
JSLint complains about functions being declared in blocks.
2013-02-21 15:13:33 +01:00
Frédéric Junod
60f0bdb113 Merge pull request #168 from fredj/touch-events
Touch events support
2013-02-21 03:29:51 -08:00
Éric Lemoine
a11a98ac1d Merge pull request #221 from elemoine/imagelayer
wms-custom-proj example broken when hosted
2013-02-20 23:06:11 -08:00
Tim Schaub
e23ca1655c Confirm that arbitrary attribute names can be used 2013-02-20 10:34:10 -07:00
Tim Schaub
7ce89f1fbe Proper getAttributes method
With a59aa9bb37 we can now provide an object with user set attributes.
2013-02-20 10:33:42 -07:00
Tim Schaub
0f2f26969d Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-02-20 10:18:09 -07:00
Tim Schaub
a59aa9bb37 Merge pull request #217 from tschaub/safer-object
Allow ol.Object to be used with arbitrary keys.  Add a getKeys method.
2013-02-20 07:56:07 -08:00
Éric Lemoine
367ea0083c Windows users should run build serve 2013-02-20 14:26:55 +01:00
Éric Lemoine
da825c27da Update Run examples locally readme section 2013-02-20 14:22:13 +01:00
Éric Lemoine
528caa08c2 Merge pull request #220 from elemoine/readme
Update readme Add examples section
2013-02-20 03:56:48 -08:00
Éric Lemoine
2bc8e1a570 Example uses exported properties 2013-02-20 11:55:28 +01:00
Éric Lemoine
cf6a27fca3 Export ol.Extent.prototype.getHeight and getWidth 2013-02-20 11:54:35 +01:00
Éric Lemoine
68844007b8 Add missing goog.require's 2013-02-20 11:53:54 +01:00
Tim Schaub
689f8c9d9d Merge pull request #206 from tschaub/interim-tiles
Share common code to find loaded tiles
2013-02-20 00:52:49 -08:00
Bart van den Eijnden
efefb2554a Merge pull request #204 from bartvde/wmscapsfixes
fixes for the WMS capabilities parser (r=@elemoine)
2013-02-20 00:48:30 -08:00
Frederic Junod
8d24311bc8 Take the resolution constraint into account.
But only at the end of the pinch zoom action.
2013-02-20 09:40:19 +01:00
Éric Lemoine
f24b277dde Update readme Add examples section 2013-02-20 09:39:15 +01:00
Frederic Junod
3e4ae0d79d Stop ongoing kinetic animation 2013-02-20 09:33:04 +01:00
Frederic Junod
48ff4a95e0 Remove unused variable, coding style 2013-02-20 09:33:04 +01:00
Frederic Junod
8c1d42a318 Listen to both mouse and touch events 2013-02-20 09:33:04 +01:00
Frederic Junod
735e534095 Add ol.interaction.TouchRotateAndZoom 2013-02-20 09:33:04 +01:00
Frederic Junod
d9a1c18300 Add ol.interaction.TouchPan 2013-02-20 09:32:34 +01:00
Frederic Junod
ccd568ca3b Remove unused goog.require 2013-02-20 09:31:40 +01:00
Frederic Junod
a066b323f2 Move dblclick handling into touch handlers 2013-02-20 09:31:40 +01:00
Frederic Junod
942255e177 Listen to IE pointer events 2013-02-20 09:31:40 +01:00
Frederic Junod
0d42e08785 Add listeners for touchstart, touchmove and touchend events 2013-02-20 09:31:40 +01:00
Frederic Junod
dc40ac6831 Remove touch events handling in handleMouse* handlers 2013-02-20 09:31:39 +01:00
Frederic Junod
0296380807 Rename MapBrowserEventHandler internal handlers name 2013-02-20 09:31:39 +01:00
Tim Schaub
8f578b88b1 Removing the typed arrays
Its not clear that we will be able to leverage the Float64Array.  It may also be that the overhead of constructing these small arrays negates any benefit of faster access.  And for all coordinate arrays, we'll need arrays that grow/shrink.
2013-02-20 01:15:39 -07:00
Tim Schaub
176f18c937 Merge branch 'master' of github.com:openlayers/ol3 into vector
Resolved conflicts:
  src/ol/renderer/canvas/canvasrenderer.js
2013-02-20 00:38:07 -07:00
Tim Schaub
d642628545 Example syntax 2013-02-20 00:21:08 -07:00
Tim Schaub
9cac8ec2f6 Moving GeoJSON into parser package
Need to discuss whether we want all to require constructing a new parser.  I liked the simple `ol.io.geojson.read` function.
2013-02-20 00:09:38 -07:00
Tim Schaub
735f490f56 Treating geometry as just another attribute
The first set geometry is considered the default.  As an added bonus, we're back to a single argument constructor.  Later, we could allow a schema to be set.  This would be done before setting values (calling constructor with no args).
2013-02-20 00:02:50 -07:00
Tim Schaub
0015e466dc Allow instanceof checks for geometries 2013-02-19 23:21:05 -07:00
Tim Schaub
083404bd58 Provides for tests 2013-02-19 23:15:45 -07:00
Tim Schaub
438664a190 Renaming literals 2013-02-19 22:35:29 -07:00
Tim Schaub
7141721bb1 Symbolizers with method for creating literals 2013-02-19 22:24:21 -07:00
Tim Schaub
1faa6214f1 Expression literal 2013-02-19 21:38:10 -07:00
Tim Schaub
360e37146c Rule is filter and symbolizer, style is collection of rules 2013-02-19 21:37:40 -07:00
Tim Schaub
2919906ba6 Add method for getting keys 2013-02-19 14:47:49 -07:00
Tim Schaub
d6ff58305d Using a dedicated object for value storage
Without this, we are limited in the key names that we can accept from users.  And because of compiler renaming, we don't know ahead of time what the limitations are (e.g. the key 'a' may clobber the 'set' method).
2013-02-19 14:35:11 -07:00
Tim Schaub
0707deb465 Properties set with set should not be accessed with bracket 2013-02-19 14:28:59 -07:00
Tim Schaub
052e995f2e Key in obj check not appropriate for user supplied keys 2013-02-19 14:19:40 -07:00
Tim Schaub
6cfc36d8cc Using hasOwnProperty is better for user keys on objects we control 2013-02-19 14:17:58 -07:00
Tim Schaub
b9507de3ea Removing unnecessary overhead 2013-02-19 14:14:36 -07:00
Tim Schaub
3698049543 View needs to call constructor on super 2013-02-19 14:03:48 -07:00
Tim Schaub
eef683fcdb Indentation for linter 2013-02-19 13:58:43 -07:00
Tim Schaub
80dc7b5bf7 Accept custom isLoaded method in findLoadedTiles method 2013-02-19 12:13:58 -07:00
Bruno Binet
6e08f5ef1b Merge pull request #216 from bbinet/remove_tilegrid_extent
Remove tilegrid extent_ property
2013-02-19 08:59:06 -08:00
Tim Schaub
1b984ac06c Fewer tiles to be considered fully loaded
With 797dba2cdb we no longer have to load excess tiles to consider an extent fully loaded.
2013-02-19 09:54:41 -07:00
Frédéric Junod
cb0fb64dd9 Merge pull request #214 from fredj/supported-const
Rename *.isSupported functions to *.SUPPORTED constants
2013-02-19 08:35:59 -08:00
Bruno Binet
0835fd6b0a Remove tile grid extent_ property
This is never used in ol3.
2013-02-19 17:22:24 +01:00
Bart van den Eijnden
793a956211 Several fixes to the WMS Capabilities parser
Make sure the object structure returned is not mangled by Closure

Do not use closure XHR or JSON in the example

Use Jasmine's async support in the test cases

Get rid of some backwards compatibility now that we have a fresh start
2013-02-19 17:12:02 +01:00
Tim Schaub
b061e23606 Merge branch 'master' of github.com:openlayers/ol3 into interim-tiles 2013-02-19 08:59:23 -07:00
Frederic Junod
c117fbbf7c Rename ol.Geolocation.isSupported to ol.Geolocation.SUPPORTED.
And add the 'const' JSDoc Tags.
2013-02-19 16:51:59 +01:00
Éric Lemoine
a04774cd96 Merge pull request #210 from elemoine/imageattribution
Image layer support to attribution control
2013-02-19 07:49:43 -08:00
Bart van den Eijnden
a2bcf51272 Merge pull request #213 from bartvde/wmtsclean
Implement WMTS GetCapabilities parser.
2013-02-19 07:45:08 -08:00
Tim Schaub
1f4b34cdb8 Merge pull request #207 from tschaub/tilerange
Make tile range calculation consistent.  Tile ranges are always inclusive in their min/max values.
2013-02-19 07:43:27 -08:00
Bart van den Eijnden
5e29830462 Add WMTS GetCapabilities parser
Implements WMTS GetCapabilities parser, which depends partly on
an OWSCommon parser.

Integration with the layer source will be done at a later stage.
2013-02-19 16:32:56 +01:00
Frederic Junod
7e3dcf36a0 Rename ol.*.isSupported function to ol.*.SUPPORTED const 2013-02-19 16:14:37 +01:00
Tim Schaub
5148ad038c Sharing code with rectangle
We cannot use the rectangle constructor here because a rectangle makes an assertion about min being less than max and a range may have equal min/max.
2013-02-19 07:30:54 -07:00
Tim Schaub
797dba2cdb Correct range for extent and resolution
Tile ranges are inclusive.  When getting the tile range for an extent, the top-right corner of the extent should be considered with a different intersection policy than the bottom-left corner.
2013-02-19 07:21:42 -07:00
Éric Lemoine
82aa44fdd1 Attribution control reads attribs from frame state 2013-02-19 15:19:44 +01:00
Éric Lemoine
f540dd8689 Image layer renderers add attributions to frame state 2013-02-19 15:19:44 +01:00
Tim Schaub
184e1e782c Spare space 2013-02-19 07:19:31 -07:00
Tim Schaub
a55a6bda3b Merge pull request #208 from tschaub/shift-with-care
Calculating resolution by left shifting tile sizes, we're unnecessarily restricted in the number of zoom levels we can have.
2013-02-19 06:00:39 -08:00
Tim Schaub
c7569026db Merge branch 'vector' of github.com:openlayers/ol3 into vector 2013-02-19 06:58:23 -07:00
ahocevar
f6c93d85b0 Making linter happy 2013-02-19 14:12:38 +01:00
ahocevar
f15c2951d0 Adding RTree tests 2013-02-19 14:07:47 +01:00
Tom Payne
6e8f5ef0fd Merge pull request #202 from twpayne/proj4js-non-global
Proj4js should not have to be global
2013-02-19 03:25:05 -08:00
Tom Payne
f27c749e49 Allow Proj4js to be non-global and cache test result 2013-02-19 09:12:40 +01:00
Tim Schaub
46e31f9f9a Lint and names 2013-02-18 22:20:50 -07:00
Tim Schaub
0a5dae9ed0 Avoid left shift in resolution calculations 2013-02-18 18:37:27 -07:00
Tim Schaub
ce4b95f960 Decoupling canvas tile grid from vector source grid
If we have a gridded vector source, the grid should have something to do with the source data (e.g. the vector data is available in a regular grid).  The vector layer renderer's internal grid is for rendering canvas tiles and doesn't have anything to do with the source.
2013-02-18 17:54:13 -07:00
Tim Schaub
8b19751264 Making it explicit that this is a range of tiles
With tile range extending rectangle, a tile range that represented a single tile was not allowed.
2013-02-18 17:07:31 -07:00
Tim Schaub
0d6c54847b Removing logic that assumes occasionally stretched tiles
When the dom renderer included logic to stretch tiles so that gaps were properly filled for fractional zoom levels, we needed to take this into account when getting a tile coordinate for a given coordinate and resolution.  This was never the proper logic for a renderer that wasn't stretching occassional tiles (e.g. the WebGL renderer, the Canvas renderer, or the new DOM renderer).
2013-02-18 15:55:27 -07:00
Tim Schaub
e8c50c7290 Passing tests 2013-02-18 15:11:53 -07:00
Tim Schaub
6aa4e99fe5 Fix return from findLoadedTiles
Previously, the findInterimTiles method was returning undefined if the min x/y coord for a tile range was already in the lookup.  The return says it indicates whether all tiles for the given z are loaded.  This change corrects the return.

This change also reveals a misunderstanding of the tile range returned by `getTileRangeForExtentAndZ`.  The previous findInterimTiles method was treating max values as inclusive.  This is intuitive.  It looks like the method returns a range where max values are exclusive.
2013-02-18 14:51:39 -07:00
Tim Schaub
ddf993f0c9 Factor out common code and test
The findInterimTiles method was used in three renderers.  This change makes it available on the tile source and adds some basic tests.
2013-02-18 14:18:08 -07:00
Tim Schaub
e9fb83d4ee Use post render frame for tile pruning
We should discuss whether post render functions must be run after each render frame or not.  If these can be run after multiple render frames, it would make sense to increase the timeout.  As it is, it looks like post render functions are run for every render.  Hard to see what the benefit is in this case.
2013-02-18 11:58:43 -07:00
Tim Schaub
8defe3a3a1 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-02-18 11:51:51 -07:00
Tom Payne
4c2463dd91 Merge pull request #203 from twpayne/work-around-python-extract-all-bug
Work around extractall bug in older versions of Python
2013-02-18 10:32:04 -08:00
Tom Payne
8c2eb55f64 Work around extractall bug in older versions of Python
Python bug: http://bugs.python.org/issue4710
Refs #200
2013-02-18 19:15:31 +01:00
Tim Schaub
e30b0959e0 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-02-18 10:11:00 -07:00
Frédéric Junod
4dd78719cf Merge pull request #201 from fredj/kinetic-begin
Remove x,y params from ol.Kinetic.begin
2013-02-18 08:01:27 -08:00
Frederic Junod
e4a5744e06 Remove x,y params from ol.Kinetic.begin 2013-02-18 16:43:20 +01:00
Tom Payne
a455473a28 Merge pull request #200 from twpayne/proj4js-tests
Proj4js tests
2013-02-18 06:28:39 -08:00
Tom Payne
3a20eaed32 Merge pull request #198 from twpayne/ellipsoid
Add ellipsoid geometry functions
2013-02-18 06:27:36 -08:00
Tom Payne
7b42b62033 Add Proj4js integration tests 2013-02-18 14:44:44 +01:00
Tom Payne
cb9fbc3dec Add Proj4js to test framework 2013-02-18 14:44:35 +01:00
Tom Payne
be48a30d6a Add target to download and install Proj4js 2013-02-18 14:44:14 +01:00
Tom Payne
281f01889e Merge pull request #196 from twpayne/sphere
Add spherical geometry functions
2013-02-18 03:35:44 -08:00
Tom Payne
36a3d02816 Add ellipsoid geometry functions 2013-02-18 12:32:43 +01:00
Tom Payne
684a336dd4 Merge pull request #197 from twpayne/geolocation-all-properties
Add remaining geolocation properties
2013-02-18 01:53:04 -08:00
Tom Payne
fc9f323f83 Store heading in radians, thanks @fredj 2013-02-17 23:53:37 +01:00
Éric Lemoine
7d5ea5928c Merge pull request #149 from elemoine/singleimage
Add support for single image WMS
2013-02-17 14:19:29 -08:00
Éric Lemoine
d713c9b8ed Deal with null images 2013-02-17 23:07:58 +01:00
Éric Lemoine
be6c1a1a27 Test the image layer renderer's transform matrix 2013-02-17 22:47:19 +01:00
Éric Lemoine
85eec4e9b8 Avoid busy-waiting while images load
This is to be in conformance with the work done with #184.
2013-02-17 22:47:19 +01:00
Tom Payne
7de6cb4fd4 Add remaining geolocation properties 2013-02-16 20:19:38 +01:00
ahocevar
266111e5f1 Adding goog.provide and goog.requires 2013-02-15 23:46:32 +01:00
ahocevar
d2a22016e2 Adding extent filter tests 2013-02-15 23:43:10 +01:00
ahocevar
77b8688eae Regrouping tests 2013-02-15 23:42:22 +01:00
Tom Payne
544f399e04 Add spherical geometry functions 2013-02-15 18:07:19 +01:00
Éric Lemoine
a3c65978d1 Make ol.Image emit change events 2013-02-15 17:57:05 +01:00
Éric Lemoine
1e4229497d Do not sort resolutions array
We assert that the resolutions array is sorted instead of sorting it ourselves. This is to consistent with ol.TileGrid.
2013-02-15 17:52:06 +01:00
ahocevar
59fe714fa6 Making the linter happy 2013-02-15 17:44:09 +01:00
Éric Lemoine
e1505abe0d Rename ol.Rectangle scale to scaleFromCenter 2013-02-15 17:43:27 +01:00
ahocevar
8c03abdaa2 Adding ol.source.Vector unit tests 2013-02-15 16:25:47 +01:00
ahocevar
8cc65756bc Only attempt fast lane for AND filters 2013-02-15 16:25:29 +01:00
Tom Payne
ea6bf83c61 Merge pull request #195 from twpayne/tmp-fix-phantomjs
Temporarily work around pake's eager evaluation of variables in target names
2013-02-15 04:40:17 -08:00
Tim Schaub
be255ed6c7 Adding ol.Expression
This simple expression constructor will be used for symbolizer properties and the layer will generate symbolizer literals for rendering by evaluating any expressions with a feature as the this argument and feature attributes as the scope.  This allows generating labels that concatenate multiple attribute values together or displaying point symbols that are sized according to a population attribute divided by an area attribute, for example.

This implementation will not work in environments where the content security policy disallows the use of the Function constructor.  This is the case on browser extensions.  A more content-security-policy-friendly implementation would be to come up with a restricted grammar and write a lex/parser.  This is the road I started down, but this verison is far less code, and I think the security policy limitations are minor at this point.  This version will always be faster/lighter than a parser, so one is written in the future, it should only be pulled in where content security policy mandates it.
2013-02-14 17:19:15 -07:00
Tim Schaub
59a203b2b7 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-02-14 17:18:00 -07:00
Tom Payne
e6ed1c1a89 Temporarily work around pake's eager evaluation of variables in target names 2013-02-15 00:45:13 +01:00
Tom Payne
012cb501df Don't re-lint files that have already passed after a lint failure 2013-02-15 00:33:05 +01:00
Éric Lemoine
3d0682a4d4 Use an ImageLayer in wms-custom-proj example 2013-02-14 23:36:36 +01:00
Éric Lemoine
02843939e3 Add ol.renderer.webgl.ImageLayer 2013-02-14 23:36:36 +01:00
Éric Lemoine
17a17b01b6 Add ol.renderer.dom.ImageLayer 2013-02-14 23:36:36 +01:00
Éric Lemoine
238c695265 Add FIXME to ol.control.Attribution 2013-02-14 23:36:36 +01:00
Éric Lemoine
8ae25684f9 Add ol.source.StaticImage 2013-02-14 23:36:36 +01:00
Éric Lemoine
62b10cf878 Add ol.source.SingleImageWMS 2013-02-14 23:36:36 +01:00
Éric Lemoine
aa9f820723 Add scale to ol.Rectangle 2013-02-14 23:36:36 +01:00
Éric Lemoine
35a6cac37f Add containsExtent to ol.Extent 2013-02-14 23:36:36 +01:00
Tom Payne
f581040b0f Add ol.renderer.canvas.ImageLayer 2013-02-14 23:36:36 +01:00
Tom Payne
5a0adf2345 Add ol.source.ImageSource 2013-02-14 23:36:36 +01:00
Tom Payne
27125640ef Add ol.layer.ImageLayer 2013-02-14 23:36:36 +01:00
Éric Lemoine
cf206a103d Add ol.Image class 2013-02-14 23:36:36 +01:00
Éric Lemoine
49696390fc Add ol.ImageUrlFunction 2013-02-14 23:36:36 +01:00
Éric Lemoine
8b83345bd2 Add equals to Rectangle 2013-02-14 23:36:35 +01:00
Bart van den Eijnden
234f6bc411 Merge pull request #180 from bartvde/wmscapsclean
add WMS GetCapabilities parser for WMS 1.1.0, 1.1.1, 1.1.1 WMS-C profile
2013-02-14 05:02:39 -08:00
Frédéric Junod
b305d7fdfa Merge pull request #192 from fredj/rotation
Change view.rotate params: rotation and optional anchor.
2013-02-14 04:48:42 -08:00
Frederic Junod
34975428c4 Change view.rotate params: rotation and optional anchor. 2013-02-14 12:17:26 +01:00
Éric Lemoine
daaff1611c Merge pull request #193 from elemoine/shaders
Apply transform matrix to text coords
2013-02-14 03:01:18 -08:00
Éric Lemoine
b6b493c198 Use vec2 for vTexCoord 2013-02-14 11:54:01 +01:00
Éric Lemoine
de7a1d8f81 Apply transform matrix to text coords
With this commit the transform matrix is applied to each texture coordinate, as opposed to each fragment. This leads to less calculation on the GPU.
2013-02-14 09:56:45 +01:00
Tim Schaub
2082ba7637 Fewer, bigger tiles 2013-02-13 15:51:06 -07:00
Tim Schaub
f5c627ab51 Only listen once for tile events
Assuming browser garbage collection cannot happen while we have listeners in the global registry, we need to listenOnce to avoid memory leaks with the tile queue.
2013-02-13 15:37:33 -07:00
Bart van den Eijnden
13d95b90a3 use namespace URI instead of prefix as suggested by @tschaub and discussed with @ahocevar 2013-02-13 20:58:48 +01:00
ahocevar
6b43435262 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-02-13 12:30:16 +01:00
ahocevar
e155f870cd Fixing RTree, and using it for retrieving geometries 2013-02-13 12:29:14 +01:00
Tom Payne
83a00c13fa Don't use problematic glob function 2013-02-12 23:03:15 +01:00
Tom Payne
110720d7d3 Merge pull request #191 from twpayne/windows-build
Windows build
2013-02-12 07:24:39 -08:00
Tom Payne
9a3e090c2b Run tests on Windows 2013-02-12 16:07:34 +01:00
Frédéric Junod
b4bd1a5569 Merge pull request #190 from fredj/rotation
view.getRotation default value already set to 0.
2013-02-12 06:55:34 -08:00
Tom Payne
357ca379db Update build instructions for Windows 2013-02-12 15:47:55 +01:00
Tom Payne
3d34360070 Add build.cmd for Windows developers 2013-02-12 15:47:55 +01:00
Tom Payne
d828fee582 Set path to gjslint on Windows 2013-02-12 15:47:54 +01:00
Frederic Junod
f4e9dd5c37 view.getRotation default value already set to 0. 2013-02-12 15:37:08 +01:00
Tom Payne
169555f2be Use ifind rather than glob to work around Windows path separator nonsense 2013-02-12 15:31:30 +01:00
Tom Payne
a3e7528841 Guess paths to Windows binaries using environment variables 2013-02-12 15:30:36 +01:00
Tom Payne
4481bb011f Update to latest version of pake 2013-02-12 15:30:08 +01:00
Tom Payne
0c09083eb8 Add missing whitespace to satisfy pep8 2013-02-12 15:28:20 +01:00
Marc Jansen
192f29513e Merge pull request #189 from marcjansen/travis-tests
Fix the serve-precommit target. (r=@elemoine/@twpayne)
2013-02-12 06:10:26 -08:00
Marc Jansen
d851cac891 Fix the serve-precommit target.
When the plovr-jar is being invoked in the serve-precommit target, it needs
the JSON files in `test/` as well to have all requirements for headless testing.

This should also reenable running the testsuite on our continuous integration
server.
2013-02-12 14:28:58 +01:00
Marc Jansen
a0932c6cba Merge pull request #177 from marcjansen/build-clean
(Re)add a reallyclean target to the build. (r=@elemoine)
2013-02-12 01:57:01 -08:00
Marc Jansen
6de649f6c6 (Re)add a reallylean target to the build.
Previously we had both a `clean` and `reallyclean` in our Makefile; both
got lost when we switched to a python build.

A clean 'target' can be invoked by calling the build script with the '-c' flag:
  ./build.py -c

This commit readds the `reallyclean` target and lets it clean up a little more
than the Makefiles `clean` or `reallyclean` did. More files are deleted,
but only if these are being ignored inside of the repository (e.g. through
.gitignore files).
2013-02-12 10:11:14 +01:00
Frédéric Junod
03b10204a4 Merge pull request #173 from fredj/geolocation
Add ol.Geolocation
2013-02-08 21:57:11 -08:00
Éric Lemoine
5f5e14f253 Merge pull request #175 from elemoine/control
Simplify control architecture
2013-02-08 14:56:19 -08:00
Tim Schaub
652b7dd696 Merge pull request #184 from tschaub/less-animation
Avoid unnecessary animation loop while tiles load
2013-02-07 15:48:28 -08:00
Tim Schaub
440ea038fe Merge pull request #183 from tschaub/natural-names
More natural names for animations
2013-02-07 13:44:13 -08:00
Tim Schaub
3c4d218ec5 Only listen for first event 2013-02-07 14:06:05 -07:00
Frederic Junod
a36145fc1f Check if the Geolocation API is supported 2013-02-07 16:20:15 +01:00
Frederic Junod
44a5eca437 Add ol.Geolocation.isSupported property 2013-02-07 15:59:12 +01:00
Tom Payne
c884a916bf Merge pull request #178 from twpayne/clean-example-list-xml
Ensure ./build.py -c cleans examples/example-list.xml
2013-02-07 05:27:20 -08:00
Tom Payne
218bf2c78b Improve LRUCache containsKey test, thanks @tschaub 2013-02-07 12:21:12 +01:00
Bart van den Eijnden
f16664cb87 add an example 2013-02-07 10:45:35 +01:00
Frédéric Junod
f7ba03f4dd Merge pull request #179 from fredj/kinetic-update-arg
Change ol.Kinetic.update and begin arguments.
2013-02-07 00:08:01 -08:00
Tim Schaub
5bbd8fd9f3 Using ol.TileCache for managing canvas tiles 2013-02-06 18:23:39 -07:00
Tim Schaub
11b8c0ff47 Don't generate new tiles while animating 2013-02-06 17:47:03 -07:00
Tim Schaub
e079c19413 Don't repeatedly render while waiting for tiles to load
Instead of going into an unnecessary animation loop, we can simply wait to be notified when tiles load.

The WebGL renderer still sets frameState.animate true, but I think this too should be unnecessary (full page example works without it, side-by-side example shows it cannot yet be removed).
2013-02-06 16:10:46 -07:00
Tim Schaub
2bd29ff60e Only track tiles that are actually wanted
Instead of keeping track of wanted tile ranges, we can instead track wanted tiles individually.  This provides enough for the map to know how to prioritize tiles and should be more efficient (no extra calls to extend tile ranges or check for tile containment within a range).
2013-02-06 16:08:24 -07:00
Tim Schaub
e335b7b74a Make frame state available before rendering frame
Without this change, tiles that are enqueued on the first rendering will always get priority `ol.TileQueue.DROP` because `map.frameState_` is not yet defined (meaning a single render call doesn't result in any tiles loading).
2013-02-06 16:02:26 -07:00
Tim Schaub
a2bbdf7ccc More natural names for animations 2013-02-06 13:43:54 -07:00
Tom Payne
0b6aeb5b05 Remove unused and erroneous function, thanks @tschaub 2013-02-06 21:43:48 +01:00
Frédéric Junod
9c9fe4a9b1 Merge pull request #181 from fredj/rotation-anim
Replace ol.animation.createSpin with ol.animation.createRotateFrom
2013-02-06 08:39:22 -08:00
Frederic Junod
3355f9345d Replace ol.animation.createSpin with ol.animation.createRotateFrom 2013-02-06 17:10:21 +01:00
ahocevar
4e971b6041 Faster extent + geometry type queries
By maintaining separate R-Trees for each geometry type, we cover
the most critical query from the canvas renderer at higher
speeds. Using the filter's own evaluate method, we can now also
serve arbitrary queries, but they won't be fast.

Still needs unit tests.
2013-02-06 16:42:55 +01:00
ahocevar
619803cdeb More goog.requires fixes 2013-02-06 16:36:42 +01:00
ahocevar
a13e6bdfda Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-02-06 16:27:45 +01:00
ahocevar
61e4452c83 Adding missing and removing unused goog.requires 2013-02-06 16:26:24 +01:00
Bart van den Eijnden
6484760507 make Travis build pass again 2013-02-06 14:35:43 +01:00
Bart van den Eijnden
360c426f14 add WMS GetCapabilities parser for WMS 1.1.0, 1.1.1, 1.1.1 WMS-C profile and WMS 1.3.0 2013-02-06 14:25:57 +01:00
Frederic Junod
2fea469037 Change ol.Kinetic.update arguments.
Instead of goog.events.BrowserEvent, accept a x,y pair.
2013-02-06 12:55:15 +01:00
Tom Payne
3692918ed7 Remove unnecessary undercores, thanks @fredj 2013-02-06 12:50:34 +01:00
Tom Payne
91141f5c01 Build precommit target by default so precommit dependencies get cleaned by default 2013-02-06 11:25:15 +01:00
Tom Payne
90730e40a3 Ensure ./build.py -c cleans examples/example-list.xml 2013-02-06 11:23:04 +01:00
Frederic Junod
753b37ad47 Add 'undefined' return type for all get* functions 2013-02-06 11:00:55 +01:00
Frederic Junod
a679bb7bef Set handleProjectionChanged from protected to private 2013-02-06 10:59:18 +01:00
Tom Payne
0c205da290 Merge pull request #176 from twpayne/lru-cache
LRU Cache
2013-02-06 01:15:04 -08:00
Tom Payne
b1df0cac65 Rename object properties so compiler can rename them 2013-02-06 10:08:03 +01:00
Tom Payne
c37837ba34 Use an object literal rather than a class for LRUCache entries 2013-02-06 10:08:03 +01:00
Tim Schaub
0c48fbd188 Check sooner and only assert if duration hasn't passed 2013-02-05 10:50:18 -07:00
ahocevar
089b7013c2 Merge branch 'master' of github.com:openlayers/ol3 into vector
Conflicts:
	src/ol/renderer/canvas/canvasrenderer.js
	test/ol.html
2013-02-05 17:28:36 +01:00
ahocevar
386b97cf9a Merge branch 'master' of github.com:openlayers/ol3 into vector
Conflicts:
	src/ol/renderer/canvas/canvasrenderer.js
	test/ol.html
2013-02-05 17:17:09 +01:00
ahocevar
dafa48da2e Using spatial index and combined filters
This should significantly speed up feature access. Needs unit
tests.
2013-02-04 22:51:58 +01:00
ahocevar
c58f0afcc3 New R-Tree struct for spatial indexing.
This needs unit tests.
2013-02-04 22:50:59 +01:00
ahocevar
428793cd7c New filters for extent and logical filtering
These need unit tests.
2013-02-04 22:50:21 +01:00
Tom Payne
c34fe519c0 Remove ol.structs.LinkedMap 2013-02-04 18:37:12 +01:00
Tom Payne
1f460975bb Port WebGL texture cache to ol.structs.LRUCache 2013-02-04 18:37:12 +01:00
Tom Payne
06eb3040af Port ol.TileCache to ol.structs.LRUCache 2013-02-04 18:37:12 +01:00
Tom Payne
c99ec2d834 Add ol.structs.LRUCache 2013-02-04 18:37:12 +01:00
Frederic Junod
114280e60e Add a marker at the device position 2013-02-04 12:29:20 +01:00
Éric Lemoine
bde61a0b4b Simplify control architecture 2013-02-04 10:18:33 +01:00
Frederic Junod
6675de437f Handle projection change in ol.Geolocation 2013-02-04 09:46:31 +01:00
ahocevar
43dd9ca68c Don't use unshift 2013-02-02 12:29:08 +01:00
Frederic Junod
38f245c5c8 Add projection property to ol.Geolocation 2013-02-01 13:53:55 +01:00
Frederic Junod
37e172f043 Add missing export file for ol.Geolocation 2013-02-01 13:50:43 +01:00
Frederic Junod
035f487dc5 Add ol.Geolocation 2013-02-01 11:10:17 +01:00
Éric Lemoine
f735a597fe Merge pull request #171 from elemoine/testdeps2
Use namespaces for tests
2013-01-31 02:02:33 -08:00
Éric Lemoine
bd2ab93e9e Merge pull request #172 from elemoine/missingvar
Missing var's in a test file
2013-01-31 02:01:55 -08:00
Éric Lemoine
bfb6d0ca87 Missing var's in a test file 2013-01-31 11:01:06 +01:00
Tom Payne
4f1d3c5201 Merge pull request #169 from twpayne/check-requires
Fix use of goog.requires
2013-01-31 01:36:32 -08:00
Éric Lemoine
b6ed5f2164 Use namespaces for tests
With this commit test files provide namespaces (using goog.provide). This fixes the issue reported by @bartvde where goog objects cannot be used in Jasmine "describe" functions. It also frees us from having to add script tags for the test files in test/ol.html.
2013-01-31 10:18:21 +01:00
Tom Payne
93976a5d9f Fix requires relating to recent commits 2013-01-30 23:47:13 +01:00
Tom Payne
f9eb7dc477 Add missing requires to examples 2013-01-30 23:47:13 +01:00
Tom Payne
e6eb401e36 Add missing goog.requires 2013-01-30 23:47:13 +01:00
Tom Payne
c9e8a92265 Detect missing goog.requires 2013-01-30 22:48:04 +01:00
Tom Payne
6e247d9331 Rename modules for support detection 2013-01-30 22:48:03 +01:00
Tom Payne
b6f856f962 Remove unused goog.requires 2013-01-30 22:48:03 +01:00
Tom Payne
7d5cc39555 Detect unused goog.requires 2013-01-30 22:48:03 +01:00
ahocevar
9a0f509a94 Use objects instead of arrays for geometry type cache
Also trying to reference features directly here instead of
storing feature ids in the index. We'll see if this is good when
we have an index for tile coords as well and want to filter
with multiple filters, accessing multiple indices.
2013-01-30 18:03:27 +01:00
ahocevar
e61c26830e Manage tile cache
This change implements a LRU policy for tile cachint, and keeps
128 tiles in the cache by default.
2013-01-30 17:09:43 +01:00
ahocevar
1ecbc36a39 Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-01-30 15:54:24 +01:00
Bruno Binet
a64e4ae579 Merge pull request #164 from bbinet/kinetic
Add support for kinetic effect while dragging
2013-01-30 06:26:01 -08:00
Bruno Binet
d2f30986db Set kinetic getDuration instance method to @private 2013-01-30 14:46:49 +01:00
Bruno Binet
dff8c2b2b2 Renaming to be more consistent with ol3 style
s/v_0/initialVelocity/
s/v_min/minVelocity/
2013-01-30 14:46:49 +01:00
Bruno Binet
d91e1d30d4 Get rid of binarySelect to find the first point. 2013-01-30 14:46:49 +01:00
Bruno Binet
79849888db Kinetic now returns directly the pre-render function
instead of returning the kinetic easing function only.

(thanks @fredj)
2013-01-29 15:34:11 +01:00
Bruno Binet
2bb8a5cfd9 Stop current kinetic animation on DOWN events 2013-01-29 14:32:38 +01:00
Éric Lemoine
773e34d736 Merge pull request #165 from elemoine/classname
Change class names in DOM renderer
2013-01-29 04:02:18 -08:00
Bruno Binet
39cbba3eb7 Add a frameState property to ol.MapBrowserEvent
so that we will be able to retrieve the current center of the view2d from the
framestate in the dragpan interaction.
2013-01-29 13:00:02 +01:00
Bruno Binet
d54864695d Add a removePreRenderFunction method to ol.Map
This will remove the pre-render function from preRenderFunctions_ array if
found.
2013-01-29 12:56:15 +01:00
Bruno Binet
7d0b4c757e Activate kinetic effect by default 2013-01-29 12:39:52 +01:00
Bruno Binet
8a9738d755 Add support for kinetic effect while dragging.
Only dragpan interaction is supported for now.

The kinetic effect use the maths below (thx @twpayne):

Rate of decay (number, must be negative) = α
Minimum velocity (pixels/millisecond) = v_min
Initial velocity (pixels/millisecond) = v₀

Velocity at time t (pixels/millisecond) =
    α⋅t
v₀⋅ℯ

Distance travelled at time t (pixels) =
   ⎛ α⋅t    ⎞
v₀⋅⎝ℯ    - 1⎠
─────────────
      α

Duration of animation (milliseconds) =
   ⎛v_min⎞
log⎜─────⎟
   ⎝  v₀ ⎠
──────────
    α

Total distance travelled (pixels) =
-v₀ + v_min
───────────
     α

Easing function =
   ⎛ α⋅duration⋅t    ⎞
v₀⋅⎝ℯ             - 1⎠
──────────────────────
     -v₀ + v_min
2013-01-29 12:39:52 +01:00
Frédéric Junod
47fbdb53e2 Merge pull request #167 from fredj/mapbrowserevent-listen
Listen to all ol.MapBrowserEvent events
2013-01-29 03:15:19 -08:00
Frederic Junod
a980de7830 Listen to all ol.MapBrowserEvent events 2013-01-29 11:29:27 +01:00
Tom Payne
bef1b9aea5 Merge pull request #163 from twpayne/attribution-control-clean-ups
Attribution control clean ups
2013-01-29 02:22:30 -08:00
Tom Payne
2e401b43f4 Make attribution control unselectable 2013-01-29 11:21:57 +01:00
Tom Payne
c2c87a80a1 Remove duplicate CSS rule 2013-01-29 11:21:57 +01:00
Tom Payne
d22c441795 Merge pull request #162 from twpayne/canvas-visibility-and-opacity
Canvas visibility and opacity
2013-01-29 02:20:39 -08:00
Éric Lemoine
0c25aa95ea Merge pull request #166 from elemoine/extracomma
Change a comma to a semi-colon (thanks @bbinet)
2013-01-29 01:34:23 -08:00
Éric Lemoine
713828d953 Change a comma to a semi-colon (thanks @bbinet) 2013-01-29 10:33:35 +01:00
Éric Lemoine
8713e84821 Change class names in DOM renderer 2013-01-29 10:24:25 +01:00
Tom Payne
3bd1b92b05 Promote renderFrame from ol.renderer.*.LayerRender to ol.renderer.LayerRenderer 2013-01-28 19:56:57 +01:00
Tom Payne
5558d6108c Promote handleLayerRendererChange from ol.renderer.webgl.Map to ol.renderer.Map 2013-01-28 19:56:56 +01:00
Tom Payne
49734de240 Promote dispatchChangeEvent from ol.renderer.webgl.Layer to ol.renderer.Layer 2013-01-28 19:56:56 +01:00
Tom Payne
4701d117f7 Always dispatch change events on load/opacity/visible changes 2013-01-28 19:56:56 +01:00
Bart van den Eijnden
c51b2b3fef add info about install Jasmine and the precommit hook from build.py 2013-01-28 15:18:15 +01:00
Frédéric Junod
eb103d3bd1 Merge pull request #160 from fredj/dblclick-unlisten
Remove event listener cleanups
2013-01-28 04:19:24 -08:00
Éric Lemoine
faee272fac Merge pull request #161 from elemoine/nullimage
Do not draw image if image is null
2013-01-28 03:51:17 -08:00
Éric Lemoine
1d2551dbcb Do not draw image if image is null 2013-01-28 12:41:46 +01:00
Frederic Junod
f8646394ae Remove event listener with goog.events.unlistenByKey 2013-01-28 10:37:32 +01:00
Frederic Junod
9e030854b2 Don't remove event listener for this.handleUp_ twice.
The listener key is in this.dragListenerKeys_
2013-01-28 10:31:24 +01:00
Frederic Junod
01098c4d8c Remove event listener with goog.events.unlistenByKey 2013-01-28 10:26:09 +01:00
Frederic Junod
f208e99c64 Add missing goog.events.EventType.DBLCLICK argument to unlisten 2013-01-28 09:54:41 +01:00
Frederic Junod
43fe004917 Add a comment about msTouchAction css on viewport 2013-01-25 17:37:04 +01:00
Frédéric Junod
36500682c3 Merge pull request #157 from fredj/ms-touch
Direct all pointer events to js code (IE pointer events)
see: http://msdn.microsoft.com/en-us/library/ie/hh673557(v=vs.85).aspx
2013-01-25 08:16:05 -08:00
ahocevar
65b3bb70a1 Some optimizations
* Tiles are now cut out of the sketch renderer in a separate
  pass. This ensures that point features at tile borders appear
  at both sides of the border. However, if such features get
  added in a later tileRange rendering pass, tiles from a
  previous rendering pass will still not have that feature.
* The tile canvas is only created once, and cloneNode(false) is
  used to get a canvas for a new tile.
2013-01-25 16:46:12 +01:00
Frederic Junod
9c794d8b00 Direct all pointer events to js code (IE pointer events).
see: http://msdn.microsoft.com/en-us/library/ie/hh673557(v=vs.85).aspx
2013-01-25 16:38:45 +01:00
Frederic Junod
bf63ddfebe Test if browser supports Windows Pointer events 2013-01-25 16:38:45 +01:00
Marc Jansen
a6f987049e Merge pull request #154 from marcjansen/todo
Add fixme/todo target to build.py.
2013-01-24 23:47:52 -08:00
Tim Schaub
a7737150fe Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-01-24 22:21:25 -07:00
Tim Schaub
4e3f984796 Properly rendering features to canvas tiles
It looks like this approach will work well for panning (as anticipated).  For animated zooming, it is not going to work as is.  It looks like the canvas tile generation is too much for this type of animation loop.  Though there are clearly still areas for optimization:

 * Don't create new tiles while animating between zoom levels.  Using existing tiles only while animating should bring a significant performance gain.
 * Simple spatial index for tiles - each tile coord in the matrix could have a feature lookup object (keyed by id).  This needs to account for rendered dimension (as witnessed by the point being cut by a tile).  Given that the current example uses only three features, adding the spatial index should only be a minor improvement.
 * Reuse a fixed set of canvas tiles that are generated at construction (and increased/decreased with view size changes).
 * If a fixed set of tiles is not used, at least new ones could be cloned from existing ones (minor).
 * Do some profiling to look for more ideas.

In addition, world-wrapping needs addressed.  I don't think this renderer is the right (or at least the only) place to address this.  And the cache of tiles needs to be managed for real.  But hey, at least we've got a working tiled vector renderer now.
2013-01-24 21:57:12 -07:00
Tim Schaub
f2b325b430 Adding convenient tile labels for debugging
This will be removed when behavior is right.
2013-01-24 17:16:54 -07:00
Tim Schaub
033daa425b Reverting b0a7badc8f
I think it's complicating things at this point to deal with this.  Unfortunately, it's not proper dateline wrapping as is (only arbitrary tile range extent wrapping).
2013-01-24 17:15:32 -07:00
Tim Schaub
8d5a45d827 Set up example for debugging 2013-01-24 16:51:10 -07:00
Éric Lemoine
fc9bfe8460 Merge pull request #159 from elemoine/renderpath
Simplify map renderer
2013-01-24 14:23:22 -08:00
Éric Lemoine
98b264e8ce Add comment 2013-01-24 22:31:57 +01:00
Éric Lemoine
80b38e608b No more need for listener keys array 2013-01-24 22:31:53 +01:00
Éric Lemoine
4a64837ba1 Make map handle background color changes 2013-01-24 22:31:08 +01:00
Éric Lemoine
2a28b7c699 Add comment 2013-01-24 22:31:08 +01:00
Éric Lemoine
15898b559b Make map handle size changes 2013-01-24 22:31:08 +01:00
Éric Lemoine
71a462cd54 Make map handle view changes
With the frameState stuff the map renderer need not listen to view changes. The map renderer receives orders from the map. These orders are renderFrame_ calls with frameState objects representing the current state.
2013-01-24 22:31:06 +01:00
Tom Payne
0bb31150b0 Merge pull request #148 from twpayne/anchored-elements
Replace ol.overlay.Overlay with ol.AnchoredElement
2013-01-24 09:36:40 -08:00
ahocevar
b0a7badc8f Started on proper date line wrapping
What we want in the end is vector tiles repeated just as raster
tiles. This change only avoids repeated tiles with the same
content being rendered and stored in the cache.
2013-01-24 17:29:21 +01:00
Tom Payne
309ddad4fe Merge pull request #152 from twpayne/texture-cache-expiry
Texture cache expiry
2013-01-24 07:36:06 -08:00
Tom Payne
8cac270234 Use + rather than Number for string to number conversion 2013-01-24 16:31:56 +01:00
Tom Payne
ace0728e8a Merge pull request #151 from twpayne/tile-cache-expiry
Tile cache expiry
2013-01-24 07:24:33 -08:00
ahocevar
fe605ceebb Better, but still not all the way there 2013-01-24 16:21:30 +01:00
Éric Lemoine
197ef89964 Merge pull request #156 from elemoine/examplefix
Remove ref to userProjection
2013-01-24 01:35:14 -08:00
Éric Lemoine
dc9fb06185 Remove ref to userProjection
The wms-custom-proj example sets a userProjection in the map while userProjection is gone for now. It was removed in 927cffb2.
2013-01-24 10:32:32 +01:00
Éric Lemoine
0945f19620 Merge pull request #155 from elemoine/typo
Fix typo in a typedef
2013-01-24 01:29:43 -08:00
Éric Lemoine
d04b2bb2bd Fix typo 2013-01-24 10:28:28 +01:00
Tim Schaub
9bd1ab99d1 Toward tiled vector rendering 2013-01-24 02:06:40 -07:00
Marc Jansen
69b915620d Add fixme/todo target to build.py.
Will show a list of lines in sourcefiles that either contains the string TODO
or FIXME.

Example output:

    user@host:~/src/ol3 $ ./build.py fixme
      src/ol/source/xyzsource.js has 4 matches:
        #1         // FIXME add minZoom support
        #46        // FIXME use goog.nullFunction ?
        #59        // FIXME factor out common code
        #76        // FIXME we shouldn't need a typecast here

      src/ol/interaction/dragpaninteraction.js has 2 matches:
        #1         // FIXME works for View2D only
        #39        // FIXME works for View2D only
2013-01-24 10:04:36 +01:00
Tim Schaub
483e309216 Merge pull request #153 from tschaub/extent
Care with transform
2013-01-24 00:56:18 -08:00
Tim Schaub
3ccfaebcfc Punctuated 2013-01-23 22:18:00 -07:00
Tim Schaub
afb9add911 Checked with third-party tool 2013-01-23 22:12:17 -07:00
Tim Schaub
0845dea366 Care with transform
Since the transform method takes an arbitrary transform function, new coordinates may not be ordered in the same way as the originals.
2013-01-23 22:03:08 -07:00
ahocevar
4a54cc69ce Tiled vector rendering
This needs more work still - see inline TODOs. It also has a
major bug - rendered vector features do not scale and do not
change their offset during panning. So only the initial view is
correct.
2013-01-23 21:37:06 +01:00
Tom Payne
b0eb7a4b9b Port ol.TileCache to ol.structs.LinkedMap 2013-01-23 19:59:03 +01:00
Tom Payne
0d7196c098 Expire old textures from texture cache 2013-01-23 19:59:02 +01:00
Tom Payne
3f6ef77a5a Add ol.structs.LinkedMap.prototype.peekLastKey 2013-01-23 19:59:02 +01:00
Tom Payne
c7d0712480 Rename goog.structs.LinkedMap to ol.structs.LinkedMap 2013-01-23 19:59:02 +01:00
Shawn Brenneman
140f8c8683 Add goog.structs.LinkedMap from Closure Library 2013-01-23 19:58:50 +01:00
Frédéric Junod
d6c96c058f Merge pull request #133 from fredj/options-obj
ol.animation.create* functions should use options objects rather than positional arguments
2013-01-23 08:50:22 -08:00
Tom Payne
0f3d708525 Use ol.TileCache in ol.source.DebugTileSource 2013-01-23 17:22:01 +01:00
Tom Payne
09ec444958 Use ol.TileCache in ol.source.ImageTileSource 2013-01-23 17:22:01 +01:00
Tom Payne
b034299158 Add ol.TileCache 2013-01-23 17:22:00 +01:00
Frederic Junod
7568688301 Use option object rather than positional arguments for ol.animation.create* functions 2013-01-23 17:07:55 +01:00
Tom Payne
b770aaa2f5 Add tile cache expiry infrastructure 2013-01-23 14:31:24 +01:00
Marc Jansen
6d3e0778e1 Merge pull request #150 from marcjansen/zoombtn-radius
Adjust border-radius of zoom buttons.
2013-01-22 23:56:28 -08:00
Marc Jansen
9af78dd2fe Adjust border-radius of zoom buttons. 2013-01-23 08:14:55 +01:00
Tim Schaub
07a56bfe3f Parsing GeoJSON FeatureCollection 2013-01-22 17:41:22 -07:00
Tim Schaub
35f6984e69 Unused var and some notes 2013-01-22 11:21:35 -07:00
Tom Payne
dda51ecec2 Replace ol.overlay.Overlay with ol.AnchoredElement
This commit adds several features:
- rename of class to better reflect its behaviour
- full ol.Object support
- integration with postrender event for integration with animations and
  render loop
- minimised DOM modifications
- more precise positioning
- element placed in DIV to avoid modifications to user-supplied element
- correctly handle changes to the positioning property
2013-01-22 15:12:25 +01:00
Tom Payne
4ab09d6df2 Merge pull request #140 from twpayne/array-clean-ups
Array clean ups
2013-01-22 06:00:04 -08:00
ahocevar
4e6b864e27 Making default symbolizers compiler safe 2013-01-22 14:09:04 +01:00
ahocevar
16865fc1fa Removing no longer needed Tiled Vector Source. 2013-01-22 13:24:37 +01:00
Tom Payne
f2164e5028 Export map.getLayers 2013-01-22 13:08:40 +01:00
Marc Jansen
577fc86684 Merge pull request #147 from marcjansen/goog.now
Use goog.now() instead of Date.now().
2013-01-22 03:13:15 -08:00
Marc Jansen
8d979127fc Use goog.now() instead of Date.now().
Date.now() is not supported in Internet Explorer up to IE 9. The goog.now()
method can be used as a replacement.
2013-01-22 12:01:44 +01:00
Tim Schaub
c50fcecf42 Vector rendering example
There is a ton of room for optimization here.  The vector layer renderer should only render dirty areas and could maintain a cache of rendered canvas tiles.  The vector source could have a simple spatial index for features (by tile coord).  Need to also discuss how to work with this animation framework (to avoid the excess work while waiting for tiles to load on every other layer).
2013-01-22 01:46:27 -07:00
Tim Schaub
1dd17fc88f Rendering vector layers 2013-01-22 01:36:32 -07:00
Éric Lemoine
a1ff01e7a5 Merge pull request #145 from elemoine/readme
Update readme.md
2013-01-21 23:42:01 -08:00
Éric Lemoine
8d56b5f261 Update readme.md 2013-01-22 08:39:37 +01:00
Tim Schaub
92c8c9c5df Shape extends point 2013-01-21 23:20:52 -07:00
Tim Schaub
45af404f4b Initial tests for filter 2013-01-21 18:06:29 -07:00
Tim Schaub
e4132813af Shorter name 2013-01-21 18:06:14 -07:00
Tim Schaub
f80f4fab36 Symbolizer literals will be cached by the renderer 2013-01-21 18:03:25 -07:00
Tim Schaub
0f33561af2 Skeleton canvas renderer for vector layer 2013-01-21 18:02:28 -07:00
Tim Schaub
1a63bf078f Basic vector source and layer
The vector source maintains a cache of features.  These are indexed by geometry type in anticipation of the renderer's needs.
2013-01-21 17:59:09 -07:00
Tim Schaub
9543ce4d4a Initial filter package, geometry type filtering only for now 2013-01-21 17:57:12 -07:00
Tim Schaub
89bc69ccc1 Types for rings and mixed collections 2013-01-21 17:56:12 -07:00
Tim Schaub
6ef2184c83 Geometry type enumeration 2013-01-21 17:46:41 -07:00
Tim Schaub
0fad23970c Disallowing mixed geometry collections for now 2013-01-21 14:46:45 -07:00
Tim Schaub
7ef127cfac Shorter name for ol.Feature 2013-01-21 14:46:02 -07:00
Tim Schaub
b4d44f815f Add getBounds to geometry 2013-01-21 12:59:04 -07:00
Tim Schaub
216d30ddc1 Getting the nanometer precision we deserve with web mercator 2013-01-21 10:52:17 -07:00
Tim Schaub
3cf3ef629c Lint
Caught by `build.py precommit` not `build.py lint`.
2013-01-21 10:51:38 -07:00
Frederic Junod
be64408728 Export map as jpeg instead of png 2013-01-21 16:13:19 +01:00
Frédéric Junod
9969a64d81 Merge pull request #143 from fredj/get-renderer-canvas
Get renderer canvas
2013-01-21 07:09:18 -08:00
Frederic Junod
8cbe0fbbbb Export canvas map as jpeg image 2013-01-21 16:08:33 +01:00
Tom Payne
c0ef84fd5d Remove stale dependencies 2013-01-21 16:07:06 +01:00
ahocevar
300c1048bd Cache and bucket fixes 2013-01-21 15:56:35 +01:00
Frederic Junod
2f2ea373ca Add ol.renderer.Map.getCanvas function. Only valid with the canvas and webgl renderers 2013-01-21 15:18:18 +01:00
Frederic Junod
c836c8d9c4 Add ol.Map.getRenderer function 2013-01-21 15:08:15 +01:00
Tom Payne
f1b11866fd Remove dependency on goog.array 2013-01-21 14:20:12 +01:00
Tom Payne
3967e17366 Use in-place filtering for pre-render functions 2013-01-21 14:20:12 +01:00
Tom Payne
d76db2005f Use for loop for iterating over layers 2013-01-21 14:20:12 +01:00
Tom Payne
7229428741 Use in-place filtering for post-render functions 2013-01-21 14:20:11 +01:00
Tom Payne
386bb636bb Add missing dependencies on goog.array 2013-01-21 14:20:11 +01:00
ahocevar
e060498fad Fixing compiler errors (mostly caused by typos) 2013-01-21 13:41:18 +01:00
Frédéric Junod
a51cd3b9bd Merge pull request #139 from fredj/easing
Add new ol.easing.elastic and ol.easing.bounce easing functions.
2013-01-21 04:36:45 -08:00
Éric Lemoine
2f539bf3be Merge pull request #126 from openlayers/tilequeue
Tile queue requires optimizing
2013-01-21 03:41:18 -08:00
Éric Lemoine
c6a8e5ef72 Remove unused Jasmine matchers 2013-01-21 12:29:31 +01:00
ahocevar
d3e63bc98a Basic feature implementation 2013-01-21 12:16:04 +01:00
Frederic Junod
8825251c42 Add new ol.easing.elastic and ol.easing.bounce easing functions. 2013-01-21 09:48:56 +01:00
ahocevar
d0d397f98f Tiled vector source
This source has features and provides tiles with the feature
geometries rendered, using the feature symbolizers. Needs more
work because it is still very unefficient, because it renders
all feature geometries to all tiles, and uses a collection of
features, which we do not have yet.
2013-01-20 21:23:19 +01:00
Tom Payne
202df34e71 Merge pull request #137 from twpayne/alt-shift-rotate
Use Alt+Shift to rotate by default, fixes #21
2013-01-20 10:38:24 -08:00
Éric Lemoine
7f38c1683e Remove unused TileQueue clear method 2013-01-20 15:15:13 +01:00
Tim Schaub
4c2ad60619 Add geojson module in io package 2013-01-20 00:28:07 -07:00
Tim Schaub
497eac82c2 Polygon rendering (no holes yet) 2013-01-19 17:50:04 -07:00
Tom Payne
9ef5f0b060 Ensure dropped tiles are properly removed from tile queue 2013-01-19 21:58:01 +01:00
Tom Payne
3383c426b3 Use shifts rather than floor 2013-01-19 18:35:24 +01:00
Tom Payne
d43abba154 Use stricter types in private methods, operate on array directly 2013-01-19 15:52:55 +01:00
Tom Payne
6507e71dd7 Clear queued tile keys when queue is cleared 2013-01-19 15:44:01 +01:00
Tom Payne
2bdfd3765b Remove stale FIXME 2013-01-19 15:38:15 +01:00
Tom Payne
4b971b5f32 Optimize tile dropping in reprioritize 2013-01-19 15:24:50 +01:00
Tom Payne
a8dc810696 Use Infinity rather than undefined to drop tiles 2013-01-19 15:24:02 +01:00
Tom Payne
4846a6a7b3 Only update wanted tiles if not all tiles are loaded 2013-01-19 15:03:01 +01:00
Tom Payne
3ec2014ad1 Rename tileUsage to usedTiles 2013-01-19 15:03:01 +01:00
Tom Payne
1c524caae6 Discard unwanted tiles from tile queue 2013-01-19 15:03:01 +01:00
Tom Payne
111b4585a8 Fix key usage 2013-01-19 14:50:25 +01:00
Tom Payne
7babfebef9 Set frame state immediately after rendering 2013-01-19 14:50:18 +01:00
Tom Payne
9cf314fd64 Sort object properties 2013-01-19 14:50:14 +01:00
Tim Schaub
0414e337b3 Render lines 2013-01-18 17:57:32 -07:00
Tim Schaub
140e9ba355 General purpose canvas renderer
Currently only renders points as circles.  Eventually will have methods for other geometry types and other symbolizer types.  Also provides static methods to render point symbolizers (returning a canvas that can be drawn on another).
2013-01-18 17:42:12 -07:00
Tim Schaub
b92fdaf911 Going with point, line, and polygon symbolizers
Separate fill and stroke symbolizers make a nicer API, but less efficient rendering
2013-01-18 17:20:10 -07:00
Tim Schaub
fd0a5f3622 Point, linestring, and linearring coordinates as Float32Array 2013-01-18 15:57:48 -07:00
Tim Schaub
278d32061f To be reworked for rendering like geoms with same symbolizer 2013-01-18 15:55:24 -07:00
Tim Schaub
3ac437393a To be reworked as ol.renderer.canvas.VectorLayer 2013-01-18 15:54:48 -07:00
Éric Lemoine
c0c9cdef15 New tile queue implementation (heapify-powered) 2013-01-18 21:02:09 +01:00
Tom Payne
f3978d200f Use Alt+Shift to rotate by default, refs #21 2013-01-18 14:09:32 +01:00
Tom Payne
2b8aefbabf Add ol.condition.altShiftKeysOnly 2013-01-18 14:03:37 +01:00
Peter Robins
11938d2264 Add missing dependencies, refs #116 2013-01-18 13:01:10 +01:00
Tim Schaub
74281d2b00 Merge from master 2013-01-17 18:12:06 -07:00
Tom Payne
f377a70dc5 Export ol.Map.addPreRenderFunction* 2013-01-18 01:59:59 +01:00
Tom Payne
1c2a1a2a2f Sort object literal exports alphabetically 2013-01-18 01:19:51 +01:00
Tom Payne
bff8a2bb1e Add DebugTileSource exports 2013-01-18 01:16:14 +01:00
Tom Payne
bb51709945 Use OpenStreetMap tiles in canvas tiles example
Stamen exports aren't quite right yet.
2013-01-18 00:34:44 +01:00
Tom Payne
6542f2037b Merge pull request #127 from twpayne/animated-zoom
Animated zoom
2013-01-17 15:23:39 -08:00
Tom Payne
37d29fb82b Merge pull request #131 from twpayne/add-missing-exports
Add missing exports
2013-01-17 15:21:28 -08:00
Tom Payne
e3c85dec8e Export ol.View2D 2013-01-18 00:19:45 +01:00
Tom Payne
d34a71e453 Export ol.RendererHints.createFromQueryData 2013-01-18 00:19:22 +01:00
Tom Payne
76e600d5f6 Fix Stamen exports 2013-01-18 00:19:06 +01:00
Tom Payne
4f2c657cf2 Export ol.tilegrid.XYZOptions 2013-01-18 00:17:50 +01:00
Tom Payne
0122c6cc0c Export ol.tilegrid.TileGridOptions 2013-01-18 00:17:09 +01:00
Tim Schaub
fe56b15c52 Clear canvas with opacity 1 2013-01-17 15:30:16 -07:00
Tom Payne
7c660f6ac0 Export animation functions, thanks @elemoine 2013-01-17 22:58:05 +01:00
Tim Schaub
d6de79b2bd Merge pull request #129 from tschaub/color
Going with CSS norms for r/g/b/a values.
2013-01-17 13:28:51 -08:00
Tim Schaub
f39b6a1be3 Errant require 2013-01-17 14:23:35 -07:00
Tim Schaub
10672ad303 Standardizing color ranges (see #129) 2013-01-17 14:19:50 -07:00
Tim Schaub
b36eab1dfa Properly set transform before filling background (closes #128)
Order of args is m11, m12, m21, m22, dx, dy
2013-01-17 13:40:00 -07:00
Tim Schaub
141e5aa9fc Trim search string before use
The `window.location.search` string includes the "?" symbol.  Without this change, `createFromQueryData` only works if the "renderer" parameter is not in first position (see 4037bafc45).
2013-01-17 13:05:47 -07:00
Tom Payne
9428a94968 Add animated zoom to keyboard zoom interaction 2013-01-17 16:21:53 +01:00
Tom Payne
90b7cfb330 Add animated zoom to zoom control 2013-01-17 16:21:53 +01:00
Tom Payne
965d5e2cc8 Add animation duration to ol.View2D.zoom 2013-01-17 15:50:28 +01:00
Tom Payne
0257db05df Add zoom from animation 2013-01-17 15:38:11 +01:00
Tom Payne
95b48bdec4 Add ol.easing.linear 2013-01-17 15:38:11 +01:00
Tom Payne
8d9ac88db7 Merge pull request #123 from twpayne/canvas-renderer
Canvas renderer
2013-01-17 06:22:20 -08:00
Tom Payne
5eeec41877 Add canvas renderer to two layers demo 2013-01-17 13:54:52 +01:00
Tom Payne
aeef260101 Add canvas renderer to side-by-side demo 2013-01-17 13:54:52 +01:00
Tom Payne
54327fb750 Add canvas renderer 2013-01-17 13:54:52 +01:00
Tom Payne
7e7356dfd6 Add canvas checks 2013-01-17 13:54:52 +01:00
Tom Payne
1468a04f8b Merge pull request #122 from twpayne/default-tile-size
Add default tile @define, refs #114, fixes #120
2013-01-17 04:49:38 -08:00
Tom Payne
04b18a8a83 Merge pull request #121 from twpayne/attribution-control-refactoring
Attribution control refactoring
2013-01-17 04:46:57 -08:00
Tom Payne
c23e02eb71 Merge pull request #124 from twpayne/dom-renderer-layer-remove
Ensure DOM element is removed when layer is removed
2013-01-17 04:35:44 -08:00
Tom Payne
c961e77e9e Merge pull request #125 from twpayne/build-clean-ups
Build clean ups
2013-01-17 03:52:15 -08:00
Tom Payne
4657b7ca97 Remove removeLayer, thanks @fredj 2013-01-17 12:40:54 +01:00
Tom Payne
1ebea904ab Only run gjslint on modified files 2013-01-17 12:33:10 +01:00
Tom Payne
d8e980a9dd Upgrade to latest version of pake 2013-01-17 12:32:51 +01:00
Tom Payne
c56e1f8b92 Ensure DOM element is removed when layer is removed 2013-01-17 12:12:09 +01:00
Tom Payne
b880ab80ee Factor out updateTileUsage 2013-01-17 11:51:38 +01:00
Tom Payne
1278ccb942 Add default tile size @define, refs #114, fixes #120 2013-01-16 17:49:51 +01:00
ahocevar
8a38f9aa9d Merge branch 'master' of github.com:openlayers/ol3 into vector 2013-01-16 16:34:59 +01:00
Tom Payne
9fbabc3696 Refactor attribution control 2013-01-16 16:34:31 +01:00
ahocevar
7c05587aed Merge pull request #114 from ahocevar/resolutions
Use validity extent to generate default resolutions. r=@twpayne,@elemoine
2013-01-16 07:17:10 -08:00
Tom Payne
41ccb4dfcd Add ol.Rectangle.extend 2013-01-16 13:53:38 +01:00
Éric Lemoine
0d87c2c14c Merge pull request #91 from elemoine/bingkey
Bing maps key will expire on 15 Jan 2013
2013-01-16 03:32:27 -08:00
Éric Lemoine
0c1116fe95 Update Bing maps key 2013-01-16 12:31:25 +01:00
Tom Payne
17bb31281b Merge pull request #118 from twpayne/mouse-position-control-refactoring
Mouse position control refactoring
2013-01-16 02:30:33 -08:00
Tom Payne
06628a88e6 Update mouse position on each frame 2013-01-16 11:26:09 +01:00
Tom Payne
11ec1de89b Refactor mouse position control to use postrender event 2013-01-16 11:25:59 +01:00
Tom Payne
5d43aa22d4 Merge pull request #117 from twpayne/postrender-event
Fire postrender events
2013-01-16 02:08:16 -08:00
Tom Payne
505987869e Fire postrender events 2013-01-15 18:38:12 +01:00
Tom Payne
f7982fc2de Merge pull request #115 from twpayne/renderer-clean-ups
Renderer clean ups
2013-01-15 08:41:06 -08:00
Tom Payne
936132cd46 Update examples to read renderer from query string 2013-01-15 10:26:43 +01:00
Tom Payne
4037bafc45 Add function to chose renderer from query string 2013-01-15 10:26:16 +01:00
Tom Payne
859af576d5 Move var outside loop 2013-01-14 20:53:00 +01:00
Tom Payne
c679bccbb9 Join short lines 2013-01-14 20:53:00 +01:00
Tom Payne
183aac90fa Remove unused requires 2013-01-14 20:52:47 +01:00
Tom Payne
8966e17b89 Structure DOM renderer code to be more similar to WebGL renderer code 2013-01-14 16:33:15 +01:00
Tom Payne
af88fb415b Remove forEachTileCoord 2013-01-14 16:21:58 +01:00
Tom Payne
8ced15ce2e Move closure out of loop, and use loop rather than forEachTileCoord 2013-01-14 16:21:58 +01:00
Tom Payne
0916f14536 Use a loop rather than tileRange.forEachTileCoord 2013-01-14 16:21:58 +01:00
ahocevar
87ce763ccb Use validity extent to generate default resolutions
Previously, the TiledWMS source generated a resolutions array
derived from the world extent in meters, to match the default
Web Mercator resolutions of the map. This wouldn't work for
projections with distance units different than meters. It is
better to commit to a default resolutions array where zoom level
0 is the validity extent of the projection (not the Web Mercator
world extent!) at a 256 pixel tile size.
2013-01-14 16:10:55 +01:00
Tom Payne
57b25693af Merge pull request #113 from twpayne/frame-state
More frame state-related fixes and improvements
2013-01-14 04:13:22 -08:00
Tom Payne
eff96ca16c DOM renderer should re-render when layers are added or removed 2013-01-14 12:46:40 +01:00
Tom Payne
be04053ef1 Move common event handlers into base class 2013-01-14 12:46:39 +01:00
Tom Payne
9764e76975 Move pixel/coordinate matrices into frame state, remove canRotate 2013-01-14 12:46:39 +01:00
Tom Payne
a927385e72 Merge pull request #110 from twpayne/interaction-hints
Interaction hints
2013-01-14 03:44:47 -08:00
Tom Payne
3febb24529 Don't remove tiles when animating 2013-01-14 12:35:54 +01:00
Tom Payne
bafb53f2e1 Make animations set animating hint 2013-01-14 12:35:54 +01:00
Tom Payne
969553cede Clone hints array so that pre-render functions can modify it 2013-01-14 12:35:54 +01:00
Tom Payne
c48bb6142e Add animating hint 2013-01-14 12:35:54 +01:00
Tom Payne
2ea6f0903c Don't remove tiles while panning 2013-01-14 12:35:54 +01:00
Tom Payne
e837a74e00 Set panning hint in DragPanInteraction 2013-01-14 12:35:53 +01:00
Tom Payne
5d31a44c12 Implement view hints architecture 2013-01-14 12:35:53 +01:00
Tom Payne
2a08e7add2 Merge pull request #112 from twpayne/dom-renderer-clean-ups
DOM renderer clean ups
2013-01-14 03:33:23 -08:00
Tom Payne
fafba39c32 Merge pull request #111 from twpayne/webgl-renderer-clean-ups
WebGL renderer clean ups
2013-01-14 03:33:04 -08:00
Tom Payne
78e8e34fe6 Add missing instance variable declaration, thanks @elemoine 2013-01-14 11:13:34 +01:00
Tom Payne
be3849d1b8 Use dequeue rather than remove, thanks @elemoine 2013-01-13 22:28:37 +01:00
Tom Payne
8b39e8f7f0 Relax type slightly 2013-01-12 23:13:34 +01:00
Tom Payne
0f8e3ddedc Remove incorrect use of @override 2013-01-12 23:12:15 +01:00
Tom Payne
deeb7b3294 Fix typecast 2013-01-12 22:52:44 +01:00
Tom Payne
3f6e6169af Hide canvas when map is not defined 2013-01-12 19:24:20 +01:00
Tom Payne
0443ebc3fa Remove stale FIXMEs 2013-01-12 19:23:54 +01:00
Tom Payne
de7699d644 Hide layers pane when map is undefined 2013-01-12 19:08:27 +01:00
Tom Payne
a0180f2131 Remove stale FIXME 2013-01-12 19:06:00 +01:00
Tom Payne
97207e5723 Remove rarely-used logger 2013-01-12 19:01:09 +01:00
Tom Payne
be28fb4ccc Don't try to overload method return type 2013-01-12 18:58:36 +01:00
Tom Payne
655b6a1b00 Always free WebGL resources in post render 2013-01-12 18:57:50 +01:00
Tom Payne
a26deb62bf Remove unused variable 2013-01-12 18:54:09 +01:00
Tom Payne
b803aad5a8 Don't enqueue tiles which are not idle 2013-01-12 16:55:36 +01:00
Tom Payne
3d5c76c346 Add empty descriptions for jsdoc 2013-01-12 13:32:57 +01:00
Tom Payne
513787147c Merge pull request #106 from twpayne/re-enable-jsdoc
Re-enable jsdoc
2013-01-12 03:28:19 -08:00
Tom Payne
92d3d001c0 Merge pull request #108 from twpayne/texture-uploads
Prioritize and throttle texture uploads
2013-01-12 03:27:37 -08:00
Tom Payne
150dae4a63 Merge pull request #104 from twpayne/debug-tile-source-fixes
Don't attempt to share canvases between renderers, fixes #101
2013-01-12 03:27:17 -08:00
Tom Payne
c5a0205cf8 Merge pull request #103 from twpayne/tile-queue
Tile queue
2013-01-12 03:26:43 -08:00
Tom Payne
05d681e7ea Merge pull request #107 from twpayne/dom-renderer-clean-ups
Clean up DOM renderer code for untested minor performance advantages
2013-01-12 03:25:12 -08:00
Tom Payne
6d44736e2f Prioritize and throttle texture uploads 2013-01-12 02:32:53 +01:00
Tom Payne
82fc5c6c9d Clean up DOM renderer code for untested minor performance advantages 2013-01-12 01:12:27 +01:00
Tom Payne
60c0ca9e49 Re-add doc to precommit target, fixes #94 2013-01-12 00:52:27 +01:00
Tom Payne
48ee9e75a4 Add empty descriptions to work around jsdoc 2013-01-12 00:51:36 +01:00
Tom Payne
fca7472506 Update copyright year 2013-01-11 23:50:29 +01:00
Tom Payne
45a3b70ec0 Merge pull request #105 from twpayne/build-cleanups
Minor clean-ups to build.py
2013-01-11 14:40:54 -08:00
Tom Payne
6bba086aca Use from/import for brevity 2013-01-11 18:25:58 +01:00
Éric Lemoine
25be29099f Improved reprioritization 2013-01-11 18:13:36 +01:00
Tom Payne
b4da378a33 Don't attempt to share canvases between renderers, fixes #101 2013-01-11 17:43:31 +01:00
Tom Payne
43caea7ed2 Merge pull request #102 from twpayne/frame-state
Frame state
2013-01-11 07:19:31 -08:00
Tom Payne
52df441cf8 Add tile queue 2013-01-11 16:18:07 +01:00
Tom Payne
2a6cc1ae70 Flag 2D-specific code, thanks @elemoine 2013-01-11 16:06:30 +01:00
Tom Payne
f00e299039 Register post-render functions instead of using an event 2013-01-11 15:49:21 +01:00
Tom Payne
434dd84c04 Add animation examples to side-by-side demo 2013-01-11 15:49:15 +01:00
Tom Payne
f3cace499c Implement frame state and animation architecture 2013-01-11 15:48:24 +01:00
Tom Payne
4ee411ebe2 Merge pull request #99 from twpayne/beyond-image-tiles
Beyond image tiles
2013-01-11 06:11:38 -08:00
Tom Payne
5c5a58acfc Merge pull request #98 from twpayne/pure-transform-dom-renderer
Pure transform DOM renderer
2013-01-11 06:02:18 -08:00
Tom Payne
878122828b Add canvas tiles example 2013-01-11 01:18:58 +01:00
Tom Payne
6984fbb9b9 Add ol.source.DebugTileSource 2013-01-11 01:18:57 +01:00
Tom Payne
97d83666a6 Factor out ImageTile and ImageTileSource 2013-01-11 01:18:57 +01:00
Tom Payne
9194a4b4eb Round transformation values to six decimal places 2013-01-10 16:43:42 +01:00
Tom Payne
8a4125281d Add option to round transformation matrix values 2013-01-10 16:43:42 +01:00
Tom Payne
0d1e6ea766 Move forEachReadyVisibleLayer into WebGL renderer 2013-01-10 16:43:42 +01:00
Tom Payne
aba686d22d Refactor DOM renderer to use only CSS transforms 2013-01-10 16:43:42 +01:00
Tom Payne
032aa8b7c8 Add 2D transform abstraction 2013-01-10 16:43:41 +01:00
Éric Lemoine
171d10f2d4 Merge pull request #97 from elemoine/view
Add view abstraction
2013-01-10 06:37:37 -08:00
Tom Payne
e05e0c2f91 Add ol.Color.equals 2013-01-09 18:49:06 +01:00
Éric Lemoine
927cffb2b7 Add view abstraction 2013-01-09 14:03:16 +01:00
Tom Payne
21331d1065 Dispatch generic changed events when any ol.Object property changes 2013-01-08 17:26:22 +01:00
Tom Payne
20e0557a4d No need to ignore /bin/*.pyc, refs #95 2013-01-07 15:41:26 +01:00
Tom Payne
b40085ca41 Fix non-view-related typecasts in ol.renderer.webgl.TileLayer 2013-01-07 13:19:00 +01:00
Tom Payne
b12711fa9d Fix non-view-related typecasts in ol.renderer.Map 2013-01-07 13:19:00 +01:00
Tom Payne
ddee13d6eb Fix non-view-related typecasts in ol.renderer.dom.TileLayer 2013-01-07 13:19:00 +01:00
Tom Payne
80e4c46805 Fix non-view-related typecasts in ol.Map 2013-01-07 13:19:00 +01:00
Tom Payne
e52ec0f7a2 Fix non-view-related typecasts in interactions 2013-01-07 13:18:59 +01:00
Tom Payne
0653546e44 Fix non-view-related typecasts in ol.control.Attribution 2013-01-07 13:18:59 +01:00
Tom Payne
6b7a3bb3bf Fix typecast in ol.Tile 2013-01-07 13:18:59 +01:00
Tom Payne
06bb56eff2 Fix typecasts in ol.layer.TileLayer 2013-01-07 13:18:59 +01:00
Tom Payne
3ef85a3651 Fix typecasts in ol.layer.Layer 2013-01-07 13:18:59 +01:00
Tom Payne
e05591f6ab Fix typecast in ol.renderer.webgl.Layer 2013-01-07 13:18:59 +01:00
Tom Payne
cadeb209cd Fix typecast in ol.renderer.dom.Layer 2013-01-07 13:18:59 +01:00
Tom Payne
5cfae7b3bc Fix typecast in ol.Proj4jsProjection 2013-01-07 13:18:59 +01:00
Tom Payne
3f08995cfb Fix typecast in ol.Collection 2013-01-07 13:18:59 +01:00
Tom Payne
0e93217396 Correctly dispose of layer renderers when layers property changes 2013-01-07 13:18:59 +01:00
Tom Payne
196c3ca15e Merge pull request #95 from marcjansen/ignore-pyc
Ignore *.pyc files in root directory.
2013-01-07 03:09:34 -08:00
Frederic Junod
4de5adf32d make replaced with build.py 2013-01-07 09:16:25 +01:00
Marc Jansen
1670972a9e Ignore all *.pyc files. 2013-01-07 09:08:14 +01:00
Tim Schaub
7971ec1b3b Render geometries to a canvas 2013-01-07 01:42:31 -05:00
Tim Schaub
7cca691b9f Start of style package
These literals will be used internally only - created when evaluating
non-literal symbolizers (with properties that are expressions).
2013-01-07 01:41:02 -05:00
Tim Schaub
997c7145ab Bare bones geom package 2013-01-07 01:34:33 -05:00
Tim Schaub
464be78a16 Satisfying compiler 2013-01-06 10:59:21 -07:00
Tim Schaub
39af56ecb3 Satisfying gjslint 2013-01-06 10:07:29 -07:00
Tim Schaub
6f929efeb3 Merge branch 'master' into vector 2013-01-06 09:37:34 -07:00
Marc Jansen
dd566ba595 Ignore pake.pyc file. 2013-01-06 16:08:21 +01:00
Tom Payne
7ad273082a Correct Stamen source options 2013-01-05 18:35:14 +01:00
Tom Payne
cd6c5ee6ed Disable document generation in precommit target, refs #94
Revert this commit when issue #94 is fixed.
2013-01-05 18:34:35 +01:00
Tom Payne
d1615db925 Merge pull request #93 from twpayne/webgl-renderer-cleanups
WebGL renderer cleanups
2013-01-05 03:46:43 -08:00
Tom Payne
cfaee15c9f Factor out color matrix generation, move color matrix into layer renderer 2013-01-05 12:30:18 +01:00
Tom Payne
8404142cec Avoid getting map twice 2013-01-05 12:18:42 +01:00
Tom Payne
d3a0f87438 Remove inadvertent double render 2013-01-05 12:18:35 +01:00
Tom Payne
118b233457 More strict matrix type 2013-01-05 12:17:37 +01:00
ahocevar
3c305db4a4 Canvas tile renderer - first cut
Untested and no styling
2013-01-04 18:47:33 +01:00
Tom Payne
30ee23d69d Merge pull request #92 from twpayne/request-render-frame
Request render frame
2013-01-04 05:02:25 -08:00
Tom Payne
b2bb08eb81 Clarify comment 2013-01-03 18:16:16 +01:00
Tom Payne
7a36793776 Port DOM renderer to request render frame architecture 2013-01-03 14:51:15 +01:00
Éric Lemoine
b386c38111 Demonstrating user-controlled animation
Inspired from 840ffb6
2013-01-03 12:23:50 +01:00
Éric Lemoine
51636ea0d1 Only appending tiles to the dom after load
A port of f46cdb4 and 4242ef40 from animation-frame branch.
2013-01-03 12:23:50 +01:00
Tom Payne
934c75bc8c Use requestRenderFrame API in interactions 2013-01-03 12:23:50 +01:00
Tom Payne
8c44dcf83a Add some WebGL renderer FIXMEs 2013-01-03 12:23:50 +01:00
Tom Payne
756792b8db Pass time to render functions and rename them to renderFrame_ 2013-01-03 12:23:50 +01:00
Tom Payne
783dfe0618 Port WebGL renderer to requestRenderFrame 2013-01-03 12:23:49 +01:00
Tom Payne
12099bab56 Implement @elemoine's requestRenderFrame architecture 2013-01-03 12:23:49 +01:00
Tom Payne
18fdb66437 Update jsdoc template to be compatible with latest version of jsdoc3 2013-01-03 12:15:30 +01:00
Tom Payne
ad983a5e68 Add missing semicolon from exampleparser output 2013-01-03 11:52:26 +01:00
Tom Payne
7f63e3b8e7 Propagate query string to example links 2013-01-03 11:50:44 +01:00
Tom Payne
874a311de2 Fix bug where all examples were assumed to be under version control 2013-01-03 11:31:31 +01:00
Éric Lemoine
7b24c5b54a Merge pull request #90 from elemoine/webglcolorfilter
WebGL color filter
2012-12-12 07:33:17 -08:00
Éric Lemoine
21f3f90ca6 Adjust hue, sat, and constrast in webgl renderer 2012-12-12 15:53:56 +01:00
tschaub
9622395c86 Use radians for hue rotation
This commit is a cherry-pick from 7f578f0.

Conflicts:

	src/ol/renderer/dom/domlayerrenderer.js
2012-12-12 15:22:01 +01:00
tschaub
4d97b583c6 Match the current Filter Effects spec
This commit is a cherry-pick of 19f7778.

The current draft of the [filter spec](https://dvcs.w3.org/hg/FXTF/raw-file/tip/filters/index.html)
describes brightness, contrast, hue-rotate, and saturate functions that
roughly match our layer's setBrightness, setContrast, setHue, and
setSaturation methods.  These changes make the range of our methods match
the corresponding functions in the spec.  The one exception is the
brightness function.  The spec says it has a range of 0 to positive infinity.
The WebKit implementation accepts a range of -1 to 1 (as of
https://github.com/WebKit/webkit/commit/8f4765e569).  There's an open
(ticket)[https://www.w3.org/Bugs/Public/show_bug.cgi?id=15647] recommending
that the spec be changed to match.

I'm not stuck on having our methods match those of the filter spec, but the
parity would be nice.

These changes leave the WebGL map renderer "broken" (whacky colors).  It would
be straightforward to update the current fragment shader to handle the new
range of hue, but the brightness, contrast, and saturation handling will
need to be reworked.

For inspiration, here are the color transformation
matrix calculations the WebKit filters:
8f4765e569/Source/WebCore/platform/graphics/chromium/cc/CCRenderSurfaceFilters.cpp (L64-80)

Conflicts:

	src/ol/renderer/dom/domlayerrenderer.js
2012-12-12 15:18:34 +01:00
Éric Lemoine
570defe940 Merge pull request #86 from geops/api-docs-comments
Some comments (no changes to code)
2012-12-03 14:02:20 -08:00
Augustus Kling
a73c15c988 Discard documentation for attributioncontrol.js and map.js to make refactoring easier due to @elemoine's request 2012-12-03 22:47:33 +01:00
Frederic Junod
14f7b9a41e git-update-ghpages removed, bin/readme.md no longer necessary 2012-11-14 12:50:13 +01:00
Frédéric Junod
12d5626288 make replaced with build.py 2012-11-14 12:45:07 +01:00
Éric Lemoine
bccfccbf9d Merge pull request #84 from elemoine/84
DOM renderer tile artifacts on FF
2012-11-13 13:47:00 -08:00
Tom Payne
72b7a136c1 Update to latest version of pake, fixes #87, thanks @cedricmoullet and @AugustusKling 2012-11-12 00:01:29 +01:00
Éric Lemoine
7b88f44a41 Keep track of tiles we're already listening on 2012-11-11 21:31:12 +01:00
augustus
f253c1bcf8 Some comments (no changes to code) 2012-11-09 16:26:59 +01:00
Tom Payne
4dde0ac2b1 Remove tile change listeners when they have fired, thanks @fredj 2012-11-09 14:33:58 +01:00
Tom Payne
3d560a08e3 Remove Makefile 2012-11-09 14:05:13 +01:00
Tom Payne
5fb39ff30d Merge pull request #76 from twpayne/pure-python-build
Building on Windows still has a few problems, mainly thanks to Windows. However, this patch does eliminate as many build dependencies as possible (make, wget, sh, find, ruby).
2012-11-09 02:53:33 -08:00
Tom Payne
df8685638c Detect corrupt downloads 2012-11-09 11:45:58 +01:00
Tom Payne
bf4e7bcb70 Work around broken operating systems 2012-11-09 11:45:58 +01:00
Tom Payne
05f3ab3290 Remove unused import 2012-11-09 11:45:31 +01:00
Éric Lemoine
826505c6d4 Register a CHANGE listener even if tile is loading
This fixes an issue easily reproducible in the side-by-side example where the DOM renderer is not notified when tiles loaded by the WebGL renderer have been received.
2012-11-08 21:20:26 +01:00
Éric Lemoine
90e379782c Only appending tiles to the dom after load
A port of f46cdb4 to the current master. The tilelayer renderer can be simplified a bit by waiting to append tiles to the dom until they have loaded. Refs #84 and #33.
2012-11-08 20:03:07 +01:00
Frederic Junod
6eb505eb2b Remove question mark from wms urls (see #85) 2012-11-08 09:02:03 +01:00
Tom Payne
bf231d0c41 Fold gh-update-pages into build.py
This also fixes a bug in gh-update-pages: gh-update-pages does not
handle file deletition, meaning that stale files are never removed.
2012-11-04 19:08:56 +01:00
Tom Payne
d30be0fb93 Merge bin/generate-requireall into build.py 2012-11-04 19:08:55 +01:00
Tom Payne
f082cddb6b Use build.py for Travis 2012-11-04 19:08:55 +01:00
Tom Payne
157c0978be Update CONTRIBUTING.md for build.py 2012-11-04 19:08:55 +01:00
Tom Payne
d16bc89be3 Update readme.md for build.py 2012-11-04 19:08:26 +01:00
Tom Payne
f78afc8d66 Add pake.py
See https://github.com/twpayne/pake
2012-11-04 19:08:26 +01:00
Tom Payne
81b4213fd7 Add build.py
This removes the dependencies on make, sh and curl for building ol3.
2012-11-04 19:08:26 +01:00
Éric Lemoine
c9f4454399 Merge pull request #85 from elemoine/tilefunction
Add ol.TileUrlFunction.createBboxParam
2012-11-04 09:52:09 -08:00
Éric Lemoine
dd014a3b79 Avoid unneeded parameter concatenations (thanks @twpayne, refs #85) 2012-11-04 19:31:20 +01:00
Éric Lemoine
529c3e8b6a Add ol.TileUrlFunction.createBboxParam 2012-11-03 22:55:54 +01:00
ahocevar
3d84571043 Use WebGL now that server sends CORS headers (see #75) 2012-11-03 10:33:20 +01:00
Éric Lemoine
b2c71ed269 Add tests showing more usages of createFromTemplate 2012-11-03 00:43:46 +01:00
Tom Payne
7ee5c5777a Fix use of goog.nullFunction and goog.functions.NULL, thanks @elemoine (again) 2012-11-02 18:28:27 +01:00
Tom Payne
9062a9cf54 Merge pull request #83 from twpayne/fix-82
Make ol.renderer.Map behave like a null renderer, fixes #82
2012-11-02 10:22:01 -07:00
Tom Payne
4d3726d183 Use goog.functions.NULL instead of goog.nullFunction, thanks @elemoine 2012-11-02 18:20:52 +01:00
Tom Payne
dfd495153d Make ol.renderer.Map behave like a null renderer, fixes #82
With this patch, creating a new ol.renderer.Map will return a map
renderer that does nothing.  Previously, it could cause assertion
failures.
2012-11-02 17:10:45 +01:00
Frédéric Junod
1de8821739 Merge pull request #81 from fredj/wms-format
Use jpeg tiles for background layer
2012-11-02 07:58:52 -07:00
Frederic Junod
127c00e1ea Use jpeg tiles for background layer 2012-11-02 15:52:34 +01:00
Éric Lemoine
2f29224691 Merge pull request #80 from elemoine/wms-custom-proj-fix
wms-custom-proj example does not work with the ol build
2012-11-02 05:38:38 -07:00
Éric Lemoine
4a604940a2 The wms-custom-proj example requires more exports 2012-11-02 12:06:24 +01:00
Tim Schaub
e57f8b45a6 Merge pull request #78 from geops/api-docs-jsdoc
Taking over new template from jsdoc but keep modifications by OpenLayers as much as possible
2012-10-31 13:38:24 -07:00
ahocevar
13e48787a3 Merge pull request #79 from ahocevar/projection
Projection handling improvements. r=@twpayne, @elemoine
2012-10-31 10:13:17 -07:00
ahocevar
eb4a8683e2 Projection handling improvements
* The Map's private createProjection_ method is now a public
  method of the Projection. It is also used by TiledWMSSource
  to calculate the appropriate projection from the user
  configuration.
* ol.Projection.addProjection now adds the transformation for
  the source == target case. This makes it easy for the user
  to create custom projection maps without including proj4js and
  without adding a custom transformation, as long as the
  userProjection equals the projection.
* The TiledWMSSource now uses the same default resolutions as
  the map (i.e. the OSM resolutions)
* The modulo calculation for wrapping extents now works for all
  grid configurations, by not calculating the number of columns
  based on an assumption about the way the zoom levels relate to
  resolutions.
* The wms-custom-proj example now shows how to properly
  configure a custom resolution, i.e. by using the validity
  extent of the projection as its extent.
2012-10-31 13:17:58 +01:00
augustus
64a252093c Taking over new template from jsdoc but keep modifications by OpenLayers as much as possible 2012-10-31 09:39:55 +01:00
Tom Payne
7af152cc49 Update Plovr version 2012-10-29 14:09:37 +01:00
ahocevar
f4139f208a Merge pull request #74 from ahocevar/tiled-wms
Adding tiled WMS source. r=@twpayne,@elemoine
2012-10-29 01:47:20 -07:00
ahocevar
e157d17ab7 Addressing review comments regarding typeDef 2012-10-29 09:44:25 +01:00
ahocevar
393bb36784 Removing standalone example 2012-10-29 09:36:08 +01:00
ahocevar
b170fa3d16 Using DOM renderer; no custom extent for layers
The server does not send CORS headers, so we cannot use the
WebGL renderer. Since the layers use the projection's extent,
it is not necessary to specify the extent.
2012-10-29 09:34:53 +01:00
ahocevar
0c77aacf33 proj4js externs are not necessary 2012-10-29 09:33:00 +01:00
ahocevar
e672083027 Indentation and line break fixes 2012-10-28 23:59:36 +01:00
Cédric Moullet
bb957a1149 Add new layer national park, attributions and layer extent to the Tiled WMS with custom projection example 2012-10-28 23:43:53 +01:00
Cédric Moullet
b907befd68 Add title to WMS tiled custom projection example 2012-10-28 23:42:58 +01:00
Cédric Moullet
dd93c24a07 Add tiled wms with custom projection 2012-10-28 07:26:05 +01:00
ahocevar
e5308fec40 No extent magic
Setting the extent on a tile source now only means that tiles
won't be drawn outside that extent. Now the only way to specify
the origin of the tile grid is to provide a custom tileGrid. By
default, the grid origin is the top left corner of the
projection's extent.
2012-10-27 17:28:08 +02:00
ahocevar
b872b5a74f Cross origin handling to make example work in Firefox
The WMS used in the example does not send CORS headers (I think
not many WMS services do). It seems that the WebGL renderer
needs script access to the image data, so the example only works
with the DOM renderer in Firefox.
2012-10-27 09:16:09 +02:00
tschaub
3af801df96 Updating instructions on contributions
This links to the newly created online ICLA form.
2012-10-26 15:41:13 -06:00
ahocevar
433b12c39a Using the projection's extent for resolutions math by default
This ensures that maps with WMS layers with different extents
do not scale the tiles differently for each layer when the
default tileGrid is used. Note that it is always possible to
configure WMS sources with a custom tileGrid.
2012-10-26 22:51:30 +02:00
ahocevar
084506cdb5 Adding tiled WMS source
As shown in the example, this adds support for tiled WMS layers.
2012-10-26 21:36:30 +02:00
Tom Payne
d0e532eadf Merge pull request #71 from twpayne/unique-filenames
Give each source file a unique name
2012-10-26 02:31:19 -07:00
Tom Payne
e5d39724c9 Give each source file a unique name 2012-10-26 11:25:26 +02:00
Tom Payne
af872e25c3 Remove incorrect property export 2012-10-26 11:24:25 +02:00
Tom Payne
41c6c2eff3 Merge pull request #72 from twpayne/source-xyz-projection
Add projection option to ol.source.XYZ
2012-10-25 23:53:03 -07:00
Tom Payne
e7d5022dc1 Add projection option to ol.source.XYZ 2012-10-25 18:48:24 +02:00
Éric Lemoine
49f717eae6 Merge pull request #69 from elemoine/exports-files
Granularize the exports
2012-10-24 13:52:56 -07:00
Éric Lemoine
576c54eb61 Move object literal exports to their own file 2012-10-24 17:05:33 +02:00
Tom Payne
92b13b36d9 Prevent default in double click zoom (refs #70) 2012-10-24 16:30:44 +02:00
Éric Lemoine
0ae3f8806e Remove examples/index.js (refs #67) 2012-10-21 21:24:15 +02:00
Éric Lemoine
02c3acbc35 Merge pull request #67 from elemoine/exampleparser
Use OpenLayers 2 examples system
2012-10-21 12:22:05 -07:00
Éric Lemoine
7ce79207e3 Better design for the full-screen examples
The text div is now placed in the top-right corner of the page. This is to avoid overlapping with the attribution div. On screens that are smaller that 600px the text div is not deplayed at all.
2012-10-21 21:11:27 +02:00
Éric Lemoine
d81b232587 Granularize the exports
This commit decomposes exports.txt into multiple, per-component, export files.  This will be required for custom builds;
2012-10-20 22:31:33 +02:00
Éric Lemoine
1e0b43dd00 Better HTML and CSS for the examples
And give the h1 tags a "title" id. The exampleparser.py script uses that as the example title in the index page.
2012-10-20 21:43:34 +02:00
Éric Lemoine
b000c052e3 Improve layout of examples index page 2012-10-20 21:43:05 +02:00
Éric Lemoine
3e3b8d6f8b Use OpenLayers 2 examples index 2012-10-19 21:56:59 +02:00
Tom Payne
bb53278db5 Merge pull request #66 from twpayne/coordinate-format-cleanup
Coordinate format cleanup
2012-10-19 10:21:09 -07:00
Tom Payne
ee1d1fa3e7 Fold ol.CoordinateFormat into ol.Coordinate 2012-10-18 14:22:23 +02:00
Tom Payne
860b4407b7 Add ol.Extent.get{Bottom,Top}{Left,Right} 2012-10-18 13:49:10 +02:00
Tom Payne
cd7627f626 Lint examples 2012-10-18 13:48:52 +02:00
Tom Payne
061c173e64 Merge pull request #64 from twpayne/examples-index
Examples index
2012-10-18 02:15:46 -07:00
Tim Schaub
eef4eb0eea Merge pull request #61 from twpayne/z-sort-in-dom-renderer
Z sort in dom renderer
2012-10-17 21:24:40 -07:00
Tom Payne
e21c182641 Use Chrome Frame if available 2012-10-17 18:20:25 +02:00
Tom Payne
68a71c4a53 Add Tom Payne to authors.txt 2012-10-17 17:43:27 +02:00
Tom Payne
a82e523f6b Try multiple context ids to get a WebGL context 2012-10-17 17:36:07 +02:00
Tom Payne
5011123228 Use ol.webgl.getContext is WebGL support test 2012-10-17 17:27:11 +02:00
Tom Payne
8cb28a7217 Move WebGL support test into ol.webgl 2012-10-17 17:25:37 +02:00
Tom Payne
1d40b64db1 Move WebGL context creation into ol.webgl 2012-10-17 17:23:30 +02:00
Tom Payne
0e81f67a00 Host example index 2012-10-17 11:36:54 +02:00
Tom Payne
e9dbb00039 Pass query string through example index
This is so that visiting

    /examples/index.html?mode=RAW&Debug=true

will automatically add ?mode=RAW&Debug=true to all links in the
generated index.
2012-10-17 11:31:40 +02:00
Tom Payne
f120410d6d Add option to hook in scripts to index generator 2012-10-17 11:29:41 +02:00
Tom Payne
129578a515 Build examples index 2012-10-17 11:22:11 +02:00
Tom Payne
7f39f1d32d Add script to generate example index 2012-10-17 11:13:01 +02:00
Éric Lemoine
c508ed39ef Merge pull request #63 from elemoine/hosted-examples
A step toward hosted examples on gh-pages
2012-10-16 13:59:31 -07:00
Éric Lemoine
84e3cf4f0d Merge pull request #62 from elemoine/bingmaps-exports
Add BingMaps exports
2012-10-16 13:57:44 -07:00
Éric Lemoine
1ac188c906 Add a hostexamples target to Makefile
This target copies the ol built files, examples, and loader script to the build/gh-pages directory, making it possible to host our examples on gh-pages.
2012-10-16 21:56:45 +02:00
Éric Lemoine
4b6ef3c046 Better comments in loader.js 2012-10-16 21:56:35 +02:00
Éric Lemoine
190e21f796 The loader adds link tag for ol.css 2012-10-16 21:55:12 +02:00
Éric Lemoine
f4b20175cc Add a specific loader for hosted examples
This loader is responsible for adding ol.js, ol.css and the example-specific js script to the document. This is the loader used in examples when hosted.
2012-10-16 21:51:48 +02:00
Éric Lemoine
1f7ecd2529 Make linter happy 2012-10-16 21:50:20 +02:00
Éric Lemoine
5c6b5cb495 Add BingMaps exports 2012-10-16 21:45:52 +02:00
Tom Payne
a38468c854 Merge pull request #60 from twpayne/hosted-examples
Hosted examples
2012-10-16 02:12:16 -07:00
Tom Payne
3e6d374859 Ensure z as object keys are sorted as numbers 2012-10-16 11:04:56 +02:00
Tom Payne
ed197f3cfe Revert "Two lessons learned"
This reverts commit f8462460bf.
2012-10-16 10:59:53 +02:00
Tom Payne
f7adc1ae75 Use identical code in compiled and standalone examples 2012-10-15 19:12:55 +02:00
Tom Payne
f9302ab030 Export goog.require as goog.nullFunction 2012-10-15 19:12:06 +02:00
Tom Payne
b45c2ca4bc Add optional argument to @exportSymbol 2012-10-15 19:11:51 +02:00
Tom Payne
98340c55ce Don't use goog.* functions in examples 2012-10-15 19:11:02 +02:00
Tom Payne
0392d898c3 Merge pull request #56 from twpayne/interaction-conditions
Abstract out key conditions for interactions, fixes #51, see also #54
2012-10-12 11:04:12 -07:00
Éric Lemoine
e440c03efb Merge pull request #58 from elemoine/dispose
The map should be disposable
2012-10-12 08:41:51 -07:00
Éric Lemoine
f49f370857 Make linter happy 2012-10-11 18:09:18 +02:00
Éric Lemoine
9c48dff286 Add tests for ol.Map.prototype.disposeInternal 2012-10-11 17:53:35 +02:00
Éric Lemoine
2a76a23b6f Add tests for ol.control.Control 2012-10-11 17:46:47 +02:00
Éric Lemoine
0b411ad69c Have disposeInternal call parent 2012-10-11 17:46:22 +02:00
Éric Lemoine
fbc810264b goog.array.forEach does not accept null values 2012-10-10 20:25:53 +02:00
Éric Lemoine
655e04368b disposeInternal implementation for ol.control.Control 2012-10-10 20:24:32 +02:00
Éric Lemoine
dc491f9114 disposeInternal implementation for ol.Map 2012-10-10 20:24:18 +02:00
Tom Payne
936584ceaa Use goog.array.map for browser compatability, thanks @AugustusKling 2012-10-10 13:49:01 +02:00
Tom Payne
ac8dd5db98 Fix sort problem identified by @tschaub in f8462460bf 2012-10-10 10:27:42 +02:00
Tim Schaub
f8462460bf Two lessons learned
Telling the compiler that object keys are numeric causes more harm
than good (see === comparison that could never be met though the
compiler didn't catch it).

Never use goog functions without reading the source first.  The
goog.array.sort method does nothing special sorting numeric strings
(so the zs array might be ['1', '10', '2'] here).
2012-10-09 23:31:38 -06:00
Tim Schaub
ce1b99cb56 Remove alt-z tiles when all tiles load at target z
The changes in a14a15159f made it so tiles
at alternate resolutions were not pruned when target tiles finished loading.
2012-10-09 22:56:37 -06:00
Tom Payne
8df0cfb9d9 Abstract out key conditions for interactions, fixes #51, see also #54 2012-10-08 12:55:20 +02:00
Tim Schaub
a14a15159f Simpler and more thorough tile pruning
The render method always generates a map of all tiles that should be drawn
(called tilesToDrawByZ).  This includes tiles at alternate resolutions, tiles
still loading, and tiles previously rendered.  At the end of the render
sequence we can simply remove all previously rendered tiles that aren't in
tilesToDrawByZ.  This provides an alternate solution to the problem described
in #53 and more.
2012-10-08 00:41:21 -06:00
Tim Schaub
2c2d40a53c Remove tiles outside rendered extent
To avoid having misplaced at alternate resolutions while zooming, all tiles
outside the rendered extent need to be removed from the dom (closes #53).
2012-10-07 23:47:47 -06:00
Tim Schaub
d6173a5aac Removing unused code 2012-10-07 22:57:09 -06:00
Tom Payne
1880cca940 Merge pull request #41 from twpayne/exports-externs
Refactor exports and externs
2012-10-04 06:16:31 -07:00
Tom Payne
d5002872dd Replace tabs with spaces 2012-10-04 15:12:50 +02:00
Tom Payne
9d253ab6bb Refactor exports and externs 2012-10-04 15:11:26 +02:00
Tom Payne
d35df1d53b More detailed texture upload logging 2012-10-04 11:38:21 +02:00
Tom Payne
21ab556d2f Cope with layers being undefined 2012-10-04 11:38:21 +02:00
Tom Payne
21f8c8f3bd Enable debugging in full screen example 2012-10-04 11:38:21 +02:00
Frédéric Junod
2b4a7e418e Merge pull request #47 from fredj/protocol-relative
Use protocol-relative URL for Bing metadata.
2012-10-04 01:24:16 -07:00
Frederic Junod
c38889955c Use protocol-relative URL for Bing metadata.
The [URI standard](http://tools.ietf.org/html/rfc3986#section-4.2)
allows for URI without a scheme.  Where http is used to load the app,
using a schemeless URL for the Bing metadata loads a script using http
- and the same goes for https.
2012-10-04 09:16:30 +02:00
Marc Jansen
bd4c7f83f6 Merge pull request #46 from marcjansen/master
Replace tabs with spaces.
2012-10-03 23:38:54 -07:00
Marc Jansen
07730d44d6 Replace tabs with spaces. 2012-10-04 08:34:29 +02:00
Tom Payne
a95e9b9c8b Avoid unecessary style changes in attribution control 2012-10-03 18:51:33 +02:00
Tom Payne
d0a330c870 Use an em space to separate attributions 2012-10-03 17:59:44 +02:00
Frédéric Junod
73a93c4f48 Merge pull request #43 from fredj/interaction-traversal
Travese the interaction array in reverse order.
2012-10-03 08:58:13 -07:00
Frederic Junod
e700ed99be Travese the interaction array in reverse order.
The interactions added via getInteractions().push(...) are evaluated
first.
2012-10-03 16:52:38 +02:00
Frédéric Junod
67770c439a Merge pull request #39 from fredj/getinteraction
Remove interactions from MapProperty
2012-10-03 04:22:36 -07:00
Frederic Junod
488a8224c3 Remove interactions from MapProperty 2012-10-03 11:39:04 +02:00
Frédéric Junod
10708ccfea Merge pull request #38 from fredj/overlay-example
Overlay example
2012-10-02 10:27:33 -07:00
Frederic Junod
3df18d2df8 Use existing local coordinate var 2012-10-02 11:26:44 +02:00
Frederic Junod
8a5e7c77c9 Don't set map at each click 2012-10-02 11:25:58 +02:00
tschaub
671c902d72 Creating the target directory for api docs 2012-10-01 16:35:38 -06:00
Tom Payne
c6a9044bee Indent all HTML files with two spaces 2012-10-01 14:29:50 +02:00
Tom Payne
d894275cf5 Add content type to examples 2012-10-01 14:28:45 +02:00
Frédéric Junod
6b0669c834 Fix path to ol.css 2012-10-01 11:05:37 +03:00
Tom Payne
5e8747d37c Add missing require 2012-09-30 18:28:27 +02:00
Tom Payne
5a51087526 Re-order declarations for clarity, thanks @elemoine 2012-09-30 15:18:16 +02:00
Tom Payne
64d0954b69 Remove Type suffix in auto-generated namespaces, thanks @elemoine 2012-09-30 15:10:15 +02:00
Tim Schaub
c120c03fb1 Properly maintain offset and origin while rotating
This brings equivalent behavior when rotating in both renderers.  Previously, offsets were maintained with style top/left.  Now a single transform handles the translation and rotation.  The scale3d function removes the separation between tiles.  The next step for the DOM renderer is to scale in this same transform.
2012-09-29 17:55:28 -06:00
Tim Schaub
0e27f31785 Avoid undefined rotation 2012-09-29 17:47:44 -06:00
ahocevar
69859b415b More MapBrowserEvent improvements
Now we use the browser's native dblclick event on pointer
devices, and we fire dragstart and dragend only if we're really
dragging, and not on mousedown/touchstart and mouseup/touchend.
2012-09-29 18:54:29 +02:00
ahocevar
877971185f MapBrowserEvent simplifications and improvements
We don't register two listeners for mouseup and touchend any
more. And instead of using the native click event on touch
devices, we react on touchend, to make clicking more responsive.
On pointer devices, the underlying native event of a dblclick
event is now a click event.
2012-09-29 16:51:08 +02:00
ahocevar
6267100871 Move customizations out of arrow_box CSS 2012-09-29 16:48:22 +02:00
Tom Payne
ef1d05fe86 Ensure target is deleted when compile fails 2012-09-29 16:04:13 +02:00
Tom Payne
3ed65c0d98 Correct clean target 2012-09-29 16:00:47 +02:00
Tom Payne
24771c73a0 Export layer options type 2012-09-29 15:36:17 +02:00
Tom Payne
f9b791b2f5 Correct generation of externs for nested namespaces 2012-09-29 15:35:25 +02:00
Tom Payne
8387f74a7b Generate exports automatically from src/ol/exports.txt 2012-09-29 15:17:40 +02:00
Tom Payne
c7c93ce099 Consistent nomenclature 2012-09-29 14:42:12 +02:00
Tom Payne
1a5375fa51 Move target container in to map options 2012-09-29 13:58:15 +02:00
Éric Lemoine
936a769869 Fix typo in ShiftDragZoom (caught by @ahocevar) 2012-09-29 13:47:00 +02:00
Tom Payne
4e5765f42f Add missing dependencies to examples/%.combined.js target 2012-09-29 13:41:23 +02:00
Tom Payne
1ec4ac7d63 Add build-examples to precommit target 2012-09-29 13:41:23 +02:00
Tom Payne
0f9578a694 Add build-examples target 2012-09-29 13:41:22 +02:00
Tom Payne
78317cdc5d Change order of precommit steps 2012-09-29 13:21:58 +02:00
Tom Payne
7cff23cf63 Remove stale .gitignore entry 2012-09-29 13:20:22 +02:00
Tom Payne
83a3306bb7 Only rebuild doc when source changes 2012-09-29 12:33:01 +02:00
Tom Payne
2341e8cd8f Add simple full screen example 2012-09-29 12:33:01 +02:00
Tom Payne
ea95ca4918 Rename full screen example to overlay and popup 2012-09-29 12:33:01 +02:00
Tom Payne
145312b273 Sort specs 2012-09-29 12:33:01 +02:00
Tom Payne
9494321c91 Use a Python script to generate requireall.js
This is needed to work around platform variations in the sort command.
2012-09-29 12:31:31 +02:00
Tom Payne
71e42b2448 Refactor build system
This rather large commit refactors the build system to solve a number of
problems:
- Object literal types are now declared in just one place
- There are no more circular dependencies
- There is no need for concealed subclasses in build-standalone mode

When building in standalone mode, you need to include the source in
build/src/external.  This declares object literal types as externs so
that their properties are not renamed.

When building with the application, you need to include the source in
build/src/internal.  This declares object literal types as typedefs so
that their properties can be renamed and removed.

Note also that ol.MapOptions has been merged into ol.Map, with some
renaming.
2012-09-29 11:51:53 +02:00
Tom Payne
012b8a584a Add serve-precommit target for Travis 2012-09-29 11:51:53 +02:00
Tom Payne
68209bc5ac Remove stray ignore 2012-09-29 11:51:53 +02:00
ahocevar
2b53481932 Making Vienna's location more accurate 2012-09-29 09:54:34 +02:00
Tim Schaub
67bc677ecb Stick with radians 2012-09-29 01:37:54 +02:00
Tim Schaub
50bf2f015c Getting rid of lines between rotated tiles
Applying the scale3d trick just to get rid of small pixel gap between rotated tiles.  This will be reworked soon with additional use of transforms.
2012-09-29 01:33:50 +02:00
Tim Schaub
bc5cd13855 Tiny bit of style 2012-09-29 01:17:46 +02:00
Tim Schaub
c24e520961 Non-functioning example
When loading this example in compiled mode, the page displays the following:

    ol3 proj4js demo

    [object Object][object Object]

With `mode=RAW`, it does display some numbers, but I think we could better explain this functionality with a different sort of tutorial/example.
2012-09-29 01:12:40 +02:00
Tim Schaub
71547c6e48 Examples don't load without make serve 2012-09-29 00:47:42 +02:00
Tom Payne
b6c06f4760 Generate externs and typedefs 2012-09-28 21:55:48 +02:00
Tom Payne
e36169c936 Ignore all errors in when testing for WebGL 2012-09-28 21:36:03 +02:00
Tom Payne
2713addb33 More accurate WebGL support test, see issue #31 2012-09-28 20:05:14 +02:00
ahocevar
dcc3fdde96 Fixing popup in example 2012-09-28 19:19:46 +02:00
Tom Payne
3eebed4580 Add drag box in shift drag zoom control 2012-09-28 17:24:17 +02:00
Tom Payne
62dc6a1b45 Port @ahocevar's drag box control to the new control architecture 2012-09-28 17:24:17 +02:00
ahocevar
467fef8875 Updating readme
File urls work fine now, so using a HTTP server has become
optional.
2012-09-28 17:07:33 +02:00
ahocevar
163737d3de Adding popup to full-screen example 2012-09-28 16:47:55 +02:00
ahocevar
6b395cafb5 Stop click event, as previously promised
This should have gone in with 3910318f1b.
2012-09-28 16:47:54 +02:00
Éric Lemoine
9d8155cf9f Move git-update-ghpages from tools to bin 2012-09-28 16:31:45 +02:00
Éric Lemoine
6cf964b3ae Remove old build files 2012-09-28 16:30:06 +02:00
Éric Lemoine
3aabf117bc CONTRIBUTING.md now mentions the precommit target 2012-09-28 16:23:51 +02:00
Éric Lemoine
82406886a2 Add a CONTRIBUTING.md file 2012-09-28 16:19:07 +02:00
Tom Payne
3e824fc683 Avoid running build twice 2012-09-28 15:52:16 +02:00
Éric Lemoine
8fd77ef330 ol.MapExport takes maxResolution and friends into account 2012-09-28 15:32:00 +02:00
Éric Lemoine
91d582e76e export ol.Projection.transformWithCodes 2012-09-28 15:29:12 +02:00
Éric Lemoine
7a296a273b Export the ol.overlay.Overlay symbol 2012-09-28 15:21:23 +02:00
Tom Payne
7bcb5886ad Use CSS rule to separate attributions 2012-09-28 14:57:54 +02:00
Tom Payne
ed67bdc489 Make attribution control less ugly 2012-09-28 14:53:45 +02:00
Tom Payne
1be9e97489 Add attribution control by default 2012-09-28 14:53:45 +02:00
ahocevar
82058412a1 Bringing label markup back
Also with a bit of css, we can make the label invisible before
it gets added as overlay to the map.
2012-09-28 14:44:36 +02:00
ahocevar
b233b8e1a5 Making sure that position:absolute is set
Positioning of overlays is only possible when position:absolute
is set on the element. So we set it programmatically now.
2012-09-28 14:44:35 +02:00
Tom Payne
acb411ef43 Use consistent naming for CSS classes 2012-09-28 14:32:41 +02:00
Tom Payne
a26f796577 Prettify CSS 2012-09-28 14:32:41 +02:00
Tom Payne
7bdb86b10e Remove unused CSS classes 2012-09-28 14:32:40 +02:00
Éric Lemoine
9af392e217 Change loader.js usage example 2012-09-28 14:25:21 +02:00
Éric Lemoine
f60af3910f Explain how to add examples in readme.md 2012-09-28 14:21:16 +02:00
Tom Payne
da5ad0bf20 Minify CSS with Closure Stylesheets
See https://code.google.com/p/closure-stylesheets/
2012-09-28 14:16:25 +02:00
Éric Lemoine
5615eabf66 Update readme.md 2012-09-28 14:02:57 +02:00
Éric Lemoine
896f5203db Change examples directory names to "examples" 2012-09-28 14:01:51 +02:00
Éric Lemoine
310d5bfeaa The serve target needs demos as its source 2012-09-28 13:54:51 +02:00
Éric Lemoine
11915549a3 Make make lint ignore demos/*.combined.js file 2012-09-28 13:52:55 +02:00
Tom Payne
31411ae33f Remove unused style 2012-09-28 13:48:20 +02:00
Tom Payne
a341df3b41 Fix not-up-to-date transform bug in mouse position control 2012-09-28 13:48:20 +02:00
Tom Payne
0bf17f64f7 Initialize controls after map has been configured 2012-09-28 13:48:20 +02:00
Éric Lemoine
e3cef24f5f Change examples/demos structure 2012-09-28 13:33:05 +02:00
ahocevar
3910318f1b Merge pull request #30 from openlayers/overlay
Introducing ol.overlay.Overlay and an overlayContainer. r=@twpayne
2012-09-28 04:05:21 -07:00
ahocevar
3d62b67172 Introducing ol.overlay.Overlay and an overlayContainer
ol.overlay.Overlay can be used to bind DOM elements to a
coordinate on the map. It has positioning options to support
e.g. popups or image markers that have an anchor at the bottom
and an unknown size.

The overlayContainer stops propagation on mousedown and
touchstart events, so clicks and gestures on overlays don't
trigger any MapBrowserEvent. To make this work reliably, we now
only fire dblclick in mapbrowserevent.js when there was a
previous mousedown or touchstart. The default container for
controls is now the overlayContainer.
2012-09-28 13:01:56 +02:00
Tom Payne
a46e251eb2 Update demos to use new controls system 2012-09-28 12:53:44 +02:00
Tom Payne
e2e983728e Add controls to map 2012-09-28 12:52:54 +02:00
Tom Payne
e7eccb302d Cope with map being null 2012-09-28 12:51:10 +02:00
Tom Payne
74f87995c8 Build doc in build/gh-pages directory 2012-09-28 12:25:06 +02:00
Tim Schaub
ff19ab0a28 Call event.getPixel() to get the map pixel offset
The new getPixel method should be used instead of checking offsetX/Y on the browser event.
2012-09-28 12:19:32 +02:00
Tim Schaub
eb29e6a43c Using null instead of null or object or undefined 2012-09-28 12:08:21 +02:00
Tim Schaub
3e34013c09 Separating out method to get pixel offset 2012-09-28 12:08:21 +02:00
Éric Lemoine
158e4b1356 Add a readme file to the tools dir 2012-09-28 11:30:32 +02:00
Éric Lemoine
e93bb6a39b Add a gh-pages target to Makefile 2012-09-28 11:26:00 +02:00
Éric Lemoine
a347454aa3 JSDoc output goes to build/<branch_name>/apidoc 2012-09-28 11:26:00 +02:00
Éric Lemoine
e27d0d9dc1 Add a tool to create/update the gh-pages branche 2012-09-28 11:26:00 +02:00
Tim Schaub
6ed27779cc Rotation support for the dom renderer
Thanks @fredj for the inspiration.  This gives us initial rotation support.  It exposes some issues in the interactions that I'll address separately.  Closes #22.
2012-09-28 10:53:36 +02:00
Éric Lemoine
ab403bf71d Merge pull request #29 from openlayers/travis2
Make Travis also build the doc
2012-09-28 00:07:54 -07:00
Tom Payne
e3c3c13ac2 Use goog.vec.Mat4.rotateZ 2012-09-27 18:21:33 +02:00
Tom Payne
8dc57d5148 Add ol.ASSUME_TOUCH @define 2012-09-27 18:21:21 +02:00
Tom Payne
7415a11c63 More responsive zoom buttons on touch devices thanks to @ahocevar 2012-09-27 18:07:17 +02:00
Éric Lemoine
a0f747379b Make Travis also build the doc 2012-09-27 18:01:31 +02:00
Éric Lemoine
676a95efd8 Merge remote-tracking branch 'upstream/master' 2012-09-27 17:57:44 +02:00
Éric Lemoine
d99a0c164e Make functions @protected or @private
This also makes jsdoc3 happy along the way.
2012-09-27 17:56:29 +02:00
Tom Payne
0faab71e3f Implement new control architecture 2012-09-27 17:54:20 +02:00
Tom Payne
65b4041aa3 Remove ol.control.DragBox temporarily 2012-09-27 17:54:20 +02:00
Tom Payne
fc81c0403e Use new Bing Maps API key 2012-09-27 17:54:20 +02:00
Tim Schaub
981a40a994 Remove tiles that are still loading at alt z
When zooming to a new zoom level, we can immediately remove tiles from the previous level.  This (strongly) suggests not adding images to the container until they have actually loaded.
2012-09-27 17:46:23 +02:00
ahocevar
9536ba8e14 Common place to store browser features
The ol.BrowserFeature object is supposed to provide all detected browser features in a central place.
2012-09-27 17:09:19 +02:00
Tom Payne
fd411eb9ab Don't create controls in interactions 2012-09-27 16:34:39 +02:00
Tim Schaub
b8a69f0777 Adjusting layers pane only when necessary
We only want to adjust things that have to do with rendering (like the position of the layers panel) when actually rendering.  The handleXChange methods may be called more times than we can actually render, so we never want to do anything that touches the DOM there.  Instead, we have to keep track of the state at previous render and adjust the layers panel (or other) based on changes only when rendering.
2012-09-27 16:09:04 +02:00
Tim Schaub
d4d04eface Less whitespace by default. 2012-09-27 16:09:03 +02:00
Tim Schaub
9f9729656b Todos done. 2012-09-27 16:09:03 +02:00
Éric Lemoine
a3d888a57b Add FIXME to MapOptions 2012-09-27 15:59:30 +02:00
Éric Lemoine
0535a31bc6 Add zoomDelta option to MapOptions 2012-09-27 15:48:04 +02:00
Éric Lemoine
4f116c2e5b Fix default value of numZoomLevels 2012-09-27 15:46:45 +02:00
Éric Lemoine
b8356f5e2e Fix bad copy and paste in mapoptions tests 2012-09-27 15:40:58 +02:00
Éric Lemoine
d2f9ebae41 Add mouseWheelZoomDelta option to MapOptions 2012-09-27 15:16:14 +02:00
Éric Lemoine
dd425ff922 Export new map options 2012-09-27 14:10:05 +02:00
Tom Payne
7dbc70bcac Don't try to be too clever with size changes 2012-09-27 14:05:19 +02:00
Tom Payne
7625607fd1 Only resize canvas when renderering 2012-09-27 14:05:19 +02:00
Tom Payne
ac0e02039c s/POST_RENDER/POSTRENDER/ 2012-09-27 14:05:19 +02:00
Éric Lemoine
d61a117787 Remove CenterConstraint entirely 2012-09-27 13:44:24 +02:00
Éric Lemoine
bd0f3d2015 Zoom control does not know about the constraints 2012-09-27 13:42:30 +02:00
Éric Lemoine
87189293b5 Make the resolution constraint configurable through map options 2012-09-27 13:36:57 +02:00
Tom Payne
1f55d139b2 Remove stray script element 2012-09-27 13:00:52 +02:00
Tom Payne
65b8e0f915 Use object literals and use generic tile layer 2012-09-27 12:45:00 +02:00
Tom Payne
5ddbf17c8d Run lint on specs 2012-09-27 12:42:13 +02:00
Tom Payne
b7def4c8c4 Clean up some lint problems in specs 2012-09-27 12:42:13 +02:00
Tom Payne
c908e88dce Fix overly-aggressive clean step 2012-09-27 12:42:13 +02:00
ahocevar
26e3179b2e Making linter and Travis happy 2012-09-27 12:18:05 +02:00
ahocevar
caaec7c366 Use the map's zoom method instead of our own
This also allows us to get rid of the resolutions constraint and configuration.
2012-09-27 12:05:53 +02:00
Éric Lemoine
f78cad0d77 Merge pull request #27 from elemoine/constraints
Refactoring to make constraints work at the map level
2012-09-27 01:42:45 -07:00
ahocevar
1b18dbedb7 Dispatch MapBrowserEvent before interactions get it
By doing so, application event handlers can preventDefault on the event, and interactions won't get the event any more. This means that interactions are default behavior that can be prevented by application event handlers.
2012-09-27 09:54:16 +02:00
Éric Lemoine
cf20fd3e49 Replace map.zoomIn and map.zoomOut by map.zoom(delta) 2012-09-27 09:37:19 +02:00
Tom Payne
d3b9af30d0 Don't modify return type of method 2012-09-27 09:36:55 +02:00
Tom Payne
96bd703271 s/tilesource/source/ 2012-09-27 09:36:55 +02:00
Tom Payne
50334b7971 s/ol.TileLayer/ol.layer.TileLayer/ 2012-09-27 09:36:55 +02:00
Tom Payne
ccf8eb3c97 Don't pass viewport size monitor to ol.Map constructor 2012-09-27 09:36:55 +02:00
Tom Payne
8ffdaad5f5 Only re-run lint when source files have changed 2012-09-27 09:36:55 +02:00
Tom Payne
9c798f410e Work around circular dependency bug 2012-09-27 09:36:55 +02:00
Éric Lemoine
25e00e5d74 Add FIXME to control/zoom.js 2012-09-27 00:10:54 +02:00
Éric Lemoine
79166dc1d6 Constraint objects moved to ol namespace from ol.interaction namespace 2012-09-27 00:10:54 +02:00
Éric Lemoine
b6bb05bf76 Refactoring to set the constraints to the map 2012-09-27 00:09:29 +02:00
ahocevar
2991fa1178 Adding important comment 2012-09-26 22:39:21 +02:00
Tom Payne
04325ee3fd Remove unnecessary require, thanks @fredj 2012-09-26 19:46:13 +02:00
Tom Payne
290d03e76f s/store/source/ 2012-09-26 19:43:23 +02:00
Tom Payne
228e5a8dbf Move requires to end of the file to ensure tests run even if goog.require fails 2012-09-26 19:40:16 +02:00
ahocevar
d6f6b828f1 preventDefault on mousedown
This is needed to avoid native image dragging.
2012-09-26 18:48:57 +02:00
ahocevar
303960731c CSS for previous commit 2012-09-26 18:33:07 +02:00
Tom Payne
ea81ce33dd Add consistent API demo 2012-09-26 18:28:06 +02:00
Tom Payne
546f1f4b9f Add initial exports and externs 2012-09-26 18:28:06 +02:00
Tom Payne
3b11398f35 Remove unnecessary precision 2012-09-26 18:28:05 +02:00
Tom Payne
a578dd6786 Remove unnecessary parentheses 2012-09-26 18:28:05 +02:00
ahocevar
e390ff80ea Adding zoom control 2012-09-26 18:27:45 +02:00
ahocevar
47c343ce4f We can rely on the click event
No need to use the mousedown/touchstart event here, because the click event gives us both clientX/clientY and button on touch devices.
2012-09-26 18:27:12 +02:00
ahocevar
4257f5c7c6 Removing unneeded preventDefault calls 2012-09-26 18:26:11 +02:00
ahocevar
c7a32b33da Fixing indentation 2012-09-26 15:11:47 +02:00
ahocevar
78c380c9a5 Type cast to make the compiler happy 2012-09-26 15:05:52 +02:00
ahocevar
fa16adec02 Making more use of Closure 2012-09-26 14:38:29 +02:00
Tim Schaub
3510c37e43 Handle map size changes in the renderer 2012-09-26 14:10:16 +02:00
Tim Schaub
5b36cf1312 Only adjust tile when necessary 2012-09-26 13:12:36 +02:00
ahocevar
bdd8a75123 Remove the box also if we don't zoom 2012-09-26 13:03:41 +02:00
Tom Payne
e7063953d7 Don't create a class for map options 2012-09-26 12:54:53 +02:00
Tom Payne
013e6c6320 Use zoom option 2012-09-26 12:54:53 +02:00
Tom Payne
b73b2d12c4 Replace ol.createMap with friendlier ol.Map constructor 2012-09-26 12:54:53 +02:00
ahocevar
3bd204fb6a DragBox control provides visual shiftdragzoom feedback
Adding a new DragBox control and using it in the shiftdragzoom interaction to provide visual feedback of the zoom box. The control is nicely separated from the interaction - it only draws the box and does not perform any action.
2012-09-26 12:50:14 +02:00
Tim Schaub
24edce24f1 Add alternate tiles under tiles at target z
When zooming or panning, if we have tiles at alternate resolutions, those tiles are inserted in the DOM before the tiles at the target resolution.  This means you should see blurry tiles instead of whitespace when panning (assuming you've already zoomed in a bit).
2012-09-26 12:18:11 +02:00
Tom Payne
9f1743cb4d Remove unused @export tags 2012-09-26 11:28:26 +02:00
Tom Payne
5db8724b9c Use consistent whitespace in Makefile 2012-09-26 11:19:14 +02:00
Tom Payne
0eeae68ee9 Don't build demos with simple optimizations 2012-09-26 11:19:14 +02:00
Éric Lemoine
7a6acb670f Update readme.md 2012-09-26 12:17:01 +03:00
Tim Schaub
48c4cbc1e5 Correcting comment typos 2012-09-26 11:11:51 +02:00
Tim Schaub
8e38ab0fdc Lint free. 2012-09-26 10:58:17 +02:00
Tim Schaub
3479e20b0a Merge branch 'alt-tiles' 2012-09-26 10:55:25 +02:00
Tim Schaub
7f58d1a8c6 Proper handling of out-of-range and alt-z tiles
Tile pruning code separated into to methods for clarity.  Alt-z tiles are only removed when all current-z tiles have loaded.  Thanks @elemoine for the excellent debugging session.
2012-09-26 10:52:17 +02:00
Tom Payne
68f8f3d5b1 Use new extra compiler checks 2012-09-26 00:04:28 +02:00
Tim Schaub
299173194c First pass at alt-tile rendering for dom renderer 2012-09-25 20:06:20 +02:00
Tom Payne
a32460945d Use Plovr built on 2012-09-25 2012-09-25 19:51:56 +02:00
ahocevar
86336b42e6 Ignoring index.html instead of debug.html 2012-09-25 19:47:26 +02:00
ahocevar
36a8dd81ee Missing change from previous commit
This should have gone in with ef383ee7b6.
2012-09-25 19:35:12 +02:00
ahocevar
3c099a96b7 No longer tap-selecting elements on touch devices
This finalizes the effort to improve map browser event handling.
2012-09-25 19:32:08 +02:00
ahocevar
ef383ee7b6 Examples using a script loader
This makes it possible to run examples hosted on hosts other than localhost. To get that version by default, debug.html has been renamed to index.html.
2012-09-25 19:06:29 +02:00
Éric Lemoine
c696356586 Update readme.md 2012-09-25 19:31:26 +03:00
ahocevar
5a97655983 Optimizing touch device handling
The native event of the touchstart/mousedown event needs to be cloned; change includes some compiler optimizations.
2012-09-25 18:30:23 +02:00
ahocevar
ce977e5364 Map browser event handling for touch devices
By handling click, dblckick and drag sequences in MapBrowserEvent, we can overcome closure issues with touch events. In particular, these issues were double drag events (from mousemove and touchmove) and a missing dblclick event on touch devices.
2012-09-25 17:28:01 +02:00
ahocevar
b151304630 Prevent default on mousedown and touchstart for all renderers
By doing this on the map renderer, we do not need to duplicate code for the webgl and dom renderers.
2012-09-25 17:28:01 +02:00
Éric Lemoine
019bc09cea Update readme.md 2012-09-25 16:41:54 +02:00
Éric Lemoine
745c906846 Run Travis builds for any branch 2012-09-25 16:23:42 +02:00
Éric Lemoine
95d2cac09f Add Travis config file 2012-09-25 16:07:07 +02:00
Éric Lemoine
4a6b13ed39 Add a download plovr target to Makefile 2012-09-25 16:06:37 +02:00
Éric Lemoine
0130915f00 Makefile - clean target adjustments 2012-09-25 15:38:09 +02:00
Éric Lemoine
e3de55e7cb Makefile - serve target needs build/ol-all.js as a source 2012-09-25 15:37:13 +02:00
Tom Payne
8369924511 Remove debug code 2012-09-25 14:00:19 +02:00
Tom Payne
06ea619989 Avoid re-rendering framebuffer in simple cases 2012-09-25 13:54:15 +02:00
Tom Payne
1bb2c3c451 Enable debugging in full screen demo 2012-09-25 13:54:15 +02:00
Éric Lemoine
629687586f Simplify and clean up the test page 2012-09-25 13:53:11 +02:00
Tom Payne
f2cd64f66f Add precommit target 2012-09-25 12:25:14 +02:00
Tom Payne
c2e08861e5 Correct order of transformations 2012-09-25 12:23:11 +02:00
Tom Payne
88fd7729e2 Add missing dependency 2012-09-25 12:18:49 +02:00
Tim Schaub
900eead7c6 Correct type for imagesToLoad. Add note about shorter path. 2012-09-25 12:08:02 +02:00
Éric Lemoine
b4416e71c4 better nosier command 2012-09-25 12:04:57 +02:00
Éric Lemoine
3e01ca97c3 remove the jsunit tests 2012-09-25 12:03:36 +02:00
Éric Lemoine
89f7e44478 Jasmine tests for ol.Collection 2012-09-25 12:02:28 +02:00
Tom Payne
c956ab3482 Relax unit tests as PhantomJS generates the wrong result on Mac OS X 2012-09-25 11:32:31 +02:00
Tom Payne
ae34e8d261 Add full screen demo 2012-09-25 10:59:38 +02:00
Éric Lemoine
116531c275 fix typo in an ol.Rectangle test 2012-09-25 10:42:07 +02:00
Éric Lemoine
db904dae5c Jasmine tests for ol.Rectangle 2012-09-25 10:42:07 +02:00
Tom Payne
b435ccc026 Satisfy gjslint 2012-09-25 10:26:10 +02:00
Éric Lemoine
589c2a8505 Jasmine tests for ol.TileRange 2012-09-25 10:22:36 +02:00
Éric Lemoine
b249b0aaa9 Jasmine tests for ol.tilestore.XYZ 2012-09-25 10:13:41 +02:00
Éric Lemoine
56e48911bf Jasmine tests for ol.TileGrid 2012-09-25 10:03:27 +02:00
ahocevar
6b8e14c623 Don't trigger extra drag events on touch devices. 2012-09-25 08:30:57 +02:00
Éric Lemoine
27d3a88413 add FIXMEs for test runner 2012-09-25 00:47:02 +02:00
Éric Lemoine
1f0d53342a Jasmine tests for ol.array 2012-09-25 00:29:23 +02:00
Éric Lemoine
f0ff1faa73 fix ol.Extent tests 2012-09-25 00:18:25 +02:00
Éric Lemoine
6fab51bde0 Jasmine tests for ol.Extent 2012-09-25 00:13:28 +02:00
Tom Payne
424dbd7582 Remove problematic (and unused) clone methods, move contains out of ol.Rectangle 2012-09-25 00:04:45 +02:00
Tom Payne
c43e04ea77 Refactor to support stricter new compiler 2012-09-25 00:03:53 +02:00
Tom Payne
2d7a21eaa0 More gjslint fixes 2012-09-25 00:03:53 +02:00
Éric Lemoine
92f0711404 Jasmine tests for ol.interaction.ResolutionConstraint 2012-09-25 00:02:22 +02:00
Éric Lemoine
94f2f85195 Jasmine tests for ol.TileUrlFunction 2012-09-24 23:39:50 +02:00
Éric Lemoine
30dfbfb8b7 mention nosier in test/readme.md 2012-09-24 23:31:57 +02:00
Éric Lemoine
ec9382e760 Jasmine tests for ol.Projection 2012-09-24 23:26:49 +02:00
Éric Lemoine
c2901dec73 Jasmine tests for ol.TileCoord 2012-09-24 22:56:40 +02:00
Éric Lemoine
2aac0140c1 add a test target to Makefile 2012-09-24 22:34:09 +02:00
Éric Lemoine
fbaefeea7c give the test dir a specific readme file 2012-09-24 22:34:09 +02:00
Éric Lemoine
1f457fc919 add ConsoleReporter to Jasmine Env (for headless testing) 2012-09-24 22:34:09 +02:00
Éric Lemoine
92dca8584c add phantom-jasmine 2012-09-24 22:34:08 +02:00
Éric Lemoine
5d88994a9a remove test/api.html 2012-09-24 22:34:08 +02:00
Tom Payne
8394147df1 Satisfy gjslint 2012-09-24 21:25:29 +02:00
Tom Payne
bd5ef6b361 Make path to jsdoc configurable 2012-09-24 18:30:32 +02:00
Tom Payne
b7020750ac Add initial exports 2012-09-24 18:25:19 +02:00
Tom Payne
d7c6ce19a9 Rename build/ol-compiled.js to build/ol.js 2012-09-24 18:25:19 +02:00
Tom Payne
6006d43656 Remove ol.Rectangle.clone 2012-09-24 18:25:19 +02:00
Tim Schaub
5eb5715530 More longname display. 2012-09-24 18:23:19 +02:00
Tim Schaub
2b307ef6a9 Replace opt_ prefix with (Optional) in description. 2012-09-24 18:23:19 +02:00
Tim Schaub
b73ffbdc7c Hide source tags (until we get the full path). 2012-09-24 18:23:19 +02:00
Tim Schaub
f2c05bdf0f Remove "arguments" column from params table. 2012-09-24 18:23:19 +02:00
Tim Schaub
99e58cb8e0 Stylesheet to hide protected members.
Source tags are also hidden here as they only provide the file name and not the complete path.  This should be fixed in JSDoc 3.
2012-09-24 18:23:19 +02:00
Éric Lemoine
4b015f9962 add Jasmine tests for ol.Object 2012-09-24 18:15:30 +02:00
Éric Lemoine
baeddfac12 remove the old tests 2012-09-24 18:12:51 +02:00
ahocevar
002e23cb74 Satisfy latest Closure library/tools. 2012-09-24 17:59:34 +02:00
Tim Schaub
2add7288e5 Doc target for building with JSDoc 3.
This assumes jsdoc is on the path.
2012-09-24 17:25:33 +02:00
Tim Schaub
d51cd1c395 Interaction in ol.interaction namespace. 2012-09-24 17:18:21 +02:00
Tim Schaub
ed754fbfdf Control in the ol.control namespace. 2012-09-24 17:15:30 +02:00
Tim Schaub
1f9e2aa3c4 Move Layer into ol.layer namespace. 2012-09-24 17:08:36 +02:00
Tim Schaub
57d75ace5d Adding a JSDoc 3 template. 2012-09-24 16:59:27 +02:00
Tim Schaub
c3a41c967e Removing file overviews for now. 2012-09-24 16:58:55 +02:00
Tom Payne
d7f12debb0 Expect to find proj4js-combined.js in build directory 2012-09-24 14:40:50 +02:00
Tom Payne
bb6f4e2ea1 Remove webgl-debug.js for now 2012-09-24 14:40:50 +02:00
Tom Payne
048d19e73a Clean up whitespace 2012-09-24 14:37:27 +02:00
Tom Payne
a416d1f601 s/TileBounds/TileRange/ 2012-09-24 14:33:24 +02:00
Tom Payne
f8c31ba45c s/ol3/ol/ 2012-09-24 14:21:41 +02:00
Tom Payne
6737220b83 Remove ol namespace 2012-09-24 14:07:11 +02:00
Tom Payne
6e427a49ab Use @inheritDoc instead of @override 2012-09-21 14:33:35 +02:00
Tom Payne
5f0c90cf7e Add minimal comments to satisfy jsdoc3. 2012-09-21 10:08:29 +02:00
Tom Payne
397ebca228 Wrap compiled API in anonymous function 2012-09-20 13:04:51 +02:00
Tom Payne
5c76291b74 Remove move dead code 2012-09-19 17:04:12 +02:00
Tom Payne
4141393423 Warn when debugger statement is used 2012-09-19 15:51:50 +02:00
Tom Payne
181a574126 Enable more compiler checks 2012-09-19 15:51:29 +02:00
Tom Payne
353727e77d Enable more aggressive compiler variable renaming 2012-09-18 17:54:56 +02:00
Tom Payne
4a8ae08c1c Merge pull request #24 from openlayers/exp 2012-09-13 15:43:42 +02:00
Tom Payne
c61fd1dccf Merge pull request #20 from openlayers/exp-reorganization
Exp reorganization
2012-09-13 06:40:53 -07:00
Tom Payne
77b6f59178 Improve file layout, thanks @elemoine 2012-09-13 15:39:54 +02:00
Tom Payne
0edb8dc502 Merge pull request #23 from openlayers/remove-openlayers2
Remove OpenLayers 2, as discussed with @ahocevar, @elemoine and @tschaub
2012-08-30 13:22:47 -07:00
Tom Payne
b643cd2fef Merge branch 'exp' 2012-08-30 17:05:32 +02:00
Tom Payne
c848d48e3f Move ol3.layer.* into their own directory 2012-08-30 16:48:00 +02:00
Tom Payne
23ee8b73bd Make directory structure better match class hierarchy 2012-08-30 16:48:00 +02:00
Tom Payne
638504f750 Reorganize renderers 2012-08-30 16:47:59 +02:00
Tom Payne
903352989d Remove entries from .gitignore 2012-08-30 15:17:24 +02:00
Tom Payne
8ab2e5dfd2 Remove attic 2012-08-30 15:14:59 +02:00
Tom Payne
211f93248c Store webgl-debug.js in build 2012-08-30 15:14:59 +02:00
Tom Payne
6c0b719aef Remove OpenLayers 2, as discussed with @ahocevar, @elemoine and @tschaub 2012-08-30 15:00:23 +02:00
Tom Payne
4aff22e980 ol3 is now internal, ol is now external
As discussed with @ahocevar, @elemoine and @tschaub.
2012-08-29 20:46:42 +02:00
Éric Lemoine
1eddf91996 Merge pull request #19 from elemoine/getcoordinate
MapBrowserEvent.getCoordinate may return wrong coords
2012-08-27 03:44:15 -07:00
Éric Lemoine
cb6c73d99f MapBrowserEvent.getCoordinate may return wrong coords 2012-08-27 11:51:39 +02:00
Éric Lemoine
5998c0a48a Merge pull request #18 from elemoine/domrenderer
DOM renderer changes
2012-08-22 01:34:22 -07:00
Éric Lemoine
d0ffc6186d remove FIXMEs 2012-08-22 10:33:30 +02:00
Éric Lemoine
e0a6f3aeeb remove ol.TWO_LAYERS_DEMO_ENABLE_DOM from two-layers example 2012-08-21 21:24:12 +02:00
Éric Lemoine
3afe799cf3 dom.LayerRenderer.handleLayerLoad addition 2012-08-21 21:23:45 +02:00
Tom Payne
7a720d2c90 Configure more detailed logging by default in side-by-side demo 2012-08-21 18:34:03 +02:00
Tom Payne
5d75d42966 Log animation and rendering related actions 2012-08-21 18:33:35 +02:00
Tom Payne
6edc051548 Give each ol.Map instance its own logger 2012-08-21 18:33:02 +02:00
Tom Payne
f92d975921 Give each instance its own logger, instead of using a per-class logger 2012-08-21 18:32:22 +02:00
Tom Payne
eae8860072 Correct some jsdoc comments 2012-08-21 18:01:02 +02:00
Tom Payne
9fccf439da Don't bother freeing resources when context is lost 2012-08-21 18:00:44 +02:00
Tom Payne
0be2fb6e75 Defer texture loads until post render 2012-08-21 18:00:27 +02:00
Tom Payne
f02a0d0471 Fix ol.webgl.MapRenderer.prototype.isImageTextureLoaded 2012-08-21 17:56:57 +02:00
Tom Payne
bc22fd9ae4 Add ol.Map.prototype.isAnimating 2012-08-21 17:56:38 +02:00
Tom Payne
1d5cdcb0ac Add Stamen maps support 2012-08-21 15:30:49 +02:00
Tom Payne
7c77b6a88b Respect extent when requesting TileJSON tiles 2012-08-21 15:30:48 +02:00
Éric Lemoine
36b8cb7845 Merge pull request #17 from elemoine/layout
change map HTML layout
2012-08-21 03:09:43 -07:00
Éric Lemoine
95a2b3845c map renderer should call map.render instead of this.render 2012-08-21 06:55:57 +02:00
Éric Lemoine
042893a817 enable DOM in two-layers example 2012-08-21 06:55:21 +02:00
Éric Lemoine
0fd6629459 map renderer should not render if map is not defined 2012-08-21 06:54:42 +02:00
Éric Lemoine
83994081b5 mouseposition listens to mousemove and mouseout on map viewport 2012-08-20 21:51:23 +02:00
Éric Lemoine
d0572c081e webgl canvas element does not need overflow:hidden 2012-08-20 21:50:24 +02:00
Éric Lemoine
21ae6d1be3 DOM map renderer no longer need a viewport 2012-08-20 21:49:40 +02:00
Éric Lemoine
a610413811 map renderer target is now map renderer container 2012-08-20 21:48:30 +02:00
Éric Lemoine
a9706cd84b Map.handleViewportResize renamed handleBrowserWindowResize 2012-08-20 21:44:57 +02:00
Éric Lemoine
66d4d199b4 map target is now map container 2012-08-20 21:44:29 +02:00
Éric Lemoine
ca2b6e4189 map has a viewport 2012-08-20 21:41:44 +02:00
Éric Lemoine
a17a4a2581 Merge pull request #16 from elemoine/tilejson
use setExtent to set extent of TileJSON tile store
2012-08-19 13:50:47 -07:00
Éric Lemoine
189b43ad4a two-layers example - do not add layers twice 2012-08-17 22:17:06 +02:00
Éric Lemoine
5096964ec2 use setExtent to set extent of TileJSON tile store 2012-08-17 22:07:54 +02:00
Tom Payne
bb8b1043d9 Add missing type declaration 2012-08-16 23:51:55 +02:00
Tom Payne
f4e0404336 Defer WebGL resource deletion to post-frame 2012-08-16 23:43:33 +02:00
Tom Payne
5df59d047d Add gl.webgl.FREE_RESOURCES_IMMEDIATELY @define 2012-08-16 23:43:33 +02:00
Tom Payne
ee59e877e0 Refactor animation logic 2012-08-16 23:43:33 +02:00
Tom Payne
867b36410b Add Map postrender event 2012-08-16 23:43:33 +02:00
Tom Payne
9b17d28b2b Add ol.webgl.tilelayerrenderer.logger 2012-08-16 23:43:32 +02:00
Tom Payne
a49ea9bbed Enable finest logging in debug mode 2012-08-16 23:22:38 +02:00
Tom Payne
b8edf651e9 Move ol.Collection.create to ol3.collection 2012-08-16 21:47:12 +02:00
Tom Payne
a30b2f1795 Move ol.Object.createFromObject to its proper home as a simplified API function 2012-08-16 21:43:23 +02:00
Tom Payne
69cd2df009 Trigger render in Map, not MapRenderer 2012-08-16 18:32:38 +02:00
Tom Payne
5a9fe22e8c Avoid calling render() too early 2012-08-16 18:26:59 +02:00
Tom Payne
44cd3ceccb Re-order functions alphabetically 2012-08-16 17:56:19 +02:00
Tom Payne
4f2b6a0c22 Initialize all member variables in constructor 2012-08-16 16:42:56 +02:00
Éric Lemoine
a43cd15b27 Merge pull request #15 from elemoine/renderer
separate map and map renderer
2012-08-16 07:27:55 -07:00
Éric Lemoine
adb209c3f9 map functions in alphabetical order 2012-08-16 16:14:16 +02:00
Éric Lemoine
70587af947 move pixel to/from coordinate calculation functions from Map to MapRenderer 2012-08-16 15:35:33 +02:00
Éric Lemoine
9eb031ed89 remove ol.webgl.LayerRenderer.prototype.getGL (as suggest by @twpayne) 2012-08-16 15:04:23 +02:00
Éric Lemoine
89eadc5770 move back rendering freeze/unfreeze and animation from map renderer to map 2012-08-16 15:00:14 +02:00
Éric Lemoine
f7185f1c75 remove map FIXME 2012-08-16 14:57:42 +02:00
Éric Lemoine
af63654776 Merge remote branch 'upstream/exp' into renderer 2012-08-14 21:19:46 +02:00
Tom Payne
c157d4f01f Merge pull request #14 from openlayers/exp-remove-object-changed-methods
Remove support for *_changed methods
2012-08-14 08:21:19 -07:00
Tom Payne
65278c4322 Remove support for *_changed methods 2012-08-14 16:00:18 +02:00
Tom Payne
104c859f85 Satisfy gjslint 2012-08-14 15:09:57 +02:00
Éric Lemoine
d9b51cdc7f fix typo in API doc 2012-08-14 10:24:30 +02:00
Éric Lemoine
0f401a2d51 forEach cannot iterate over a null object 2012-08-14 10:24:12 +02:00
Éric Lemoine
9f5b98e70c remove split out renderer FIXME 2012-08-14 10:23:06 +02:00
Éric Lemoine
da9de171d2 exit renderer hint for loop when map renderer is found 2012-08-14 10:22:46 +02:00
Tom Payne
dafbd503a5 Use matrix inversion to calculate pixel to coordinate matrix 2012-08-14 09:37:48 +02:00
Tom Payne
477dc0b92b Fix direction of rotation in coordinate to pixel matrix 2012-08-14 09:37:16 +02:00
Tom Payne
d9009eae10 Fix missed used of goog.webgl 2012-08-14 09:20:51 +02:00
Éric Lemoine
85c8dddc02 add a FIXME 2012-08-14 07:48:13 +02:00
Éric Lemoine
e7696dd6aa map renderer unregisters listeners on dispose 2012-08-14 07:44:25 +02:00
Éric Lemoine
f0ecf858c8 better type 2012-08-14 07:35:24 +02:00
Éric Lemoine
7be8a735fa better code (thanks @twpayne) 2012-08-14 07:26:43 +02:00
Éric Lemoine
6f0ae684f7 fix linter errors 2012-08-14 07:15:54 +02:00
Éric Lemoine
9efa34a2a3 separate map and renderer 2012-08-13 23:38:37 +02:00
Tom Payne
9b4b35f9eb Add two layers demo 2012-08-13 21:32:41 +02:00
Tom Payne
d9eb9eda60 Add missing check 2012-08-13 21:31:41 +02:00
Tom Payne
c7f78caec9 Check left mouse button is pressed in interactions 2012-08-13 18:41:10 +02:00
Tom Payne
8a2074a383 Don't listen to earlycancel dragger events
earlycancel drag events do not have a corresponding
goog.events.BrowserEvent object, which breaks many interactions.
2012-08-13 18:40:03 +02:00
Tom Payne
07c3cd3d8d Fix drag pan for rotated maps 2012-08-13 18:07:30 +02:00
Tom Payne
85fb3980b6 Add missing closing tag 2012-08-13 17:52:46 +02:00
Tom Payne
5ae3d25f52 Add some FIXMEs 2012-08-13 17:24:31 +02:00
Tom Payne
e9e1b8eaa9 Improve handling of undefined coordinates 2012-08-13 17:24:25 +02:00
Tom Payne
d5bd49d86b Use ol.control.MousePosition in demo 2012-08-13 16:45:10 +02:00
Tom Payne
85ca630935 Add ol.control.MousePosition 2012-08-13 16:45:10 +02:00
Tom Payne
6495cfb043 Add crude coordinate formatter 2012-08-13 16:45:10 +02:00
Tom Payne
ec3475806e s/View/Control/, thanks @elemoine 2012-08-13 16:45:10 +02:00
Tom Payne
208db33bfc s/Control/Interaction/, thanks @elemoine 2012-08-13 16:45:10 +02:00
Tom Payne
b2da697519 Revert "Improve WebGL pixel precision"
This reverts commit 05b6ca05fe.
2012-08-08 15:30:41 +02:00
Tom Payne
ad2061ae5c Sort projections 2012-08-08 11:53:23 +02:00
Tom Payne
e434695082 Make more projection constants private 2012-08-08 01:27:05 +02:00
Tom Payne
35cf4db8cf Remove stray variable 2012-08-08 01:20:57 +02:00
Tom Payne
7ed5f42fb9 Make some projection functions private, for now 2012-08-08 00:44:15 +02:00
Tom Payne
e78986c954 Add Proj4js demo 2012-08-08 00:44:15 +02:00
Tom Payne
6bab81ffe7 Add Proj4js support 2012-08-08 00:44:15 +02:00
Tom Payne
4aa7745de5 Enable Proj4js externs 2012-08-08 00:37:41 +02:00
Tom Payne
21cb524a53 Better clean up in Makefile 2012-08-08 00:37:25 +02:00
Tom Payne
5062b71b3c Add simplified API demo 2012-08-07 20:31:09 +02:00
Tom Payne
6cb362218b Add initial simplified API 2012-08-07 20:29:19 +02:00
Tom Payne
ebe132f765 Add reset rotation key to side-by-side demo 2012-08-07 17:48:38 +02:00
Tom Payne
05b6ca05fe Improve WebGL pixel precision 2012-08-07 17:46:06 +02:00
Tom Payne
eab38e9042 Use Alt key instead of Shift for rotation 2012-08-07 17:20:42 +02:00
Tom Payne
f76b34bc38 Consistent capitalization 2012-08-07 16:40:40 +02:00
Tom Payne
43a940027f Set events pane width and height in pixels 2012-08-07 16:38:27 +02:00
Tom Payne
991c61110b Use simple optimizations instead of whitespace only 2012-08-07 16:04:15 +02:00
Tom Payne
c53e91e205 Degrade gracefully if WebGL is not supported 2012-08-07 15:53:51 +02:00
Tom Payne
74a332d166 Add side-by-side demo notes 2012-08-07 15:46:12 +02:00
Tom Payne
afe85dd620 Add keyboard controls to side-by-side demo 2012-08-07 14:59:40 +02:00
Tom Payne
49dc2788d5 Add ol.control.Keyboard hack 2012-08-07 14:59:39 +02:00
Tom Payne
7612054913 Cosmetic touchups to side-by-side demo 2012-08-07 14:55:07 +02:00
Tom Payne
0a4d31417f Clean up build system and add demos 2012-08-07 14:17:15 +02:00
Tom Payne
e1e64b0fde Add missing dependency 2012-08-07 13:18:55 +02:00
Tom Payne
d8af9a2108 Friendlier type checking 2012-08-07 13:18:46 +02:00
Tom Payne
88d2299096 Use ShiftDragRotate instead of ShiftDragRotateAndZoom control by default 2012-08-07 13:18:20 +02:00
Tom Payne
7a675a0789 Clean up .gitignore 2012-08-07 12:12:35 +02:00
Tom Payne
9366ced2a8 Move to-be-merged code into attic 2012-08-07 12:11:25 +02:00
Tom Payne
1f5cda88c4 Replace ol.Tile.isLoaded with ol.Tile.getState 2012-08-07 12:07:55 +02:00
Tom Payne
2983a2ef02 Remove redundant call 2012-08-07 12:07:00 +02:00
Tom Payne
161b15c6aa Log WebGLContext{Lost,Restored} events in debug mode 2012-08-07 10:04:20 +02:00
Tom Payne
2443326d0e Use || operator instead of goog.isDef()/?: 2012-08-06 18:43:05 +02:00
Tom Payne
1b9015fab8 Add ol.layer.TileJSON 2012-08-06 18:02:40 +02:00
Tom Payne
0ea267b95b Use TileJSON externs 2012-08-06 17:59:55 +02:00
Tom Payne
1c98275ff2 Add TileJSON externs 2012-08-06 17:55:47 +02:00
Tom Payne
485a0f6403 Clean up after callback called 2012-08-06 17:55:30 +02:00
Tom Payne
75342968ce Add ol.layer.MapQuest{OSM,OpenAerial} 2012-08-06 15:51:46 +02:00
Tom Payne
9b50b96729 Use new tile server syntax 2012-08-06 15:50:49 +02:00
Tom Payne
3cb1d9f64f Add convenient syntax for specifying multiple tile servers 2012-08-06 15:50:12 +02:00
Tom Payne
4a76efbbc7 Use nicer zoom levels 2012-08-06 13:54:51 +02:00
Tom Payne
b0fa84b38c Add specialized ol.tilegrid.XYZ.forEachTileCoordParentTileBounds 2012-08-06 13:45:22 +02:00
Tom Payne
c4a9e970b5 Remove merged code 2012-08-06 10:49:59 +02:00
Tom Payne
0edb85f159 Clean up whitespace 2012-08-06 09:59:33 +02:00
Tom Payne
bf2958494d Add another FIXME 2012-08-06 09:57:29 +02:00
Tom Payne
4675ae2285 Fix rendering at large zooms 2012-08-06 09:39:41 +02:00
Tom Payne
9d891c1339 Add missing require 2012-08-06 09:20:05 +02:00
Tom Payne
d62f776be5 Fix zoom to anchor 2012-08-06 09:14:28 +02:00
Tom Payne
fe8c064a2e Clean up calculation of framebuffer extent and size 2012-08-06 01:20:21 +02:00
Tom Payne
530724235a Add ol.webgl.Map.isImageTextureLoaded 2012-08-06 01:20:21 +02:00
Tom Payne
2a198bf255 Update FIXMEs 2012-08-06 01:20:21 +02:00
Tom Payne
adbd86feb8 Use continuous zoom by default 2012-08-06 01:20:21 +02:00
Tom Payne
aad50aa8a4 Add ol.control.ResolutionConstraint.createContinuous 2012-08-06 01:14:25 +02:00
Tom Payne
17c68a18fc Fix typo 2012-08-06 01:14:25 +02:00
Tom Payne
2d8514148d Order functions alphabetically 2012-08-06 00:20:41 +02:00
Tom Payne
f776e3f616 Order functions alphabetically 2012-08-06 00:07:38 +02:00
Tom Payne
bf6705a80d Improve algorithm for finding framebuffer size 2012-08-06 00:07:38 +02:00
Tom Payne
71c659396d Remove unused variable 2012-08-06 00:07:38 +02:00
Tom Payne
d8cbe6c8fe Order functions alphabetically and clean up whitespace 2012-08-06 00:07:38 +02:00
Tom Payne
f06d236383 Remove unused renderbuffer 2012-08-05 23:44:37 +02:00
Tom Payne
9cff381149 Use vec4 rather than mat4 for linear tile transforms 2012-08-05 23:42:43 +02:00
Tom Payne
a38dc0db28 Add interim tiles 2012-08-05 23:17:56 +02:00
Tom Payne
9861cd4ddc Remove unused code 2012-08-05 23:13:02 +02:00
Tom Payne
3e4b132446 Replace getTileTexture with bindImageTexture 2012-08-05 01:13:30 +02:00
Tom Payne
e0509d7d08 s/framebufferTileBoundsExtent/framebufferExtent/ 2012-08-05 00:39:52 +02:00
Tom Payne
d7623356fc More explict key variable names 2012-08-05 00:38:27 +02:00
Tom Payne
a3b73d5fd4 s/forEachTileCoordParent/forEachTileCoordParentTileBounds/ 2012-08-05 00:32:02 +02:00
Tom Payne
c2b1a94298 Don't re-use ol.TileCoord object 2012-08-04 18:46:54 +02:00
Tom Payne
051175ea68 Add another FIXME 2012-08-04 16:53:48 +02:00
Tom Payne
b7e7a9b3ba Add zoom to/from anchor 2012-08-04 16:53:48 +02:00
Tom Payne
97eabc8693 Parameterize pixel delta 2012-08-04 15:51:35 +02:00
Tom Payne
7ab3b3dd82 Add rotation constraints 2012-08-04 15:51:35 +02:00
Tom Payne
0fd122a1ed Add and use ol.Constraints 2012-08-04 15:51:35 +02:00
Tom Payne
eaca7d0a8c Add ol.Coordinate.ZERO 2012-08-04 15:51:35 +02:00
Tom Payne
505804fc55 Fix missed variable name 2012-08-04 15:51:35 +02:00
Tom Payne
e7cb2ca383 s/ZoomFunction/ResolutionConstraint/ 2012-08-04 15:51:35 +02:00
Tom Payne
c84d5ef9ef Use ol.control.CenterConstraint 2012-08-04 15:51:34 +02:00
Tom Payne
1f72319b05 Add ol.control.CenterConstraint 2012-08-04 15:51:34 +02:00
Tom Payne
78f11873cf Clean up whitespace 2012-08-03 17:27:16 +02:00
Tom Payne
f0d0157871 Add missing @protected 2012-08-03 11:13:29 +02:00
Tom Payne
d03586d8e9 Use goog.dom functions 2012-08-03 11:13:01 +02:00
Tom Payne
c75ce23c5a Remove stray bracket 2012-08-03 11:11:38 +02:00
Tom Payne
0c35d50fed Export properties so libary can be used in compiled mode 2012-08-03 10:37:17 +02:00
Tom Payne
59398db62b Treat warnings as errors 2012-08-03 10:32:34 +02:00
Tom Payne
bd8ae92f89 Update readme.md 2012-08-02 17:06:36 +02:00
Tom Payne
e503955b6d Update FIXMEs 2012-08-02 17:03:19 +02:00
Tom Payne
62a6faa4d5 Use goog.dom functions and clean up when layers change 2012-08-02 17:02:14 +02:00
Tom Payne
a96982f112 Remove collection {insert,remove,set}_at callbacks 2012-08-02 16:49:09 +02:00
Tom Payne
1b8132ecfd Use add/remove events 2012-08-02 16:47:08 +02:00
Tom Payne
bc0bfd8385 Add add and remove events 2012-08-02 16:42:50 +02:00
Tom Payne
be17ed3707 Add another FIXME 2012-08-02 16:13:13 +02:00
Tom Payne
66f4e1f401 Correct stupid typo 2012-08-02 16:13:01 +02:00
Tom Payne
e203944abf Refactor and optimize attributions 2012-08-02 16:07:10 +02:00
Tom Payne
bee4cab2ac Handle attribution visiblity for tile layers 2012-08-02 15:14:03 +02:00
Tom Payne
5d870e62c2 Handle not-ready layers in attribution view 2012-08-02 14:43:20 +02:00
Tom Payne
53f1397109 Correct coordinate order in Bing Maps coverage area bboxes 2012-08-02 14:32:42 +02:00
Tom Payne
fbdc0a1ce1 Clean up and simplify build system 2012-08-02 14:02:37 +02:00
Tom Payne
b0899863a8 Move more code to be merged into the attic 2012-08-02 13:57:41 +02:00
Tom Payne
eec1fdab62 Use goog.nullFunction 2012-08-02 12:38:55 +02:00
Tom Payne
09f439cb4f Clean up whitespace 2012-08-02 12:18:45 +02:00
Tom Payne
b86fd52026 Remove some fixed FIXMEs 2012-08-01 19:26:29 +02:00
Tom Payne
979b0d882e Remove projection check 2012-08-01 19:23:53 +02:00
Tom Payne
b4183642ae Make ol.CoverageArea use composition rather than inheritance for extent 2012-08-01 19:23:21 +02:00
Tom Payne
2fc4b10492 Use better check for equivalent transforms 2012-08-01 19:14:53 +02:00
Tom Payne
a9ee017158 Add ol.view.Attribution 2012-07-30 22:17:12 +02:00
Tom Payne
71201340cc Add ol.View 2012-07-30 22:17:12 +02:00
Tom Payne
fdfe23faac Use ol.Attribution 2012-07-30 22:17:12 +02:00
Tom Payne
09d904967a Add attributions to ol.Store 2012-07-30 21:53:05 +02:00
Tom Payne
575ae03f5d Add ol.Attribution 2012-07-30 21:51:58 +02:00
Tom Payne
43f3f18871 Add ol.CoverageArea 2012-07-30 21:51:42 +02:00
Tom Payne
de1e704bc7 Reuse existing function 2012-07-30 21:51:20 +02:00
Tom Payne
076342b886 Less fancy type checking 2012-07-30 21:50:48 +02:00
Tom Payne
ab8d297827 s/transform/transformFn/ 2012-07-30 21:37:25 +02:00
Tom Payne
95371b596e Use ol.control.ZoomFunction 2012-07-30 15:09:50 +02:00
Tom Payne
187da7767f Add ol.control.ZoomFunction 2012-07-30 15:09:50 +02:00
Tom Payne
82f67006ab Allow center and resolution to set to undefined 2012-07-30 15:09:50 +02:00
Tom Payne
65c8fe3741 Use ol.array utility functions 2012-07-30 15:09:50 +02:00
Tom Payne
4f9044cda4 Add ol.array utility functions 2012-07-30 15:09:50 +02:00
Tom Payne
8512eaa24f Use simpler comparison function 2012-07-30 13:02:31 +02:00
Tom Payne
34f9e35ba9 Remove trailing zeros 2012-07-30 11:56:34 +02:00
Tom Payne
b291885ffa Use clearer argument names 2012-07-30 09:19:44 +02:00
Tom Payne
a5b0fb4908 Rename ol.Array to ol.Collection 2012-07-30 09:14:53 +02:00
Tom Payne
f39a09807b Update FIXMEs 2012-07-30 00:35:07 +02:00
Tom Payne
422010271b Use ultra-sexy RotateAndZoom control by default 2012-07-30 00:30:55 +02:00
Tom Payne
74dd45f856 Add ultra-sexy RotateAndZoom control 2012-07-30 00:30:28 +02:00
Tom Payne
24888be786 Use ol.control.ShiftDragRotate 2012-07-30 00:10:08 +02:00
Tom Payne
8b900c7822 Add ol.control.ShiftDragRotate 2012-07-30 00:09:47 +02:00
Tom Payne
2f32158374 Rename ol.control.DragZoom to ol.control.ShiftDragZoom 2012-07-29 17:17:49 +02:00
Tom Payne
8179cf0b69 Add rotation to WebGL tile layer renderer 2012-07-29 17:09:33 +02:00
Tom Payne
9f3c02757d Add rotation infrastructure 2012-07-29 17:09:33 +02:00
Tom Payne
f9aa8d2e6c Order variables alphabetically 2012-07-29 17:09:33 +02:00
Tom Payne
5c30902de0 Clean up Makefile 2012-07-29 17:09:32 +02:00
Tom Payne
bd87448b59 Make ol.Coordinate inherit from goog.math.Vec2 2012-07-29 17:09:32 +02:00
Tom Payne
a8664df76b Make ol.Map.isDef stricter 2012-07-29 17:09:32 +02:00
Tom Payne
adfbf2ae7b Remove empty functions 2012-07-29 17:09:32 +02:00
Tom Payne
faa37490ea Use ol.Pixel to represent pixels 2012-07-29 17:09:32 +02:00
Tom Payne
10c85f3d07 Add ol.Pixel 2012-07-29 17:09:32 +02:00
Tom Payne
6d83205c08 Remove unused require 2012-07-29 17:09:32 +02:00
Tom Payne
b45a211cdc Use matricies for pixel/coordinate transforms 2012-07-29 17:09:32 +02:00
Tom Payne
2607399a48 Add rotation property 2012-07-29 11:13:50 +02:00
Tom Payne
74b67a2e3a Fix intermediate zoom levels in WebGL tile layer renderer 2012-07-29 11:05:13 +02:00
Tom Payne
12956da634 Add another FIXME 2012-07-28 23:47:14 +02:00
Tom Payne
ef91733505 Use consistent variable names between WebGL and DOM tile layer renderers 2012-07-28 23:42:27 +02:00
Tom Payne
6ef859b07e Avoid recalculating extent 2012-07-28 23:35:26 +02:00
Tom Payne
a4727c4ef7 Add missing dependencies 2012-07-28 23:26:34 +02:00
Tom Payne
5c0498a958 Use public methods where available 2012-07-28 23:19:14 +02:00
Tom Payne
88d1759751 Add more FIXMEs 2012-07-28 23:18:41 +02:00
Tom Payne
90a4fe9625 Layer loads should be handled by LayerRenderers, not the Map 2012-07-28 16:25:57 +02:00
Tom Payne
7144e7ad0b Use Closure logging infrastructure for WebGL errors 2012-07-28 16:01:38 +02:00
Tom Payne
b88c4f5888 Activate Closure logging infrastructure 2012-07-28 16:01:14 +02:00
Tom Payne
c4f9e3656b Don't use webgl-debug.js 2012-07-28 15:57:53 +02:00
Tom Payne
83077d2754 Clean up whitespace 2012-07-28 15:40:46 +02:00
Tom Payne
0ae4555f30 Add initial ol.layer.BingMaps 2012-07-28 01:23:40 +02:00
Tom Payne
08735e30ff Make attributions an array of strings rather than a string 2012-07-28 01:15:33 +02:00
Tom Payne
b59fe13242 Make ol.Rectangle.intersects a member function rather than a static function 2012-07-28 01:15:33 +02:00
Tom Payne
bf20ec718e Remove dead function 2012-07-28 01:15:33 +02:00
Tom Payne
c9bbf37fb0 Add another FIXME 2012-07-28 01:15:32 +02:00
Tom Payne
0804283543 Make ol.TileStore.tileGrid and tileUrlFunction protected 2012-07-28 01:15:32 +02:00
Tom Payne
6c4e91b9f6 Force render when layers load 2012-07-28 01:15:32 +02:00
Tom Payne
ade0d17541 Only iterate over ready, visible layers 2012-07-28 01:15:32 +02:00
Tom Payne
6ceeac2427 Add ol.Layer.isReady 2012-07-27 23:34:11 +02:00
Tom Payne
04f71183e8 Add ol.Store.isReady 2012-07-27 23:32:48 +02:00
Tom Payne
588f8df8ba Pass optional tile size through ol.tilegrid.XYZ 2012-07-27 20:15:27 +02:00
Tom Payne
caf67ac5ba Use strings rather than RegExps in replace 2012-07-27 20:15:03 +02:00
Tom Payne
215d1ec8db Clean up Makefile 2012-07-27 18:07:27 +02:00
Tom Payne
1afea5ca0c Update tests 2012-07-26 01:52:19 +02:00
Tom Payne
c4f9704f4f Add ol.TileUrlFunction.nullTileUrlFunction 2012-07-26 01:38:44 +02:00
Tom Payne
f193a94847 Correct type declaration of ol.TileUrlFunction 2012-07-26 01:38:44 +02:00
Tom Payne
69fabce0c0 Rename toQuadKey to quadKey 2012-07-26 01:38:31 +02:00
Tom Payne
96b02904ef Sort .gitignore 2012-07-26 00:27:59 +02:00
Tom Payne
b64d0ffdf1 Add initial Bing Maps externs 2012-07-26 00:25:46 +02:00
Tom Payne
ed4a888469 Use inheritance rather than creating an instance for OpenStreetMap, make attribution a function rather than a property 2012-07-26 00:25:03 +02:00
Tom Payne
bcee2d3a12 Auto-generate ol.js 2012-07-26 00:23:18 +02:00
Tom Payne
f3d9b3332c Move code to be merged into src/attic 2012-07-26 00:21:37 +02:00
Tom Payne
8d936e7865 Rename ol.TileCoord.fromString to createFromString 2012-07-25 17:43:08 +02:00
Tom Payne
7902803063 Add ol.TileCoord.toQuadKey and createFromQuadKey 2012-07-25 17:39:38 +02:00
Tom Payne
3ddb1137cc Use undefined, not null, found in parallel with @elemoine 2012-07-24 22:34:31 +02:00
Tom Payne
228547d0fe Add ol.Map.isDef 2012-07-24 20:47:34 +02:00
Tom Payne
042434bc54 Make cross origin 'anonymous' by default 2012-07-24 15:17:35 +02:00
Tom Payne
b1012b5b86 Make extent a function rather than a property 2012-07-24 15:17:35 +02:00
Éric Lemoine
8a8a9a8c9a add map FIXMES 2012-07-23 23:27:03 +02:00
Éric Lemoine
6d28ad2740 use goog.fx.Dragger for map drag 2012-07-23 23:26:48 +02:00
Tom Payne
58bd2182a6 Remove some unnecessary parentheses 2012-07-22 22:37:43 +02:00
Tom Payne
269bd9387e Rename freeze/thaw to freezeRendering/unfreezeRendering 2012-07-22 22:37:43 +02:00
Tom Payne
a2f24b9d43 Check that values are in range and avoid unnecessary updates 2012-07-22 22:37:43 +02:00
Tom Payne
b809bde576 Activate keyboard zoom by default 2012-07-22 14:54:17 +02:00
Tom Payne
5aa01a4b6b Add ol.control.KeyboardZoom 2012-07-22 14:54:17 +02:00
Tom Payne
0edac78bd0 Activate keyboard pan control by default 2012-07-22 14:54:17 +02:00
Tom Payne
ce0866dac4 Add ol.control.KeyboardPan 2012-07-22 14:54:17 +02:00
Tom Payne
463084ab3e Handle keyboard events 2012-07-22 14:54:17 +02:00
Tom Payne
7ed71f7149 Make browserEvent property public 2012-07-22 14:54:17 +02:00
Tom Payne
5e2a5dfbc4 Add missing require 2012-07-22 14:54:17 +02:00
Tom Payne
4b433f0c9b Move file missed in earlier clean-up 2012-07-22 14:54:17 +02:00
Éric Lemoine
75c7bee6d9 update readme.md 2012-07-22 13:48:57 +02:00
Tom Payne
ea623b7be6 Fix some stupid bugs in ol.TileBounds 2012-07-22 12:18:56 +02:00
Tom Payne
8987dc8607 Improve modularity 2012-07-22 12:17:06 +02:00
Tom Payne
cbafc0795d Add another FIXME 2012-07-22 11:40:48 +02:00
Tom Payne
511ca18b23 Tidy up fragment shader 2012-07-22 11:40:47 +02:00
Tom Payne
ec2ab8265c Add brightness and contrast controls, thanks @evanw 2012-07-22 11:40:47 +02:00
Tom Payne
883089c3d1 Sort properties 2012-07-22 11:40:47 +02:00
Tom Payne
f280faff67 Add hue and saturation controls, thanks @evanw 2012-07-22 11:40:47 +02:00
Tom Payne
21e3f2fe83 Promote opacity/visibility changes into base class 2012-07-22 11:40:47 +02:00
Tom Payne
65b7504c9f Clean up directory structure 2012-07-22 11:40:47 +02:00
Tom Payne
3eefbaa337 Remove merged code 2012-07-22 03:10:33 +02:00
Tom Payne
abc1b4ff04 Rename redraw to render 2012-07-22 03:10:33 +02:00
Tom Payne
33449e657a Add various FIXMEs 2012-07-22 03:10:32 +02:00
Tom Payne
f859a48033 Enable side-by-side DOM and WebGL demo 2012-07-22 03:10:32 +02:00
Tom Payne
4906bdced5 Add working WebGL renderer 2012-07-22 03:10:32 +02:00
Tom Payne
c82bacb762 Add ol.TileBounds.equals 2012-07-22 03:06:26 +02:00
Tom Payne
f46c9e12fb Add ol.TileBounds.containsTileBounds 2012-07-22 03:06:25 +02:00
Éric Lemoine
089f069456 finish porting tschaub's infinite zooming work 2012-07-21 23:53:51 +02:00
Éric Lemoine
014c5e8905 refactoring, and renamings in tilegrid.js (related to continous zooming) 2012-07-21 23:52:56 +02:00
Éric Lemoine
753ebab2ad Revert "add TileLayerRenderer.getPreferredZ_ plus tests". As noted by @twpayne, TileGrid.getZForResolution already returns the "preferred" z for an arbitrary resolution.
This reverts commit 8f5d0ac642.
2012-07-21 16:00:45 +02:00
Tom Payne
89efc96dd5 Don't bother making forEachTileCoord abortable 2012-07-21 01:08:44 +02:00
Tom Payne
277c1ea3a6 Use XYZ to indicate OpenStreetMap-style tile grids 2012-07-21 01:05:55 +02:00
Tom Payne
0602942cf8 Add ol.Color 2012-07-21 01:05:55 +02:00
Tom Payne
0d7426e1be Fix bug where forEachVisibleLayer returned invisible layers 2012-07-21 01:05:55 +02:00
Tom Payne
e81e857d75 Merge pull request #12 from fredj/plovr-download
Fix plovr download path
2012-07-20 10:25:08 -07:00
Frederic Junod
0b6f4e348c Fix plovr download path 2012-07-20 13:36:21 +02:00
Éric Lemoine
c723e719c6 use ol instead of goog.math 2012-07-19 23:36:16 +02:00
Éric Lemoine
8f5d0ac642 add TileLayerRenderer.getPreferredZ_ plus tests 2012-07-19 23:28:35 +02:00
Éric Lemoine
404d123623 add TileGrid getTileCoordForArbitraryResolution and getTileCoordPixelBoundsForArbitraryResolution + tests, based on @tschaub work 2012-07-19 17:48:39 +02:00
Éric Lemoine
45c067dfda add ol.PixelBounds 2012-07-19 17:47:34 +02:00
Tom Payne
1190bc08db Make demo layer more opaque 2012-07-19 15:47:19 +02:00
Tom Payne
e2824745d1 Ensure visibility and opacity are set when DOM layer renderer is created 2012-07-19 15:46:02 +02:00
Tom Payne
08b4ef665b Call inherited method, thanks @elemoine 2012-07-19 14:58:02 +02:00
Tom Payne
9ce406c203 Fix type, thanks @elemoine 2012-07-19 10:48:25 +02:00
Tom Payne
513d8e7268 Create ol.Size around goog.math.Size 2012-07-19 10:46:43 +02:00
Tom Payne
c547404615 Create ol.Coordinate around goog.math.Coordinate 2012-07-19 10:34:12 +02:00
Tom Payne
d62ba69458 Order controls alphabetically 2012-07-19 10:10:07 +02:00
Tom Payne
33d252f0f7 Only start drag pan if shift key is not pressed 2012-07-19 10:08:35 +02:00
Tom Payne
5e39d051e6 Set default user projection to EPSG:4326 2012-07-19 10:02:34 +02:00
Tom Payne
e0d17ca09c Add user projections 2012-07-19 10:02:34 +02:00
Tom Payne
305462f57a Stricter type checking for map projection 2012-07-19 10:02:34 +02:00
Tom Payne
43c32e6da7 Differentiate between identity and clone transforms 2012-07-19 09:51:08 +02:00
Tom Payne
5ace389ccb Redraw map when WebGL context is restored 2012-07-19 09:12:22 +02:00
Tom Payne
d83235b5dc Include drag zoom control in default map 2012-07-19 00:29:25 +02:00
Tom Payne
d47eb3453f Implement initial drag zoom control (shift + drag) 2012-07-19 00:29:25 +02:00
Tom Payne
3ff84dce9b Add ol.Extent.boundingExtent 2012-07-19 00:29:25 +02:00
Tom Payne
4e347dcf45 Don't drag on incompletely defined maps 2012-07-19 00:29:25 +02:00
Tom Payne
0e3b97a0b6 s/event/mapBrowserEvent/g 2012-07-19 00:29:25 +02:00
Tom Payne
1d6101a5a1 Implement ol.control.DragPan 2012-07-19 00:29:25 +02:00
Tom Payne
4299cf4fae Add startCenter and startCoordinate to ol.control.Drag 2012-07-19 00:29:24 +02:00
Tom Payne
82b8a46752 Use RAW mode for demo while ol.Object is not adapted for compiled mode 2012-07-19 00:29:24 +02:00
Tom Payne
15d2ad984b Bind map layers in demo 2012-07-19 00:29:24 +02:00
Tom Payne
a6e2b501bd Enable DOM renderers to share tile layers 2012-07-19 00:29:24 +02:00
Tom Payne
4ddcfcc037 Add context argument to Tile.getImage to support re-use in DOM renderer 2012-07-19 00:29:24 +02:00
Tom Payne
eb43cf14c1 Clean up layer renderers when layers changes 2012-07-19 00:29:24 +02:00
Tom Payne
376d75ea4f Rename ol.Projection.createFromCode to getFromCode 2012-07-19 00:29:24 +02:00
Tom Payne
da941562cc Handle background color in ol.webgl.Map 2012-07-19 00:29:24 +02:00
Tom Payne
092fce96ec Add background color property 2012-07-19 00:29:24 +02:00
Tom Payne
52ce0b3fd0 Assure redraw is called when layer becomes invisible 2012-07-19 00:29:24 +02:00
Tom Payne
d3ed8b315c Make ol.Map.getSize public 2012-07-19 00:29:24 +02:00
Tom Payne
0a33077ecc Add ol.Rectangle.toString 2012-07-19 00:29:24 +02:00
Éric Lemoine
62f3f46b51 fix compilation - private property cannot be used in subclasses 2012-07-19 00:00:23 +02:00
Éric Lemoine
db91206d41 code styling 2012-07-18 20:27:38 +02:00
Éric Lemoine
7fc82daafa dom layer renderer - support opacity and visibility change 2012-07-18 16:33:27 +02:00
Éric Lemoine
b53e5a3fda two maps in the skeleton example 2012-07-18 16:33:27 +02:00
Tom Payne
aab2bc093a Add experimental drag control (to be replaced) 2012-07-18 15:12:31 +02:00
Tom Payne
4754ed1cc2 Add ol.control.MouseWheelZoom 2012-07-18 15:12:30 +02:00
Tom Payne
c6343ed2bc Add experimental controls infrastructure, thanks @elemoine 2012-07-18 15:12:30 +02:00
Éric Lemoine
1af79ede29 dom map renderer - add FIXMEs 2012-07-18 14:52:12 +02:00
Éric Lemoine
3724fca57d dom map renderer - new properties for layerPane 2012-07-18 14:50:34 +02:00
Éric Lemoine
a9438fefd9 make gjslint happy 2012-07-18 14:50:01 +02:00
Éric Lemoine
6d61ac2bc5 dom map renderer - map shiftLayersPane_ work 2012-07-18 14:49:30 +02:00
Éric Lemoine
808a854d0f dom map renderer - add a viewport div to the top of hierarchy, this is to handle overflow of tiles 2012-07-18 14:47:41 +02:00
Éric Lemoine
1d565fc4d6 dom map renderer - use goog.asserts 2012-07-18 14:43:57 +02:00
Éric Lemoine
da6263fec8 dom layer renderer - origin and setOrigin are back 2012-07-18 14:43:16 +02:00
Éric Lemoine
db4603940d dom renderer - reset the layers pane when center changes 2012-07-18 11:13:32 +02:00
Éric Lemoine
f491a5a4d2 setting top and left to 0 is not necessary 2012-07-18 11:12:46 +02:00
Éric Lemoine
be97a57cad remove state variables from the dom map and dom layer renderers 2012-07-18 11:12:14 +02:00
Tom Payne
40c767c330 Remove main.json (replaced with ol.json) 2012-07-18 09:01:12 +02:00
ahocevar
78f8ed04dd Fixing typo. 2012-07-18 08:10:44 +02:00
ahocevar
6c9ef26c79 Using safe unicode notation. 2012-07-18 08:10:35 +02:00
Tom Payne
bffc586218 Rename ol.Map.setExtent to fitExtent 2012-07-18 07:34:14 +02:00
Tom Payne
88721ce230 Use DOM renderer by default 2012-07-18 07:33:11 +02:00
Tom Payne
fc603372c2 Add renderer hint 2012-07-18 07:32:40 +02:00
Tom Payne
e85ca98179 Refactor build system and layout 2012-07-18 02:26:41 +02:00
Tom Payne
f166285fd2 Remove api.json 2012-07-18 01:17:37 +02:00
Tom Payne
cf2bb5a841 Don't use webgl-debug.js for now 2012-07-18 00:52:31 +02:00
Tom Payne
0abc4219b3 Document various FIXMEs 2012-07-18 00:35:44 +02:00
Tom Payne
659ef30802 Lift common composite rendering code into ol.Map 2012-07-18 00:21:20 +02:00
Tom Payne
86335211a6 Always pass base to parseInt 2012-07-18 00:12:22 +02:00
Tom Payne
a421943eb1 Clear framebuffer before writing tiles 2012-07-18 00:10:43 +02:00
Tom Payne
4ca1fd00c7 Suppress compiler warning 2012-07-18 00:10:43 +02:00
Tom Payne
854280eb11 Snapshot ol.webgl.Map 2012-07-18 00:10:43 +02:00
Tom Payne
7febc1c8b3 Add ol.webgl.TileLayerRenderer.getMatrix 2012-07-18 00:10:43 +02:00
Tom Payne
b6db84a54c Add ol.webgl.LayerRenderer.getMatrix 2012-07-18 00:10:43 +02:00
Tom Payne
29f149976f Add missing require 2012-07-18 00:10:43 +02:00
Tom Payne
b93cb7c47a Add ol.Rectangle.normalize 2012-07-18 00:10:43 +02:00
Tom Payne
fad873d44c Refine getSize in terms of getWidth and getHeight 2012-07-18 00:10:42 +02:00
Tom Payne
db59dfd5a2 Rename textureCache to tileTextureCache 2012-07-18 00:10:42 +02:00
Tom Payne
7dc2884498 Fix tile edge artefacts 2012-07-18 00:10:42 +02:00
Tom Payne
6abcc56789 Suppress compiler warnings 2012-07-18 00:10:42 +02:00
Tom Payne
d0233600d5 Add ol.TileGrid.getTileBoundsExtent 2012-07-18 00:10:42 +02:00
Tom Payne
0d5bc44326 Add ol.Rectangle.getSize 2012-07-18 00:10:42 +02:00
Éric Lemoine
b31c3f90bd initial port of @tschaub DOM renderer 2012-07-17 22:28:58 +02:00
Éric Lemoine
5b5b89819e alphabetize goog.require classes for gjslint 2012-07-17 22:13:15 +02:00
Tom Payne
f77ad158f0 Initial working WebGL TileLayerRenderer 2012-07-17 18:56:10 +02:00
Tom Payne
40e83b9258 Don't redraw if center or resolution is not defined 2012-07-17 18:55:33 +02:00
Tom Payne
be94eafae6 Override getLayer in ol.webgl.TileLayerRenderer 2012-07-17 17:39:47 +02:00
Tom Payne
aded70d6e6 Add ol.TileBounds.getSize 2012-07-17 17:28:51 +02:00
Éric Lemoine
b4fea2233e remove setDefaultCenterAndResolution 2012-07-17 17:21:28 +02:00
Tom Payne
41175a475f Add ol.Rectangle.intersects 2012-07-17 15:51:13 +02:00
Tom Payne
d8a5126265 Snapshot WebGL renderer 2012-07-17 14:07:29 +02:00
Tom Payne
51e1d364c4 Remove unnecessary texture parameters 2012-07-17 14:07:16 +02:00
Tom Payne
7c290e9e30 Add skeleton ol.webgl.TileLayerRenderer shaders 2012-07-17 14:06:45 +02:00
Tom Payne
117321ea43 Name event handlers more consistently 2012-07-17 14:06:01 +02:00
Tom Payne
ab702c29e6 Replace forEachLayer with forEachVisibleLayer and pass layer renderer 2012-07-17 14:05:15 +02:00
Tom Payne
ac80a6e0b6 Merge shaders into single file 2012-07-17 13:41:38 +02:00
Tom Payne
7e2816ecd8 Implement shaders as singletons 2012-07-17 13:17:40 +02:00
Tom Payne
3ba0525495 Snapshot WebGL renderer 2012-07-17 12:15:33 +02:00
Tom Payne
0db1b0c0d6 Override getMap in ol.webgl.LayerRenderer 2012-07-17 12:13:51 +02:00
Tom Payne
e0f840dd27 Override method rather than adding a new one 2012-07-17 12:13:15 +02:00
Tom Payne
49c9a409e2 Use @nosideeffects in webgl-debug externs 2012-07-17 12:12:38 +02:00
Tom Payne
e3bbd67092 Use @nosideeffects in Proj4js externs 2012-07-17 12:12:28 +02:00
Tom Payne
253d62763f Refactor context lost handling 2012-07-17 12:01:32 +02:00
Tom Payne
495630355a Add texture cache 2012-07-17 12:01:32 +02:00
Tom Payne
1aaa59a110 Move ol.webgl.WebGLContextEventType into ol.webgl 2012-07-17 11:56:44 +02:00
Tom Payne
da9c39b737 Add missing requires 2012-07-17 08:57:47 +02:00
Tom Payne
472f6ddd17 Satisfy more recent gjslint 2012-07-17 08:55:45 +02:00
Tom Payne
ff8b9133b3 Add more functions and clean up unnecessary comments 2012-07-16 13:11:44 +02:00
Tom Payne
c162f3582d Remove unnecessary comments 2012-07-16 13:10:54 +02:00
Tom Payne
5c168d3b89 Update externs files for gjslint's --limited_doc_files 2012-07-15 22:34:09 +02:00
Tom Payne
13ce1aa374 Use --limited_doc_files option for externs 2012-07-15 22:31:04 +02:00
Tom Payne
a84198f756 OpenStreetMap wraps X and crops Y 2012-07-15 22:22:46 +02:00
Tom Payne
8df2404e77 Return null tiles when out of range 2012-07-15 22:22:25 +02:00
Tom Payne
bf31b614e8 Allow out-of-range signalling with undefined 2012-07-15 22:21:25 +02:00
Tom Payne
e23e19c074 Snapshot ol.webgl.TileLayerRenderer 2012-07-15 20:50:21 +02:00
Tom Payne
dd40b4a758 Dispatch change event on load 2012-07-15 20:50:21 +02:00
Tom Payne
ddbe0dccaf Correct target 2012-07-15 20:50:21 +02:00
Tom Payne
249449df3b Listen for changes in layer renderers 2012-07-15 20:50:21 +02:00
Tom Payne
74bfdd7ebe Cope with missing layer renderers 2012-07-15 20:50:21 +02:00
Tom Payne
bcf6e7d7b1 Add ol.DEBUG_WEBGL @define 2012-07-15 20:50:21 +02:00
Tom Payne
00c9c38ab9 Replace spaces with tabs 2012-07-15 20:50:21 +02:00
Tom Payne
377043b20e Add webgl-debug.js externs 2012-07-15 20:50:21 +02:00
Tom Payne
7d8d8253a3 Include webgl-debug.js 2012-07-15 20:42:09 +02:00
Tom Payne
b6282ba631 No need to create object 2012-07-15 20:40:16 +02:00
Tom Payne
ac1e757fda Clean up stale filter 2012-07-15 19:00:53 +02:00
Tom Payne
ca7d010974 Remove ol.Bounds 2012-07-15 19:00:01 +02:00
Tom Payne
ae7572aa7a Port ol.webgl.TileLayerRenderer to ol.Rectangle 2012-07-15 18:56:57 +02:00
Tom Payne
63408b82eb Port ol.Map to ol.Rectangle 2012-07-15 18:56:19 +02:00
Tom Payne
4b337ade48 Port ol.Projection to ol.Rectangle 2012-07-15 18:55:53 +02:00
Tom Payne
8c9fbc1478 Port ol.TileGrid to ol.Rectangle 2012-07-15 18:55:33 +02:00
Tom Payne
aa6ef496ef Base ol.TileBounds on ol.Rectangle instead of goog.math.Box 2012-07-15 18:54:31 +02:00
Tom Payne
ac3d05421b Base ol.Extent on ol.Rectangle instead of goog.math.Box 2012-07-15 18:54:05 +02:00
Tom Payne
b4ee35954f Add ol.Rectangle 2012-07-15 18:51:51 +02:00
Tom Payne
582a9e93e0 Snapshot WebGL renderer 2012-07-15 16:32:00 +02:00
Tom Payne
1d567bb2bf Transform tile coords when converting them to URLs 2012-07-15 16:23:03 +02:00
Tom Payne
b4c9c1e846 Use normalized tile coordinates (bottom left) 2012-07-15 16:14:24 +02:00
Tom Payne
61ab5c8f49 Refactor shader and program management 2012-07-15 14:11:32 +02:00
Tom Payne
73187bc018 Add ol.webgl.LayerRenderer.getTexture 2012-07-15 12:33:44 +02:00
Tom Payne
af8e093768 Add ol.TileLayer.getTileStore 2012-07-15 12:32:42 +02:00
Tom Payne
af7dfc60aa Set extent to undefined when it is undefined 2012-07-15 12:32:09 +02:00
Tom Payne
26aa704a4d Refresh layer renderer management 2012-07-15 12:31:33 +02:00
Tom Payne
446fe16da1 Disable debug options by default 2012-07-15 00:41:05 +02:00
Tom Payne
55655207d1 Add commented-out compilation options 2012-07-15 00:40:37 +02:00
Tom Payne
e509f4cfe5 Be super-strict 2012-07-15 00:40:11 +02:00
Tom Payne
9e024011d4 Use goog.fx.anim 2012-07-15 00:36:26 +02:00
Tom Payne
adfdedb12b Add ol.Map.freeze/thaw 2012-07-14 22:41:04 +02:00
Tom Payne
75ab503473 Correct WebGL context handling 2012-07-14 22:18:57 +02:00
Tom Payne
d258db6204 Snapshot ol.webgl.TileLayerRenderer 2012-07-14 22:00:43 +02:00
Tom Payne
998dbdabd0 Make ol.Map.layerRenderers protected 2012-07-14 22:00:43 +02:00
Tom Payne
5aab7cb142 Add ol.TileLayer 2012-07-14 22:00:43 +02:00
Tom Payne
8d9cee2ee1 Add map parameter to ol.LayerRenderer 2012-07-14 21:51:04 +02:00
Tom Payne
669a83ff78 Add ol.webgl.LayerRenderer 2012-07-14 21:50:35 +02:00
Tom Payne
b30d0c314b Add pixel to/from coordinate transforms 2012-07-14 19:54:41 +02:00
Tom Payne
caba3814f7 Don't clone center or extent 2012-07-14 19:26:35 +02:00
Tom Payne
ba9a62120b Only redraw if visible layers are added or removed 2012-07-14 19:23:25 +02:00
Tom Payne
f66016af2e Handle resizing 2012-07-14 19:23:08 +02:00
Tom Payne
c7f418240f Check projection when adding layers 2012-07-14 18:34:39 +02:00
Tom Payne
acb8c14d28 Shortcut projection equivalence test 2012-07-14 18:34:26 +02:00
Tom Payne
fcf552ea40 Merge Camera into Map 2012-07-14 18:34:02 +02:00
Tom Payne
b80ce1fc26 Set camera defaults when layers is changed 2012-07-14 17:47:43 +02:00
Tom Payne
9266b7fdb2 Create new extent if no existing one 2012-07-14 17:47:18 +02:00
Tom Payne
dbb26dc68d Add ol.Camera.isFullyDefined 2012-07-14 17:46:50 +02:00
Tom Payne
c0aa3b77fe Configure default camera when first layer is added 2012-07-14 16:14:12 +02:00
Tom Payne
fab1bca1fb Recalculate map extent when camera property changes 2012-07-14 16:13:54 +02:00
Tom Payne
461552a72e Correct camera property change handling 2012-07-14 16:12:56 +02:00
Tom Payne
c59e6e1462 Return cloned size rather then reference 2012-07-14 16:12:24 +02:00
Tom Payne
9e8c8ad316 Add extent handling to ol.Map 2012-07-14 16:11:52 +02:00
Tom Payne
8c4d408795 ol.Store should not inherit from ol.Object 2012-07-14 15:31:36 +02:00
Tom Payne
a8138cfe17 Remove ol.TileGrid.getMaxResolution 2012-07-14 15:30:35 +02:00
Tom Payne
7107b8d105 Add ol.Extent.getCenter 2012-07-14 15:29:36 +02:00
Tom Payne
d5e706d9ff Remove unused requires 2012-07-14 15:29:21 +02:00
Tom Payne
d1e5906e2c Merge Map and MapRenderer 2012-07-14 13:36:24 +02:00
Tom Payne
19ea6a0cba Import WebGL code from WebGL Maps 2012-07-13 19:27:48 +02:00
Tom Payne
a35cd158be Snapshot WebGLMapRenderer 2012-07-13 19:14:34 +02:00
Tom Payne
f5790e14f2 Use goog.nullFunction 2012-07-13 19:13:51 +02:00
Tom Payne
8279e79818 Handle undefined properties 2012-07-13 19:13:17 +02:00
Tom Payne
bb1e81b72a Add ol.MapRenderer.forEachLayerRenderer 2012-07-13 19:12:40 +02:00
Tom Payne
773590345a Bind Map to MapRenderer properties 2012-07-13 19:12:14 +02:00
Tom Payne
152c0e9f78 Export ol.MapRendererProperty 2012-07-13 19:11:47 +02:00
Tom Payne
8ac2cb7103 Provide default layer change handlers 2012-07-13 19:11:01 +02:00
Tom Payne
d2caf1543f Add CSS to ensure map fills body 2012-07-13 19:09:41 +02:00
ahocevar
fd2ac782cf Using high level map event instead of browser event. 2012-07-13 17:54:34 +02:00
ahocevar
1c07c38a70 Using minus sign instead of ndash. 2012-07-13 17:53:33 +02:00
Éric Lemoine
425b6c6652 Merge pull request #10 from elemoine/event
make ol.Map inherit from goog.events.EventTarget
2012-07-13 08:47:39 -07:00
Éric Lemoine
a365b0aaf3 improvements to the drag handler tests 2012-07-13 17:44:46 +02:00
Éric Lemoine
226480af90 fix mousewheel handler tests 2012-07-13 16:20:23 +02:00
Éric Lemoine
6fd5bb8647 fix drag handler tests 2012-07-13 16:20:07 +02:00
Éric Lemoine
1f62bd8cd6 fix typo in drag handler 2012-07-13 16:19:42 +02:00
Éric Lemoine
2b9df6442b Revert "Allow for using a different set of default behaviors."
This reverts commit 3cc069186c.
2012-07-13 15:38:06 +02:00
Éric Lemoine
f34aa03109 Revert "Replace the navigation control by two controls, namely DragPan and MouseWheelZoom. DragPan is the map default drag control. MouseWheelZoom is the map default mouse wheel control."
This reverts commit c2a30f4ac4.
2012-07-13 15:37:39 +02:00
Éric Lemoine
dd5182c55c remove trailing spaces in tests 2012-07-13 15:37:21 +02:00
Éric Lemoine
c2a30f4ac4 Replace the navigation control by two controls, namely DragPan and MouseWheelZoom. DragPan is the map default drag control. MouseWheelZoom is the map default mouse wheel control. 2012-07-13 08:57:40 +02:00
ahocevar
f4532f1548 Completing tests for map handlers. 2012-07-12 23:48:13 +02:00
ahocevar
ba986e536d We decided to be explicit about bubble/capture. 2012-07-12 23:47:37 +02:00
ahocevar
8183164298 The underlying event will be needed frequently.
But there will also be events that don't have an underlying event, so we make it optional.
2012-07-12 23:47:16 +02:00
ahocevar
3cc069186c Allow for using a different set of default behaviors.
The default behavior of dragging and wheel zooming feels specific to 2D maps. So I think it makes sense to introduce a special type of controls (ol.control.DefaultControl) that implement default behaviors. This change also re-introduces the Navigatin control, which is a container for the default behaviors that were previously defined in the map handlers. Maybe this control needs to be renamed to Navigatin2D in the future, and there could be a different Navigation control for 3D maps.
2012-07-12 20:51:47 +02:00
ahocevar
42c4c9d869 No need to pass the element to the constructor.
If MapHandler subclasses could live without a map, it would make sense to have a constructor with a target and an element. But because the target is always the map, and the handler need to know about the map for performing default behavior, we always assume the map's viewport as element.
2012-07-12 20:44:32 +02:00
Tom Payne
964bbf41bd Add scope to ol.Array.forEach 2012-07-12 19:23:06 +02:00
ahocevar
f672303f0a New MapHandler base class; better API docs 2012-07-12 15:21:15 +02:00
ahocevar
1ad915b428 Shuffling resources; better variable names; better type declarations. 2012-07-12 13:43:47 +02:00
Éric Lemoine
8206f11372 be more explicit when calling goog.events.listen and unlisten 2012-07-12 08:20:42 +02:00
Éric Lemoine
dea307e53a typed objects for map events 2012-07-12 08:18:22 +02:00
Éric Lemoine
d4106f166d remove reference to ol.control.Navigation from ol.export.js 2012-07-12 08:17:23 +02:00
Éric Lemoine
8801542744 add code comments to click and mousewheel handlers 2012-07-12 08:14:21 +02:00
Éric Lemoine
d517bdc5cd use of goog.events.Event.stopPropagation instead of our own function 2012-07-12 07:35:14 +02:00
Tom Payne
7ae4fc3eb5 Add initial ol.WebLGLMapRenderer experiments (size not working) 2012-07-11 21:58:18 +02:00
Tom Payne
e4f729f1b9 Add ol.webglrender.IGLObject 2012-07-11 21:57:01 +02:00
Tom Payne
7a4e3aa323 Listen for target resizes in ol.MapRenderer 2012-07-11 21:21:38 +02:00
Tom Payne
5c40e1d570 Listen for all camera property changes 2012-07-11 21:20:29 +02:00
Tom Payne
9c0ce6e635 Make ol.LayerProperty public 2012-07-11 21:18:47 +02:00
Tom Payne
02113f05be Make ol.StoreProperty public 2012-07-11 21:18:34 +02:00
Tom Payne
73abd6e8b8 Make ol.CameraProperty public 2012-07-11 21:15:28 +02:00
Tom Payne
87853a5f54 Stricter type checking on target 2012-07-11 19:33:17 +02:00
Éric Lemoine
a6b37ff83d remove reference to ol.control.Navigation in ol.js 2012-07-11 18:00:40 +02:00
Éric Lemoine
c6b8a93394 add goog.require for ol.handler.Click in ol.js 2012-07-11 17:52:21 +02:00
Éric Lemoine
8194f05ce4 better doc strings for the mousewheel handler 2012-07-11 17:49:13 +02:00
Éric Lemoine
62aee1d7ea remove unused function in the mousewheel handler 2012-07-11 17:48:48 +02:00
Éric Lemoine
d73531bf57 missing goog.require in the mousewheel handler 2012-07-11 17:47:16 +02:00
Éric Lemoine
3936c62e77 drag handler constructor should call its parent 2012-07-11 17:46:57 +02:00
Éric Lemoine
be0f73fb11 better doc strings for the drag handler 2012-07-11 17:46:25 +02:00
Éric Lemoine
d73410a9b3 add a click handler 2012-07-11 17:45:32 +02:00
Éric Lemoine
da11a8c34d add ol.ENABLE_DRAG_HANDLER and ol.ENABLE_MOUSEWHEEL_HANDLER @defines, and pass a an object to the handlers for sharing states 2012-07-11 17:43:42 +02:00
Éric Lemoine
38f946d944 remove the navigation control and the event target hierarchy 2012-07-11 17:38:18 +02:00
Éric Lemoine
ae5cdc75b4 the mousewheel handler zooms the map by default 2012-07-11 17:35:50 +02:00
Tom Payne
00462bb9e4 Move renderers into their own directories 2012-07-11 17:20:09 +02:00
Tom Payne
133f6199f7 Fix gjslint errors 2012-07-11 17:20:09 +02:00
Tom Payne
cf9a41f77e Create camera, layers and projection if not specified 2012-07-11 17:20:09 +02:00
Tom Payne
a6ea18c4fc Add skeleton HTML 2012-07-11 17:20:09 +02:00
Tom Payne
62a25d7242 Add ol.TileLayer.createOpenStreetMap 2012-07-11 17:20:09 +02:00
Tom Payne
1485137f7b Add ol.TileStore.createOpenStreetMap 2012-07-11 17:20:09 +02:00
Tom Payne
b9667c208b Add ol.TileUrlFunction.createFromTemplates 2012-07-11 17:20:09 +02:00
Tom Payne
d9077f3002 Correct type of opt_values 2012-07-11 17:20:09 +02:00
Tom Payne
1298cc3da3 Add ol.Map skeleton 2012-07-11 17:20:09 +02:00
Tom Payne
995aa76d1a Add initial ol.DOMMapRenderer skeleton 2012-07-11 17:20:09 +02:00
Tom Payne
fbefb98026 Add initial ol.WebGLMapRenderer skeleton 2012-07-11 17:20:09 +02:00
Tom Payne
bcf4d9416c Add initial ol.MapRenderer skeleton 2012-07-11 17:20:09 +02:00
Tom Payne
6c1090a2df Add initial ol.LayerRenderer skeleton 2012-07-11 17:20:09 +02:00
Tom Payne
06d32b3819 Allow values to be passed to ol.Layer 2012-07-11 17:20:09 +02:00
Tom Payne
56de224667 Add missing require 2012-07-11 17:20:09 +02:00
Tom Payne
11835b18c9 Remove ol.coord.AccessorInterface 2012-07-11 17:20:08 +02:00
Tom Payne
b2b9a41be1 Merge tile cache into TileStore 2012-07-11 17:20:08 +02:00
Tom Payne
5adbd13705 Add ol.TileCoord.toString 2012-07-11 17:20:08 +02:00
Tom Payne
e199fbd7f6 Update ol.Tile 2012-07-11 17:20:08 +02:00
Tom Payne
01cb568a50 Rename Layer to Store and LayerRendereOptions to Layer 2012-07-11 17:20:08 +02:00
Tom Payne
5de1ac3dd6 Don't use typedef for type that is only used once 2012-07-11 17:20:08 +02:00
Tom Payne
2dbd9c676b Make name calculations public 2012-07-11 17:20:08 +02:00
Tom Payne
fc585de50f Cache event types and changed method names 2012-07-11 17:20:08 +02:00
Tom Payne
6610496e56 Clean up comments and argument name 2012-07-11 17:20:08 +02:00
Tom Payne
defffdada8 Allow optional initial values to be passed to ol.Object 2012-07-11 17:20:08 +02:00
Tom Payne
5a7c2e72a6 Better type checking in Layer 2012-07-11 17:20:08 +02:00
Tom Payne
dd3dead3cd Add layer to LayerRendererOptions 2012-07-11 17:20:08 +02:00
Tom Payne
1c344ffa9f s/LayerView/LayerRendererOptions/ 2012-07-11 17:20:08 +02:00
Tom Payne
10f8f1198b Add ol.TileGrid.createOpenStreetMap 2012-07-11 17:20:08 +02:00
Tom Payne
3050268eb0 Add initial ol.TileLayer skeleton 2012-07-11 17:20:08 +02:00
Tom Payne
5494c36748 Sort functions alphabetically 2012-07-11 17:20:08 +02:00
Tom Payne
40acb70a3c Add ol.TileGrid.getZForResolution 2012-07-11 17:20:08 +02:00
Tom Payne
391b5906bc s/getTileResolution/getTileCoordResolution/g 2012-07-11 17:20:07 +02:00
Tom Payne
d30c30f01d s/TileUrl/TileUrlFunction/ 2012-07-11 17:20:07 +02:00
Tom Payne
58e9ba322e Replace corner with xEast/ySouth 2012-07-11 17:20:07 +02:00
Tom Payne
d444618a11 Add missing @template declaration 2012-07-11 17:20:07 +02:00
Tom Payne
24ba87bf92 s/yield/forEach/ 2012-07-11 17:20:07 +02:00
Tom Payne
65b0094a78 Test ol.TileGrid.yieldTileCoordParents 2012-07-11 17:20:07 +02:00
Tom Payne
abb49a899a Add ol.TileBounds.forEachTileCoord 2012-07-11 17:20:07 +02:00
Tom Payne
85716afa38 Top should always be greater than or equal to bottom in ol.TileBounds 2012-07-11 17:20:07 +02:00
Tom Payne
9a89814896 Store number of resolutions in member variable 2012-07-11 17:20:07 +02:00
Tom Payne
ff34400d96 Add ol.TileCoord.clone 2012-07-11 17:20:07 +02:00
Tom Payne
9712c706ba Test ol.TileGrid.getExtentTileBounds 2012-07-11 17:20:07 +02:00
Tom Payne
4ff6f03834 s/getTileBounds/getExtentTileBounds/ 2012-07-11 17:20:07 +02:00
Tom Payne
656974090f Pass z when yielding TileCoord parents 2012-07-11 17:20:07 +02:00
Tom Payne
e63f7d166f Don't crop against TileGrid extent in TileGrid 2012-07-11 17:20:07 +02:00
Tom Payne
fe38bb694b Re-order functions alphabetically 2012-07-11 17:20:07 +02:00
Tom Payne
e656597a59 Stricter type checking on ol.TileGrid origins 2012-07-11 17:20:07 +02:00
Tom Payne
ad30fbe544 Add initial ol.TileGrid tests 2012-07-11 17:20:06 +02:00
Tom Payne
896c4c102a Check resolutions are strictly monotonically decreasing 2012-07-11 17:20:06 +02:00
Tom Payne
727b2905f7 Suppress gjslint warnings 2012-07-11 17:20:06 +02:00
Tom Payne
b92a958bcd Add more ol.Array tests 2012-07-11 17:20:06 +02:00
Tom Payne
7b6fb0b4ca Enumerate ol.Array properties 2012-07-11 17:20:06 +02:00
Tom Payne
d70869c702 Rename ol.MVCArray to ol.Array 2012-07-11 17:20:06 +02:00
Tom Payne
331ee15ac8 Enumerate ol.Object properties 2012-07-11 17:20:06 +02:00
Tom Payne
438d5f2484 Rename ol.MVCObject to ol.Object 2012-07-11 17:20:06 +02:00
Tom Payne
4bdaf293b0 Add ol.Extent.transform 2012-07-11 17:20:06 +02:00
Tom Payne
9368f05d1c Factor out ol.TransformFunction 2012-07-11 17:20:06 +02:00
Tom Payne
a2cf655bfa Add ol.Layer 2012-07-11 17:20:06 +02:00
Tom Payne
89ec9bf07a Update ol.Projection 2012-07-11 17:20:06 +02:00
Tim Schaub
c56fce2be8 Attempting to clarify. 2012-07-11 17:20:06 +02:00
Tom Payne
94d85d4821 Fix lint warnings 2012-07-11 17:20:06 +02:00
Tom Payne
13c8b8b0de Include externs in lint 2012-07-11 17:20:06 +02:00
Tom Payne
48cc0bed93 Add externs for Proj4js 2012-07-11 17:20:06 +02:00
Tom Payne
bd61a0be15 Add ol.LayerView 2012-07-11 17:20:06 +02:00
Tom Payne
9900084f46 Add initial ol.TileGrid skeleton 2012-07-11 17:20:05 +02:00
Tom Payne
afb37035dc Add ol.Extent 2012-07-11 17:20:05 +02:00
Tom Payne
8014f68719 Use goog.math.Bounds for extents 2012-07-11 17:20:05 +02:00
Tom Payne
25d67e670f Layers should always have an extent 2012-07-11 17:20:05 +02:00
Tom Payne
dc2993b61d Add ol.Camera 2012-07-11 17:20:05 +02:00
Tom Payne
c04e3d339f Add ol.TileUrl 2012-07-11 17:20:05 +02:00
Tom Payne
6ced2b5815 Update ol.Bounds, remove referenced/unreferenced bounds distinction 2012-07-11 17:20:05 +02:00
Tom Payne
a3322aa9e1 Add ol.TileBounds 2012-07-11 17:20:05 +02:00
Tom Payne
9f0738aa99 Add ol.TileCoord 2012-07-11 17:20:05 +02:00
Tom Payne
b4e2e45166 Add ol.MVCArray 2012-07-11 17:20:05 +02:00
Tom Payne
97b062fb73 Add ol.MVCObject 2012-07-11 17:20:05 +02:00
Tom Payne
46b4d96fb0 Add all.js for testing 2012-07-11 17:20:05 +02:00
Tom Payne
61038cde5f Move ol.js and ol.export.js into exports/ol.js 2012-07-11 17:20:05 +02:00
Tom Payne
79aa190e30 Add Makefile with lint target to use gjslint 2012-07-11 17:20:00 +02:00
Tom Payne
67105b0256 Don't discard Plovr version 2012-07-11 17:12:38 +02:00
Tom Payne
ed01a5db13 Ignore build targets 2012-07-11 17:12:38 +02:00
Éric Lemoine
6f1f9922cc more structure in doc/ol3.md 2012-07-11 17:12:37 +02:00
Éric Lemoine
3efa392d1f ol3.md updates 2012-07-11 17:12:37 +02:00
Éric Lemoine
c07d0c668d change ol3 doc from txt to markdown 2012-07-11 17:12:37 +02:00
Éric Lemoine
1bd975bc23 add design assertions to the doc/ol3.txt doc 2012-07-11 17:12:37 +02:00
Tom Payne
2474429f8c Add initial architecture draft 2012-07-11 17:12:37 +02:00
Éric Lemoine
357d08df99 the drag handler moves the map by default 2012-07-11 08:31:38 +02:00
Éric Lemoine
82b5a59647 remove ol.event entirely 2012-07-09 21:34:47 +02:00
Éric Lemoine
e4ff1a7574 ol.Tile inherits from goog.events.EventTarget 2012-07-09 21:33:08 +02:00
Éric Lemoine
f9cb029a74 ol.control.Zoom no longer require ol.event 2012-07-09 21:32:10 +02:00
Éric Lemoine
77b809bead ol.control.Attribution no longer require ol.event 2012-07-09 21:31:56 +02:00
Éric Lemoine
a3387bc673 ol.Map requires ol.handler.MouseWheel 2012-07-09 21:11:13 +02:00
Éric Lemoine
04f87f8f73 ol.Map:destroy is back (api tests pass again) 2012-07-09 21:09:42 +02:00
Éric Lemoine
7c7cd08494 base tests for ol.handler.Drag and ol.handler.MouseWheel 2012-07-09 21:09:09 +02:00
Éric Lemoine
aebfb643ac better type checking 2012-07-09 20:51:28 +02:00
Éric Lemoine
127a2c9606 [ol.handler.Drag] receive mousemove/touchmove events when dragstart and dragend only 2012-07-09 20:50:59 +02:00
Éric Lemoine
32757f2cd5 Merge remote branch 'upstream/master' into event 2012-07-09 19:47:46 +02:00
Éric Lemoine
484d0f8d04 use goog.events.dispatchEvent 2012-07-09 09:33:53 +02:00
Éric Lemoine
1679a59835 reset the map DEFAULT_CONTROLS array 2012-07-09 09:33:32 +02:00
Éric Lemoine
406a2da466 do no export ol.Map.prototype.destroy, it is gone 2012-07-09 09:32:57 +02:00
Éric Lemoine
f2e0adc24f make the drag handler prevent page scrolling 2012-07-09 09:32:18 +02:00
Éric Lemoine
bc72e2e444 ol.control.Attribution no longer relies on map.getEvents 2012-07-09 09:31:33 +02:00
Éric Lemoine
e0b53360d2 ol.Popup no longer relies on map.getEvents 2012-07-09 09:30:34 +02:00
Éric Lemoine
9e693f29c5 use the mousewheel handler 2012-07-09 09:28:56 +02:00
Éric Lemoine
2c61e16b55 add a mouse wheel handler 2012-07-09 09:27:36 +02:00
Tim Schaub
1dd2512765 Specs for getting tile coords. 2012-07-09 01:15:56 -06:00
Tim Schaub
7f594364ca Pixels aligned top,left to origin. 2012-07-09 01:15:56 -06:00
Éric Lemoine
34a450a009 Merge branch 'master' into event
Conflicts:
	src/ol/Map.js
	src/ol/event/Drag.js
2012-07-09 08:57:55 +02:00
ahocevar
d76eea8ac4 Fixing tests. 2012-07-09 08:26:25 +02:00
Tim Schaub
5a485ea856 Getting explicit about pixels and size.
Eventually, well have to ask renderers for all pixel and size related stuff.  And the map overlay renderer will do all pixel<->loc math.  For now, we let the map do this math based on its viewport - as this is where the mouse events are handled and it is pixels relative to the viewport that are being generated.  For now, the getViewportPixelForLoc and getLocForViewportPixel are now more explicitly named.
2012-07-08 20:57:36 -06:00
Tim Schaub
3d130d3325 Letting the map ask renderer for resolution. 2012-07-08 20:56:36 -06:00
Tim Schaub
4dfb5d0dee Set center on reset. Only shift if offset. 2012-07-08 20:42:15 -06:00
Tim Schaub
b24d63a898 Spaces for tabs. 2012-07-08 19:34:53 -06:00
Tim Schaub
4911320eef Rework DOM composite renderer. 2012-07-08 18:37:23 -06:00
Tim Schaub
ceaba3cdd4 Overlays above the renderer. 2012-07-08 18:37:23 -06:00
ahocevar
7bf1ffe606 Nice improvement of the wheel zooming experience. 2012-07-08 20:27:10 +02:00
ahocevar
4132ded263 Merge branch 'events' 2012-07-08 12:19:32 +02:00
ahocevar
ca2414c9d6 Simplify controls by registering click events on own elements.
This makes sense for all controls that provide buttons or similar UI elements that don't interfer with map interaction.
2012-07-08 12:17:11 +02:00
ahocevar
a38a331085 Allow for events on other elements than the map viewport.
Not registering browser events as priority events makes it easy for controls to preventDefault or stopPropagation when events are registered on children of the map viewport element.
2012-07-08 12:14:26 +02:00
ahocevar
e67e9049ca preventDefault and stopPropagation convenience functions.
These functions can directly be used as browser event listeners.
2012-07-08 12:12:19 +02:00
ahocevar
e8ac3f1a6b preventDefault for mousemove and touchmove.
This avoids panning of the browser page when drag-panning the map.
2012-07-08 11:55:31 +02:00
Tim Schaub
bb7127c548 Merge branch 'renderer' 2012-07-07 17:17:59 -06:00
Tim Schaub
ddd57426b5 Allow renderer to have a buffer. 2012-07-07 16:50:22 -06:00
Tim Schaub
dc409ebcc4 Resize images in case they were previously scaled. 2012-07-07 15:42:08 -06:00
Tim Schaub
c0777cc003 Working with integer pixel space. 2012-07-07 15:19:49 -06:00
Tim Schaub
523f4d61fc Shift container for all layer renderers together. 2012-07-07 13:13:07 -06:00
tschaub
d435f6b4fd Simplifying the loader.
Plovr checks the referrer for query string parameters (like mode), so we don't need any of this query string parsing (thanks @elemoine for the tip).

The reason we still dynamically generate the script tag is to work on other domains (e.g. testing on a VM or mobile device).  In this case, we make use of the `window.location.hostname`.
2012-07-05 13:55:24 -06:00
Éric Lemoine
22e7dc67d6 add a @fileoverview to ol/handler/Drag.js 2012-07-05 14:02:13 +02:00
Éric Lemoine
2fcd76bd54 ol.handler.Drag no longer needs a disposeInternal method 2012-07-05 14:01:44 +02:00
Éric Lemoine
8e36850e7f create parent event target for the map, to allow stopping event propagation 2012-07-05 13:55:57 +02:00
Éric Lemoine
410d79faa1 rely on registerDisposable 2012-07-05 11:11:35 +02:00
Éric Lemoine
946cd33350 make ol.Map inherit from goog.EventTarget, and add an ol.handler.Drag 2012-07-05 11:11:35 +02:00
Tim Schaub
0650d93d17 Let the composite renderer manage containers. 2012-07-04 22:17:56 -06:00
Tim Schaub
d8e8e55b44 Generalizing query string parsing in the loader. 2012-07-04 20:53:03 -06:00
ahocevar
578f74eb86 Less magic.
Each control is responsible for its handlers. And all controls are rendered into an overlay, not any more depending on assumptions about link click handling.
2012-06-29 09:44:52 +02:00
ahocevar
f28fe4912f I think we decided to name events in a noun+verb fashion. 2012-06-26 13:34:34 +02:00
ahocevar
8541490f53 Be more explicit about object properties to get rid of warnings. 2012-06-26 09:56:50 +02:00
ahocevar
b7c8486289 Testing Control.js. 2012-06-26 00:18:29 +02:00
ahocevar
56542de1f3 More Events.js tests. 2012-06-26 00:00:36 +02:00
Marc Jansen
1d12c1b5d8 Better test description. 2012-06-25 23:23:42 +02:00
Marc Jansen
f477fd8ced Allow multi* geometries in Collections/collections. 2012-06-25 23:19:25 +02:00
Marc Jansen
29b684f916 Correct the formatPoint test to use API methods. 2012-06-25 23:03:01 +02:00
Marc Jansen
ca5b06f108 Add exports for multilinestring. 2012-06-25 23:02:35 +02:00
Marc Jansen
25202cae6d Add a LineStringLike typedef. 2012-06-25 22:46:11 +02:00
Marc Jansen
0a60d2dc82 Include test spec in api.html. 2012-06-25 22:45:17 +02:00
Marc Jansen
7eef78ed4c Add geom/multilinestring classes and tests. 2012-06-25 22:44:42 +02:00
Marc Jansen
f2577bbf12 Correct test for remove method. 2012-06-25 22:43:22 +02:00
Marc Jansen
6d84d4d3a1 Add geom/MultiLineString classes and tests. 2012-06-25 21:36:17 +02:00
ahocevar
f962b78caa If no listeners are registered, triggerEvent does nothing now. 2012-06-25 06:32:10 +02:00
ahocevar
87459deb65 Removing unused variable. 2012-06-25 06:32:10 +02:00
Éric Lemoine
fbd4023d6a [ol.layer.TileLayer] better func comment 2012-06-24 22:30:48 +02:00
Éric Lemoine
192caa1c65 [ol.layer.TileLayer] do not load tiles outside the layer's extent 2012-06-24 22:25:01 +02:00
ahocevar
9c46aadd22 Adding attribution control and attribution. 2012-06-24 22:22:18 +02:00
ahocevar
dfc21754c9 Adding addLayers method and addlayer event. 2012-06-24 22:14:48 +02:00
ahocevar
c218e7a139 Adding missing return type. 2012-06-24 22:12:58 +02:00
ahocevar
9758910fc6 Making Element/Node types more consistent. 2012-06-24 22:12:38 +02:00
ahocevar
eabc2d9922 Shortcut to register events. 2012-06-24 20:03:58 +02:00
ahocevar
1b93856e89 Keep track of the number of events we have registered.
This is needed to reliably prevent the handleBrowserEvent method to perform potentially expensive calculations.
2012-06-24 20:03:16 +02:00
ahocevar
d8599f28b9 Let the controls decide about stopPropagation and preventDefault. 2012-06-24 19:53:42 +02:00
ahocevar
68498bc36e Fixing the way we prevent the extra click. 2012-06-24 19:48:59 +02:00
ahocevar
bd8354c831 Adding destroy method.
The control now removes its markup from the DOM. A nice aspect of our event handling is that no events need to be registered on any of the dom elements that controls create.
2012-06-24 17:08:32 +02:00
ahocevar
45222ac5cb Adding getStaticOverlay method.
This will be used by overlays, e.g. to display layer attribution.
2012-06-24 17:07:02 +02:00
Marc Jansen
f7b75a8913 Merge pull request #3 from cedricmoullet/master
Semicolon missing
2012-06-24 05:43:20 -07:00
ahocevar
bc37121ae0 Accessibility - now we can use the keyboard to zoom in and out. 2012-06-24 13:45:32 +02:00
ahocevar
218ad77103 preventDefault now happens in Events.js for all handled events. 2012-06-24 13:43:53 +02:00
ahocevar
fcadf842e5 stopPropagation and preventDefault when the event was handled. 2012-06-24 13:43:11 +02:00
ahocevar
446a434c06 New isEnterOrSpace method for keyboard navigation. 2012-06-24 13:42:34 +02:00
ahocevar
7f01528311 Proper destruction. 2012-06-24 13:41:00 +02:00
ahocevar
2fbb29efa0 Using goog.object.clear in destroy. 2012-06-24 12:46:09 +02:00
ahocevar
53a1f9b579 Adding tests for Loc.add. 2012-06-24 12:02:45 +02:00
ahocevar
fdfccb7a82 Fixing type of maxResolution. 2012-06-24 11:40:18 +02:00
ahocevar
0c9b3d1d58 Making map_ protected instead of private. 2012-06-24 11:39:42 +02:00
Cédric Moullet
38db8178e2 semicolon missing 2012-06-24 11:26:23 +02:00
ahocevar
81577d6dce Adding Loc.add method. 2012-06-24 10:09:24 +02:00
Petr Pridal
587512cac8 Introduced "ol.API" @define which will allow in future to compile HPI apps with the OL. Discussed in ol3-sprint mailing-list. 2012-06-23 23:06:45 +02:00
Éric Lemoine
b615eb94b7 add a ol.layer.wms factory 2012-06-23 21:53:45 +02:00
Éric Lemoine
0b36e10f8f [ol.map] option name maxRes changed to maxResolution (discussed in cdd9439) 2012-06-23 21:27:39 +02:00
Éric Lemoine
c7e799ebf4 [ol.popup] make the API tests pass in advanced mode 2012-06-23 21:20:15 +02:00
Tim Schaub
08d6e35252 Accept an id param for the loader. 2012-06-23 20:00:28 +02:00
Tim Schaub
2fcbce30bc For now, we require a projection on loc internally. 2012-06-23 19:59:49 +02:00
ahocevar
12fb6c5af4 Merge branch 'master' of github.com:openlayers/ol3 2012-06-23 17:03:57 +02:00
ahocevar
bba7500ab7 Making Popup tests pass. 2012-06-23 17:00:58 +02:00
Tim Schaub
bcc85b9dd7 Must set a projection before setting center. 2012-06-23 16:55:16 +02:00
Tim Schaub
db2cbe07b7 Transforming coords before setting center.
The internal setCenter method can only be called with locations that have projections.  This method always transforms.
2012-06-23 16:42:51 +02:00
ahocevar
81b8a472d8 No longer need to calculate the anchor transformation. 2012-06-23 16:16:37 +02:00
ahocevar
026b60826e Removing stub method, and use the real method in Popup. 2012-06-23 16:16:37 +02:00
ahocevar
ad8568a259 New setCenterAndZoom and setZoom methods. 2012-06-23 16:16:37 +02:00
ahocevar
abf4f41eab Check for renderer before calling methods on it. 2012-06-23 16:16:37 +02:00
Tim Schaub
48704cce2f Make sure to set a projection on user center.
Only in the API do we allow setting the map center without a projection.  This is all handled in the center getter/setter.
2012-06-23 15:40:43 +02:00
Tim Schaub
167f77dd7e Updating example with build config. 2012-06-23 15:22:37 +02:00
Tim Schaub
df1dfd5295 Adding exports to get advanced compilation. 2012-06-23 15:22:37 +02:00
ahocevar
c656bac601 Making the pointer position the zoom origin. 2012-06-23 14:22:54 +02:00
ahocevar
d391c65ac6 New pixel conversion and zoom/center related methods. 2012-06-23 14:21:37 +02:00
ahocevar
6d7c79a9b9 Merge branch 'master' of github.com:openlayers/ol3 2012-06-23 14:18:25 +02:00
ahocevar
43adc61b26 No click event at the end of a drag sequence. 2012-06-23 14:18:02 +02:00
Tim Schaub
795f8b854d Adding instructions for build utilities. 2012-06-23 14:10:25 +02:00
Tim Schaub
a1fcb4e065 Build with an arbitrary configuration. 2012-06-23 13:55:06 +02:00
ahocevar
3adf04f728 Merge branch 'master' of github.com:openlayers/ol3 2012-06-23 13:41:35 +02:00
ahocevar
e03595fdac Priority flag for unregistering priority events. 2012-06-23 13:37:39 +02:00
Tim Schaub
2991041b3c Cleaning up a bit. 2012-06-23 13:23:10 +02:00
Tim Schaub
c4f91d498c Prep for more efficient moves. 2012-06-23 12:42:09 +02:00
ahocevar
cdd9439bbd Consistency: get/setMaxResolution instead of get/setMaxRes. 2012-06-23 09:10:01 +02:00
Tim Schaub
76d90428bd Pleasant zoom. 2012-06-23 03:32:27 +02:00
Tim Schaub
0554bceb29 Drag and zoom without throwing.
(This is a bit tedious, suggests a pending state.)
2012-06-23 02:17:14 +02:00
Tim Schaub
789eaa2742 Loaded typo. 2012-06-23 02:11:26 +02:00
Tim Schaub
ef0fd8da60 Pixels increase right and down. 2012-06-23 02:00:28 +02:00
Tim Schaub
b6cfeecdfb Adjust tiles if already rendered. 2012-06-23 01:59:20 +02:00
ahocevar
a6069bb78e Center tranformation in the api; moveByPx implemented. 2012-06-22 20:49:58 +02:00
Tim Schaub
5fa42e9b30 A map that zooms. 2012-06-22 20:46:34 +02:00
Éric Lemoine
0eaaefdf1d make the TileLayerRenderer tests pass 2012-06-22 20:43:13 +02:00
Éric Lemoine
f92e128636 [ol.layer.WMS] add a basic tiled WMS layer implementation 2012-06-22 20:39:56 +02:00
Tim Schaub
cfe3f14777 Stray console log. 2012-06-22 20:38:24 +02:00
Tim Schaub
787f2ba979 Common method for conditionally rendering. 2012-06-22 20:37:29 +02:00
Tim Schaub
b986395358 This is not doing what you think it is. 2012-06-22 20:25:26 +02:00
Tim Schaub
f46a7dbc2a Updated example. 2012-06-22 20:10:02 +02:00
Tim Schaub
bc0614d3ee Render last. 2012-06-22 20:08:44 +02:00
Tim Schaub
f86e6f17a9 Absolute position for tiles. 2012-06-22 20:08:44 +02:00
Tim Schaub
af73489bd5 Create a renderer and draw when possible. 2012-06-22 20:08:44 +02:00
ahocevar
c72f803038 Adding scroll sequence and scroll support for the Navigation control. 2012-06-22 19:51:35 +02:00
ahocevar
6b8000d963 Removing debug output. 2012-06-22 19:48:05 +02:00
Tim Schaub
7b41119bc9 Composite renderer creates layer renderers. 2012-06-22 19:46:40 +02:00
Tim Schaub
ff9bacf044 Temporary way for map renderers to register. 2012-06-22 19:46:40 +02:00
Tim Schaub
915f7b5330 Clean up old tiles. 2012-06-22 19:46:40 +02:00
Mike Adair
e7240062b3 adding some more tests 2012-06-22 13:05:18 -04:00
Éric Lemoine
5dc156995a [ol.layer.TileLayer] use ol.error 2012-06-22 18:46:52 +02:00
Éric Lemoine
a26913f26e [ol.layer.TileLayer] getTileUrl should be implemented in subclasses 2012-06-22 18:31:32 +02:00
ahocevar
f504fe87b8 Removing incorrect comments. 2012-06-22 18:27:06 +02:00
ahocevar
84ee96fbd0 Don't subclass fx.Dragger - just use it. 2012-06-22 18:27:06 +02:00
Marc Jansen
c54dda723a Remove debugg statement 2012-06-22 18:26:09 +02:00
Marc Jansen
be9448457d Test & improve the getCentroid/centroid method of collections 2012-06-22 18:24:53 +02:00
Marc Jansen
abb254a0fb Test the getCentroid/centroid Method of multipoints 2012-06-22 18:24:53 +02:00
Tim Schaub
2fffa0293d Test renderer type. 2012-06-22 17:48:44 +02:00
Tim Schaub
5b2d29878b Tile may be null. 2012-06-22 17:38:59 +02:00
Éric Lemoine
68fdab6824 [ol.layer.TileLayer] do not create tiles outside the layer extent 2012-06-22 17:30:35 +02:00
Tim Schaub
0c0eecebd9 Tile index based math (needs simplification). 2012-06-22 17:29:06 +02:00
Mike Adair
264cc741ca Merge branch 'master' of github.com:openlayers/ol3 2012-06-22 11:26:25 -04:00
Mike Adair
d8b527776a fixing compiler warning 2012-06-22 11:26:09 -04:00
Marc Jansen
4dd3e695a4 Test the getCentroid/centroid Method of linestrings 2012-06-22 17:25:39 +02:00
Marc Jansen
bddb84ec14 Fix the the 'remove' exists test. 2012-06-22 17:25:39 +02:00
Marc Jansen
a235613238 dangling whitespace 2012-06-22 17:25:39 +02:00
ahocevar
6c1d510bf0 Getting rid of compiler warnings. 2012-06-22 17:17:25 +02:00
ahocevar
f12a20d7aa Stop the event chain when we have handled the event. 2012-06-22 17:14:46 +02:00
ahocevar
0420d2efb9 Adding Zoom control.
Tests still missing.
2012-06-22 17:14:22 +02:00
ahocevar
d9537b558a Simplified ISequence API; add object property also for browser events. 2012-06-22 17:12:29 +02:00
Éric Lemoine
22f569750f [ol.TileCache] tile cache size is not 1 2012-06-22 16:53:56 +02:00
Mike Adair
e748d39680 Merge branch 'master' of github.com:openlayers/ol3 2012-06-22 10:53:17 -04:00
Mike Adair
2163d54323 adds autosizing and image loading listener 2012-06-22 10:52:58 -04:00
Éric Lemoine
c501559413 Revert "[ol.TileCache] tile cache size is not 1"
This reverts commit 3f9fd2f47a.
2012-06-22 16:51:28 +02:00
Éric Lemoine
3f9fd2f47a [ol.TileCache] tile cache size is not 1 2012-06-22 16:48:48 +02:00
Marc Jansen
b664847591 Add export symbols. 2012-06-22 16:26:19 +02:00
Marc Jansen
396875c719 A centroid method for LineStrings 2012-06-22 16:26:19 +02:00
Marc Jansen
483c431e1b A centroid method vor Collections 2012-06-22 16:26:19 +02:00
Marc Jansen
73e07df544 Give geometrues a centroid method. 2012-06-22 16:26:19 +02:00
Marc Jansen
e23b119059 Whitespace changes only. 2012-06-22 16:26:19 +02:00
Marc Jansen
09d7f15fb2 Give points a getCentroid/centroid method. 2012-06-22 16:26:19 +02:00
Marc Jansen
1456e234e2 Whitespace changes only. 2012-06-22 16:26:19 +02:00
Marc Jansen
5a3dad9326 Add a basic geometry interface 2012-06-22 16:26:19 +02:00
Tim Schaub
db3a6e9c4a Get closest resolution. 2012-06-22 16:14:33 +02:00
ahocevar
65ae7eb7a7 Adding 'object' property to event object. 2012-06-22 15:58:58 +02:00
Éric Lemoine
e5c3dcfe09 [ol.layer.TileLayer] fix maxResolution calculation 2012-06-22 15:43:18 +02:00
Éric Lemoine
1df7c048b8 [ol.layer.TileLayer] tileOriginCorner is tl by default 2012-06-22 15:43:18 +02:00
Tim Schaub
ef06bee222 Allowing people to set up things backwards. 2012-06-22 15:42:56 +02:00
Éric Lemoine
71a804c5e0 [ol.layer.TileLayer] add a getTileForXYZ func 2012-06-22 15:16:58 +02:00
Petr Pridal
976239816e Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-22 14:53:53 +02:00
Petr Pridal
6cfb942ff9 Fix the calls of .transform in internal code. It should be .doTransform. 2012-06-22 14:53:12 +02:00
Petr Pridal
6f9f1783bd The demo of compilation with library in a different ways. 2012-06-22 14:48:49 +02:00
Mike Adair
675dd2b47e Merge branch 'master' of github.com:openlayers/ol3 2012-06-22 08:14:42 -04:00
Mike Adair
2396c95b2d Merge branch 'master' of github.com:openlayers/ol3 2012-06-22 08:14:13 -04:00
ahocevar
494305d725 Simplified the ISequence interface and sequence event handling. 2012-06-22 14:14:10 +02:00
Mike Adair
368bb28671 initial version of popups 2012-06-22 08:13:34 -04:00
Marc Jansen
07021d367b Handmade exports for multipoints. 2012-06-22 14:13:14 +02:00
Marc Jansen
dc686c3d07 Handmade exports for linestrings. 2012-06-22 14:13:14 +02:00
Mike Adair
a8642e9af5 Merge branch 'master' of github.com:openlayers/ol3 2012-06-22 08:12:25 -04:00
Mike Adair
5e3b18ae84 Merge branch 'master' of github.com:openlayers/ol3 2012-06-22 08:09:59 -04:00
Éric Lemoine
01668a2748 [ol.layer.TileLayer] add a getTileSize function 2012-06-22 14:09:57 +02:00
Éric Lemoine
cf3da75d83 fix layer.osm and layer.xyz api tests in adv mode 2012-06-22 14:04:44 +02:00
Éric Lemoine
e78b990f52 fix ol.geom.geometry api tests 2012-06-22 13:57:43 +02:00
Petr Pridal
8d36dfe475 Handmade exports: Require only for the 'ol', added map.renderTo and remoced map.maxRes. 2012-06-22 13:54:40 +02:00
Tom Payne
2e46765c77 Fix another typo 2012-06-22 13:43:51 +02:00
Tom Payne
fb686c9db4 Fix typo 2012-06-22 13:42:57 +02:00
Petr Pridal
f31486a982 The dynamic registration of controls - hack for the advanced mode compilation. 2012-06-22 13:13:22 +02:00
Tim Schaub
4e2ea47e73 Decode what we encode. 2012-06-22 13:12:47 +02:00
Marc Jansen
11aedf710b Test restructuring. No functional change. 2012-06-22 13:07:52 +02:00
Petr Pridal
965a5a13b2 Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-22 12:55:32 +02:00
Petr Pridal
c0dc9facf0 Let's use the handmade src/os.export.js instead of the automated generation from the @export jsdoc for testing. 2012-06-22 12:53:47 +02:00
Mike Adair
fdfeaa3c44 Merge branch 'master' of github.com:openlayers/ol3 2012-06-22 06:52:22 -04:00
Éric Lemoine
2e7d361f1e make the feature api tests pass in advanced mode 2012-06-22 12:50:06 +02:00
Petr Pridal
a5e9757234 Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-22 12:42:03 +02:00
Petr Pridal
53f8727062 Anonymous wrapper function around the api.js compiled in advanced compilation. 2012-06-22 12:40:42 +02:00
Marc Jansen
f143f32a6f Use ol.error instead of throwing directly. 2012-06-22 12:37:10 +02:00
Éric Lemoine
2d50a35850 the API user does not know about UnreferencedBounds, and remove getResForZoom and getMaxRes from the map API 2012-06-22 12:34:15 +02:00
Éric Lemoine
1d114b4630 two test pages, one for api, one for ol 2012-06-22 12:17:57 +02:00
Marc Jansen
f6a728b074 Do not loose URL-parameters passed to jasmine. 2012-06-22 12:14:35 +02:00
Tom Payne
3e15ce93bb Use ol.base.checkKeys to check keys 2012-06-22 11:58:03 +02:00
Tom Payne
afd6369da7 Add ol.base.checkKeys 2012-06-22 11:56:45 +02:00
Tom Payne
fd4c776181 Create new ol.base and include ol.error 2012-06-22 11:56:45 +02:00
Éric Lemoine
a0e5741774 [ol.layer.TileLayer, ol.layer.XYZ] add a getMaxResolution func to TileLayer, and make ol.layer.XYZ be just a projection and a number of zoom levels 2012-06-22 11:52:40 +02:00
Mike Adair
89b3019cde return correct map overlay elem 2012-06-22 05:50:14 -04:00
Petr Pridal
1fcdffacc1 Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-22 11:45:50 +02:00
Petr Pridal
fa9507ab79 Removing Makefile. Use 'bin/ol' for starting plovr. 2012-06-22 11:45:01 +02:00
ahocevar
deb84cf212 Removing unused code. 2012-06-22 11:42:17 +02:00
ahocevar
fbcca9642c Use renderTo instead of el as method/option name. 2012-06-22 11:17:27 +02:00
Éric Lemoine
86a3eaad19 [ol.layer.TileLayer] move getData from layer.XYZ to layer.TileLayer 2012-06-22 11:09:08 +02:00
Tom Payne
0b06267afe Trigger redraws on tile loads. 2012-06-22 11:02:44 +02:00
Éric Lemoine
cb37aaa01b map.test.js - fix the map is destroyable test in advanced mode 2012-06-22 10:59:57 +02:00
Éric Lemoine
ad2c3e15e3 [ol.Tile] as an isLoading method 2012-06-22 10:51:59 +02:00
Petr Pridal
f25b3aa350 Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-22 10:48:58 +02:00
Petr Pridal
5439d63e89 Hello world for various modes of compilation. 2012-06-22 10:44:34 +02:00
Éric Lemoine
0cf1a830d9 [ol.layer.XYZ] no need to call setResolutions 2012-06-22 10:41:06 +02:00
Éric Lemoine
7c36d2f42f [ol.layer.XYZ] does not require ol.Tile 2012-06-22 10:40:25 +02:00
Éric Lemoine
9d21d6f20f [ol.TileLayer] no setTileSize method anymore 2012-06-22 10:39:53 +02:00
Éric Lemoine
f7a956f404 [ol.Tile] add ol.Tile.createConstructor and set width and height to the img archetype 2012-06-22 10:38:40 +02:00
Marc Jansen
67ce7afe67 Export the Collection constructor. 2012-06-22 09:45:05 +02:00
Marc Jansen
bed71db109 Export the LineString constructor. 2012-06-22 09:44:21 +02:00
Marc Jansen
9a533aeb7d Export the MultiPoint constructor. 2012-06-22 09:41:37 +02:00
Marc Jansen
3a40925a7d API point fixed (using ADVANCED compilation) 2012-06-22 09:36:58 +02:00
Marc Jansen
45917504b0 Fix the geom tests to only use API methods. 2012-06-22 09:18:12 +02:00
Petr Pridal
8ace8aee78 Added missing goog.require() 2012-06-22 01:43:09 +02:00
Petr Pridal
e10a845058 Advanced compilation of the API with 'bin/ol api' 2012-06-22 01:32:29 +02:00
Éric Lemoine
9529db0151 throw an error if ol.map gets passed an unknown option 2012-06-21 20:16:11 +02:00
Éric Lemoine
7e8c418155 fix ol.error 2012-06-21 20:16:11 +02:00
Tim Schaub
c67ca2660d Partial tile layer renderer. 2012-06-21 19:59:43 +02:00
Tim Schaub
948e792ddd Bounds transforms. 2012-06-21 19:59:43 +02:00
Tim Schaub
6198df9381 Location transform in api. 2012-06-21 19:59:43 +02:00
Tim Schaub
ba7b54949c Bounds spec. 2012-06-21 19:59:43 +02:00
Tom Payne
7f7528baf9 Add GeoJSON externs. 2012-06-21 19:47:12 +02:00
ahocevar
4776b11658 Now the map also has overlay divs. 2012-06-21 19:40:04 +02:00
Éric Lemoine
5388657791 [ol.Tile] a tile can be loaded only once 2012-06-21 19:37:16 +02:00
ahocevar
ed62cc00a7 Fixing typos. 2012-06-21 19:36:11 +02:00
ahocevar
188615391d Using a map for controls also. 2012-06-21 19:33:33 +02:00
ahocevar
9bd507e9b8 Adding a map of sequence providers 2012-06-21 19:27:18 +02:00
Éric Lemoine
6c76f4621e [ol.Tile] add a isLoaded function 2012-06-21 19:10:28 +02:00
Tom Payne
79f5339573 Add simple ol.error function 2012-06-21 19:01:27 +02:00
Éric Lemoine
98495cafc3 [ol.Tile] an image is a HTMLImageElement 2012-06-21 19:00:09 +02:00
Éric Lemoine
1c7e0f8481 add an ol.TileCache and use it in ol.TileLayer 2012-06-21 19:00:09 +02:00
ahocevar
a06de64f37 Minimal demo. 2012-06-21 18:57:07 +02:00
ahocevar
e9e5fd27dc The map now has a viewport and can render to a container. 2012-06-21 18:56:48 +02:00
Marc Jansen
8f90db58dc MultiPoints shall only contain points. 2012-06-21 18:23:37 +02:00
Marc Jansen
340caf2720 Collections cannot contain Collections.
By having both the constructor and the setComponents checking
a white- and a blacklist for allowed types, we ensure that no
Collections can be added through these methods to the list of
components.
2012-06-21 18:23:37 +02:00
ahocevar
8d8819ec3c Removing unused file and code. 2012-06-21 17:30:23 +02:00
Tim Schaub
7c17374231 Bounds has projection or null. 2012-06-21 17:28:47 +02:00
ahocevar
81a55eb320 Finally fixing event sequences. 2012-06-21 17:26:23 +02:00
Tim Schaub
0a1f8cddd8 Intersects method for bounds. 2012-06-21 17:12:05 +02:00
Petr Pridal
08ad8c80d6 Rename MapRenderer attribut 'target' to 'container' to follow the new conventions. 2012-06-21 17:01:21 +02:00
Tom Payne
8448aba616 Add initial WebGL renderer skeleton 2012-06-21 16:39:47 +02:00
Éric Lemoine
435557b425 [ol.Tile] trigger load and error events 2012-06-21 16:10:52 +02:00
Éric Lemoine
79b0bb74c8 [ol.Tile] add comments for handleImageLoad and handleImageError 2012-06-21 16:10:51 +02:00
Éric Lemoine
e72ab5135c [ol.Tile] register to image error 2012-06-21 16:10:51 +02:00
Éric Lemoine
1dc6b04ac1 [ol.Tile] register to image load 2012-06-21 16:10:51 +02:00
Marc Jansen
ce49bb8876 Add LineString/linestring.
The inhertance of this class might change in the future.
2012-06-21 16:00:08 +02:00
Marc Jansen
745ae25b6b Change the inhertance of MultiPoint/multipoint. 2012-06-21 16:00:08 +02:00
Marc Jansen
0374d1abc7 Add geom.Collection & geom.collection.
Also make MultiPoint and multipoint inherit from Collection/collection
respectively.
2012-06-21 16:00:08 +02:00
Petr Pridal
6ca9112af2 WebGL MapRenderer inicializaiton with a test (it may fail on computers without WebGL). 2012-06-21 15:51:00 +02:00
Éric Lemoine
1cca6b4069 add numZoomLevels and maxResolution properties to the TileLayer 2012-06-21 14:18:52 +02:00
ahocevar
5b747cf7fd Temporarily removing Drag sequence. 2012-06-21 14:14:36 +02:00
ahocevar
6213e07f96 Navigation control with Drag sequence Dragger
This is totally unfinished, but tests pass, and it is only meant to give the map a Navigation control.
2012-06-21 14:08:50 +02:00
Petr Pridal
8fc1e9cc98 More complete constructor of the WebGL MapRenderer. 2012-06-21 13:53:10 +02:00
Tim Schaub
2741a22cf1 Add animate to draw. 2012-06-21 13:31:23 +02:00
Tim Schaub
a6f464e473 New name for element.
You are provided a container.  To this container you can append elements, and you are responsible for removing elements that you add.  You cannot move or otherwise alter anything about this container.
2012-06-21 13:28:29 +02:00
Éric Lemoine
5f1e53a0c9 move properties from layer/XYZ to layer/TileLayer 2012-06-21 12:42:36 +02:00
Tim Schaub
5da8fc8d49 Allow map renderers access to target. 2012-06-21 12:26:51 +02:00
Petr Pridal
56456ec878 Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-21 12:24:26 +02:00
Petr Pridal
638d00b759 First css styles in /css/ol.css 2012-06-21 12:23:37 +02:00
Tim Schaub
661f07d80a Only check src for js. 2012-06-21 12:23:14 +02:00
Marc Jansen
f85d6402e9 Add MultiPoint and multipoint. 2012-06-21 12:19:42 +02:00
Petr Pridal
cff7ee5db8 WebGL MapRender - initial not finished version. 2012-06-21 12:02:21 +02:00
Tim Schaub
45f734d77e Base for map renderer. 2012-06-21 11:40:51 +02:00
Tim Schaub
9cc501caba Composite renderer requires an element. 2012-06-21 11:30:53 +02:00
Mike Adair
f3ab95b051 change feature obj literal property names to match GeoJSON 2012-06-21 03:31:57 -04:00
Éric Lemoine
22bffd9d8b add an OSM layer constructor to the API 2012-06-21 08:46:23 +02:00
Éric Lemoine
b91769f00b [ol.layer.XYZ] less than 8 chars lines 2012-06-21 08:38:38 +02:00
Tim Schaub
43c8b89460 Initial pass at tiled layer renderer. 2012-06-21 01:18:57 +02:00
Tim Schaub
fe0e242a39 Initial composite map renderer. 2012-06-21 01:17:34 +02:00
Tim Schaub
ae242de94a Ignoring jsdoc output. 2012-06-21 01:16:37 +02:00
Tim Schaub
4baf760b7e Layer for demo. 2012-06-21 01:15:54 +02:00
Tim Schaub
be54add905 Width and height on unreferenced bounds. 2012-06-21 00:50:26 +02:00
Tim Schaub
5287677489 Additional tileset getters. 2012-06-21 00:42:28 +02:00
Tim Schaub
d8b31ab1ff Class name on archetype image. 2012-06-21 00:33:31 +02:00
Tim Schaub
57764813e3 Constructing tiles with bounds. 2012-06-20 23:38:15 +02:00
Tim Schaub
f9813616e5 Giving a tile bounds. 2012-06-20 23:38:15 +02:00
Tim Schaub
c9c1f79928 Layer hierarchy for renderers. 2012-06-20 23:38:14 +02:00
ahocevar
5a31638da8 Updating name. 2012-06-20 23:21:58 +02:00
ahocevar
6ddda53a70 Initial port of Control.js and Navigation.js.
This also adds an Events instance to the map, so the Navigation control can register events on the map.

Tests still missing.
2012-06-20 23:21:44 +02:00
Mike Adair
4ea2fe3701 adding features 2012-06-20 13:33:20 -04:00
Tom Payne
d5f9f9e8a4 Use inheritance. 2012-06-20 19:17:59 +02:00
ahocevar
a36972fd35 Exporting the API. 2012-06-20 19:07:11 +02:00
ahocevar
74d1a06177 No need for cross browser handling here. 2012-06-20 19:07:11 +02:00
Tim Schaub
a4a6bc4db4 Typo in PointLike def. 2012-06-20 18:49:40 +02:00
Petr Pridal
6f4975883f Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-20 18:43:49 +02:00
Petr Pridal
1c25a53876 Allow ?mode=ADVANCED on the test/index.html and make the output easier to debug. 2012-06-20 18:42:56 +02:00
Tim Schaub
32d5397301 Dot notation for unquoted property. 2012-06-20 18:42:43 +02:00
Petr Pridal
453d2e9c08 Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-20 18:38:34 +02:00
Petr Pridal
5ed80bcf6c Adding @export tags to functions missing it - for advanced compilation. 2012-06-20 18:37:56 +02:00
ahocevar
c4c595862f Support for event sequences, and a drag sequence.
Tests still missing.
2012-06-20 18:35:42 +02:00
ahocevar
05e13e86a3 Adding drag sequence. Tests still missing. 2012-06-20 18:32:27 +02:00
Éric Lemoine
7413770a46 add an ol.layer.xyz factory 2012-06-20 18:09:10 +02:00
Marc Jansen
958e291545 Quoting properties for external use.
See also 1ac40021bb.
2012-06-20 17:57:27 +02:00
Petr Pridal
e3b20ddf8b Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-20 17:47:28 +02:00
Petr Pridal
6922be1b02 Missing @export tags for advanced compilation 2012-06-20 17:46:36 +02:00
Marc Jansen
a9d280a317 Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-20 17:45:00 +02:00
Marc Jansen
94fe46c5be Remove stray ')' 2012-06-20 17:43:54 +02:00
Tim Schaub
1ac40021bb Quoting properties for external use. 2012-06-20 17:43:46 +02:00
Éric Lemoine
025547d199 [ol.Layer.XYZ] minor changes in code comments 2012-06-20 17:43:24 +02:00
Marc Jansen
eb690951ab Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-20 16:52:33 +02:00
Marc Jansen
b49c036ae2 Make the testuite configurable via URL. 2012-06-20 16:49:51 +02:00
Éric Lemoine
7bf05964b8 [ol.layer.XYZ] more tiling fixes, and additional tests 2012-06-20 16:18:01 +02:00
Tim Schaub
5eeb21c125 Disallow nowhere. 2012-06-20 16:11:41 +02:00
ahocevar
f74d265dec Verified isSingleTouch and isMultiTouch functions. 2012-06-20 16:02:41 +02:00
ahocevar
66a5a8ad7a countFn not needed - do everything with logFn. 2012-06-20 15:53:01 +02:00
ahocevar
8c4b528ded Better cleanup. 2012-06-20 15:52:24 +02:00
ahocevar
80f76a91e1 Always provide a proper event object. 2012-06-20 15:52:08 +02:00
ahocevar
733f1478dc Merge branch 'master' of github.com:openlayers/ol3 2012-06-20 15:50:56 +02:00
Éric Lemoine
d4ebe97ab1 [test/index.html] remove the mode=RAW script tag again, it does not work anymore 2012-06-20 15:50:31 +02:00
Marc Jansen
edc2773147 Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-20 15:42:43 +02:00
Marc Jansen
6b8cd1216f Easier getter/setter for geom.point. 2012-06-20 15:42:10 +02:00
ahocevar
2fa71057b1 Finalizing tests for ol.Events 2012-06-20 15:26:02 +02:00
Éric Lemoine
2890a55ee7 [ol.layer.XYZ] a tiling fix 2012-06-20 15:13:22 +02:00
Éric Lemoine
e989c61e63 make the tests run in Closure RAW mode, but leave the SIMPLE mode script tag to still catch compilation errors/warnings while running tests 2012-06-20 15:11:20 +02:00
Mike Adair
e61769c6dc put back to SIMPLE mode 2012-06-20 09:04:51 -04:00
Mike Adair
45c03c29ba Merge branch 'master' of github.com:openlayers/ol3 2012-06-20 09:02:51 -04:00
Mike Adair
aa584e17e9 center returned in user projection 2012-06-20 09:02:20 -04:00
Marc Jansen
0ccbb8e6d0 Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-20 14:59:18 +02:00
Marc Jansen
d933404df8 Make Points transformable. 2012-06-20 14:58:37 +02:00
Tim Schaub
09a6b6c456 Changing expectations for projection. 2012-06-20 14:52:29 +02:00
Mike Adair
a6b93773cd Merge branch 'master' of github.com:openlayers/ol3 2012-06-20 08:42:11 -04:00
Mike Adair
00e25d3a62 fix warnings 2012-06-20 08:41:47 -04:00
Mike Adair
99b397bffc implement getMaxRes, getMaxExtent, getResForZoom 2012-06-20 08:29:43 -04:00
Marc Jansen
33c2e0aa30 Correct the tests for geom.Point and geom.point.
Add tests for the API version `ol.point()`; adjust the tests for the internal
`new ol.Point()`.
2012-06-20 13:36:07 +02:00
Marc Jansen
cdcf3ef5a4 remove the coordinate mixin. 2012-06-20 12:06:55 +02:00
Éric Lemoine
a4a90b18b7 [ol.layer.XYZ] zoomForResolution is no longer private 2012-06-20 12:04:07 +02:00
Tim Schaub
14b1a34f98 Splitting tests between api and internal. 2012-06-20 11:56:20 +02:00
Éric Lemoine
a7a86bb169 add a Jasmine toBeA matcher 2012-06-20 11:44:43 +02:00
Petr Pridal
02840ad573 Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-20 11:40:25 +02:00
Petr Pridal
638a3b104e Turn on WARNING for compilation on visibility and other compiler options. 2012-06-20 11:39:28 +02:00
Petr Pridal
e0d444551c Fixing visibility (@private/@protected) annotationto introduce compiler warnings for that. 2012-06-20 11:35:58 +02:00
Marc Jansen
ac2a0bbccd Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-20 11:30:43 +02:00
Marc Jansen
85f0f43b7b Saving state prior to spec moving. 2012-06-20 11:30:06 +02:00
ahocevar
b63e13d09c More Events tests. 2012-06-20 11:29:07 +02:00
ahocevar
4854eee97c Getting rid of debugger statement. 2012-06-20 11:26:33 +02:00
ahocevar
25d4ef17fd Fixing types and getting rid of evt.touches warning. 2012-06-20 11:23:48 +02:00
Éric Lemoine
e995ffea89 more "setters should not return this" changes + warning fixes 2012-06-20 11:21:29 +02:00
Éric Lemoine
27305925ff run fromdos on ol/Map.js 2012-06-20 11:21:29 +02:00
Éric Lemoine
487e61884e EPI setters no longer return this 2012-06-20 11:21:29 +02:00
Marc Jansen
41df32df9a Merge branch 'master' of https://github.com/openlayers/ol3 2012-06-20 11:19:48 +02:00
Marc Jansen
aec8f953e5 Remove the mixin approach and give the Point class a projection. 2012-06-20 11:18:07 +02:00
Marc Jansen
073c636cb2 Removed interfaces package and introduced coord package. 2012-06-20 11:17:13 +02:00
Mike Adair
c657bdeeb6 remove debugger line 2012-06-20 05:00:48 -04:00
Mike Adair
a9a2e7cf8f remove debugger line 2012-06-20 04:58:30 -04:00
Mike Adair
4161595c85 extent and res tests 2012-06-20 04:37:16 -04:00
Mike Adair
2c7e308960 adding getMaxExtent and getMaxRes 2012-06-20 04:37:14 -04:00
Éric Lemoine
4fcc00e39c move ol.Projection code and units methods to the api dir 2012-06-20 10:28:54 +02:00
ahocevar
dfc35282ff Fixing API docs 2012-06-20 09:59:19 +02:00
Éric Lemoine
a96b559ddd very first XYZ layer bits 2012-06-20 09:18:46 +02:00
Éric Lemoine
5f557e6c6c the TileSet constructor takes 4 args 2012-06-20 09:17:55 +02:00
Éric Lemoine
8d74113897 the Tile constructor now takes a url as the first arg 2012-06-20 09:17:55 +02:00
Éric Lemoine
84d594cacb Tile.test.js - remove test that sets a src on the image 2012-06-20 09:17:55 +02:00
ahocevar
fb8b1e878d Events.js ported, with tests stub. More tests to be added. 2012-06-20 01:09:21 +02:00
Tim Schaub
54b8ebacaf OS neutral dev tools. 2012-06-20 00:41:28 +02:00
Tim Schaub
b06a52888f Adding unreferenced bounds. 2012-06-20 00:11:06 +02:00
Marc Jansen
450f8f7b74 First state of a geom package. 2012-06-19 18:21:21 +02:00
Tim Schaub
712070c1f0 Location tests passing. 2012-06-19 18:06:00 +02:00
Tim Schaub
408413ec92 Projection cannot be null. 2012-06-19 17:41:17 +02:00
Mike Adair
6ed79a3d36 add layers and resolutions array 2012-06-19 11:17:55 -04:00
Mike Adair
28955dc0b1 Merge branch 'three' of https://github.com/tschaub/openlayers into three 2012-06-19 10:18:21 -04:00
Mike Adair
b0490ecdb6 initial set of tests running 2012-06-19 10:17:41 -04:00
Petr Pridal
8dde795baa Merge branch 'three' of https://github.com/tschaub/openlayers into three 2012-06-19 16:13:39 +02:00
Petr Pridal
fd14df352b JSDoc documentation generator with plovr by "make jsdoc" 2012-06-19 16:13:00 +02:00
Tim Schaub
d69d56aab2 Avoiding warnings. 2012-06-19 15:54:13 +02:00
Tim Schaub
6f3b47709a No projection warnings. 2012-06-19 15:43:50 +02:00
Mike Adair
efcecc4c5f map initialization 2012-06-19 09:37:42 -04:00
Tim Schaub
4588d794d8 Keep compiling. 2012-06-19 15:23:36 +02:00
Mike Adair
b25339549a Merge branch 'three' of https://github.com/tschaub/openlayers into three 2012-06-19 09:21:48 -04:00
Éric Lemoine
1c8abd38a6 add a basic TileSet class 2012-06-19 15:18:34 +02:00
Mike Adair
171c8522b3 intialization of Map again 2012-06-19 09:16:56 -04:00
Mike Adair
322cf702ed Merge branch 'three' of https://github.com/tschaub/openlayers into three 2012-06-19 09:04:25 -04:00
Mike Adair
d990be61af Merge branch 'three' of https://github.com/tschaub/openlayers into three
Conflicts:
	src/api/loc.js
	src/api/map.js
	src/ol/Map.js
2012-06-19 09:04:04 -04:00
Éric Lemoine
79af86bde5 minor doc string additions to ol.Tile 2012-06-19 15:01:57 +02:00
Éric Lemoine
ce20ba066c add an ol.Tile class 2012-06-19 14:52:25 +02:00
Tim Schaub
1043a53fe1 Use simple compilation. 2012-06-19 14:49:56 +02:00
Mike Adair
82f204f30c map get/set methods 2012-06-19 08:06:08 -04:00
Tom Payne
116c26422e Loc fixes. 2012-06-19 13:09:31 +02:00
Tom Payne
7358529c4e Map fixes. 2012-06-19 13:09:31 +02:00
Tom Payne
f435bb1874 Bounds fixes. 2012-06-19 13:00:24 +02:00
Mike Adair
818ca7016a interim map test updates 2012-06-19 06:53:59 -04:00
Tom Payne
94e6146b8a Remove dead code. 2012-06-19 12:44:06 +02:00
Tom Payne
7958e02bd0 Add map user projection getter and setter. 2012-06-19 12:43:54 +02:00
Tom Payne
ef83910c3d Make more Loc tests pass. 2012-06-19 12:33:59 +02:00
Tom Payne
95fe8762da Rename Location to Loc for consistency. 2012-06-19 12:01:22 +02:00
Tom Payne
da7449454e Pass bounds spec. 2012-06-19 11:56:48 +02:00
Tim Schaub
77c07a500e A passing test. 2012-06-19 11:14:53 +02:00
Marc Jansen
b1e26fab1d change indentation. 2012-06-19 10:56:01 +02:00
Marc Jansen
a6fa08550f change indentation. 2012-06-19 10:51:16 +02:00
Marc Jansen
c04ae35498 change indentation. 2012-06-19 10:49:44 +02:00
Tim Schaub
90f33c587a Debugged. 2012-06-19 10:39:42 +02:00
Tim Schaub
738561e417 Exporting the map. 2012-06-19 10:29:03 +02:00
Tim Schaub
8572ae35cf Phony task 2012-06-19 10:28:51 +02:00
Tim Schaub
01e22e098c Ignoring plovr. 2012-06-19 09:47:27 +02:00
Tim Schaub
56c6d69999 File shuffle. 2012-06-19 09:46:19 +02:00
Tim Schaub
bd6b52c2cd File shuffle. 2012-06-19 09:45:08 +02:00
Tim Schaub
f24b518f61 Small fixes. 2012-06-19 09:43:20 +02:00
Tim Schaub
e84a0473d5 Removing additional main.json. 2012-06-19 09:25:25 +02:00
Petr Pridal
0a354d3923 Merge branch 'three' of https://github.com/tschaub/openlayers into three 2012-06-19 09:21:30 +02:00
Tom Payne
d4a9b9859c Fix setters. 2012-06-19 09:21:04 +02:00
Petr Pridal
7e8c41b2ab Merge branch 'three' of https://github.com/tschaub/openlayers into three 2012-06-19 09:20:51 +02:00
Petr Pridal
7109bd3868 Plovr demo 2012-06-19 09:19:59 +02:00
Tom Payne
986f152e61 Remove broken code. 2012-06-19 09:18:56 +02:00
Tom Payne
613b90c7f3 Add broken code for testing. 2012-06-18 18:40:00 +02:00
Tim Schaub
b9d690044f Adding test spec. 2012-06-18 18:15:51 +02:00
1785 changed files with 95730 additions and 225575 deletions

8
.gitignore vendored
View File

@@ -1,7 +1,5 @@
/build/OpenLayers.js
/tools/closure-compiler.jar
/tools/*.pyc
/apidoc_config/Data/
/doc/apidocs/
*.pyc
/build
/examples/*.html.png
/examples/example-list.js
/examples/example-list.xml

12
.travis.yml Normal file
View File

@@ -0,0 +1,12 @@
before_install:
- "sudo pip install http://closure-linter.googlecode.com/files/closure_linter-latest.tar.gz"
- "git clone --depth=50 https://github.com/jsdoc3/jsdoc build/jsdoc"
- "git clone https://code.google.com/p/glsl-unit/ build/glsl-unit"
before_script:
- "./build.py plovr"
- "./build.py serve-integration-test &"
- "rm src/ol/renderer/webgl/*shader.js"
- "sleep 3"
script: "./build.py JSDOC=build/jsdoc/jsdoc integration-test"

57
AUTHORS.md Normal file
View File

@@ -0,0 +1,57 @@
OpenLayers contributors:
* Antoine Abt
* Mike Adair
* Jeff Adams
* Seb Benthall
* Bruno Binet
* Stéphane Brunner
* Howard Butler
* Bertil Chaupis
* John Cole
* Tim Coulter
* Robert Coup
* Jeff Dege
* Roald de Wit
* Schuyler Erle
* Christian López Espínola
* John Frank
* Sean Gilles
* Pierre Giraud
* Ivan Grcic
* Andreas Hocevar
* Marc Jansen
* Ian Johnson
* Frédéric Junod
* Eric Lemoine
* Philip Lindsay
* Martijn van Oosterhout
* David Overstrom
* Tom Payne
* Corey Puffault
* Peter William Robins
* Gregers Rygg
* Tim Schaub
* Christopher Schmidt
* Cameron Shorter
* Pedro Simonetti
* Paul Spencer
* Paul Smith
* Glen Stampoultzis
* James Stembridge
* Erik Uzureau
* Bart van den Eijnden
* Ivan Willig
* Thomas Wood
* Bill Woodall
* Steve Woodbridge
* David Zwarg
Some portions of OpenLayers are used under the Apache 2.0 license, available
in doc/licenses/APACHE-2.0.txt.
Some portions of OpenLayers are used under the MIT license, availabie in
doc/licenses/MIT-LICENSE.txt.
Some portions of OpenLayers are Copyright 2001 Robert Penner, and are used
under the BSD license, available in doc/licenses/BSD-LICENSE.txt

21
CONTRIBUTING.md Normal file
View File

@@ -0,0 +1,21 @@
# Contributing to OpenLayers 3
Thanks for your interest in contributing to OpenLayers 3.
## Contributing Code
Our preferred means of receiving contributions is through [pull
requests](https://help.github.com/articles/using-pull-requests).
See the [Developer
Guide](https://github.com/openlayers/ol3/wiki/Developer-Guide) to get started
with OpenLayers 3 development. This guide provides information you should know
before creating pull requests.
Note that, before accepting a contribution, we ask that you provide us
a Contributor License Agreement. If you are making your contribution as part of
work for your employer, please follow the guidelines on submitting a [Corporate
Contributor License Agreement](http://www.openlayers.org/ccla.txt). If you are
making your contribution as an individual, you can submit a digital [Individual
Contributor License
Agreement](https://docs.google.com/spreadsheet/viewform?formkey=dGNNVUJEMXF2dERTU0FXM3JjNVBQblE6MQ).

View File

@@ -1,13 +1,13 @@
Copyright 2005-2013 OpenLayers Contributors. All rights reserved. See
authors.txt for full list.
AUTHORS.md for full list.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation and/or
other materials provided with the distribution.

9
README.md Normal file
View File

@@ -0,0 +1,9 @@
# OpenLayers 3
[![Travis CI Status](https://secure.travis-ci.org/openlayers/ol3.png)](http://travis-ci.org/#!/openlayers/ol3)
Welcome to [OpenLayers 3](http://ol3js.org/)!
Check out the [hosted examples](http://ol3js.org/en/master/examples/) or poke around the evolving [API docs](http://ol3js.org/en/master/apidoc/).
Please see our guide on [contributing](CONTRIBUTING.md) if you're interested in getting involved.

View File

@@ -1,113 +0,0 @@
Format: 1.52
# This is the Natural Docs languages file for this project. If you change
# anything here, it will apply to THIS PROJECT ONLY. If you'd like to change
# something for all your projects, edit the Languages.txt in Natural Docs'
# Config directory instead.
# You can prevent certain file extensions from being scanned like this:
# Ignore Extensions: [extension] [extension] ...
#-------------------------------------------------------------------------------
# SYNTAX:
#
# Unlike other Natural Docs configuration files, in this file all comments
# MUST be alone on a line. Some languages deal with the # character, so you
# cannot put comments on the same line as content.
#
# Also, all lists are separated with spaces, not commas, again because some
# languages may need to use them.
#
# Language: [name]
# Alter Language: [name]
# Defines a new language or alters an existing one. Its name can use any
# characters. If any of the properties below have an add/replace form, you
# must use that when using Alter Language.
#
# The language Shebang Script is special. It's entry is only used for
# extensions, and files with those extensions have their shebang (#!) lines
# read to determine the real language of the file. Extensionless files are
# always treated this way.
#
# The language Text File is also special. It's treated as one big comment
# so you can put Natural Docs content in them without special symbols. Also,
# if you don't specify a package separator, ignored prefixes, or enum value
# behavior, it will copy those settings from the language that is used most
# in the source tree.
#
# Extensions: [extension] [extension] ...
# [Add/Replace] Extensions: [extension] [extension] ...
# Defines the file extensions of the language's source files. You can
# redefine extensions found in the main languages file. You can use * to
# mean any undefined extension.
#
# Shebang Strings: [string] [string] ...
# [Add/Replace] Shebang Strings: [string] [string] ...
# Defines a list of strings that can appear in the shebang (#!) line to
# designate that it's part of the language. You can redefine strings found
# in the main languages file.
#
# Ignore Prefixes in Index: [prefix] [prefix] ...
# [Add/Replace] Ignored Prefixes in Index: [prefix] [prefix] ...
#
# Ignore [Topic Type] Prefixes in Index: [prefix] [prefix] ...
# [Add/Replace] Ignored [Topic Type] Prefixes in Index: [prefix] [prefix] ...
# Specifies prefixes that should be ignored when sorting symbols in an
# index. Can be specified in general or for a specific topic type.
#
#------------------------------------------------------------------------------
# For basic language support only:
#
# Line Comments: [symbol] [symbol] ...
# Defines a space-separated list of symbols that are used for line comments,
# if any.
#
# Block Comments: [opening sym] [closing sym] [opening sym] [closing sym] ...
# Defines a space-separated list of symbol pairs that are used for block
# comments, if any.
#
# Package Separator: [symbol]
# Defines the default package separator symbol. The default is a dot.
#
# [Topic Type] Prototype Enders: [symbol] [symbol] ...
# When defined, Natural Docs will attempt to get a prototype from the code
# immediately following the topic type. It stops when it reaches one of
# these symbols. Use \n for line breaks.
#
# Line Extender: [symbol]
# Defines the symbol that allows a prototype to span multiple lines if
# normally a line break would end it.
#
# Enum Values: [global|under type|under parent]
# Defines how enum values are referenced. The default is global.
# global - Values are always global, referenced as 'value'.
# under type - Values are under the enum type, referenced as
# 'package.enum.value'.
# under parent - Values are under the enum's parent, referenced as
# 'package.value'.
#
# Perl Package: [perl package]
# Specifies the Perl package used to fine-tune the language behavior in ways
# too complex to do in this file.
#
#------------------------------------------------------------------------------
# For full language support only:
#
# Full Language Support: [perl package]
# Specifies the Perl package that has the parsing routines necessary for full
# language support.
#
#-------------------------------------------------------------------------------
# The following languages are defined in the main file, if you'd like to alter
# them:
#
# Text File, Shebang Script, C/C++, C#, Java, JavaScript, Perl, Python,
# PHP, SQL, Visual Basic, Pascal, Assembly, Ada, Tcl, Ruby, Makefile,
# ActionScript, ColdFusion, R, Fortran
# If you add a language that you think would be useful to other developers
# and should be included in Natural Docs by default, please e-mail it to
# languages [at] naturaldocs [dot] org.

View File

@@ -1,472 +0,0 @@
Format: 1.52
Title: OpenLayers
SubTitle: JavaScript Mapping Library
# You can add a footer to your documentation like this:
# Footer: [text]
# If you want to add a copyright notice, this would be the place to do it.
# You can add a timestamp to your documentation like one of these:
# Timestamp: Generated on month day, year
# Timestamp: Updated mm/dd/yyyy
# Timestamp: Last updated mon day
#
# m - One or two digit month. January is "1"
# mm - Always two digit month. January is "01"
# mon - Short month word. January is "Jan"
# month - Long month word. January is "January"
# d - One or two digit day. 1 is "1"
# dd - Always two digit day. 1 is "01"
# day - Day with letter extension. 1 is "1st"
# yy - Two digit year. 2006 is "06"
# yyyy - Four digit year. 2006 is "2006"
# year - Four digit year. 2006 is "2006"
# --------------------------------------------------------------------------
#
# Cut and paste the lines below to change the order in which your files
# appear on the menu. Don't worry about adding or removing files, Natural
# Docs will take care of that.
#
# You can further organize the menu by grouping the entries. Add a
# "Group: [name] {" line to start a group, and add a "}" to end it.
#
# You can add text and web links to the menu by adding "Text: [text]" and
# "Link: [name] ([URL])" lines, respectively.
#
# The formatting and comments are auto-generated, so don't worry about
# neatness when editing the file. Natural Docs will clean it up the next
# time it is run. When working with groups, just deal with the braces and
# forget about the indentation and comments.
#
# --------------------------------------------------------------------------
Group: OpenLayers {
File: OpenLayers (no auto-title, OpenLayers.js)
Group: BaseTypes {
File: Base Types (no auto-title, OpenLayers/BaseTypes.js)
File: Bounds (no auto-title, OpenLayers/BaseTypes/Bounds.js)
File: Class (no auto-title, OpenLayers/BaseTypes/Class.js)
File: Date (no auto-title, OpenLayers/BaseTypes/Date.js)
File: Element (no auto-title, OpenLayers/BaseTypes/Element.js)
File: LonLat (no auto-title, OpenLayers/BaseTypes/LonLat.js)
File: Pixel (no auto-title, OpenLayers/BaseTypes/Pixel.js)
File: Size (no auto-title, OpenLayers/BaseTypes/Size.js)
} # Group: BaseTypes
File: Console (no auto-title, OpenLayers/Console.js)
Group: Control {
File: Control (no auto-title, OpenLayers/Control.js)
File: ArgParser (no auto-title, OpenLayers/Control/ArgParser.js)
File: Attribution (no auto-title, OpenLayers/Control/Attribution.js)
File: Button (no auto-title, OpenLayers/Control/Button.js)
File: DragFeature (no auto-title, OpenLayers/Control/DragFeature.js)
File: DragPan (no auto-title, OpenLayers/Control/DragPan.js)
File: DrawFeature (no auto-title, OpenLayers/Control/DrawFeature.js)
File: EditingToolbar (no auto-title, OpenLayers/Control/EditingToolbar.js)
File: Geolocate (no auto-title, OpenLayers/Control/Geolocate.js)
File: GetFeature (no auto-title, OpenLayers/Control/GetFeature.js)
File: Graticule (no auto-title, OpenLayers/Control/Graticule.js)
File: KeyboardDefaults (no auto-title, OpenLayers/Control/KeyboardDefaults.js)
File: LayerSwitcher (no auto-title, OpenLayers/Control/LayerSwitcher.js)
File: Measure (no auto-title, OpenLayers/Control/Measure.js)
File: ModifyFeature (no auto-title, OpenLayers/Control/ModifyFeature.js)
File: MousePosition (no auto-title, OpenLayers/Control/MousePosition.js)
File: Navigation (no auto-title, OpenLayers/Control/Navigation.js)
File: NavigationHistory (no auto-title, OpenLayers/Control/NavigationHistory.js)
File: NavToolbar (no auto-title, OpenLayers/Control/NavToolbar.js)
File: OverviewMap (no auto-title, OpenLayers/Control/OverviewMap.js)
File: Pan (no auto-title, OpenLayers/Control/Pan.js)
File: Panel (no auto-title, OpenLayers/Control/Panel.js)
File: PanPanel (no auto-title, OpenLayers/Control/PanPanel.js)
File: PanZoom (no auto-title, OpenLayers/Control/PanZoom.js)
File: PanZoomBar (no auto-title, OpenLayers/Control/PanZoomBar.js)
File: Permalink (no auto-title, OpenLayers/Control/Permalink.js)
File: PinchZoom (no auto-title, OpenLayers/Control/PinchZoom.js)
File: Scale (no auto-title, OpenLayers/Control/Scale.js)
File: ScaleLine (no auto-title, OpenLayers/Control/ScaleLine.js)
File: SelectFeature (no auto-title, OpenLayers/Control/SelectFeature.js)
File: SLDSelect (no auto-title, OpenLayers/Control/SLDSelect.js)
File: Snapping (no auto-title, OpenLayers/Control/Snapping.js)
File: Split (no auto-title, OpenLayers/Control/Split.js)
File: TouchNavigation (no auto-title, OpenLayers/Control/TouchNavigation.js)
File: TransformFeature (no auto-title, OpenLayers/Control/TransformFeature.js)
File: WMSGetFeatureInfo (no auto-title, OpenLayers/Control/WMSGetFeatureInfo.js)
File: WMTSGetFeatureInfo (no auto-title, OpenLayers/Control/WMTSGetFeatureInfo.js)
File: ZoomBox (no auto-title, OpenLayers/Control/ZoomBox.js)
File: ZoomIn (no auto-title, OpenLayers/Control/ZoomIn.js)
File: ZoomOut (no auto-title, OpenLayers/Control/ZoomOut.js)
File: ZoomPanel (no auto-title, OpenLayers/Control/ZoomPanel.js)
File: ZoomToMaxExtent (no auto-title, OpenLayers/Control/ZoomToMaxExtent.js)
} # Group: Control
File: Events (no auto-title, OpenLayers/Events.js)
Group: Feature {
File: Feature (no auto-title, OpenLayers/Feature.js)
File: Vector (no auto-title, OpenLayers/Feature/Vector.js)
} # Group: Feature
Group: Filter {
File: Filter (no auto-title, OpenLayers/Filter.js)
File: Comparison (no auto-title, OpenLayers/Filter/Comparison.js)
File: FeatureId (no auto-title, OpenLayers/Filter/FeatureId.js)
File: Function (no auto-title, OpenLayers/Filter/Function.js)
File: Logical (no auto-title, OpenLayers/Filter/Logical.js)
File: Spatial (no auto-title, OpenLayers/Filter/Spatial.js)
} # Group: Filter
Group: Format {
File: Format (no auto-title, OpenLayers/Format.js)
File: ArcXML (no auto-title, OpenLayers/Format/ArcXML.js)
File: ArcXML.Features (no auto-title, OpenLayers/Format/ArcXML/Features.js)
File: Atom (no auto-title, OpenLayers/Format/Atom.js)
File: Context (no auto-title, OpenLayers/Format/Context.js)
File: CQL (no auto-title, OpenLayers/Format/CQL.js)
File: CSWGetDomain (no auto-title, OpenLayers/Format/CSWGetDomain.js)
File: CSWGetDomain.v2_0_2 (no auto-title, OpenLayers/Format/CSWGetDomain/v2_0_2.js)
File: CSWGetRecords (no auto-title, OpenLayers/Format/CSWGetRecords.js)
File: CSWGetRecords.v2_0_2 (no auto-title, OpenLayers/Format/CSWGetRecords/v2_0_2.js)
Group: Filter {
File: Filter (no auto-title, OpenLayers/Format/Filter.js)
File: v1 (no auto-title, OpenLayers/Format/Filter/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/Filter/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/Filter/v1_1_0.js)
} # Group: Filter
Group: GML {
File: GML (no auto-title, OpenLayers/Format/GML.js)
File: Base (no auto-title, OpenLayers/Format/GML/Base.js)
File: v2 (no auto-title, OpenLayers/Format/GML/v2.js)
File: v3 (no auto-title, OpenLayers/Format/GML/v3.js)
} # Group: GML
Group: SLD {
File: SLD (no auto-title, OpenLayers/Format/SLD.js)
File: v1 (no auto-title, OpenLayers/Format/SLD/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/SLD/v1_0_0.js)
} # Group: SLD
File: GeoJSON (no auto-title, OpenLayers/Format/GeoJSON.js)
File: GeoRSS (no auto-title, OpenLayers/Format/GeoRSS.js)
File: GPX (no auto-title, OpenLayers/Format/GPX.js)
File: JSON (no auto-title, OpenLayers/Format/JSON.js)
File: KML (no auto-title, OpenLayers/Format/KML.js)
File: OGCExceptionReport (no auto-title, OpenLayers/Format/OGCExceptionReport.js)
File: OSM (no auto-title, OpenLayers/Format/OSM.js)
Group: OWSCommon {
File: OWSCommon (no auto-title, OpenLayers/Format/OWSCommon.js)
File: v1 (no auto-title, OpenLayers/Format/OWSCommon/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/OWSCommon/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/OWSCommon/v1_1_0.js)
} # Group: OWSCommon
File: OWSContext (no auto-title, OpenLayers/Format/OWSContext.js)
File: OWSContext.v0_3_1 (no auto-title, OpenLayers/Format/OWSContext/v0_3_1.js)
File: QueryStringFilter (no auto-title, OpenLayers/Format/QueryStringFilter.js)
File: SOSCapabilities (no auto-title, OpenLayers/Format/SOSCapabilities.js)
File: SOSCapabilities.v1_0_0 (no auto-title, OpenLayers/Format/SOSCapabilities/v1_0_0.js)
File: SOSGetFeatureOfInterest (no auto-title, OpenLayers/Format/SOSGetFeatureOfInterest.js)
File: SOSGetObservation (no auto-title, OpenLayers/Format/SOSGetObservation.js)
File: Text (no auto-title, OpenLayers/Format/Text.js)
File: VersionedOGC (OpenLayers/Format/XML/VersionedOGC.js)
File: WCSGetCoverage version 1.1.0 (no auto-title, OpenLayers/Format/WCSGetCoverage.js)
File: WFS (no auto-title, OpenLayers/Format/WFS.js)
Group: WFSCapabilities {
File: WFSCapabilities (no auto-title, OpenLayers/Format/WFSCapabilities.js)
File: v1 (no auto-title, OpenLayers/Format/WFSCapabilities/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/WFSCapabilities/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/WFSCapabilities/v1_1_0.js)
} # Group: WFSCapabilities
Group: WFST {
File: WFST (no auto-title, OpenLayers/Format/WFST.js)
File: v1 (no auto-title, OpenLayers/Format/WFST/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/WFST/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/WFST/v1_1_0.js)
} # Group: WFST
Group: WMC {
File: WMC (no auto-title, OpenLayers/Format/WMC.js)
File: v1 (no auto-title, OpenLayers/Format/WMC/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/WMC/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/WMC/v1_1_0.js)
} # Group: WMC
Group: WMSCapabilities {
File: WMSCapabilities (no auto-title, OpenLayers/Format/WMSCapabilities.js)
File: v1 (no auto-title, OpenLayers/Format/WMSCapabilities/v1.js)
File: v1_1 (no auto-title, OpenLayers/Format/WMSCapabilities/v1_1.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/WMSCapabilities/v1_1_0.js)
File: v1_1_1 (no auto-title, OpenLayers/Format/WMSCapabilities/v1_1_1.js)
File: v1_3 (no auto-title, OpenLayers/Format/WMSCapabilities/v1_3.js)
File: v1_3_0 (no auto-title, OpenLayers/Format/WMSCapabilities/v1_3_0.js)
File: WMSCapabilities/v1_1_1_WMSC (no auto-title, OpenLayers/Format/WMSCapabilities/v1_1_1_WMSC.js)
} # Group: WMSCapabilities
Group: WMSDescribeLayer {
File: WMSDescribeLayer (no auto-title, OpenLayers/Format/WMSDescribeLayer.js)
File: v1_1 (no auto-title, OpenLayers/Format/WMSDescribeLayer/v1_1.js)
} # Group: WMSDescribeLayer
File: WFSDescribeFeatureType (no auto-title, OpenLayers/Format/WFSDescribeFeatureType.js)
File: WKT (no auto-title, OpenLayers/Format/WKT.js)
File: WMSGetFeatureInfo (no auto-title, OpenLayers/Format/WMSGetFeatureInfo.js)
File: WMTSCapabilities (no auto-title, OpenLayers/Format/WMTSCapabilities.js)
File: WMTSCapabilities.v1_0_0 (no auto-title, OpenLayers/Format/WMTSCapabilities/v1_0_0.js)
File: WPSCapabilities (no auto-title, OpenLayers/Format/WPSCapabilities.js)
File: WPSCapabilities.v1_0_0 (no auto-title, OpenLayers/Format/WPSCapabilities/v1_0_0.js)
File: WPSDescribeProcess (no auto-title, OpenLayers/Format/WPSDescribeProcess.js)
File: WPSExecute version 1.0.0 (no auto-title, OpenLayers/Format/WPSExecute.js)
File: XLS (no auto-title, OpenLayers/Format/XLS.js)
File: XLS.v1 (no auto-title, OpenLayers/Format/XLS/v1.js)
File: XLS.v1_1_0 (no auto-title, OpenLayers/Format/XLS/v1_1_0.js)
File: XML (no auto-title, OpenLayers/Format/XML.js)
} # Group: Format
Group: Geometry {
File: Geometry (no auto-title, OpenLayers/Geometry.js)
File: Collection (no auto-title, OpenLayers/Geometry/Collection.js)
File: Curve (no auto-title, OpenLayers/Geometry/Curve.js)
File: LinearRing (no auto-title, OpenLayers/Geometry/LinearRing.js)
File: LineString (no auto-title, OpenLayers/Geometry/LineString.js)
File: MultiLineString (no auto-title, OpenLayers/Geometry/MultiLineString.js)
File: MultiPoint (no auto-title, OpenLayers/Geometry/MultiPoint.js)
File: MultiPolygon (no auto-title, OpenLayers/Geometry/MultiPolygon.js)
File: Point (no auto-title, OpenLayers/Geometry/Point.js)
File: Polygon (no auto-title, OpenLayers/Geometry/Polygon.js)
} # Group: Geometry
Group: Handler {
File: Handler (no auto-title, OpenLayers/Handler.js)
File: Box (no auto-title, OpenLayers/Handler/Box.js)
File: Click (no auto-title, OpenLayers/Handler/Click.js)
File: Drag (no auto-title, OpenLayers/Handler/Drag.js)
File: Feature (no auto-title, OpenLayers/Handler/Feature.js)
File: Hover (no auto-title, OpenLayers/Handler/Hover.js)
File: Keyboard (no auto-title, OpenLayers/Handler/Keyboard.js)
File: MouseWheel (no auto-title, OpenLayers/Handler/MouseWheel.js)
File: Path (no auto-title, OpenLayers/Handler/Path.js)
File: Pinch (no auto-title, OpenLayers/Handler/Pinch.js)
File: Point (no auto-title, OpenLayers/Handler/Point.js)
File: Polygon (no auto-title, OpenLayers/Handler/Polygon.js)
File: RegularPolygon (no auto-title, OpenLayers/Handler/RegularPolygon.js)
} # Group: Handler
File: Icon (no auto-title, OpenLayers/Icon.js)
Group: Lang {
File: Lang (no auto-title, OpenLayers/Lang.js)
File: ar (no auto-title, OpenLayers/Lang/ar.js)
File: be-tarask (no auto-title, OpenLayers/Lang/be-tarask.js)
File: bg (no auto-title, OpenLayers/Lang/bg.js)
File: br (no auto-title, OpenLayers/Lang/br.js)
File: ca (no auto-title, OpenLayers/Lang/ca.js)
File: cs-CZ (no auto-title, OpenLayers/Lang/cs-CZ.js)
File: da-DK (no auto-title, OpenLayers/Lang/da-DK.js)
File: de (no auto-title, OpenLayers/Lang/de.js)
File: en (no auto-title, OpenLayers/Lang/en.js)
File: en-CA (no auto-title, OpenLayers/Lang/en-CA.js)
File: es (no auto-title, OpenLayers/Lang/es.js)
File: el (no auto-title, OpenLayers/Lang/el.js)
File: fi (no auto-title, OpenLayers/Lang/fi.js)
File: fr (no auto-title, OpenLayers/Lang/fr.js)
File: fur (no auto-title, OpenLayers/Lang/fur.js)
File: gl (no auto-title, OpenLayers/Lang/gl.js)
File: gsw (no auto-title, OpenLayers/Lang/gsw.js)
File: hr (no auto-title, OpenLayers/Lang/hr.js)
File: hsb (no auto-title, OpenLayers/Lang/hsb.js)
File: hu (no auto-title, OpenLayers/Lang/hu.js)
File: ia (no auto-title, OpenLayers/Lang/ia.js)
File: id (no auto-title, OpenLayers/Lang/id.js)
File: io (no auto-title, OpenLayers/Lang/io.js)
File: is (no auto-title, OpenLayers/Lang/is.js)
File: it (no auto-title, OpenLayers/Lang/it.js)
File: ja (no auto-title, OpenLayers/Lang/ja.js)
File: km (no auto-title, OpenLayers/Lang/km.js)
File: ksh (no auto-title, OpenLayers/Lang/ksh.js)
File: lt (no auto-title, OpenLayers/Lang/lt.js)
File: nds (no auto-title, OpenLayers/Lang/nds.js)
File: nb (no auto-title, OpenLayers/Lang/nb.js)
File: nl (no auto-title, OpenLayers/Lang/nl.js)
File: nn (no auto-title, OpenLayers/Lang/nn.js)
File: oc (no auto-title, OpenLayers/Lang/oc.js)
File: pt (no auto-title, OpenLayers/Lang/pt.js)
File: pl (no auto-title, OpenLayers/Lang/pl.js)
File: pt-BR (no auto-title, OpenLayers/Lang/pt-BR.js)
File: ru (no auto-title, OpenLayers/Lang/ru.js)
File: sk (no auto-title, OpenLayers/Lang/sk.js)
File: sv-SE (no auto-title, OpenLayers/Lang/sv-SE.js)
File: te (no auto-title, OpenLayers/Lang/te.js)
File: vi (no auto-title, OpenLayers/Lang/vi.js)
File: zh-CN (no auto-title, OpenLayers/Lang/zh-CN.js)
File: zh-TW (no auto-title, OpenLayers/Lang/zh-TW.js)
} # Group: Lang
Group: Layer {
File: Layer (no auto-title, OpenLayers/Layer.js)
File: ArcGISCache.js (no auto-title, OpenLayers/Layer/ArcGISCache.js)
File: ArcGIS93Rest (no auto-title, OpenLayers/Layer/ArcGIS93Rest.js)
File: ArcIMS (no auto-title, OpenLayers/Layer/ArcIMS.js)
File: Bing (no auto-title, OpenLayers/Layer/Bing.js)
File: Boxes (no auto-title, OpenLayers/Layer/Boxes.js)
File: EventPane (no auto-title, OpenLayers/Layer/EventPane.js)
File: FixedZoomLevels (no auto-title, OpenLayers/Layer/FixedZoomLevels.js)
File: GeoRSS (no auto-title, OpenLayers/Layer/GeoRSS.js)
File: Google (no auto-title, OpenLayers/Layer/Google.js)
File: Google.v3 (no auto-title, OpenLayers/Layer/Google/v3.js)
File: Grid (no auto-title, OpenLayers/Layer/Grid.js)
File: HTTPRequest (no auto-title, OpenLayers/Layer/HTTPRequest.js)
File: Image (no auto-title, OpenLayers/Layer/Image.js)
File: KaMap (no auto-title, OpenLayers/Layer/KaMap.js)
File: KaMapCache (no auto-title, OpenLayers/Layer/KaMapCache.js)
File: MapGuide (no auto-title, OpenLayers/Layer/MapGuide.js)
File: MapServer (no auto-title, OpenLayers/Layer/MapServer.js)
File: Markers (no auto-title, OpenLayers/Layer/Markers.js)
File: OSM (no auto-title, OpenLayers/Layer/OSM.js)
File: PointGrid (no auto-title, OpenLayers/Layer/PointGrid.js)
File: PointTrack (no auto-title, OpenLayers/Layer/PointTrack.js)
File: SphericalMercator (no auto-title, OpenLayers/Layer/SphericalMercator.js)
File: Text (no auto-title, OpenLayers/Layer/Text.js)
File: TileCache (no auto-title, OpenLayers/Layer/TileCache.js)
File: TMS (no auto-title, OpenLayers/Layer/TMS.js)
File: Vector (no auto-title, OpenLayers/Layer/Vector.js)
File: Vector.RootContainer (no auto-title, OpenLayers/Layer/Vector/RootContainer.js)
File: WMS (no auto-title, OpenLayers/Layer/WMS.js)
File: WMTS (no auto-title, OpenLayers/Layer/WMTS.js)
File: WorldWind (no auto-title, OpenLayers/Layer/WorldWind.js)
File: XYZ (no auto-title, OpenLayers/Layer/XYZ.js)
File: Zoomify (no auto-title, OpenLayers/Layer/Zoomify.js)
} # Group: Layer
File: Map (no auto-title, OpenLayers/Map.js)
Group: Marker {
File: Marker (no auto-title, OpenLayers/Marker.js)
File: Box (no auto-title, OpenLayers/Marker/Box.js)
} # Group: Marker
Group: Popup {
File: Popup (no auto-title, OpenLayers/Popup.js)
File: Anchored (no auto-title, OpenLayers/Popup/Anchored.js)
File: Framed (no auto-title, OpenLayers/Popup/Framed.js)
File: FramedCloud (no auto-title, OpenLayers/Popup/FramedCloud.js)
} # Group: Popup
File: Projection (no auto-title, OpenLayers/Projection.js)
Group: Protocol {
File: Protocol (no auto-title, OpenLayers/Protocol.js)
File: HTTP (no auto-title, OpenLayers/Protocol/HTTP.js)
Group: WFS {
File: WFS (no auto-title, OpenLayers/Protocol/WFS.js)
File: v1 (no auto-title, OpenLayers/Protocol/WFS/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Protocol/WFS/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Protocol/WFS/v1_1_0.js)
} # Group: WFS
File: Script (no auto-title, OpenLayers/Protocol/Script.js)
File: SOS.DEFAULTS (no auto-title, OpenLayers/Protocol/SOS.js)
File: SOS.v1_0_0 (no auto-title, OpenLayers/Protocol/SOS/v1_0_0.js)
} # Group: Protocol
Group: Renderer {
File: Renderer (no auto-title, OpenLayers/Renderer.js)
File: Canvas (no auto-title, OpenLayers/Renderer/Canvas.js)
File: ElementsIndexer (no auto-title, OpenLayers/Renderer/Elements.js)
File: SVG (no auto-title, OpenLayers/Renderer/SVG.js)
File: VML (no auto-title, OpenLayers/Renderer/VML.js)
} # Group: Renderer
Group: Request {
File: Request (no auto-title, OpenLayers/Request.js)
File: XMLHttpRequest (no auto-title, OpenLayers/Request/XMLHttpRequest.js)
} # Group: Request
File: Rule (no auto-title, OpenLayers/Rule.js)
File: SingleFile.js (no auto-title, OpenLayers/SingleFile.js)
Group: Strategy {
File: Strategy (no auto-title, OpenLayers/Strategy.js)
File: BBOX (no auto-title, OpenLayers/Strategy/BBOX.js)
File: Cluster (no auto-title, OpenLayers/Strategy/Cluster.js)
File: Filter (no auto-title, OpenLayers/Strategy/Filter.js)
File: Fixed (no auto-title, OpenLayers/Strategy/Fixed.js)
File: Paging (no auto-title, OpenLayers/Strategy/Paging.js)
File: Refresh (no auto-title, OpenLayers/Strategy/Refresh.js)
File: Save (no auto-title, OpenLayers/Strategy/Save.js)
} # Group: Strategy
File: Style (no auto-title, OpenLayers/Style.js)
File: Style2 (no auto-title, OpenLayers/Style2.js)
File: StyleMap (no auto-title, OpenLayers/StyleMap.js)
Group: Symbolizer {
File: Symbolizer (no auto-title, OpenLayers/Symbolizer.js)
File: Line (no auto-title, OpenLayers/Symbolizer/Line.js)
File: Point (no auto-title, OpenLayers/Symbolizer/Point.js)
File: Polygon (no auto-title, OpenLayers/Symbolizer/Polygon.js)
File: Raster (no auto-title, OpenLayers/Symbolizer/Raster.js)
File: Text (no auto-title, OpenLayers/Symbolizer/Text.js)
} # Group: Symbolizer
Group: Tile {
File: Tile (no auto-title, OpenLayers/Tile.js)
File: Image (no auto-title, OpenLayers/Tile/Image.js)
File: Image.IFrame (no auto-title, OpenLayers/Tile/Image/IFrame.js)
} # Group: Tile
File: Tween (no auto-title, OpenLayers/Tween.js)
File: Util (no auto-title, OpenLayers/Util.js)
File: Deprecated (no auto-title, deprecated.js)
} # Group: OpenLayers
Group: Index {
Index: Everything
Class Index: Classes
Constant Index: Constants
Function Index: Functions
Property Index: Properties
File Index: Files
Constructor Index: Constructor
} # Group: Index

View File

@@ -1,20 +0,0 @@
p {
text-indent: 0; margin-bottom: 1em;
}
.MGroup {
font-variant: normal;
margin: 0.4em 0 0em 10px
}
.MTitle {
font-variant: normal;
}
.CGroup .CTitle {
font-variant: normal;
}
.SGroup .SEntry {
font-variant: normal;
}

View File

@@ -1,105 +0,0 @@
Format: 1.52
# This is the Natural Docs topics file for this project. If you change anything
# here, it will apply to THIS PROJECT ONLY. If you'd like to change something
# for all your projects, edit the Topics.txt in Natural Docs' Config directory
# instead.
Ignore Keywords:
function, functions
func, funcs
procedure, procedures
proc, procs
routine, routines
subroutine, subroutines
sub, subs
method, methods
callback, callbacks
property, properties
prop, props
#-------------------------------------------------------------------------------
# SYNTAX:
#
# Topic Type: [name]
# Alter Topic Type: [name]
# Creates a new topic type or alters one from the main file. Each type gets
# its own index and behavior settings. Its name can have letters, numbers,
# spaces, and these charaters: - / . '
#
# Plural: [name]
# Sets the plural name of the topic type, if different.
#
# Keywords:
# [keyword]
# [keyword], [plural keyword]
# ...
# Defines or adds to the list of keywords for the topic type. They may only
# contain letters, numbers, and spaces and are not case sensitive. Plural
# keywords are used for list topics. You can redefine keywords found in the
# main topics file.
#
# Index: [yes|no]
# Whether the topics get their own index. Defaults to yes. Everything is
# included in the general index regardless of this setting.
#
# Scope: [normal|start|end|always global]
# How the topics affects scope. Defaults to normal.
# normal - Topics stay within the current scope.
# start - Topics start a new scope for all the topics beneath it,
# like class topics.
# end - Topics reset the scope back to global for all the topics
# beneath it.
# always global - Topics are defined as global, but do not change the scope
# for any other topics.
#
# Class Hierarchy: [yes|no]
# Whether the topics are part of the class hierarchy. Defaults to no.
#
# Page Title If First: [yes|no]
# Whether the topic's title becomes the page title if it's the first one in
# a file. Defaults to no.
#
# Break Lists: [yes|no]
# Whether list topics should be broken into individual topics in the output.
# Defaults to no.
#
# Can Group With: [type], [type], ...
# Defines a list of topic types that this one can possibly be grouped with.
# Defaults to none.
#-------------------------------------------------------------------------------
# The following topics are defined in the main file, if you'd like to alter
# their behavior or add keywords:
#
# Generic, Class, Interface, Section, File, Group, Function, Variable,
# Property, Type, Constant, Enumeration, Event, Delegate, Macro,
# Database, Database Table, Database View, Database Index, Database
# Cursor, Database Trigger, Cookie, Build Target
# If you add something that you think would be useful to other developers
# and should be included in Natural Docs by default, please e-mail it to
# topics [at] naturaldocs [dot] org.
Topic Type: Constructor
Class Hierarchy: Yes
Keywords:
constructor
initialize
Alter Topic Type: Function
Add Keywords:
apimethod
apifunction
Alter Topic Type: Property
Add Keywords:
apiproperty

View File

@@ -1,127 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://web.resource.org/cc/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="18.000000px"
height="18.000000px"
id="svg2"
sodipodi:version="0.32"
inkscape:version="0.42"
sodipodi:docbase="/Users/phil/Documents/work/metacarta/2svn.openlayers.net/follower/code/b-edits-1/openlayers/assets/ui_elements"
sodipodi:docname="pan_icons.svg"
inkscape:export-filename="/Users/phil/Documents/work/metacarta/2svn.openlayers.net/follower/code/b-edits-1/openlayers/assets/ui_elements/zoom-minus-mini.png"
inkscape:export-xdpi="90.000000"
inkscape:export-ydpi="90.000000">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="1.0000000"
inkscape:cx="9.0000000"
inkscape:cy="9.0000000"
inkscape:document-units="px"
inkscape:current-layer="layer1"
inkscape:window-width="1226"
inkscape:window-height="800"
inkscape:window-x="42"
inkscape:window-y="22" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="background"
inkscape:groupmode="layer"
id="layer1">
<g
id="g2110">
<path
transform="matrix(0.000000,-1.003160,1.003160,0.000000,-2.844000e-2,18.02844)"
d="M 17.971654 9.0000000 A 8.9716539 8.9716539 0 1 1 0.028346062,9.0000000 A 8.9716539 8.9716539 0 1 1 17.971654 9.0000000 z"
sodipodi:ry="8.9716539"
sodipodi:rx="8.9716539"
sodipodi:cy="9.0000000"
sodipodi:cx="9.0000000"
id="path2059"
style="fill:#00008b;fill-opacity:1.0000000;stroke:none;stroke-width:39.984146;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-dasharray:none;stroke-opacity:1.0000000"
sodipodi:type="arc" />
<rect
transform="matrix(0.000000,-1.000000,1.000000,0.000000,0.000000,0.000000)"
y="4.3599998e-06"
x="-9.0000048"
height="18.000000"
width="9.0000000"
id="rect2061"
style="fill:#00008b;fill-opacity:1.0000000;stroke:none;stroke-width:39.984146;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-dasharray:none;stroke-opacity:1.0000000" />
</g>
</g>
<g
inkscape:groupmode="layer"
id="layer4"
inkscape:label="zoom"
style="display:inline">
<text
xml:space="preserve"
style="font-size:18.000000px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125.00000%;writing-mode:lr-tb;text-anchor:start;fill:#ffffff;fill-opacity:1.0000000;stroke:#ffffff;stroke-width:1.0000000px;stroke-linecap:butt;stroke-linejoin:round;stroke-opacity:1.0000000;font-family:Helvetica"
x="3.7485352"
y="-3.4077148"
id="text2114"
sodipodi:linespacing="125.00000%"
transform="scale(1.000000,-1.000000)"><tspan
sodipodi:role="line"
id="tspan2118"
x="3.7485352"
y="-3.4077148"></tspan></text>
</g>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="overlay"
style="display:none">
<path
style="font-size:12.000000px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125.00000%;writing-mode:lr-tb;text-anchor:start;fill:#ffffff;fill-opacity:1.0000000;stroke:none;stroke-width:1.0000000px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1.0000000;font-family:Verdana"
d="M 2.9678210,9.0332227 C 2.9678314,9.5015070 3.1752531,9.8938504 3.5900866,10.210254 C 3.6463464,10.254553 3.9451742,10.453889 4.4865710,10.808262 L 8.1568835,13.247754 C 8.2693886,13.323691 8.4240759,13.393300 8.6209460,13.456582 C 8.8107943,13.519862 9.0041535,13.551503 9.2010240,13.551504 C 9.5736843,13.551503 9.8936056,13.431269 10.160789,13.190801 C 10.427980,12.950332 10.561574,12.659238 10.561572,12.317520 C 10.561574,11.861896 10.322511,11.488536 9.8443836,11.197442 L 8.5998522,10.428575 L 14.548408,10.428575 C 15.026535,10.428577 15.406221,10.298849 15.687470,10.039395 C 15.968721,9.7799443 16.109345,9.4318977 16.109345,8.9952540 C 16.109345,8.5396330 15.961690,8.1915865 15.666377,7.9511133 C 15.364034,7.7106494 14.980831,7.5904152 14.516767,7.5904102 L 8.6314928,7.5904102 L 9.9920390,6.7076368 C 10.160793,6.5937365 10.290871,6.4481897 10.382274,6.2709962 C 10.466652,6.0874870 10.508840,5.8913153 10.508837,5.6824805 C 10.508840,5.3281127 10.378761,5.0338552 10.118602,4.7997070 C 9.8584498,4.5655745 9.5279814,4.4485043 9.1271961,4.4484962 C 8.7615757,4.4485043 8.4029823,4.5624104 8.0514147,4.7902149 L 3.9697741,7.5239649 C 3.6393151,7.7454540 3.4002529,7.9542820 3.2525866,8.1504493 C 3.0627532,8.3972503 2.9678314,8.6756875 2.9678210,8.9857618 L 2.9678210,9.0332227"
id="text2082"
sodipodi:nodetypes="csccsssscccssscccssssccscc" />
</g>
<g
inkscape:groupmode="layer"
id="layer3"
inkscape:label="pan triangle"
style="display:none">
<path
sodipodi:type="star"
style="fill:#ffffff;fill-opacity:1.0000000;stroke:none;stroke-width:39.984146;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-dasharray:none;stroke-opacity:1.0000000"
id="path2107"
sodipodi:sides="3"
sodipodi:cx="6.8031497"
sodipodi:cy="5.1874018"
sodipodi:r1="5.0880113"
sodipodi:r2="2.5440056"
sodipodi:arg1="1.0471976"
sodipodi:arg2="2.0943951"
inkscape:flatsided="false"
inkscape:rounded="0.0000000"
inkscape:randomized="0.0000000"
d="M 9.3471551,9.5937489 L 5.5311469,7.3905753 L 1.7151384,5.1874015 L 5.5311469,2.9842283 L 9.3471555,0.78105489 L 9.3471553,5.1874018 L 9.3471551,9.5937489 z "
transform="matrix(0.000000,-1.331000,1.331000,0.000000,2.038879,16.92102)" />
</g>
</svg>

Before

Width:  |  Height:  |  Size: 6.3 KiB

View File

@@ -1,128 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://web.resource.org/cc/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="18.000000px"
height="18.000000px"
id="svg2"
sodipodi:version="0.32"
inkscape:version="0.43"
sodipodi:docbase="/home/sderle/projects/openlayers/layerswitcher/art"
sodipodi:docname="layer-switcher-maximize.svg"
inkscape:export-filename="/Users/phil/Documents/work/metacarta/2svn.openlayers.net/follower/code/b-edits-1/openlayers/assets/ui_elements/zoom-minus-mini.png"
inkscape:export-xdpi="90.000000"
inkscape:export-ydpi="90.000000">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="16"
inkscape:cx="9"
inkscape:cy="9"
inkscape:document-units="px"
inkscape:current-layer="layer4"
inkscape:window-width="1226"
inkscape:window-height="800"
inkscape:window-x="42"
inkscape:window-y="25" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="background"
inkscape:groupmode="layer"
id="layer1">
<g
id="g2110"
transform="matrix(-7.849624e-17,1,-1,-7.849624e-17,18,0)">
<path
transform="matrix(0,-1.00316,1.00316,0,-2.844e-2,18.02844)"
d="M 17.971654 9 A 8.9716539 8.9716539 0 1 1 0.028346062,9 A 8.9716539 8.9716539 0 1 1 17.971654 9 z"
sodipodi:ry="8.9716539"
sodipodi:rx="8.9716539"
sodipodi:cy="9"
sodipodi:cx="9"
id="path2059"
style="fill:#00008b;fill-opacity:1;stroke:none;stroke-width:39.98414612;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
sodipodi:type="arc" />
<rect
transform="matrix(0,-1,1,0,0,0)"
y="4.3599998e-06"
x="-9.0000048"
height="18"
width="9"
id="rect2061"
style="fill:#00008b;fill-opacity:1;stroke:none;stroke-width:39.98414612;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
</g>
</g>
<g
inkscape:groupmode="layer"
id="layer4"
inkscape:label="zoom"
style="display:inline">
<text
xml:space="preserve"
style="font-size:18px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#ffffff;fill-opacity:1;stroke:#ffffff;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:round;stroke-opacity:1;display:inline;font-family:Helvetica"
x="1.5214844"
y="-3.2949219"
id="text2114"
sodipodi:linespacing="125%"
transform="scale(1,-1)"><tspan
sodipodi:role="line"
id="tspan2118"
x="1.5214844"
y="-3.2949219">+</tspan></text>
</g>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="overlay"
style="display:none">
<path
style="font-size:12.000000px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125.00000%;writing-mode:lr-tb;text-anchor:start;fill:#ffffff;fill-opacity:1.0000000;stroke:none;stroke-width:1.0000000px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1.0000000;font-family:Verdana"
d="M 2.9678210,9.0332227 C 2.9678314,9.5015070 3.1752531,9.8938504 3.5900866,10.210254 C 3.6463464,10.254553 3.9451742,10.453889 4.4865710,10.808262 L 8.1568835,13.247754 C 8.2693886,13.323691 8.4240759,13.393300 8.6209460,13.456582 C 8.8107943,13.519862 9.0041535,13.551503 9.2010240,13.551504 C 9.5736843,13.551503 9.8936056,13.431269 10.160789,13.190801 C 10.427980,12.950332 10.561574,12.659238 10.561572,12.317520 C 10.561574,11.861896 10.322511,11.488536 9.8443836,11.197442 L 8.5998522,10.428575 L 14.548408,10.428575 C 15.026535,10.428577 15.406221,10.298849 15.687470,10.039395 C 15.968721,9.7799443 16.109345,9.4318977 16.109345,8.9952540 C 16.109345,8.5396330 15.961690,8.1915865 15.666377,7.9511133 C 15.364034,7.7106494 14.980831,7.5904152 14.516767,7.5904102 L 8.6314928,7.5904102 L 9.9920390,6.7076368 C 10.160793,6.5937365 10.290871,6.4481897 10.382274,6.2709962 C 10.466652,6.0874870 10.508840,5.8913153 10.508837,5.6824805 C 10.508840,5.3281127 10.378761,5.0338552 10.118602,4.7997070 C 9.8584498,4.5655745 9.5279814,4.4485043 9.1271961,4.4484962 C 8.7615757,4.4485043 8.4029823,4.5624104 8.0514147,4.7902149 L 3.9697741,7.5239649 C 3.6393151,7.7454540 3.4002529,7.9542820 3.2525866,8.1504493 C 3.0627532,8.3972503 2.9678314,8.6756875 2.9678210,8.9857618 L 2.9678210,9.0332227"
id="text2082"
sodipodi:nodetypes="csccsssscccssscccssssccscc" />
</g>
<g
inkscape:groupmode="layer"
id="layer3"
inkscape:label="pan triangle"
style="display:none">
<path
sodipodi:type="star"
style="fill:#ffffff;fill-opacity:1.0000000;stroke:none;stroke-width:39.984146;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-dasharray:none;stroke-opacity:1.0000000"
id="path2107"
sodipodi:sides="3"
sodipodi:cx="6.8031497"
sodipodi:cy="5.1874018"
sodipodi:r1="5.0880113"
sodipodi:r2="2.5440056"
sodipodi:arg1="1.0471976"
sodipodi:arg2="2.0943951"
inkscape:flatsided="false"
inkscape:rounded="0.0000000"
inkscape:randomized="0.0000000"
d="M 9.3471551,9.5937489 L 5.5311469,7.3905753 L 1.7151384,5.1874015 L 5.5311469,2.9842283 L 9.3471555,0.78105489 L 9.3471553,5.1874018 L 9.3471551,9.5937489 z "
transform="matrix(0.000000,-1.331000,1.331000,0.000000,2.038879,16.92102)" />
</g>
</svg>

Before

Width:  |  Height:  |  Size: 6.1 KiB

View File

@@ -1,142 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://web.resource.org/cc/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
inkscape:export-ydpi="90.000000"
inkscape:export-xdpi="90.000000"
inkscape:export-filename="/home/sderle/projects/openlayers/layerswitcher/img/layer-switcher-minimize.png"
sodipodi:docname="layer-switcher-minimize.svg"
sodipodi:docbase="/home/sderle/projects/openlayers/layerswitcher/art"
inkscape:version="0.43"
sodipodi:version="0.32"
id="svg2"
height="18.000000px"
width="18.000000px">
<defs
id="defs4" />
<sodipodi:namedview
inkscape:window-y="26"
inkscape:window-x="42"
inkscape:window-height="800"
inkscape:window-width="1226"
inkscape:current-layer="layer1"
inkscape:document-units="px"
inkscape:cy="9.3025513"
inkscape:cx="9"
inkscape:zoom="16"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
borderopacity="1.0"
bordercolor="#666666"
pagecolor="#ffffff"
id="base" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<g
style="display:inline"
id="layer1"
inkscape:groupmode="layer"
inkscape:label="background">
<rect
style="fill:#00008b;fill-opacity:0;stroke:none;stroke-width:39.984146;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
id="rect2061"
width="18.014498"
height="18.000000"
x="-18.014502"
y="4.3599998e-06"
transform="matrix(0.000000,-1.000000,1.000000,0.000000,0.000000,0.000000)"
inkscape:export-xdpi="90"
inkscape:export-ydpi="90"
inkscape:export-filename="/home/sderle/projects/openlayers/layerswitcher/art/layer-switcher-minimize.png" />
</g>
<g
inkscape:label="graticule"
id="layer5"
inkscape:groupmode="layer">
<text
xml:space="preserve"
style="font-size:18px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;writing-mode:lr-tb;text-anchor:start;fill:#ffffff;fill-opacity:1;stroke:#ffffff;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:round;stroke-opacity:1;display:inline;font-family:Helvetica"
x="5.2802601"
y="-3.8032362"
id="text1432"
sodipodi:linespacing="125%"
transform="scale(1,-1)"><tspan
sodipodi:role="line"
id="tspan1434"
x="5.2802601"
y="-3.8032362">-</tspan></text>
<rect
style="fill:none;fill-opacity:0.75;fill-rule:evenodd;stroke:#ffffff;stroke-width:0.99699599px;stroke-linecap:butt;stroke-linejoin:round;stroke-opacity:1"
id="rect1438"
width="13.003004"
height="13.002999"
x="2.498498"
y="2.4984975" />
</g>
<g
style="display:none"
inkscape:label="zoom"
id="layer4"
inkscape:groupmode="layer">
<text
transform="scale(1.000000,-1.000000)"
sodipodi:linespacing="125.00000%"
id="text2114"
y="-3.4077148"
x="3.7485352"
style="font-size:18.000000;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;fill:#ffffff;fill-opacity:1.0000000;stroke:#ffffff;stroke-width:1.0000000px;stroke-linecap:butt;stroke-linejoin:round;stroke-opacity:1.0000000;font-family:Helvetica;text-anchor:start;writing-mode:lr-tb"
xml:space="preserve"><tspan
y="-3.4077148"
x="3.7485352"
id="tspan2118"
sodipodi:role="line"></tspan></text>
</g>
<g
style="display:none"
inkscape:label="overlay"
id="layer2"
inkscape:groupmode="layer">
<path
sodipodi:nodetypes="csccsssscccssscccssssccscc"
id="text2082"
d="M 2.9678210,9.0332227 C 2.9678314,9.5015070 3.1752531,9.8938504 3.5900866,10.210254 C 3.6463464,10.254553 3.9451742,10.453889 4.4865710,10.808262 L 8.1568835,13.247754 C 8.2693886,13.323691 8.4240759,13.393300 8.6209460,13.456582 C 8.8107943,13.519862 9.0041535,13.551503 9.2010240,13.551504 C 9.5736843,13.551503 9.8936056,13.431269 10.160789,13.190801 C 10.427980,12.950332 10.561574,12.659238 10.561572,12.317520 C 10.561574,11.861896 10.322511,11.488536 9.8443836,11.197442 L 8.5998522,10.428575 L 14.548408,10.428575 C 15.026535,10.428577 15.406221,10.298849 15.687470,10.039395 C 15.968721,9.7799443 16.109345,9.4318977 16.109345,8.9952540 C 16.109345,8.5396330 15.961690,8.1915865 15.666377,7.9511133 C 15.364034,7.7106494 14.980831,7.5904152 14.516767,7.5904102 L 8.6314928,7.5904102 L 9.9920390,6.7076368 C 10.160793,6.5937365 10.290871,6.4481897 10.382274,6.2709962 C 10.466652,6.0874870 10.508840,5.8913153 10.508837,5.6824805 C 10.508840,5.3281127 10.378761,5.0338552 10.118602,4.7997070 C 9.8584498,4.5655745 9.5279814,4.4485043 9.1271961,4.4484962 C 8.7615757,4.4485043 8.4029823,4.5624104 8.0514147,4.7902149 L 3.9697741,7.5239649 C 3.6393151,7.7454540 3.4002529,7.9542820 3.2525866,8.1504493 C 3.0627532,8.3972503 2.9678314,8.6756875 2.9678210,8.9857618 L 2.9678210,9.0332227"
style="font-size:12.000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#ffffff;fill-opacity:1.0000000;stroke:none;stroke-width:1.0000000px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1.0000000;font-family:Verdana;text-anchor:start;writing-mode:lr-tb" />
</g>
<g
style="display:none"
inkscape:label="pan triangle"
id="layer3"
inkscape:groupmode="layer">
<path
transform="matrix(0.000000,-1.331000,1.331000,0.000000,2.038879,16.92102)"
d="M 9.3471551,9.5937489 L 5.5311469,7.3905753 L 1.7151384,5.1874015 L 5.5311469,2.9842283 L 9.3471555,0.78105489 L 9.3471553,5.1874018 L 9.3471551,9.5937489 z "
inkscape:randomized="0.0000000"
inkscape:rounded="0.0000000"
inkscape:flatsided="false"
sodipodi:arg2="2.0943951"
sodipodi:arg1="1.0471976"
sodipodi:r2="2.5440056"
sodipodi:r1="5.0880113"
sodipodi:cy="5.1874018"
sodipodi:cx="6.8031497"
sodipodi:sides="3"
id="path2107"
style="fill:#ffffff;fill-opacity:1.0000000;stroke:none;stroke-width:39.984146;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
sodipodi:type="star" />
</g>
</svg>

Before

Width:  |  Height:  |  Size: 6.6 KiB

View File

@@ -1,25 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 12.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 51448) -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [
<!ENTITY ns_ai "http://ns.adobe.com/AdobeIllustrator/10.0/">
<!ENTITY ns_svg "http://www.w3.org/2000/svg">
]>
<svg version="1.1" id="Layer_1" xmlns:i="&ns_ai;"
xmlns="&ns_svg;" width="20.5" height="24.5" viewBox="0 0 20.5 24.5"
overflow="visible" enable-background="new 0 0 20.5 24.5" xml:space="preserve">
<g i:extraneous="self">
<rect x="0.25" y="0.25" opacity="0" stroke="#000000" stroke-width="1" width="20" height="24"/>
<g id="XMLID_2_">
<g>
<polygon fill="#FF0000" points="10.12,0.6 19.93,7.71 10.06,24.03 0.6,7.58 "/>
</g>
<g>
<polyline fill="none" stroke="#000000" stroke-width="1" points="9.98,24.16 10.06,24.03 19.93,7.71 20.06,7.49 "/>
<polyline fill="none" stroke="#000000" stroke-width="1" points="10.13,24.16 10.06,24.03 0.6,7.58 0.5,7.41 "/>
<polyline fill="none" stroke="#000000" stroke-width="1" points="0.41,7.72 0.6,7.58 10.12,0.6 10.29,0.47 "/>
<polyline fill="none" stroke="#000000" stroke-width="1" points="9.94,0.47 10.12,0.6 19.93,7.71 20.06,7.8 "/>
</g>
</g>
<ellipse stroke="#000000" stroke-width="1" cx="10.125" cy="9.25" rx="1.5" ry="1.5"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 1.4 KiB

View File

@@ -1,36 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 12.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 51448) -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [
<!ENTITY ns_extend "http://ns.adobe.com/Extensibility/1.0/">
<!ENTITY ns_ai "http://ns.adobe.com/AdobeIllustrator/10.0/">
<!ENTITY ns_graphs "http://ns.adobe.com/Graphs/1.0/">
<!ENTITY ns_vars "http://ns.adobe.com/Variables/1.0/">
<!ENTITY ns_imrep "http://ns.adobe.com/ImageReplacement/1.0/">
<!ENTITY ns_sfw "http://ns.adobe.com/SaveForWeb/1.0/">
<!ENTITY ns_custom "http://ns.adobe.com/GenericCustomNamespace/1.0/">
<!ENTITY ns_adobe_xpath "http://ns.adobe.com/XPath/1.0/">
<!ENTITY ns_svg "http://www.w3.org/2000/svg">
<!ENTITY ns_xlink "http://www.w3.org/1999/xlink">
]>
<svg version="1.1" id="Layer_1" xmlns:x="&ns_extend;" xmlns:i="&ns_ai;" xmlns:graph="&ns_graphs;"
xmlns="&ns_svg;" xmlns:xlink="&ns_xlink;" width="28.375" height="28" viewBox="0 0 28.375 28"
overflow="visible" enable-background="new 0 0 28.375 28" xml:space="preserve">
<g i:extraneous="self">
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M27.875,1.375"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M0,1.375"/>
<path fill="none" stroke="#FFFFFF" d="M0,27.475"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M1,27.645"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M1,0.544"/>
<line fill="none" stroke="#00008B" x1="0.875" y1="27.5" x2="27.875" y2="27.475"/>
<rect x="0.875" y="1.045" fill="#00008B" width="27.125" height="26"/>
<line fill="none" stroke="#00008B" x1="27.875" y1="26.925" x2="27.875" y2="0.925"/>
<line fill="none" stroke="#FFFFFF" x1="1.375" y1="0.5" x2="27.375" y2="0.5"/>
<line fill="none" stroke="#FFFFFF" x1="0.875" y1="1" x2="0.875" y2="27"/>
<rect x="5.252" y="11.157" transform="matrix(0.7933 -0.6088 0.6088 0.7933 -5.1621 12.1086)" fill="#FFBF00" width="20" height="5"/>
<line fill="#FFBF00" stroke="#000000" x1="8.376" y1="15.783" x2="10.717" y2="18.766"/>
<line fill="#FFBF00" stroke="#000000" x1="11.946" y1="13.043" x2="14.288" y2="16.027"/>
<line fill="#FFBF00" stroke="#000000" x1="15.342" y1="10.437" x2="17.684" y2="13.42"/>
<line fill="#FFBF00" stroke="#000000" x1="18.69" y1="7.869" x2="21.03" y2="10.852"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.3 KiB

View File

@@ -1,36 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 12.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 51448) -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [
<!ENTITY ns_extend "http://ns.adobe.com/Extensibility/1.0/">
<!ENTITY ns_ai "http://ns.adobe.com/AdobeIllustrator/10.0/">
<!ENTITY ns_graphs "http://ns.adobe.com/Graphs/1.0/">
<!ENTITY ns_vars "http://ns.adobe.com/Variables/1.0/">
<!ENTITY ns_imrep "http://ns.adobe.com/ImageReplacement/1.0/">
<!ENTITY ns_sfw "http://ns.adobe.com/SaveForWeb/1.0/">
<!ENTITY ns_custom "http://ns.adobe.com/GenericCustomNamespace/1.0/">
<!ENTITY ns_adobe_xpath "http://ns.adobe.com/XPath/1.0/">
<!ENTITY ns_svg "http://www.w3.org/2000/svg">
<!ENTITY ns_xlink "http://www.w3.org/1999/xlink">
]>
<svg version="1.1" id="Layer_1" xmlns:x="&ns_extend;" xmlns:i="&ns_ai;" xmlns:graph="&ns_graphs;"
xmlns="&ns_svg;" xmlns:xlink="&ns_xlink;" width="28.375" height="28" viewBox="0 0 28.375 28"
overflow="visible" enable-background="new 0 0 28.375 28" xml:space="preserve">
<g i:extraneous="self">
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M27.875,1.375"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M0,1.375"/>
<path fill="none" stroke="#FFFFFF" d="M0,27.475"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M1,27.645"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M1,0.544"/>
<line fill="none" stroke="#FFFFFF" x1="0.875" y1="27.5" x2="27.875" y2="27.475"/>
<rect x="0.875" y="1.045" fill="#ADD8E6" width="27.125" height="26"/>
<line fill="none" stroke="#FFFFFF" x1="27.875" y1="26.925" x2="27.875" y2="0.925"/>
<line fill="none" stroke="#00008B" x1="1.375" y1="0.5" x2="27.375" y2="0.5"/>
<line fill="none" stroke="#00008B" x1="0.875" y1="1" x2="0.875" y2="27"/>
<rect x="4.252" y="12.157" transform="matrix(0.7933 -0.6088 0.6088 0.7933 -5.9776 11.7065)" fill="#FFBF00" width="20" height="5"/>
<line fill="#FFBF00" stroke="#000000" x1="7.376" y1="16.783" x2="9.717" y2="19.766"/>
<line fill="#FFBF00" stroke="#000000" x1="10.946" y1="14.043" x2="13.288" y2="17.027"/>
<line fill="#FFBF00" stroke="#000000" x1="14.342" y1="11.437" x2="16.684" y2="14.42"/>
<line fill="#FFBF00" stroke="#000000" x1="17.69" y1="8.869" x2="20.03" y2="11.852"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.3 KiB

View File

@@ -1,44 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 12.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 51448) -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [
<!ENTITY ns_extend "http://ns.adobe.com/Extensibility/1.0/">
<!ENTITY ns_ai "http://ns.adobe.com/AdobeIllustrator/10.0/">
<!ENTITY ns_graphs "http://ns.adobe.com/Graphs/1.0/">
<!ENTITY ns_vars "http://ns.adobe.com/Variables/1.0/">
<!ENTITY ns_imrep "http://ns.adobe.com/ImageReplacement/1.0/">
<!ENTITY ns_sfw "http://ns.adobe.com/SaveForWeb/1.0/">
<!ENTITY ns_custom "http://ns.adobe.com/GenericCustomNamespace/1.0/">
<!ENTITY ns_adobe_xpath "http://ns.adobe.com/XPath/1.0/">
<!ENTITY ns_svg "http://www.w3.org/2000/svg">
<!ENTITY ns_xlink "http://www.w3.org/1999/xlink">
]>
<svg version="1.1" id="Layer_1" xmlns:x="&ns_extend;" xmlns:i="&ns_ai;" xmlns:graph="&ns_graphs;"
xmlns="&ns_svg;" xmlns:xlink="&ns_xlink;" width="28.375" height="28" viewBox="0 0 28.375 28"
overflow="visible" enable-background="new 0 0 28.375 28" xml:space="preserve">
<g i:extraneous="self">
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M27.875,1.375"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M0,1.375"/>
<path fill="none" stroke="#FFFFFF" d="M0,27.475"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M1,27.645"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M1,0.544"/>
<line fill="none" stroke="#00008B" x1="0.875" y1="27.5" x2="27.875" y2="27.475"/>
<rect x="0.875" y="1.045" fill="#00008B" width="27.125" height="26"/>
<line fill="none" stroke="#00008B" x1="27.875" y1="26.925" x2="27.875" y2="0.925"/>
<line fill="none" stroke="#FFFFFF" x1="1.375" y1="0.5" x2="27.375" y2="0.5"/>
<line fill="none" stroke="#FFFFFF" x1="0.875" y1="1" x2="0.875" y2="27"/>
<path fill="#FFFFFF" stroke="#000000" d="M9.458,22.458c-0.473-0.168-1.02-1.269-1.363-1.695
c-0.479-0.595-0.894-1.245-1.377-1.829c-0.733-0.887-1.356-1.729-1.854-2.764c-0.375-0.782-0.884-1.997-0.005-2.648
c1.036-0.767,2.095-0.162,2.934,0.479c0.844,0.646,1.729,1.18,2.526,1.869c-0.372-0.305-0.548-0.986-0.778-1.421
c-0.253-0.477-0.565-0.906-0.822-1.375c-0.359-0.657-0.767-1.201-1.21-1.823c-0.544-0.763-1.051-1.74-0.925-2.709
c0.133-1.025,0.972-1.527,1.924-1.207c1.202,0.405,1.969,1.692,2.627,2.698c0.636,0.971,1.201,2.159,1.938,3.042
c-0.222-0.209-0.148-0.508-0.155-0.782c-0.01-0.37-0.097-0.626-0.219-0.967c-0.162-0.455-0.219-0.972-0.24-1.45
c-0.034-0.776-0.25-1.465-0.25-2.247c0-0.988-0.14-1.963,0.71-2.631c0.666-0.523,1.649-0.764,2.381-0.248
c1.385,0.976,1.057,2.999,1.209,4.458c0.079,0.759,0.165,1.489,0.2,2.263c0.022,0.496,0.209,1.067,0.168,1.558
c-0.146-0.269-0.113-0.749-0.127-1.057c-0.022-0.502-0.041-0.982-0.115-1.47c-0.114-0.743-0.188-1.564-0.25-2.324
c-0.152-1.877,2.054-3.17,3.301-1.469c0.884,1.206,0.773,2.643,0.773,4.085c0,0.698-0.034,1.251-0.22,1.91
c-0.13,0.459-0.293,1.222-0.239,1.638c0-0.902,0.334-1.697,0.334-2.588c0-0.678-0.272-2.099,0.581-2.334
c1.065-0.294,2.008,0.875,2.428,1.66c0.458,0.855,0.555,1.901,0.409,2.882c-0.318,2.154-0.845,4.227-2.096,6.072
c-0.268,0.396-0.485,0.838-0.79,1.22c-0.361,0.452-0.923,0.772-1.416,1.071c-0.381,0.232-0.764,0.53-1.176,0.604
c-0.822,0.149-1.725,0.157-2.565,0.157c-1.29,0-2.564-0.068-3.832-0.251c-0.799-0.115-2.12,0.153-2.668-0.54"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 3.3 KiB

View File

@@ -1,44 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 12.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 51448) -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" [
<!ENTITY ns_extend "http://ns.adobe.com/Extensibility/1.0/">
<!ENTITY ns_ai "http://ns.adobe.com/AdobeIllustrator/10.0/">
<!ENTITY ns_graphs "http://ns.adobe.com/Graphs/1.0/">
<!ENTITY ns_vars "http://ns.adobe.com/Variables/1.0/">
<!ENTITY ns_imrep "http://ns.adobe.com/ImageReplacement/1.0/">
<!ENTITY ns_sfw "http://ns.adobe.com/SaveForWeb/1.0/">
<!ENTITY ns_custom "http://ns.adobe.com/GenericCustomNamespace/1.0/">
<!ENTITY ns_adobe_xpath "http://ns.adobe.com/XPath/1.0/">
<!ENTITY ns_svg "http://www.w3.org/2000/svg">
<!ENTITY ns_xlink "http://www.w3.org/1999/xlink">
]>
<svg version="1.1" id="Layer_1" xmlns:x="&ns_extend;" xmlns:i="&ns_ai;" xmlns:graph="&ns_graphs;"
xmlns="&ns_svg;" xmlns:xlink="&ns_xlink;" width="28.375" height="28" viewBox="0 0 28.375 28"
overflow="visible" enable-background="new 0 0 28.375 28" xml:space="preserve">
<g i:extraneous="self">
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M27.875,1.375"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M0,1.375"/>
<path fill="none" stroke="#FFFFFF" d="M0,27.475"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M1,27.645"/>
<path fill="none" stroke="#00008B" stroke-width="1.5" d="M1,0.544"/>
<line fill="none" stroke="#FFFFFF" x1="0.875" y1="27.5" x2="27.875" y2="27.475"/>
<rect x="0.875" y="1.045" fill="#ADD8E6" width="27.125" height="26"/>
<line fill="none" stroke="#FFFFFF" x1="27.875" y1="26.925" x2="27.875" y2="0.925"/>
<line fill="none" stroke="#00008B" x1="1.375" y1="0.5" x2="27.375" y2="0.5"/>
<line fill="none" stroke="#00008B" x1="0.875" y1="1" x2="0.875" y2="27"/>
<path fill="#FFFFFF" stroke="#000000" d="M8.458,23.458c-0.473-0.168-1.02-1.269-1.363-1.695
c-0.479-0.595-0.894-1.245-1.377-1.829c-0.733-0.887-1.356-1.729-1.854-2.764c-0.375-0.782-0.884-1.997-0.005-2.648
c1.036-0.767,2.095-0.161,2.934,0.479c0.844,0.646,1.729,1.18,2.526,1.869c-0.372-0.305-0.548-0.986-0.778-1.421
c-0.253-0.477-0.565-0.906-0.822-1.375c-0.359-0.657-0.767-1.201-1.21-1.823c-0.544-0.763-1.051-1.74-0.925-2.709
c0.133-1.025,0.972-1.527,1.924-1.207c1.202,0.405,1.969,1.692,2.627,2.698c0.636,0.971,1.201,2.159,1.938,3.042
c-0.222-0.21-0.148-0.509-0.155-0.783c-0.01-0.37-0.097-0.626-0.219-0.967c-0.162-0.455-0.219-0.972-0.24-1.45
c-0.034-0.776-0.25-1.465-0.25-2.247c0-0.988-0.14-1.963,0.71-2.631c0.666-0.523,1.649-0.764,2.381-0.248
c1.385,0.976,1.057,2.999,1.209,4.458c0.079,0.759,0.165,1.489,0.2,2.263c0.022,0.496,0.209,1.068,0.168,1.558
c-0.146-0.27-0.113-0.75-0.127-1.058c-0.022-0.502-0.041-0.982-0.115-1.47c-0.114-0.743-0.188-1.564-0.25-2.324
c-0.152-1.877,2.054-3.17,3.301-1.469c0.884,1.206,0.773,2.643,0.773,4.085c0,0.698-0.034,1.251-0.22,1.91
c-0.13,0.459-0.293,1.222-0.239,1.639c0-0.902,0.334-1.697,0.334-2.589c0-0.678-0.272-2.099,0.581-2.334
c1.065-0.294,2.008,0.875,2.428,1.66c0.458,0.855,0.555,1.901,0.409,2.883c-0.318,2.153-0.845,4.227-2.096,6.071
c-0.268,0.396-0.485,0.838-0.79,1.22c-0.361,0.452-0.923,0.772-1.416,1.071c-0.381,0.232-0.764,0.53-1.176,0.604
c-0.822,0.149-1.725,0.157-2.565,0.157c-1.29,0-2.564-0.068-3.832-0.251c-0.799-0.115-2.12,0.153-2.668-0.54"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 3.3 KiB

View File

@@ -1,71 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://web.resource.org/cc/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="210mm"
height="297mm"
id="svg2"
sodipodi:version="0.32"
inkscape:version="0.41.1"
sodipodi:docbase="/afs/metacarta.com/user/sderle/public_html/ol.zoombar/art"
sodipodi:docname="slider.svg"
inkscape:export-filename="/afs/metacarta.com/user/sderle/public_html/ol.zoombar/img/slider.png"
inkscape:export-xdpi="90.000000"
inkscape:export-ydpi="90.000000">
<defs
id="defs3" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="39.870978"
inkscape:cx="140.00732"
inkscape:cy="695.49796"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="true"
inkscape:window-width="1010"
inkscape:window-height="538"
inkscape:window-x="20"
inkscape:window-y="107" />
<metadata
id="metadata4">
<rdf:RDF
id="RDF5">
<cc:Work
rdf:about=""
id="Work6">
<dc:format
id="format7">image/svg+xml</dc:format>
<dc:type
id="type9"
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1">
<rect
style="fill:#00008b;fill-opacity:1.0000000;stroke:#000080;stroke-width:4.9999957;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
id="rect1291"
x="132.50000"
y="354.86218"
width="15.014628"
height="4.0040474" />
<path
style="fill:none;fill-opacity:0.75000000;fill-rule:evenodd;stroke:#ffffff;stroke-width:2.0000000;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
d="M 134.08880,356.89603 L 146.00000,356.87002"
id="path2052" />
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.4 KiB

View File

@@ -1,193 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:xml="http://www.w3.org/XML/1998/namespace"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://web.resource.org/cc/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
inkscape:export-ydpi="90.000000"
inkscape:export-xdpi="90.000000"
inkscape:export-filename="/Users/phil/Documents/work/metacarta/2svn.openlayers.net/follower/code/b-edits-1/openlayers/assets/ui_elements/zoom-minus-mini.png"
sodipodi:docname="zoom-world.svg"
sodipodi:docbase="/afs/metacarta.com/user/sderle/OL/openlayers/assets/ui_elements"
inkscape:version="0.41.1"
sodipodi:version="0.32"
id="svg2"
height="18.000000px"
width="18.000000px">
<defs
id="defs4" />
<sodipodi:namedview
inkscape:window-y="26"
inkscape:window-x="42"
inkscape:window-height="800"
inkscape:window-width="1226"
inkscape:current-layer="layer5"
inkscape:document-units="px"
inkscape:cy="9.3025513"
inkscape:cx="9.0000000"
inkscape:zoom="1.0000000"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
borderopacity="1.0"
bordercolor="#666666"
pagecolor="#ffffff"
id="base" />
<metadata
id="metadata7">
<rdf:RDF
id="RDF1295">
<cc:Work
id="Work1297"
rdf:about="">
<dc:format
id="format1299">image/svg+xml</dc:format>
<dc:type
id="type1301"
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<g
style="display:inline"
id="layer1"
inkscape:groupmode="layer"
inkscape:label="background">
<rect
style="fill:#00008b;fill-opacity:1.0000000;stroke:none;stroke-width:39.984146;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
id="rect2061"
width="18.014498"
height="18.000000"
x="-18.014502"
y="4.3599998e-06"
transform="matrix(0.000000,-1.000000,1.000000,0.000000,0.000000,0.000000)" />
</g>
<g
inkscape:label="graticule"
id="layer5"
inkscape:groupmode="layer">
<g
transform="translate(0.000000,-4.419417e-2)"
id="g2876">
<path
transform="matrix(1.155321,0.000000,0.000000,1.155321,-2.292065,-1.751761)"
d="M 16.869573 9.3188362 A 7.0579743 7.0579743 0 1 1 2.7536244,9.3188362 A 7.0579743 7.0579743 0 1 1 16.869573 9.3188362 z"
sodipodi:ry="7.0579743"
sodipodi:rx="7.0579743"
sodipodi:cy="9.3188362"
sodipodi:cx="9.8115988"
id="path1321"
style="fill:none;fill-opacity:1.0000000;stroke:#ffffff;stroke-width:0.50000000;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
sodipodi:type="arc" />
<path
sodipodi:nodetypes="cc"
id="path2086"
d="M 8.1145142,1.1289949 C 15.315267,9.5238831 8.3963197,17.101449 8.3963197,17.057255"
style="fill:none;fill-opacity:0.75000000;fill-rule:evenodd;stroke:#ffffff;stroke-width:0.50000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000" />
<path
sodipodi:nodetypes="cc"
id="path2846"
d="M 11.588885,1.3666059 C 18.922222,9.5405232 11.605526,16.764536 11.605526,16.764536"
style="fill:none;fill-opacity:0.75000000;fill-rule:evenodd;stroke:#ffffff;stroke-width:0.50000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000" />
<path
sodipodi:nodetypes="cc"
id="path2848"
d="M 5.2258471,2.0593951 C 11.080923,9.7405585 5.3432210,16.278941 5.3432210,16.278941"
style="fill:none;fill-opacity:0.75000000;fill-rule:evenodd;stroke:#ffffff;stroke-width:0.50000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000" />
<path
sodipodi:nodetypes="cc"
id="path2850"
d="M 2.7388198,3.7571959 C 6.3686281,9.1817837 2.9127331,14.361601 2.9127331,14.361601"
style="fill:none;fill-opacity:0.75000000;fill-rule:evenodd;stroke:#ffffff;stroke-width:0.50000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000" />
</g>
<g
transform="matrix(-6.269315e-2,0.998033,-0.998033,-6.269315e-2,18.62352,0.612232)"
id="g2883">
<path
transform="matrix(1.155321,0.000000,0.000000,1.155321,-2.292065,-1.751761)"
d="M 16.869573 9.3188362 A 7.0579743 7.0579743 0 1 1 2.7536244,9.3188362 A 7.0579743 7.0579743 0 1 1 16.869573 9.3188362 z"
sodipodi:ry="7.0579743"
sodipodi:rx="7.0579743"
sodipodi:cy="9.3188362"
sodipodi:cx="9.8115988"
id="path2885"
style="fill:none;fill-opacity:1.0000000;stroke:#ffffff;stroke-width:0.50000000;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
sodipodi:type="arc" />
<path
sodipodi:nodetypes="cc"
id="path2887"
d="M 8.1145142,1.1289949 C 15.315267,9.5238831 8.3963197,17.101449 8.3963197,17.057255"
style="fill:none;fill-opacity:0.75000000;fill-rule:evenodd;stroke:#ffffff;stroke-width:0.50000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000" />
<path
sodipodi:nodetypes="cc"
id="path2889"
d="M 11.588885,1.3666059 C 18.922222,9.5405232 11.605526,16.764536 11.605526,16.764536"
style="fill:none;fill-opacity:0.75000000;fill-rule:evenodd;stroke:#ffffff;stroke-width:0.50000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000" />
<path
sodipodi:nodetypes="cc"
id="path2891"
d="M 5.2258471,2.0593951 C 11.080923,9.7405585 5.3432210,16.278941 5.3432210,16.278941"
style="fill:none;fill-opacity:0.75000000;fill-rule:evenodd;stroke:#ffffff;stroke-width:0.50000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000" />
<path
sodipodi:nodetypes="cc"
id="path2893"
d="M 2.7388198,3.7571959 C 6.3686281,9.1817837 2.9127331,14.361601 2.9127331,14.361601"
style="fill:none;fill-opacity:0.75000000;fill-rule:evenodd;stroke:#ffffff;stroke-width:0.50000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000" />
</g>
</g>
<g
style="display:none"
inkscape:label="zoom"
id="layer4"
inkscape:groupmode="layer">
<text
transform="scale(1.000000,-1.000000)"
sodipodi:linespacing="125.00000%"
id="text2114"
y="-3.4077148"
x="3.7485352"
style="font-size:18.000000;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;fill:#ffffff;fill-opacity:1.0000000;stroke:#ffffff;stroke-width:1.0000000px;stroke-linecap:butt;stroke-linejoin:round;stroke-opacity:1.0000000;font-family:Helvetica;text-anchor:start;writing-mode:lr-tb"
xml:space="preserve"><tspan
y="-3.4077148"
x="3.7485352"
id="tspan2118"
sodipodi:role="line"></tspan></text>
</g>
<g
style="display:none"
inkscape:label="overlay"
id="layer2"
inkscape:groupmode="layer">
<path
sodipodi:nodetypes="csccsssscccssscccssssccscc"
id="text2082"
d="M 2.9678210,9.0332227 C 2.9678314,9.5015070 3.1752531,9.8938504 3.5900866,10.210254 C 3.6463464,10.254553 3.9451742,10.453889 4.4865710,10.808262 L 8.1568835,13.247754 C 8.2693886,13.323691 8.4240759,13.393300 8.6209460,13.456582 C 8.8107943,13.519862 9.0041535,13.551503 9.2010240,13.551504 C 9.5736843,13.551503 9.8936056,13.431269 10.160789,13.190801 C 10.427980,12.950332 10.561574,12.659238 10.561572,12.317520 C 10.561574,11.861896 10.322511,11.488536 9.8443836,11.197442 L 8.5998522,10.428575 L 14.548408,10.428575 C 15.026535,10.428577 15.406221,10.298849 15.687470,10.039395 C 15.968721,9.7799443 16.109345,9.4318977 16.109345,8.9952540 C 16.109345,8.5396330 15.961690,8.1915865 15.666377,7.9511133 C 15.364034,7.7106494 14.980831,7.5904152 14.516767,7.5904102 L 8.6314928,7.5904102 L 9.9920390,6.7076368 C 10.160793,6.5937365 10.290871,6.4481897 10.382274,6.2709962 C 10.466652,6.0874870 10.508840,5.8913153 10.508837,5.6824805 C 10.508840,5.3281127 10.378761,5.0338552 10.118602,4.7997070 C 9.8584498,4.5655745 9.5279814,4.4485043 9.1271961,4.4484962 C 8.7615757,4.4485043 8.4029823,4.5624104 8.0514147,4.7902149 L 3.9697741,7.5239649 C 3.6393151,7.7454540 3.4002529,7.9542820 3.2525866,8.1504493 C 3.0627532,8.3972503 2.9678314,8.6756875 2.9678210,8.9857618 L 2.9678210,9.0332227"
style="font-size:12.000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#ffffff;fill-opacity:1.0000000;stroke:none;stroke-width:1.0000000px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1.0000000;font-family:Verdana;text-anchor:start;writing-mode:lr-tb" />
</g>
<g
style="display:none"
inkscape:label="pan triangle"
id="layer3"
inkscape:groupmode="layer">
<path
transform="matrix(0.000000,-1.331000,1.331000,0.000000,2.038879,16.92102)"
d="M 9.3471551,9.5937489 L 5.5311469,7.3905753 L 1.7151384,5.1874015 L 5.5311469,2.9842283 L 9.3471555,0.78105489 L 9.3471553,5.1874018 L 9.3471551,9.5937489 z "
inkscape:randomized="0.0000000"
inkscape:rounded="0.0000000"
inkscape:flatsided="false"
sodipodi:arg2="2.0943951"
sodipodi:arg1="1.0471976"
sodipodi:r2="2.5440056"
sodipodi:r1="5.0880113"
sodipodi:cy="5.1874018"
sodipodi:cx="6.8031497"
sodipodi:sides="3"
id="path2107"
style="fill:#ffffff;fill-opacity:1.0000000;stroke:none;stroke-width:39.984146;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-opacity:1.0000000"
sodipodi:type="star" />
</g>
</svg>

Before

Width:  |  Height:  |  Size: 10 KiB

View File

@@ -1,73 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://web.resource.org/cc/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="18"
height="18"
id="svg2"
sodipodi:version="0.32"
inkscape:version="0.43"
version="1.0"
inkscape:export-filename="C:\Documents and Settings\crschmidt\Desktop\zoombar.png"
inkscape:export-xdpi="90"
inkscape:export-ydpi="90"
sodipodi:docbase="C:\Documents and Settings\crschmidt\Desktop"
sodipodi:docname="zoombar.svg">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="1"
inkscape:cx="-117.50597"
inkscape:cy="65.94562"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showguides="false"
showgrid="false"
inkscape:window-width="1024"
inkscape:window-height="721"
inkscape:window-x="-4"
inkscape:window-y="-4" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1">
<rect
style="opacity:0.5;fill:#808080;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000012;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
id="rect1307"
width="16.999998"
height="10.000004"
x="-125.51302"
y="-52.420002" />
<path
style="fill:none;fill-opacity:0.75;fill-rule:evenodd;stroke:#000000;stroke-width:0.99999958;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.50196078"
d="M -125.54176,-52.415494 L -125.54176,-42.415495"
id="path8297" />
<path
style="fill:none;fill-opacity:0.75;fill-rule:evenodd;stroke:#000000;stroke-width:0.99999982;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.50196078"
d="M -108.48157,-52.418044 L -108.48157,-42.418046"
id="path12667" />
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.6 KiB

View File

@@ -1,56 +0,0 @@
OpenLayers contributors:
Antoine Abt
Mike Adair
Jeff Adams
Seb Benthall
Bruno Binet
Stéphane Brunner
Howard Butler
Bertil Chaupis
John Cole
Tim Coulter
Robert Coup
Jeff Dege
Roald de Wit
Schuyler Erle
Christian López Espínola
John Frank
Sean Gilles
Pierre Giraud
Ivan Grcic
Andreas Hocevar
Marc Jansen
Ian Johnson
Frédéric Junod
Eric Lemoine
Philip Lindsay
Martijn van Oosterhout
David Overstrom
Corey Puffault
Peter William Robins
Gregers Rygg
Tim Schaub
Christopher Schmidt
Cameron Shorter
Pedro Simonetti
Paul Spencer
Paul Smith
Glen Stampoultzis
James Stembridge
Erik Uzureau
Bart van den Eijnden
Ivan Willig
Thomas Wood
Bill Woodall
Steve Woodbridge
David Zwarg
Some portions of OpenLayers are used under the Apache 2.0 license, available
in doc/licenses/APACHE-2.0.txt.
Some portions of OpenLayers are used under the MIT license, availabie in
doc/licenses/MIT-LICENSE.txt.
Some portions of OpenLayers are Copyright 2001 Robert Penner, and are used
under the BSD license, available in doc/licenses/BSD-LICENSE.txt

30
bin/check-example.js Normal file
View File

@@ -0,0 +1,30 @@
//
// A PhantomJS script used to check that the hosted examples load
// without errors. This script is executed by the build tool's
// check-examples target.
//
var args = require('system').args;
if (args.length != 2) {
phantom.exit(2);
}
var examplePath = args[1];
var page = require('webpage').create();
page.onError = function(msg, trace) {
var msgStack = ['JavaScript ERROR: ' + msg];
if (trace) {
msgStack.push('TRACE:');
trace.forEach(function(t) {
msgStack.push(' -> ' + t.file + ': ' + t.line + (t.function ? ' (in function "' + t.function + '")' : ''));
});
}
console.error(msgStack.join('\n'));
phantom.exit(1);
};
page.open(examplePath, function(s) {
var exitCode = 0;
if (s != 'success') {
exitCode = 1;
console.error('PAGE LOAD ERROR');
}
phantom.exit(exitCode);
});

202
bin/closure/depswriter.py Normal file
View File

@@ -0,0 +1,202 @@
#!/usr/bin/env python
#
# Copyright 2009 The Closure Library Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS-IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
"""Generates out a Closure deps.js file given a list of JavaScript sources.
Paths can be specified as arguments or (more commonly) specifying trees
with the flags (call with --help for descriptions).
Usage: depswriter.py [path/to/js1.js [path/to/js2.js] ...]
"""
import logging
import optparse
import os
import posixpath
import shlex
import sys
import source
import treescan
__author__ = 'nnaze@google.com (Nathan Naze)'
def MakeDepsFile(source_map):
"""Make a generated deps file.
Args:
source_map: A dict map of the source path to source.Source object.
Returns:
str, A generated deps file source.
"""
# Write in path alphabetical order
paths = sorted(source_map.keys())
lines = []
for path in paths:
js_source = source_map[path]
# We don't need to add entries that don't provide anything.
if js_source.provides:
lines.append(_GetDepsLine(path, js_source))
return ''.join(lines)
def _GetDepsLine(path, js_source):
"""Get a deps.js file string for a source."""
provides = sorted(js_source.provides)
requires = sorted(js_source.requires)
return 'goog.addDependency(\'%s\', %s, %s);\n' % (path, provides, requires)
def _GetOptionsParser():
"""Get the options parser."""
parser = optparse.OptionParser(__doc__)
parser.add_option('--output_file',
dest='output_file',
action='store',
help=('If specified, write output to this path instead of '
'writing to standard output.'))
parser.add_option('--root',
dest='roots',
default=[],
action='append',
help='A root directory to scan for JS source files. '
'Paths of JS files in generated deps file will be '
'relative to this path. This flag may be specified '
'multiple times.')
parser.add_option('--root_with_prefix',
dest='roots_with_prefix',
default=[],
action='append',
help='A root directory to scan for JS source files, plus '
'a prefix (if either contains a space, surround with '
'quotes). Paths in generated deps file will be relative '
'to the root, but preceded by the prefix. This flag '
'may be specified multiple times.')
parser.add_option('--path_with_depspath',
dest='paths_with_depspath',
default=[],
action='append',
help='A path to a source file and an alternate path to '
'the file in the generated deps file (if either contains '
'a space, surround with whitespace). This flag may be '
'specified multiple times.')
return parser
def _NormalizePathSeparators(path):
"""Replaces OS-specific path separators with POSIX-style slashes.
Args:
path: str, A file path.
Returns:
str, The path with any OS-specific path separators (such as backslash on
Windows) replaced with URL-compatible forward slashes. A no-op on systems
that use POSIX paths.
"""
return path.replace(os.sep, posixpath.sep)
def _GetRelativePathToSourceDict(root, prefix=''):
"""Scans a top root directory for .js sources.
Args:
root: str, Root directory.
prefix: str, Prefix for returned paths.
Returns:
dict, A map of relative paths (with prefix, if given), to source.Source
objects.
"""
# Remember and restore the cwd when we're done. We work from the root so
# that paths are relative from the root.
start_wd = os.getcwd()
os.chdir(root)
path_to_source = {}
for path in treescan.ScanTreeForJsFiles('.'):
prefixed_path = _NormalizePathSeparators(os.path.join(prefix, path))
path_to_source[prefixed_path] = source.Source(source.GetFileContents(path))
os.chdir(start_wd)
return path_to_source
def _GetPair(s):
"""Return a string as a shell-parsed tuple. Two values expected."""
try:
# shlex uses '\' as an escape character, so they must be escaped.
s = s.replace('\\', '\\\\')
first, second = shlex.split(s)
return (first, second)
except:
raise Exception('Unable to parse input line as a pair: %s' % s)
def main():
"""CLI frontend to MakeDepsFile."""
logging.basicConfig(format=(sys.argv[0] + ': %(message)s'),
level=logging.INFO)
options, args = _GetOptionsParser().parse_args()
path_to_source = {}
# Roots without prefixes
for root in options.roots:
path_to_source.update(_GetRelativePathToSourceDict(root))
# Roots with prefixes
for root_and_prefix in options.roots_with_prefix:
root, prefix = _GetPair(root_and_prefix)
path_to_source.update(_GetRelativePathToSourceDict(root, prefix=prefix))
# Source paths
for path in args:
path_to_source[path] = source.Source(source.GetFileContents(path))
# Source paths with alternate deps paths
for path_with_depspath in options.paths_with_depspath:
srcpath, depspath = _GetPair(path_with_depspath)
path_to_source[depspath] = source.Source(source.GetFileContents(srcpath))
# Make our output pipe.
if options.output_file:
out = open(options.output_file, 'w')
else:
out = sys.stdout
out.write('// This file was autogenerated by %s.\n' % sys.argv[0])
out.write('// Please do not edit.\n')
out.write(MakeDepsFile(path_to_source))
if __name__ == '__main__':
main()

114
bin/closure/source.py Normal file
View File

@@ -0,0 +1,114 @@
# Copyright 2009 The Closure Library Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS-IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
"""Scans a source JS file for its provided and required namespaces.
Simple class to scan a JavaScript file and express its dependencies.
"""
__author__ = 'nnaze@google.com'
import re
_BASE_REGEX_STRING = '^\s*goog\.%s\(\s*[\'"](.+)[\'"]\s*\)'
_PROVIDE_REGEX = re.compile(_BASE_REGEX_STRING % 'provide')
_REQUIRES_REGEX = re.compile(_BASE_REGEX_STRING % 'require')
# This line identifies base.js and should match the line in that file.
_GOOG_BASE_LINE = (
'var goog = goog || {}; // Identifies this file as the Closure base.')
class Source(object):
"""Scans a JavaScript source for its provided and required namespaces."""
# Matches a "/* ... */" comment.
# Note: We can't definitively distinguish a "/*" in a string literal without a
# state machine tokenizer. We'll assume that a line starting with whitespace
# and "/*" is a comment.
_COMMENT_REGEX = re.compile(
r"""
^\s* # Start of a new line and whitespace
/\* # Opening "/*"
.*? # Non greedy match of any characters (including newlines)
\*/ # Closing "*/""",
re.MULTILINE | re.DOTALL | re.VERBOSE)
def __init__(self, source):
"""Initialize a source.
Args:
source: str, The JavaScript source.
"""
self.provides = set()
self.requires = set()
self._source = source
self._ScanSource()
def __str__(self):
return 'Source %s' % self._path
def GetSource(self):
"""Get the source as a string."""
return self._source
@classmethod
def _StripComments(cls, source):
return cls._COMMENT_REGEX.sub('', source)
def _ScanSource(self):
"""Fill in provides and requires by scanning the source."""
source = self._StripComments(self.GetSource())
source_lines = source.splitlines()
for line in source_lines:
match = _PROVIDE_REGEX.match(line)
if match:
self.provides.add(match.group(1))
match = _REQUIRES_REGEX.match(line)
if match:
self.requires.add(match.group(1))
# Closure's base file implicitly provides 'goog'.
for line in source_lines:
if line == _GOOG_BASE_LINE:
if len(self.provides) or len(self.requires):
raise Exception(
'Base files should not provide or require namespaces.')
self.provides.add('goog')
def GetFileContents(path):
"""Get a file's contents as a string.
Args:
path: str, Path to file.
Returns:
str, Contents of file.
Raises:
IOError: An error occurred opening or reading the file.
"""
fileobj = open(path)
try:
return fileobj.read()
finally:
fileobj.close()

78
bin/closure/treescan.py Normal file
View File

@@ -0,0 +1,78 @@
#!/usr/bin/env python
#
# Copyright 2010 The Closure Library Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS-IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
"""Shared utility functions for scanning directory trees."""
import os
import re
__author__ = 'nnaze@google.com (Nathan Naze)'
# Matches a .js file path.
_JS_FILE_REGEX = re.compile(r'^.+\.js$')
def ScanTreeForJsFiles(root):
"""Scans a directory tree for JavaScript files.
Args:
root: str, Path to a root directory.
Returns:
An iterable of paths to JS files, relative to cwd.
"""
return ScanTree(root, path_filter=_JS_FILE_REGEX)
def ScanTree(root, path_filter=None, ignore_hidden=True):
"""Scans a directory tree for files.
Args:
root: str, Path to a root directory.
path_filter: A regular expression filter. If set, only paths matching
the path_filter are returned.
ignore_hidden: If True, do not follow or return hidden directories or files
(those starting with a '.' character).
Yields:
A string path to files, relative to cwd.
"""
def OnError(os_error):
raise os_error
for dirpath, dirnames, filenames in os.walk(root, onerror=OnError):
# os.walk allows us to modify dirnames to prevent decent into particular
# directories. Avoid hidden directories.
for dirname in dirnames:
if ignore_hidden and dirname.startswith('.'):
dirnames.remove(dirname)
for filename in filenames:
# nothing that starts with '.'
if ignore_hidden and filename.startswith('.'):
continue
fullpath = os.path.join(dirpath, filename)
if path_filter and not path_filter.match(fullpath):
continue
yield os.path.normpath(fullpath)

180
bin/example-screenshot.js Normal file
View File

@@ -0,0 +1,180 @@
/**
* This script is supposed to be executed via phantomjs. It will generate
* screenshots of the html files in the directory specified by a commandline
* option when these files are served through a webserver which can also be
* specified. The screenshots will be in the current working directory.
*
* Example usage:
*
* user@host:~/ol3/bin $ phantomjs example-screenshot.js \
* http://localhost:8000/ol3/examples/ \
* ../examples
*
* The above command will generate `*.png` files in `examples/` for all html
* files that are served through `http://localhost:8000/ol3/examples/`.
*
* So if there is a file `my-humpty-example.html` inside of the relative folder
* `../examples/` which is being served through the webserver so that
* `http://localhost:8000/ol3/examples/my-humpty-example.html` is a valid and
* reachable URL, this script will generate a screenshot and store it as
* `my-humpty-example.html.png`.
*
* The query string `?mode=raw` will be appended to the generated URL.
*
* Known limitations:
*
* As phantomjs doesn't support WebGL (see e.g.
* https://github.com/ariya/phantomjs/wiki/Supported-Web-Standards and
* http://code.google.com/p/phantomjs/issues/detail?id=273) This won't render
* OpenLayers maps rendered through the webglrenderer.
*
* In parts based upon this gist: https://gist.github.com/crazy4groovy/3160121
*/
(function() { // global closure
var page = require('webpage').create(), // imports
fs = require('fs'),
system = require('system'),
// arguments
baseExamplesUrl = system.args[1],
exampleDir = system.args[2],
// various settings
ignoreFiles = [
'index.html'
],
intervalMillisecs = 25,
renderMillisecs = 2000,
// basic variables
curDir = fs.workingDirectory,
exampleDirList = fs.list(exampleDir),
pageindex = 0,
fileName = '',
htmlFiles = [],
lenHtmlFiles = 0,
loadInProgress = false;
// simple object with helper functions
var util = {
/**
* Returns the basename of a file given a path.
*/
baseName: function(path) {
var parts = path.split(fs.separator);
return parts[parts.length - 1];
},
/**
* Super basic test whether a file can be considered a HTML-file.
*/
isHtmlFile: function(filename) {
return (/\.html?$/).test(filename);
},
/**
* Appends a slash to given string if it isn't there already.
*/
appendSlash: function(str) {
return ((/\/$/).test(str)) ? str : str + '/';
},
/**
* Generates an URL out of given baseurl and path.
*/
buildUrl: function(baseurl, path) {
var name = util.baseName(path),
mode = 'raw';
return util.appendSlash(baseurl) + name + '?mode=' + mode;
},
/**
* Simple progressbar logger that uses our globals pageindex & lenHtmlFiles.
*/
logProgress: function() {
var doneSymbol = '-',
todoSymbol = ' ',
currentSymbol = '>',
barStrLeft = '[',
barStrRight = ']',
progresStep = 5, // one doneSymbol equals this percentage
totalSteps = Math.round(100 / progresStep),
ratio = (lenHtmlFiles === 0) ? 0 : (pageindex / lenHtmlFiles),
percent = (ratio === 0) ? 0 : ratio * 100,
normalizedNumDone = Math.floor(ratio * totalSteps),
normalizedNumTodo = totalSteps - normalizedNumDone,
progressLine = '',
i = 0;
// the progress bar
progressLine += barStrLeft;
for (; i < normalizedNumDone; i++) {
progressLine += doneSymbol;
}
for (i = 0; i < normalizedNumTodo; i++) {
progressLine += (i === 0) ? currentSymbol : todoSymbol;
}
progressLine += barStrRight;
// the percentage information
// pad if necessary
if (percent < 10) {
progressLine += ' ';
} else if (percent < 100) {
progressLine += ' ';
}
progressLine += ' ' + percent.toFixed(1) + ' % done';
// additional information
if (fileName !== '') {
progressLine += ', ' + util.baseName(fileName) + '';
}
console.log(progressLine);
}
};
// iterate over all files in examples directory
// and find the HTML files.
for (var i = 0; i < exampleDirList.length; i++) {
var fullpath = exampleDir + fs.separator + exampleDirList[i];
if (fs.isFile(fullpath) && util.isHtmlFile(fullpath) &&
ignoreFiles.indexOf(util.baseName(fullpath)) === -1) {
//TODO: make this more async (i.e. pop on/off stack WHILE rending pages)
htmlFiles.push(fullpath);
}
}
lenHtmlFiles = htmlFiles.length;
console.log('Capturing ' + lenHtmlFiles + ' example screenshots.');
// The main interval function that is executed regularily and renders a
// page to a file
var interval = setInterval(function() {
if (!loadInProgress && pageindex < lenHtmlFiles) {
util.logProgress();
fileName = htmlFiles[pageindex];
page.viewportSize = { width: 800, height: 600 };
page.clipRect = {
top: 0,
left: 0,
width: page.viewportSize.width,
height: page.viewportSize.height
};
page.open(util.buildUrl(baseExamplesUrl, htmlFiles[pageindex]));
}
if (pageindex == lenHtmlFiles) {
util.logProgress();
console.log(lenHtmlFiles + ' screenshots captured.');
phantom.exit();
}
}, intervalMillisecs);
// set loadInProgress flag so we only process one image at time.
page.onLoadStarted = function() {
loadInProgress = true;
};
// When the page is loaded, render it to an image
page.onLoadFinished = function() {
var dest = exampleDir + fs.separator + util.baseName(fileName) + '.png';
window.setTimeout(function() {
loadInProgress = false;
page.render(dest); // actually render the page.
pageindex++;
}, renderMillisecs);
};
})(); // eof global closure

View File

@@ -7,41 +7,44 @@ import time
from xml.dom.minidom import Document
try:
import xml.etree.ElementTree as ElementTree
import xml.etree.ElementTree as ElementTree
except ImportError:
try:
import cElementTree as ElementTree
import cElementTree as ElementTree # NOQA
except ImportError:
try:
import elementtree.ElementTree as ElementTree
import elementtree.ElementTree as ElementTree # NOQA
except ImportError:
import lxml.etree as ElementTree
import lxml.etree as ElementTree # NOQA
missing_deps = False
try:
import json
except ImportError:
try:
import simplejson as json
import simplejson as json # NOQA
except ImportError, E:
missing_deps = E
missing_deps = E
try:
from BeautifulSoup import BeautifulSoup
except ImportError, E:
missing_deps = E
missing_deps = E
feedName = "example-list.xml"
feedPath = "http://openlayers.org/dev/examples/"
feedPath = "http://openlayers.github.io/ol3/master/examples/"
def getListOfExamples(relPath):
"""
returns list of .html filenames within a given path - excludes example-list.html
returns list of .html filenames within a given path - excludes
index.html
"""
examples = os.listdir(relPath)
examples = [example for example in examples if example.endswith('.html') and example != "example-list.html"]
examples = [example for example in examples if
example.endswith('.html') and example != "index.html"]
return examples
def getExampleHtml(path):
"""
@@ -52,41 +55,44 @@ def getExampleHtml(path):
html = f.read()
f.close()
return html
def extractById(soup, tagId, value=None):
"""
returns full contents of a particular tag id
"""
beautifulTag = soup.find(id=tagId)
if beautifulTag:
if beautifulTag.contents:
if beautifulTag.contents:
value = str(beautifulTag.renderContents()).strip()
value = value.replace('\t','')
value = value.replace('\n','')
value = value.replace('\t', '')
value = value.replace('\n', '')
return value
def getRelatedClasses(html):
"""
parses the html, and returns a list of all OpenLayers Classes
used within (ie what parts of OL the javascript uses).
parses the html, and returns a list of all OpenLayers Classes
used within (ie what parts of OL the javascript uses).
"""
rawstr = r'''(?P<class>OpenLayers\..*?)\('''
rawstr = r'''(?P<class>ol\..*?)\('''
return re.findall(rawstr, html)
def parseHtml(html,ids):
def parseHtml(html, ids):
"""
returns dictionary of items of interest
"""
soup = BeautifulSoup(html)
d = {}
for tagId in ids:
d[tagId] = extractById(soup,tagId)
d[tagId] = extractById(soup, tagId)
#classes should eventually be parsed from docs - not automatically created.
classes = getRelatedClasses(html)
d['classes'] = classes
return d
def getGitInfo(exampleDir, exampleName):
orig = os.getcwd()
os.chdir(exampleDir)
@@ -95,14 +101,19 @@ def getGitInfo(exampleDir, exampleName):
log = h.read()
h.close()
d = {}
parts = log.split("|")
d["author"] = parts[0]
# compensate for spaces in git log time
td = parts[1].split(" ")
td.insert(1, "T")
d["date"] = "".join(td)
if log:
parts = log.split("|")
d["author"] = parts[0]
# compensate for spaces in git log time
td = parts[1].split(" ")
td.insert(1, "T")
d["date"] = "".join(td)
else:
d["author"] = ""
d["date"] = ""
return d
def createFeed(examples):
doc = Document()
atomuri = "http://www.w3.org/2005/Atom"
@@ -114,55 +125,62 @@ def createFeed(examples):
link = doc.createElementNS(atomuri, "link")
link.setAttribute("rel", "self")
link.setAttribute("href", feedPath + feedName)
modtime = time.strftime("%Y-%m-%dT%I:%M:%SZ", time.gmtime())
id = doc.createElementNS(atomuri, "id")
id.appendChild(doc.createTextNode("%s%s#%s" % (feedPath, feedName, modtime)))
id.appendChild(doc.createTextNode(
"%s%s#%s" % (feedPath, feedName, modtime)))
feed.appendChild(id)
updated = doc.createElementNS(atomuri, "updated")
updated.appendChild(doc.createTextNode(modtime))
feed.appendChild(updated)
examples.sort(key=lambda x:x["modified"])
for example in sorted(examples, key=lambda x:x["modified"], reverse=True):
examples.sort(key=lambda x: x["modified"])
for example in sorted(examples, key=lambda x: x["modified"], reverse=True):
entry = doc.createElementNS(atomuri, "entry")
title = doc.createElementNS(atomuri, "title")
title.appendChild(doc.createTextNode(example["title"] or example["example"]))
title.appendChild(doc.createTextNode(example["title"] or
example["example"]))
entry.appendChild(title)
tags = doc.createElementNS(atomuri, "tags")
tags.appendChild(doc.createTextNode(example["tags"] or example["example"]))
tags.appendChild(doc.createTextNode(example["tags"] or
example["example"]))
entry.appendChild(tags)
link = doc.createElementNS(atomuri, "link")
link.setAttribute("href", "%s%s" % (feedPath, example["example"]))
entry.appendChild(link)
summary = doc.createElementNS(atomuri, "summary")
summary.appendChild(doc.createTextNode(example["shortdesc"] or example["example"]))
summary.appendChild(doc.createTextNode(example["shortdesc"] or
example["example"]))
entry.appendChild(summary)
updated = doc.createElementNS(atomuri, "updated")
updated.appendChild(doc.createTextNode(example["modified"]))
entry.appendChild(updated)
author = doc.createElementNS(atomuri, "author")
name = doc.createElementNS(atomuri, "name")
name.appendChild(doc.createTextNode(example["author"]))
author.appendChild(name)
entry.appendChild(author)
id = doc.createElementNS(atomuri, "id")
id.appendChild(doc.createTextNode("%s%s#%s" % (feedPath, example["example"], example["modified"])))
id.appendChild(doc.createTextNode("%s%s#%s" % (feedPath,
example["example"],
example["modified"])))
entry.appendChild(id)
feed.appendChild(entry)
doc.appendChild(feed)
return doc
return doc
def wordIndex(examples):
"""
Create an inverted index based on words in title and shortdesc. Keys are
@@ -180,35 +198,37 @@ def wordIndex(examples):
for word in words:
if word:
word = word.lower()
if index.has_key(word):
if index[word].has_key(i):
if word in index:
if i in index[word]:
index[word][i] += 1
else:
index[word][i] = 1
else:
index[word] = {i: 1}
return index
if __name__ == "__main__":
if missing_deps:
print "This script requires json or simplejson and BeautifulSoup. You don't have them. \n(%s)" % E
print """This script requires json or simplejson and BeautifulSoup.
You don't have them. \n(%s)""" % E
sys.exit()
if len(sys.argv) == 3:
inExampleDir = sys.argv[1]
outExampleDir = sys.argv[2]
else:
inExampleDir = "../examples"
outExampleDir = "../examples"
outFile = open(os.path.join(outExampleDir, "example-list.js"), "w")
print 'Reading examples from %s and writing out to %s' % (inExampleDir, outFile.name)
print 'Reading examples from %s and writing out to %s' % (inExampleDir,
outFile.name)
exampleList = []
docIds = ['title','shortdesc','tags']
docIds = ['title', 'shortdesc', 'tags']
examples = getListOfExamples(inExampleDir)
modtime = time.strftime("%Y-%m-%dT%I:%M:%SZ", time.gmtime())
@@ -216,7 +236,7 @@ if __name__ == "__main__":
for example in examples:
path = os.path.join(inExampleDir, example)
html = getExampleHtml(path)
tagvalues = parseHtml(html,docIds)
tagvalues = parseHtml(html, docIds)
tagvalues['example'] = example
# add in author/date info
d = getGitInfo(inExampleDir, example)
@@ -225,27 +245,25 @@ if __name__ == "__main__":
tagvalues['link'] = example
exampleList.append(tagvalues)
print
exampleList.sort(key=lambda x:x['example'].lower())
exampleList.sort(key=lambda x: x['example'].lower())
index = wordIndex(exampleList)
json = json.dumps({"examples": exampleList, "index": index})
#give the json a global variable we can use in our js. This should be replaced or made optional.
json = 'var info=' + json
# Give the json a global variable we can use in our js.
# This should be replaced or made optional.
json = 'var info=' + json + ';'
outFile.write(json)
outFile.close()
outFeedPath = os.path.join(outExampleDir, feedName);
outFeedPath = os.path.join(outExampleDir, feedName)
print "writing feed to %s " % outFeedPath
atom = open(outFeedPath, 'w')
doc = createFeed(exampleList)
atom.write(doc.toxml())
atom.close()
print 'complete'

323
bin/generate-exports.py Executable file
View File

@@ -0,0 +1,323 @@
#!/usr/bin/env python
from collections import defaultdict
from itertools import ifilter
from operator import attrgetter
from optparse import OptionParser
import re
import sys
def simplerepr(obj):
keys = sorted(key for key in obj.__dict__.keys() if not key.startswith('_'))
attrs = ''.join(' %s=%r' % (key, obj.__dict__[key]) for key in keys)
return '<%s%s>' % (obj.__class__.__name__, attrs)
class Exportable(object):
def __init__(self, name):
self.name = name
__repr__ = simplerepr
def export(self):
return ''
def extern(self):
return ''
def typedef(self):
return ''
class Class(Exportable):
def __init__(self, name, object_literal, objects):
Exportable.__init__(self, name)
self.object_literal = object_literal
self.objects = objects
self.props = set()
__repr__ = simplerepr
def nested_options(self):
def get_class_by_object_literal_name(name):
for k, o in self.objects.iteritems():
if isinstance(o, Class) and o.object_literal.name == name:
return o
return None
for option in sorted(self.object_literal.prop_types.keys()):
types = self.object_literal.prop_types[option].split('|')
base, object_literal = None, None
for t in types:
if t in self.objects:
o = self.objects[t]
if isinstance(o, (Class, Symbol)):
if base:
raise RuntimeError('Multiple "class" types found for '
'option %s.%s: %s, %s.' %
(self.object_literal.name, option,
base.name, o.name))
base = o
elif isinstance(o, ObjectLiteral):
if object_literal:
raise RuntimeError('Multiple "literal" types found for '
'option %s.%s: %s, %s.' %
(self.object_literal.name, option,
object_literal.name, o.name))
object_literal = o
if object_literal:
if not base:
raise RuntimeError('%s "literal" type found for option %s.%s, '
'but no "class" type.' %
(object_literal.name, self.object_literal.name, option))
klass = get_class_by_object_literal_name(object_literal.name)
if not klass:
raise RuntimeError('No constructor taking a %s found.' %
object_literal.name)
yield option, object_literal, klass, base
def export(self):
lines = []
if self.object_literal is None:
lines.append('\n\ngoog.exportSymbol(\n \'%s\',\n %s);\n' % (self.name, self.name))
else:
lines.append('\n\n\n')
lines.append('/**\n')
lines.append(' * @constructor\n')
lines.append(' * @extends {%s}\n' % (self.name,))
lines.append(' * @param {%s} options Options.\n' % (self.object_literal.extern_name(),))
lines.append(' */\n')
lines.append('%s = function(options) {\n' % (self.export_name(),))
lines.append(' /** @type {%s} */\n' % (self.object_literal.name,))
lines.append(' var arg;\n');
lines.append(' if (goog.isDefAndNotNull(options)) {\n')
# FIXME: we modify the user's options object
lines.append(''.join(
' if (!(options.%(o)s instanceof %(base)s)) {\n'
' options.%(o)s = new %(ctor)s(\n'
' /** @type {%(extern)s} */ (options.%(o)s));\n'
' }\n' %
{'o': o, 'base': b.name, 'ctor': k.export_name(),
'extern': ol.extern_name()} \
for o, ol, k, b in self.nested_options()))
lines.append(' arg = {')
lines.extend(','.join('\n %s: options.%s' % (key, key) for key in sorted(self.object_literal.prop_types.keys())))
lines.append('\n };\n')
lines.append(' } else {\n')
lines.append(' arg = /** @type {%s} */ (options);\n' % (self.object_literal.name,))
lines.append(' }\n')
lines.append(' goog.base(this, arg);\n')
lines.append('};\n')
lines.append('goog.inherits(\n')
lines.append(' %sExport,\n' % (self.name,));
lines.append(' %s);\n' % (self.name,));
lines.append('goog.exportSymbol(\n')
lines.append(' \'%s\',\n' % (self.name,))
lines.append(' %s);\n' % (self.export_name(),))
lines.extend('goog.exportProperty(\n %s,\n \'%s\',\n %s.%s);\n' % (self.name, prop, self.name, prop) for prop in sorted(self.props))
return ''.join(lines)
def export_name(self):
return '%sExport' % self.name
class ObjectLiteral(Exportable):
def __init__(self, name):
Exportable.__init__(self, name)
self.prop_types = {}
__repr__ = simplerepr
def extern(self):
lines = []
lines.append('\n\n\n')
lines.append('/**\n')
lines.append(' * @interface\n')
lines.append(' */\n')
lines.append('%s = function() {};\n' % (self.extern_name(),))
for prop in sorted(self.prop_types.keys()):
lines.append('\n\n')
lines.append('/**\n')
lines.append(' * @type {%s}\n' % (self.prop_types[prop],))
lines.append(' */\n')
lines.append('%s.prototype.%s;\n' % (self.extern_name(), prop))
return ''.join(lines)
def extern_name(self):
return re.sub(r'ol\.(\S+)', r'olx.\1Extern', self.name)
def extern_namespace(self):
return '.'.join(self.extern_name().split('.')[:-1]) or None
def provide(self):
return 'goog.provide(\'%s\');\n' % (self.name,)
def typedef(self):
lines = []
lines.append('\n\n')
lines.append('/**\n')
for i, prop in enumerate(sorted(self.prop_types.keys())):
prefix = ' * @typedef {{' if i == 0 else ' * '
suffix = '}}' if i == len(self.prop_types) - 1 else ','
type = self.prop_types[prop]
if '|' in type:
type = '(%s)' % (type,)
lines.append('%s%s: %s%s\n' % (prefix, prop, type, suffix))
lines.append(' */\n')
lines.append('%s;\n' % (self.name,))
return ''.join(lines)
class Symbol(Exportable):
def __init__(self, name, export_symbol, export_as=None):
Exportable.__init__(self, name)
self.export_symbol = export_symbol
self.export_as = export_as or self.name
self.props = set()
__repr__ = simplerepr
def export(self):
lines = []
if self.export_symbol:
lines.append('\n\ngoog.exportSymbol(\n \'%s\',\n %s);\n' % (self.name, self.export_as))
lines.extend('goog.exportProperty(\n %s,\n \'%s\',\n %s.%s);\n' % (self.name, prop, self.name, prop) for prop in sorted(self.props))
return ''.join(lines)
def main(argv):
option_parser = OptionParser()
option_parser.add_option('--exports', action='store_true')
option_parser.add_option('--externs', action='store_true')
option_parser.add_option('--typedef', action='store_true')
options, args = option_parser.parse_args(argv[1:])
objects = {}
requires = set()
for arg in args:
in_comment = False
object_literal = None
for line in open(arg):
line = line.strip()
if not line:
continue
if line == '/**':
assert not in_comment
in_comment = True
continue
if line == '*/':
assert in_comment
in_comment = False
object_literal = None
continue
if in_comment:
if not line.startswith('*'):
raise RuntimeError(line) # malformed comment
m = re.match(r'\*\s*@typedef\s*\{Object\}\s*(?P<name>\S+)', line)
if m:
assert object_literal is None
name = m.group('name')
if name in objects:
raise RuntimeError(line) # Name already defined
object_literal = ObjectLiteral(name)
objects[name] = object_literal
continue
m = re.match(r'\*\s*@property\s*{(?P<type>.*)}\s*(?P<prop>\S+)', line)
if m:
assert object_literal is not None
prop = m.group('prop')
if prop in object_literal.prop_types:
raise RuntimeError(line) # Duplicate property
type = m.group('type')
object_literal.prop_types[prop] = type
continue
continue
m = re.match(r'@exportClass\s+(?P<name>\S+)(?:\s+(?P<object_literal_name>\S+))?\Z', line)
if m:
name = m.group('name')
if name in objects:
raise RuntimeError(line) # Name already defined
object_literal_name = m.group('object_literal_name')
object_literal = objects[object_literal_name]
if not isinstance(object_literal, ObjectLiteral):
raise RuntimeError(line) # Undefined object literal
klass = Class(name, object_literal, objects)
objects[name] = klass
continue
m = re.match(r'@exportProperty\s+(?P<prop>\S+)\Z', line)
if m:
components = m.group('prop').split('.')
if components[-2] == 'prototype':
requires.add('.'.join(components[:-2]))
else:
requires.add('.'.join(components[:-1]))
name = '.'.join(components[:-1])
prop = components[-1]
if name in objects:
symbol = objects[name]
else:
symbol = Symbol(name, False)
objects[name] = symbol
symbol.props.add(prop)
continue
m = re.match(r'@exportSymbol\s+(?P<name>\S+)(?:\s+(?P<export_as>\S+))?\Z', line)
if m:
name = m.group('name')
if name in objects:
raise RuntimeError(line) # Name already defined
export_as = m.group('export_as')
symbol = Symbol(name, True, export_as)
objects[name] = symbol
if not export_as:
components = m.group('name').split('.')
if re.match(r'[A-Z]', components[-1]):
requires.add(name)
elif len(components) > 1:
requires.add('.'.join(components[:-1]))
continue
raise RuntimeError(line)
objects = sorted(objects.values(), key=attrgetter('name'))
if options.exports:
requires.update(obj.name for obj in objects if isinstance(obj, Class))
if requires:
for require in sorted(requires):
sys.stdout.write('goog.require(\'%s\');\n' % (require,))
for obj in objects:
sys.stdout.write(obj.export())
if options.externs:
object_literals = [obj for obj in objects if isinstance(obj, ObjectLiteral)]
sys.stdout.write('/**\n')
sys.stdout.write(' * @externs\n')
sys.stdout.write(' */\n')
namespaces = sorted(set(filter(None, (object_literal.extern_namespace() for object_literal in object_literals))))
for namespace in namespaces:
sys.stdout.write('\n\n')
sys.stdout.write('/**\n')
sys.stdout.write(' * @type {Object}\n')
sys.stdout.write(' */\n')
if '.' in namespace:
sys.stdout.write('%s = {};\n' % (namespace,))
else:
sys.stdout.write('var %s;\n' % (namespace,))
for object_literal in object_literals:
sys.stdout.write(object_literal.extern())
if options.typedef:
object_literals = [obj for obj in objects if isinstance(obj, ObjectLiteral)]
for object_literal in object_literals:
sys.stdout.write(object_literal.provide())
for object_literal in object_literals:
sys.stdout.write(object_literal.typedef())
if __name__ == '__main__':
sys.exit(main(sys.argv))

View File

@@ -0,0 +1,86 @@
/**
* Loader to add ol.css, ol.js and the example-specific js file to the
* documents.
*
* This loader is used for the hosted examples. It is used in place of the
* development loader (examples/loader.js).
*
* ol.css, ol.js, ol-simple.js, ol-whitespace.js, and ol-deps.js are built
* by OL3's build.py script. They are located in the ../build/ directory,
* relatively to this script.
*
* The script must be named loader.js.
*
* Usage:
*
* <script src="../loader.js?id=my-demo"></script>
*/
(function() {
var i, pair;
var href = window.location.href, start, end, paramsString, pairs,
pageParams = {};
if (href.indexOf('?') > 0) {
start = href.indexOf('?') + 1;
end = href.indexOf('#') > 0 ? href.indexOf('#') : href.length;
paramsString = href.substring(start, end);
pairs = paramsString.split(/[&;]/);
for (i = 0; i < pairs.length; ++i) {
pair = pairs[i].split('=');
if (pair[0]) {
pageParams[decodeURIComponent(pair[0])] =
decodeURIComponent(pair[1]);
}
}
}
var scripts = document.getElementsByTagName('script');
var src, index, search, chunks, scriptParams = {};
for (i = scripts.length - 1; i >= 0; --i) {
src = scripts[i].getAttribute('src');
if (~(index = src.indexOf('loader.js?'))) {
search = src.substr(index + 10);
chunks = search ? search.split('&') : [];
for (i = chunks.length - 1; i >= 0; --i) {
pair = chunks[i].split('=');
if (pair[0]) {
scriptParams[decodeURIComponent(pair[0])] =
decodeURIComponent(pair[1]);
}
}
break;
}
}
var oljs = 'ol.js', mode;
if ('mode' in pageParams) {
mode = pageParams.mode.toLowerCase();
if (mode == 'debug') {
mode = 'raw';
}
if (mode != 'advanced' && mode != 'raw') {
oljs = 'ol-' + mode + '.js';
}
}
// CLOSURE_NO_DEPS has an effect in "raw" and "whitespace" modes only (i.e.
// when COMPILED is false). In "raw" mode we use our own deps file
// (ol-deps.js), so we set CLOSURE_NO_DEPS to true to prevent Google
// Library's base.js script to load deps.js. In "whitespace" mode
// no deps file is needed at all, yet base.js will attempt to load deps.js
// if CLOSURE_NO_DEPS is not set to true.
window.CLOSURE_NO_DEPS = true;
var scriptId = encodeURIComponent(scriptParams.id);
document.write('<link rel="stylesheet" href="../build/ol.css" type="text/css">');
if (mode != 'raw') {
document.write('<scr' + 'ipt type="text/javascript" src="../build/' + oljs + '"></scr' + 'ipt>');
} else {
document.write('<scr' + 'ipt type="text/javascript" src="../closure-library/closure/goog/base.js"></scr' + 'ipt>');
document.write('<scr' + 'ipt type="text/javascript" src="../build/ol-deps.js"></scr' + 'ipt>');
document.write('<scr' + 'ipt type="text/javascript" src="' + scriptId + '-require.js"></scr' + 'ipt>');
}
document.write('<scr' + 'ipt type="text/javascript" src="' + scriptId + '.js"></scr' + 'ipt>');
}());

2
build.cmd Executable file
View File

@@ -0,0 +1,2 @@
@echo off
%SystemDrive%\Python27\python.exe build.py %*

745
build.py Executable file
View File

@@ -0,0 +1,745 @@
#!/usr/bin/env python
from cStringIO import StringIO
import gzip
import json
import os
import os.path
import re
import shutil
import sys
from pake import Target
from pake import ifind, main, output, rule, target, variables, virtual, which
if sys.platform == 'win32':
""" windows_defaults assumes that jsdoc was installed at a specific place
(C:\jsdoc). It also fixes a certain version (1.9.0) of phantomjs which
might not anymore be proposed on
http://code.google.com/p/phantomjs/downloads/list"""
windows_defaults = {
'ProgramFiles': os.environ.get('ProgramFiles', 'C:\\Program Files'),
'Python27': os.environ.get('SystemDrive', 'C:') + '\\Python27',
'jsdoc': os.environ.get('SystemDrive', 'C:') + '\\jsdoc3',
'phantomjs': (os.environ.get('SystemDrive', 'C:') +
'\\phantomjs-1.9.0-windows')
}
if which('git.exe'):
variables.GIT = 'git.exe'
else:
variables.GIT = os.path.join(windows_defaults['ProgramFiles'],
'Git', 'bin', 'git.exe')
if which('gjslint.exe'):
variables.GJSLINT = 'gjslint.exe'
else:
variables.GJSLINT = os.path.join(windows_defaults['Python27'],
'Scripts', 'gjslint.exe')
if which('java.exe'):
variables.JAVA = 'java.exe'
else:
variables.JAVA = os.path.join(windows_defaults['ProgramFiles'],
'Java', 'jre7', 'bin', 'java.exe')
if which('jar.exe'):
variables.JAR = 'jar.exe'
else:
variables.JAR = os.path.join(windows_defaults['ProgramFiles'],
'Java', 'jdk1.7.0_17', 'bin', 'jar.exe')
if which('jsdoc.cmd'):
variables.JSDOC = 'jsdoc.cmd'
else:
variables.JSDOC = os.path.join(windows_defaults['jsdoc'],
'jsdoc.cmd')
if which('python.exe'):
variables.PYTHON = 'python.exe'
else:
variables.PYTHON = os.path.join(windows_defaults['Python27'],
'python.exe')
if which('phantomjs.exe'):
variables.PHANTOMJS = 'phantomjs.exe'
else:
variables.PHANTOMJS = os.path.join(windows_defaults['phantomjs'],
'phantomjs.exe')
else:
variables.GIT = 'git'
variables.GJSLINT = 'gjslint'
variables.JAVA = 'java'
variables.JAR = 'jar'
variables.JSDOC = 'jsdoc'
variables.NODE = 'node'
variables.PYTHON = 'python'
variables.PHANTOMJS = 'phantomjs'
TEMPLATE_GLSL_COMPILER_JS = 'build/glsl-unit/bin/template_glsl_compiler.js'
variables.BRANCH = output(
'%(GIT)s', 'rev-parse', '--abbrev-ref', 'HEAD').strip()
EXECUTABLES = [variables.GIT, variables.GJSLINT, variables.JAVA, variables.JAR,
variables.JSDOC, variables.PYTHON, variables.PHANTOMJS]
EXPORTS = [path
for path in ifind('src')
if path.endswith('.exports')]
EXTERNAL_SRC = [
'build/src/external/externs/types.js',
'build/src/external/src/exports.js',
'build/src/external/src/types.js']
EXAMPLES = [path
for path in ifind('examples')
if path.endswith('.html')
if path != 'examples/index.html']
EXAMPLES_SRC = [path
for path in ifind('examples')
if path.endswith('.js')
if not path.endswith('.combined.js')
if not path.startswith('examples/bootstrap')
if not path.startswith('examples/font-awesome')
if path != 'examples/Jugl.js'
if path != 'examples/jquery.min.js'
if path != 'examples/loader.js'
if path != 'examples/example-list.js']
EXAMPLES_JSON = ['build/' + example.replace('.html', '.json')
for example in EXAMPLES]
EXAMPLES_COMBINED = ['build/' + example.replace('.html', '.combined.js')
for example in EXAMPLES]
INTERNAL_SRC = [
'build/src/internal/src/requireall.js',
'build/src/internal/src/types.js']
GLSL_SRC = [path
for path in ifind('src')
if path.endswith('.glsl')]
JSDOC_SRC = [path
for path in ifind('src')
if path.endswith('.jsdoc')]
SHADER_SRC = [path.replace('.glsl', 'shader.js')
for path in GLSL_SRC]
SPEC = [path
for path in ifind('test/spec')
if path.endswith('.js')]
SRC = [path
for path in ifind('src/ol')
if path.endswith('.js')
if path not in SHADER_SRC]
PLOVR_JAR = 'build/plovr-eba786b34df9.jar'
PLOVR_JAR_MD5 = '20eac8ccc4578676511cf7ccbfc65100'
PROJ4JS = 'build/proj4js/lib/proj4js-combined.js'
PROJ4JS_ZIP = 'build/proj4js-1.1.0.zip'
PROJ4JS_ZIP_MD5 = '17caad64cf6ebc6e6fe62f292b134897'
def report_sizes(t):
t.info('uncompressed: %d bytes', os.stat(t.name).st_size)
stringio = StringIO()
gzipfile = gzip.GzipFile(t.name, 'w', 9, stringio)
with open(t.name) as f:
shutil.copyfileobj(f, gzipfile)
gzipfile.close()
t.info(' compressed: %d bytes', len(stringio.getvalue()))
virtual('default', 'build')
virtual('integration-test', 'lint', 'build', 'build-all',
'test', 'build-examples', 'check-examples', 'doc')
virtual('build', 'build/ol.css', 'build/ol.js',
'build/ol-simple.js', 'build/ol-whitespace.js')
virtual('check', 'lint', 'build/ol.css', 'build/ol-all.js', 'test')
virtual('todo', 'fixme')
@target('build/ol.css', 'build/ol.js')
def build_ol_css(t):
t.touch()
@target('build/ol.js', PLOVR_JAR, SRC, EXTERNAL_SRC, SHADER_SRC,
'buildcfg/base.json', 'buildcfg/ol.json')
def build_ol_js(t):
t.output('%(JAVA)s', '-jar', PLOVR_JAR, 'build', 'buildcfg/ol.json')
report_sizes(t)
@target('build/ol-simple.js', PLOVR_JAR, SRC, INTERNAL_SRC, SHADER_SRC,
'buildcfg/base.json', 'buildcfg/ol.json', 'buildcfg/ol-simple.json')
def build_ol_simple_js(t):
t.output('%(JAVA)s', '-jar', PLOVR_JAR, 'build', 'buildcfg/ol-simple.json')
report_sizes(t)
@target('build/ol-whitespace.js', PLOVR_JAR, SRC, INTERNAL_SRC, SHADER_SRC,
'buildcfg/base.json', 'buildcfg/ol.json',
'buildcfg/ol-whitespace.json')
def build_ol_whitespace_js(t):
t.output('%(JAVA)s', '-jar', PLOVR_JAR,
'build', 'buildcfg/ol-whitespace.json')
report_sizes(t)
virtual('build-all', 'build/ol-all.js')
@target('build/ol-all.js', PLOVR_JAR, SRC, INTERNAL_SRC, SHADER_SRC,
'buildcfg/base.json', 'buildcfg/ol-all.json')
def build_ol_all_js(t):
t.output('%(JAVA)s', '-jar', PLOVR_JAR, 'build', 'buildcfg/ol-all.json')
@target('build/src/external/externs/types.js', 'bin/generate-exports.py',
'src/objectliterals.jsdoc')
def build_src_external_externs_types_js(t):
t.output('%(PYTHON)s', 'bin/generate-exports.py',
'--externs', 'src/objectliterals.jsdoc')
@target('build/src/external/src/exports.js', 'bin/generate-exports.py',
'src/objectliterals.jsdoc', EXPORTS)
def build_src_external_src_exports_js(t):
t.output('%(PYTHON)s', 'bin/generate-exports.py',
'--exports', 'src/objectliterals.jsdoc', EXPORTS)
@target('build/src/external/src/types.js', 'bin/generate-exports.py',
'src/objectliterals.jsdoc')
def build_src_external_src_types_js(t):
t.output('%(PYTHON)s', 'bin/generate-exports.py',
'--typedef', 'src/objectliterals.jsdoc')
if os.path.exists(TEMPLATE_GLSL_COMPILER_JS):
for glsl_src in GLSL_SRC:
def shader_src_helper(glsl_src):
@target(glsl_src.replace('.glsl', 'shader.js'), glsl_src,
'src/ol/webgl/shader.mustache')
def shader_src(t):
t.run('%(NODE)s', TEMPLATE_GLSL_COMPILER_JS,
'--input', glsl_src,
'--template', 'src/ol/webgl/shader.mustache',
'--output', t.name)
shader_src_helper(glsl_src)
def _build_require_list(dependencies, output_file_name):
requires = set()
for dependency in dependencies:
for line in open(dependency):
match = re.match(r'goog\.provide\(\'(.*)\'\);', line)
if match:
requires.add(match.group(1))
with open(output_file_name, 'w') as f:
for require in sorted(requires):
f.write('goog.require(\'%s\');\n' % (require,))
@target('build/src/internal/src/requireall.js', SRC, SHADER_SRC)
def build_src_internal_src_requireall_js(t):
_build_require_list(t.dependencies, t.name)
@target('build/test/requireall.js', SPEC)
def build_test_requireall_js(t):
_build_require_list(t.dependencies, t.name)
@target('build/src/internal/src/types.js', 'bin/generate-exports.py',
'src/objectliterals.jsdoc')
def build_src_internal_types_js(t):
t.output('%(PYTHON)s', 'bin/generate-exports.py',
'--typedef', 'src/objectliterals.jsdoc')
virtual('build-examples', 'examples', EXAMPLES_COMBINED)
virtual('examples', 'examples/example-list.xml', EXAMPLES_JSON)
@target('examples/example-list.xml', 'examples/example-list.js')
def examples_examples_list_xml(t):
t.touch() # already generated by bin/exampleparser.py
@target('examples/example-list.js', 'bin/exampleparser.py', EXAMPLES)
def examples_examples_list_js(t):
t.run('%(PYTHON)s', 'bin/exampleparser.py', 'examples', 'examples')
@rule(r'\Abuild/examples/(?P<id>.*).json\Z')
def examples_star_json(name, match):
def action(t):
content = json.dumps({
'id': match.group('id'),
'inherits': '../../buildcfg/base.json',
'inputs': [
'../examples/%(id)s.js' % match.groupdict(),
'../build/src/internal/src/types.js',
],
'externs': [
'//json.js',
'//jquery-1.7.js',
'../externs/bingmaps.js',
'../externs/bootstrap.js',
'../externs/geojson.js',
'../externs/oli.js',
'../externs/proj4js.js',
'../externs/tilejson.js',
'../externs/w3c_device_sensor_event.js',
],
})
with open(t.name, 'w') as f:
f.write(content)
dependencies = [__file__, 'buildcfg/base.json']
return Target(name, action=action, dependencies=dependencies)
@rule(r'\Abuild/examples/(?P<id>.*).combined.js\Z')
def examples_star_combined_js(name, match):
def action(t):
t.output('%(JAVA)s', '-jar', PLOVR_JAR, 'build',
'build/examples/%(id)s.json' % match.groupdict())
report_sizes(t)
dependencies = [PLOVR_JAR, SRC, INTERNAL_SRC, SHADER_SRC,
'buildcfg/base.json',
'examples/%(id)s.js' % match.groupdict(),
'build/examples/%(id)s.json' % match.groupdict()]
return Target(name, action=action, dependencies=dependencies)
@target('serve', PLOVR_JAR, 'test-deps', 'examples')
def serve(t):
t.run('%(JAVA)s', '-jar', PLOVR_JAR, 'serve', 'buildcfg/ol.json',
'buildcfg/ol-all.json', EXAMPLES_JSON, 'buildcfg/test.json')
@target('serve-integration-test', PLOVR_JAR, INTERNAL_SRC)
def serve_precommit(t):
t.run('%(JAVA)s', '-jar', PLOVR_JAR, 'serve',
'buildcfg/ol-all.json', 'buildcfg/test.json')
virtual('lint', 'build/lint-timestamp', 'build/lint-generated-timestamp',
'build/check-requires-timestamp', 'build/check-whitespace-timestamp')
@target('build/lint-timestamp', SRC, EXAMPLES_SRC, SPEC, precious=True)
def build_lint_src_timestamp(t):
t.run('%(GJSLINT)s',
'--jslint_error=all',
'--strict',
t.newer(t.dependencies))
t.touch()
@target('build/lint-generated-timestamp', INTERNAL_SRC, EXTERNAL_SRC,
precious=True)
def build_lint_generated_timestamp(t):
limited_doc_files = [
path
for path in ifind('externs', 'build/src/external/externs')
if path.endswith('.js')]
t.run('%(GJSLINT)s',
'--jslint_error=all',
# ignore error for max line length (for these auto-generated sources)
'--disable=110',
# for a complete list of error codes to allow, see
# http://closure-linter.googlecode.com/svn/trunk/closure_linter/errors.py
'--limited_doc_files=%s' % (','.join(limited_doc_files),),
'--strict',
t.newer(t.dependencies))
t.touch()
def _strip_comments(lines):
# FIXME this is a horribe hack, we should use a proper JavaScript parser
# here
in_multiline_comment = False
lineno = 0
for line in lines:
lineno += 1
if in_multiline_comment:
index = line.find('*/')
if index != -1:
in_multiline_comment = False
line = line[index + 2:]
if not in_multiline_comment:
line = re.sub(r'//[^\n]*', '', line)
line = re.sub(r'/\*.*?\*/', '', line)
index = line.find('/*')
if index != -1:
yield lineno, line[:index]
in_multiline_comment = True
else:
yield lineno, line
@target('build/check-requires-timestamp', SRC, INTERNAL_SRC, EXTERNAL_SRC,
EXAMPLES_SRC, SHADER_SRC, SPEC)
def build_check_requires_timestamp(t):
from zipfile import ZipFile
unused_count = 0
all_provides = set()
zf = ZipFile(PLOVR_JAR)
for zi in zf.infolist():
if zi.filename.endswith('.js'):
if not zi.filename.startswith('closure/goog/'):
continue
# Skip goog.i18n because it contains so many modules that it causes
# the generated regular expression to exceed Python's limits
if zi.filename.startswith('closure/goog/i18n/'):
continue
for line in zf.open(zi):
m = re.match(r'goog.provide\(\'(.*)\'\);', line)
if m:
all_provides.add(m.group(1))
for filename in sorted(t.dependencies):
if filename == 'build/src/internal/src/requireall.js':
continue
require_linenos = {}
uses = set()
lines = open(filename).readlines()
for lineno, line in _strip_comments(lines):
m = re.match(r'goog.provide\(\'(.*)\'\);', line)
if m:
all_provides.add(m.group(1))
continue
m = re.match(r'goog.require\(\'(.*)\'\);', line)
if m:
require_linenos[m.group(1)] = lineno
continue
ignore_linenos = require_linenos.values()
for lineno, line in enumerate(lines):
if lineno in ignore_linenos:
continue
for require in require_linenos.iterkeys():
if require in line:
uses.add(require)
for require in sorted(set(require_linenos.keys()) - uses):
t.info('%s:%d: unused goog.require: %r' % (
filename, require_linenos[require], require))
unused_count += 1
all_provides.discard('ol')
all_provides.discard('ol.MapProperty')
class Node(object):
def __init__(self):
self.present = False
self.children = {}
def _build_re(self, key):
if len(self.children) == 1:
child_key, child = next(self.children.iteritems())
child_re = '\\.' + child._build_re(child_key)
if self.present:
return key + '(' + child_re + ')?'
else:
return key + child_re
elif self.children:
children_re = '(?:\\.(?:' + '|'.join(
self.children[k]._build_re(k)
for k in sorted(self.children.keys())) + '))'
if self.present:
return key + children_re + '?'
else:
return key + children_re
else:
assert self.present
return key
def build_re(self, key):
return re.compile('\\b' + self._build_re(key) + '\\b')
root = Node()
for provide in all_provides:
node = root
for component in provide.split('.'):
if component not in node.children:
node.children[component] = Node()
node = node.children[component]
node.present = True
provide_res = [child.build_re(key)
for key, child in root.children.iteritems()]
missing_count = 0
for filename in sorted(t.dependencies):
if filename in INTERNAL_SRC or filename in EXTERNAL_SRC:
continue
provides = set()
requires = set()
uses = set()
uses_linenos = {}
for lineno, line in _strip_comments(open(filename)):
m = re.match(r'goog.provide\(\'(.*)\'\);', line)
if m:
provides.add(m.group(1))
continue
m = re.match(r'goog.require\(\'(.*)\'\);', line)
if m:
requires.add(m.group(1))
continue
while True:
for provide_re in provide_res:
m = provide_re.search(line)
if m:
uses.add(m.group())
uses_linenos[m.group()] = lineno
line = line[:m.start()] + line[m.end():]
break
else:
break
if filename == 'src/ol/renderer/layerrenderer.js':
uses.discard('ol.renderer.Map')
m = re.match(
r'src/ol/renderer/(\w+)/\1(\w*)layerrenderer\.js\Z', filename)
if m:
uses.discard('ol.renderer.Map')
uses.discard('ol.renderer.%s.Map' % (m.group(1),))
missing_requires = uses - requires - provides
if missing_requires:
for missing_require in sorted(missing_requires):
t.info("%s:%d missing goog.require('%s')" %
(filename, uses_linenos[missing_require], missing_require))
missing_count += 1
if unused_count or missing_count:
t.error('%d unused goog.requires, %d missing goog.requires' %
(unused_count, missing_count))
t.touch()
@target('build/check-whitespace-timestamp', SRC, INTERNAL_SRC, EXTERNAL_SRC,
EXAMPLES_SRC, SPEC, EXPORTS, JSDOC_SRC,
precious=True)
def build_check_whitespace_timestamp(t):
CR_RE = re.compile(r'\r')
TRAILING_WHITESPACE_RE = re.compile(r'\s+\n\Z')
NO_NEWLINE_RE = re.compile(r'[^\n]\Z')
ALL_WHITESPACE_RE = re.compile(r'\s+\Z')
errors = 0
for filename in sorted(t.newer(t.dependencies)):
whitespace = False
for lineno, line in enumerate(open(filename)):
if CR_RE.search(line):
t.info('%s:%d: carriage return character in line', filename, lineno + 1)
errors += 1
if TRAILING_WHITESPACE_RE.search(line):
t.info('%s:%d: trailing whitespace', filename, lineno + 1)
errors += 1
if NO_NEWLINE_RE.search(line):
t.info('%s:%d: no newline at end of file', filename, lineno + 1)
errors += 1
whitespace = ALL_WHITESPACE_RE.match(line)
if whitespace:
t.info('%s: trailing whitespace at end of file', filename)
errors += 1
if errors:
t.error('%d whitespace errors' % (errors,))
t.touch()
virtual('plovr', PLOVR_JAR)
@target(PLOVR_JAR, clean=False)
def plovr_jar(t):
t.info('downloading %r', t.name)
t.download('https://plovr.googlecode.com/files/' +
os.path.basename(PLOVR_JAR), md5=PLOVR_JAR_MD5)
t.info('downloaded %r', t.name)
virtual('doc', 'build/jsdoc-%(BRANCH)s-timestamp' % vars(variables))
@target('build/jsdoc-%(BRANCH)s-timestamp' % vars(variables), 'host-resources',
'build/src/external/src/exports.js', 'build/src/external/src/types.js',
SRC, SHADER_SRC, ifind('doc/template'))
def jsdoc_BRANCH_timestamp(t):
t.run('%(JSDOC)s', '-c', 'doc/conf.json', 'src', 'doc/index.md',
'-d', 'build/hosted/%(BRANCH)s/apidoc')
t.touch()
def split_example_file(example, dst_dir):
lines = open(example).readlines()
target_lines = []
target_require_lines = []
found_requires = False
found_code = False
for line in lines:
m = re.match(r'goog.require\(\'(.*)\'\);', line)
if m:
found_requires = True
target_require_lines.append(line)
elif found_requires:
if found_code or line not in ('\n', '\r\n'):
found_code = True
target_lines.append(line)
target = open(
os.path.join(dst_dir, os.path.basename(example)), 'w')
target_require = open(
os.path.join(dst_dir, os.path.basename(example)
.replace('.js', '-require.js')),
'w')
target.writelines(target_lines)
target.close()
target_require.writelines(target_require_lines)
target_require.close()
@target('host-resources', phony=True)
def host_resources(t):
resources_dir = 'build/hosted/%(BRANCH)s/resources'
t.rm_rf(resources_dir)
t.cp_r('resources', resources_dir)
@target('host-examples', 'build', 'host-resources', 'examples', phony=True)
def host_examples(t):
examples_dir = 'build/hosted/%(BRANCH)s/examples'
build_dir = 'build/hosted/%(BRANCH)s/build'
t.rm_rf(examples_dir)
t.makedirs(examples_dir)
t.rm_rf(build_dir)
t.makedirs(build_dir)
t.cp(EXAMPLES, examples_dir)
for example in [path.replace('.html', '.js') for path in EXAMPLES]:
split_example_file(example, examples_dir % vars(variables))
t.cp_r('examples/data', examples_dir + '/data')
t.cp('bin/loader_hosted_examples.js', examples_dir + '/loader.js')
t.cp('build/ol.js', 'build/ol-simple.js', 'build/ol-whitespace.js',
'build/ol.css', build_dir)
t.cp('examples/index.html', 'examples/example-list.js',
'examples/example-list.xml', 'examples/Jugl.js',
'examples/jquery.min.js', examples_dir)
t.rm_rf('build/hosted/%(BRANCH)s/closure-library')
t.makedirs('build/hosted/%(BRANCH)s/closure-library')
with t.chdir('build/hosted/%(BRANCH)s/closure-library'):
t.run('%(JAR)s', 'xf', '../../../../' + PLOVR_JAR, 'closure')
t.run('%(JAR)s', 'xf', '../../../../' + PLOVR_JAR, 'third_party')
t.rm_rf('build/hosted/%(BRANCH)s/ol')
t.makedirs('build/hosted/%(BRANCH)s/ol')
t.cp_r('src/ol', 'build/hosted/%(BRANCH)s/ol/ol')
t.run('%(PYTHON)s', 'bin/closure/depswriter.py',
'--root_with_prefix', 'src ../../../ol',
'--root', 'build/hosted/%(BRANCH)s/closure-library/closure/goog',
'--root_with_prefix', 'build/hosted/%(BRANCH)s/closure-library/'
'third_party ../../third_party',
'--output_file', 'build/hosted/%(BRANCH)s/build/ol-deps.js')
@target('check-examples', 'host-examples', phony=True)
def check_examples(t):
examples = ['build/hosted/%(BRANCH)s/' + e for e in EXAMPLES]
all_examples = \
[e + '?mode=raw' for e in examples] + \
[e + '?mode=whitespace' for e in examples] + \
[e + '?mode=simple' for e in examples] + \
examples
for example in all_examples:
t.run('%(PHANTOMJS)s', 'bin/check-example.js', example)
@target(PROJ4JS, PROJ4JS_ZIP)
def proj4js(t):
from zipfile import ZipFile
zf = ZipFile(PROJ4JS_ZIP)
contents = zf.open('proj4js/lib/proj4js-combined.js').read()
with open(t.name, 'wb') as f:
f.write(contents)
@target(PROJ4JS_ZIP, clean=False)
def proj4js_zip(t):
t.info('downloading %r', t.name)
t.download('http://download.osgeo.org/proj4js/' +
os.path.basename(t.name), md5=PROJ4JS_ZIP_MD5)
t.info('downloaded %r', t.name)
virtual('test-deps', INTERNAL_SRC, PROJ4JS, 'build/test/requireall.js')
@target('test', 'test-deps', phony=True)
def test(t):
t.run('%(PHANTOMJS)s', 'test/mocha-phantomjs.coffee', 'test/ol.html')
@target('fixme', phony=True)
def find_fixme(t):
regex = re.compile('FIXME|TODO')
matches = dict()
totalcount = 0
for filename in SRC:
f = open(filename, 'r')
for lineno, line in enumerate(f):
if regex.search(line):
if (filename not in matches):
matches[filename] = list()
matches[filename].append('#%-10d %s' % (
lineno + 1, line.strip()))
totalcount += 1
f.close()
for filename in matches:
num_matches = len(matches[filename])
noun = 'matches' if num_matches > 1 else 'match'
print ' %s has %d %s:' % (filename, num_matches, noun)
for match in matches[filename]:
print ' %s' % (match,)
print
print 'A total of %d TODO/FIXME(s) were found' % (totalcount,)
@target('reallyclean')
def reallyclean(t):
"""Removes untracked files and folders from previous builds."""
# -X => only clean up files that are usually ignored e.g.
# through .gitignore
# -d => also consider directories for deletion
# -f => if git configuration variable clean.requireForce != false,
# git clean will refuse to run unless given -f or -n.
t.run('%(GIT)s', 'clean', '-X', '-d', '-f', '.')
@target('checkdeps')
def check_dependencies(t):
for exe in EXECUTABLES:
status = 'present' if which(exe) else 'MISSING'
print 'Program "%s" seems to be %s.' % (exe, status)
print 'For certain targets all above programs need to be present.'
if __name__ == '__main__':
main()

View File

@@ -1,46 +0,0 @@
The OpenLayers build tool supports several different
forms of compressing your javascript code, and a method
of describing build profiles to create customized
OpenLayers builds with only the components you need.
When building a file, you can choose to build with several
different compression options to the Python-based build.py
script. The following is an example script:
python build.py -c closure full OpenLayers-closure.js
This script selects the 'closure' compression mechanism,
uses a config file called 'full.cfg', and writes the output
to OpenLayers-closure.js.
The options available for compression are:
* closure
This requires you to have a closure-compiler.jar in your
tools directory. You can do this by fetching the compiler
from:
http://closure-compiler.googlecode.com/files/compiler-latest.zip
Then unzipping that file, and placing compiler.jar into tools
and renaming it closure-compiler.jar.
* closure_ws
This uses the closure compiler webservice. This will only work
for files source Javascript files which are under 1MB. (Note that
the default OpenLayers full build is not under 1MB.)
* jsmin
jsmin is the default compiler, and uses the Python-based
jsmin script to compress the Javascript.
* minimize
This is a simple whitespace removing Python script, designed
to fill in when other tools are unavailable.
* none
None will leave the Javascript uncompressed.
For more information on the build script and custom build profiles,
see http://docs.openlayers.org/library/deploying.html

View File

@@ -1,158 +0,0 @@
#!/usr/bin/env python
import sys
import os
sys.path.append("../tools")
import mergejs
import optparse
def build(config_file = None, output_file = None, options = None):
have_compressor = []
try:
import jsmin
have_compressor.append("jsmin")
except ImportError:
print "No jsmin"
try:
# tools/closure_library_jscompiler.py from:
# http://code.google.com/p/closure-library/source/browse/trunk/closure/bin/build/jscompiler.py
import closure_library_jscompiler as closureCompiler
have_compressor.append("closure")
except Exception, E:
print "No closure (%s)" % E
try:
import closure_ws
have_compressor.append("closure_ws")
except ImportError:
print "No closure_ws"
try:
import minimize
have_compressor.append("minimize")
except ImportError:
print "No minimize"
try:
import uglify_js
uglify_js.check_available()
have_compressor.append("uglify-js")
except Exception, E:
print "No uglify-js (%s)" % E
use_compressor = None
if options.compressor and options.compressor in have_compressor:
use_compressor = options.compressor
sourceDirectory = "../lib"
configFilename = "full.cfg"
outputFilename = "OpenLayers.js"
if config_file:
configFilename = config_file
extension = configFilename[-4:]
if extension != ".cfg":
configFilename = config_file + ".cfg"
if output_file:
outputFilename = output_file
print "Merging libraries."
try:
if use_compressor == "closure" or use_compressor == 'uglify-js':
sourceFiles = mergejs.getNames(sourceDirectory, configFilename)
else:
merged = mergejs.run(sourceDirectory, None, configFilename)
except mergejs.MissingImport, E:
print "\nAbnormal termination."
sys.exit("ERROR: %s" % E)
if options.amdname:
options.amdname = "'" + options.amdname + "',"
else:
options.amdname = ""
if options.amd == 'pre':
print "\nAdding AMD function."
merged = "define(%sfunction(){%sreturn OpenLayers;});" % (options.amdname, merged)
print "Compressing using %s" % use_compressor
if use_compressor == "jsmin":
minimized = jsmin.jsmin(merged)
elif use_compressor == "minimize":
minimized = minimize.minimize(merged)
elif use_compressor == "closure_ws":
if len(merged) > 1000000: # The maximum file size for this web service is 1000 KB.
print "\nPre-compressing using jsmin"
merged = jsmin.jsmin(merged)
print "\nIs being compressed using Closure Compiler Service."
try:
minimized = closure_ws.minimize(merged)
except Exception, E:
print "\nAbnormal termination."
sys.exit("ERROR: Closure Compilation using Web service failed!\n%s" % E)
if len(minimized) <= 2:
print "\nAbnormal termination due to compilation errors."
sys.exit("ERROR: Closure Compilation using Web service failed!")
else:
print "Closure Compilation using Web service has completed successfully."
elif use_compressor == "closure":
jscompilerJar = "../tools/closure-compiler.jar"
if not os.path.isfile(jscompilerJar):
print "\nNo closure-compiler.jar; read README.txt!"
sys.exit("ERROR: Closure Compiler \"%s\" does not exist! Read README.txt" % jscompilerJar)
minimized = closureCompiler.Compile(
jscompilerJar,
sourceFiles, [
"--externs", "closure-compiler/Externs.js",
"--jscomp_warning", "checkVars", # To enable "undefinedVars"
"--jscomp_error", "checkRegExp", # Also necessary to enable "undefinedVars"
"--jscomp_error", "undefinedVars"
]
)
if minimized is None:
print "\nAbnormal termination due to compilation errors."
sys.exit("ERROR: Closure Compilation failed! See compilation errors.")
print "Closure Compilation has completed successfully."
elif use_compressor == "uglify-js":
minimized = uglify_js.compile(sourceFiles)
if minimized is None:
print "\nAbnormal termination due to compilation errors."
sys.exit("ERROR: Uglify JS compilation failed! See compilation errors.")
print "Uglify JS compilation has completed successfully."
else: # fallback
minimized = merged
if options.amd == 'post':
print "\nAdding AMD function."
minimized = "define(%sfunction(){%sreturn OpenLayers;});" % (options.amdname, minimized)
if options.status:
print "\nAdding status file."
minimized = "// status: " + file(options.status).read() + minimized
print "\nAdding license file."
minimized = file("license.txt").read() + minimized
print "Writing to %s." % outputFilename
file(outputFilename, "w").write(minimized)
print "Done."
if __name__ == '__main__':
opt = optparse.OptionParser(usage="%s [options] [config_file] [output_file]\n Default config_file is 'full.cfg', Default output_file is 'OpenLayers.js'")
opt.add_option("-c", "--compressor", dest="compressor", help="compression method: one of 'jsmin' (default), 'minimize', 'closure_ws', 'closure', or 'none'", default="jsmin")
opt.add_option("-s", "--status", dest="status", help="name of a file whose contents will be added as a comment at the front of the output file. For example, when building from a git repo, you can save the output of 'git describe --tags' in this file. Default is no file.", default=False)
opt.add_option("--amd", dest="amd", help="output should be AMD module; wrap merged files in define function; can be either 'pre' (before compilation) or 'post' (after compilation). Wrapping the OpenLayers var in a function means the filesize can be reduced by the closure compiler using 'pre', but be aware that a few functions depend on the OpenLayers variable being present. Either option can be used with jsmin or minimize compression. Default false, not AMD.", default=False)
opt.add_option("--amdname", dest="amdname", help="only useful with amd option. Name of AMD module. Default no name, anonymous module.", default=False)
(options, args) = opt.parse_args()
if not len(args):
build(options=options)
elif len(args) == 1:
build(args[0], options=options)
elif len(args) == 2:
build(args[0], args[1], options=options)
else:
print "Wrong number of arguments"

View File

@@ -1,25 +0,0 @@
#!/usr/bin/env python
import sys
sys.path.append("../tools")
import jsmin, mergejs
sourceDirectory = "../lib"
configFilename = "full.cfg"
outputFilename = "OpenLayers.js"
if len(sys.argv) > 1:
configFilename = sys.argv[1] + ".cfg"
if len(sys.argv) > 2:
outputFilename = sys.argv[2]
print "Merging libraries."
merged = mergejs.run(sourceDirectory, None, configFilename)
print "Adding license file."
merged = file("license.txt").read() + merged
print "Writing to %s." % outputFilename
file(outputFilename, "w").write(merged)
print "Done."

View File

@@ -1,50 +0,0 @@
// ********************************************
// This source file serves *ONLY* to avoid some compilation errors when the
// compiler uses the flag:
// --jscomp_error undefinedVars
//
// In this source are declared all variables from other programs that use
// OpenLayers. This avoids the error of undefined variable for these names.
//
// NOTE: The compiler does not include externs files like this in the
// compilation result.
// ********************************************
// Used in lib/Firebug/firebug.js when gecko_dom
var frames;
// Check the console when using Firebug Lite
var console;
// Proj4js
var Proj4js = {Proj: function(){}};
// Check JSON in lib/OpenLayers/Format/JSON.js
var JSON = {};
// Google Maps
var GMap2;
var G_NORMAL_MAP;
var GEvent;
var GLatLngBounds = function(){};
var GSize = function(x, y){};
var GPoint = function(x, y){};
var GLatLng = function(lat, lon){};
// Multimap
var MultimapViewer = function(div){};
var MMLatLon = function(lat, lon){};
var MMPoint = function(x, y){};
//VirtualEarth
var VEMap = function(name){};
var VEPixel = function(x, y){};
var VELatLong = function(lat, lon){};
var Msn = {VE:{}};
// Yahoo
var YMap = function(div, type, size){};
var YGeoPoint = function(lat, lon){};
var YCoordPoint = function(x, y){};
var YSize = function(w, h){};

View File

@@ -1,14 +0,0 @@
# This is the full build with all files: this includes the vector-related files
# like Renderers and Formats.
[first]
[last]
[include]
[exclude]
Firebug
OpenLayers.js
OpenLayers/Lang
deprecated.js

View File

@@ -1,57 +0,0 @@
/*
OpenLayers.js -- OpenLayers Map Viewer Library
Copyright (c) 2006-2013 by OpenLayers Contributors
Published under the 2-clause BSD license.
See http://openlayers.org/dev/license.txt for the full text of the license, and http://openlayers.org/dev/authors.txt for full list of contributors.
Includes compressed code under the following licenses:
(For uncompressed versions of the code used, please see the
OpenLayers Github repository: <https://github.com/openlayers/openlayers>)
*/
/**
* Contains XMLHttpRequest.js <http://code.google.com/p/xmlhttprequest/>
* Copyright 2007 Sergey Ilinsky (http://www.ilinsky.com)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
*/
/**
* OpenLayers.Util.pagePosition is based on Yahoo's getXY method, which is
* Copyright (c) 2006, Yahoo! Inc.
* All rights reserved.
*
* Redistribution and use of this software in source and binary forms, with or
* without modification, are permitted provided that the following conditions
* are met:
*
* * Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* * Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* * Neither the name of Yahoo! Inc. nor the names of its contributors may be
* used to endorse or promote products derived from this software without
* specific prior written permission of Yahoo! Inc.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/

View File

@@ -1,32 +0,0 @@
[first]
[last]
[include]
OpenLayers/Map.js
OpenLayers/Kinetic.js
OpenLayers/Projection.js
OpenLayers/Layer/Vector.js
OpenLayers/Layer/OSM.js
OpenLayers/Layer/Bing.js
OpenLayers/Layer/WMS.js
OpenLayers/Layer/Google/v3.js
OpenLayers/Popup/FramedCloud.js
OpenLayers/Control/Navigation.js
OpenLayers/Control/Zoom.js
OpenLayers/Control/Attribution.js
OpenLayers/Control/SelectFeature.js
OpenLayers/Control/Panel.js
OpenLayers/Control/LayerSwitcher.js
OpenLayers/Renderer/SVG.js
OpenLayers/Renderer/VML.js
OpenLayers/Format/GeoJSON.js
OpenLayers/Protocol/HTTP.js
OpenLayers/Strategy/Fixed.js
OpenLayers/Strategy/BBOX.js
OpenLayers/StyleMap.js
OpenLayers/Rule.js
OpenLayers/Filter/Comparison.js
OpenLayers/Filter/Logical.js
[exclude]

View File

@@ -1,17 +0,0 @@
# This file includes a small subset of OpenLayers code, designed to be
# integrated into another application. It includes only the Layer types
# neccesary to create tiled or untiled WMS, and does not include any Controls.
# This is the result of what was at the time called "Webmap.js" at the FOSS4G
# Web Mapping BOF.
[first]
[last]
[include]
OpenLayers/Map.js
OpenLayers/Layer/WMS.js
[exclude]

View File

@@ -1,36 +0,0 @@
[first]
[last]
[include]
OpenLayers/Map.js
OpenLayers/Kinetic.js
OpenLayers/Projection.js
OpenLayers/Layer/OSM.js
OpenLayers/Layer/Bing.js
OpenLayers/Layer/WMS.js
OpenLayers/Control/TouchNavigation.js
OpenLayers/Control/Geolocate.js
OpenLayers/Control/Zoom.js
OpenLayers/Control/Attribution.js
OpenLayers/Control/SelectFeature.js
OpenLayers/Control/DrawFeature.js
OpenLayers/Control/ModifyFeature.js
OpenLayers/Control/Panel.js
OpenLayers/Handler/Point.js
OpenLayers/Handler/Path.js
OpenLayers/Handler/Polygon.js
OpenLayers/Layer/Vector.js
OpenLayers/Renderer/SVG.js
OpenLayers/Renderer/Canvas.js
OpenLayers/Format/GeoJSON.js
OpenLayers/Format/KML.js
OpenLayers/Protocol/HTTP.js
OpenLayers/Protocol/WFS.js
OpenLayers/Protocol/WFS/v1_0_0.js
OpenLayers/Strategy/Fixed.js
OpenLayers/TileManager.js
[exclude]

View File

@@ -1,11 +0,0 @@
# This build config is supposed to be used for the units tests with "mode=build"
[first]
[last]
[include]
[exclude]
Firebug
OpenLayers.js

105
buildcfg/base.json Normal file
View File

@@ -0,0 +1,105 @@
{
"ambiguate-properties": true,
"checks": {
"accessControls": "ERROR",
"ambiguousFunctionDecl": "ERROR",
"checkDebuggerStatement": "WARNING",
"checkRegExp": "ERROR",
"checkTypes": "ERROR",
"checkVars": "ERROR",
"const": "ERROR",
"constantProperty": "ERROR",
"deprecated": "ERROR",
"duplicate": "ERROR",
"duplicateMessage": "ERROR",
"es5Strict": "ERROR",
"externsValidation": "ERROR",
"fileoverviewTags": "ERROR",
"globalThis": "ERROR",
"internetExplorerChecks": "ERROR",
"invalidCasts": "ERROR",
"missingProperties": "ERROR",
"nonStandardJsDocs": "ERROR",
"strictModuleDepCheck": "ERROR",
"typeInvalidation": "ERROR",
"undefinedNames": "ERROR",
"undefinedVars": "ERROR",
"unknownDefines": "ERROR",
"uselessCode": "ERROR",
"visibility": "ERROR"
},
"define": {
"goog.dom.ASSUME_STANDARDS_MODE": true,
"goog.DEBUG": false
},
"disambiguate-properties": true,
"externs": [
"//json.js",
"../externs/bingmaps.js",
"../externs/geojson.js",
"../externs/oli.js",
"../externs/proj4js.js",
"../externs/tilejson.js",
"../externs/w3c_device_sensor_event.js"
],
"level": "VERBOSE",
"mode": "ADVANCED",
"name-suffixes-to-strip": [
"logger",
"logger_"
],
"paths": [
"../build/src/internal/src",
"../src"
],
"treat-warnings-as-errors": false,
"type-prefixes-to-strip": [
"goog.asserts",
"goog.debug.Console",
"goog.debug.DebugWindow",
"goog.debug.DevCss",
"goog.debug.DivConsole",
"goog.debug.EntryPointMonitor",
"goog.debug.ErrorHandler",
"goog.debug.ErrorReporter",
"goog.debug.FancyWindow",
"goog.debug.Formatter",
"goog.debug.FpsDisplay",
"goog.debug.GcDiagnostics",
"goog.debug.HtmlFormatter",
"goog.debug.LogBuffer",
"goog.debug.LogManager",
"goog.debug.LogRecord",
"goog.debug.Logger",
"goog.debug.RelativeTimeProvider",
"goog.debug.TextFormatter",
"goog.debug.Trace",
"goog.debug.catchErrors",
"goog.debug.deepExpose",
"goog.debug.enhanceError",
"goog.debug.entryPointRegistry",
"goog.debug.errorHandlerWeakDep",
"goog.debug.expose",
"goog.debug.exposeArray",
"goog.debug.exposeException",
"goog.debug.getFunctionName",
"goog.debug.getStacktrace",
"goog.debug.getStacktraceSimple",
"goog.debug.logRecordSerializer",
"goog.debug.makeWhitespaceVisible",
"goog.debug.normalizeErrorObject",
"goog.debug.reflect"
]
}

24
buildcfg/ol-all.json Normal file
View File

@@ -0,0 +1,24 @@
{
"id": "ol-all",
"externs": [
"//json.js",
"../build/src/external/externs/types.js",
"../externs/bingmaps.js",
"../externs/geojson.js",
"../externs/oli.js",
"../externs/proj4js.js",
"../externs/tilejson.js",
"../externs/w3c_device_sensor_event.js"
],
"inherits": "base.json",
"inputs": [
"../build/src/internal/src/requireall.js",
"../build/src/internal/src/types.js",
"../build/src/external/src/exports.js"
]
}

38
buildcfg/ol-simple.json Normal file
View File

@@ -0,0 +1,38 @@
{
// If ambiguate-properties and disambiguate-properties are set to true
// we get function names like "ol_control_Control_prototype$setMap" in
// the compiled code when using the SIMPLE compilation. It looks like
// "ambiguate-properties" and "disambiguate-properties" are only
// appropriate for ADVANCED compilation.
"ambiguate-properties": false,
"disambiguate-properties": false,
"id": "ol-simple",
"externs": [
"//json.js",
"../externs/bingmaps.js",
"../externs/geojson.js",
"../externs/oli.js",
"../externs/proj4js.js",
"../externs/tilejson.js",
"../externs/w3c_device_sensor_event.js"
],
"inherits": "ol.json",
"inputs": [
"../build/src/internal/src/requireall.js",
"../build/src/internal/src/types.js"
],
"mode": "SIMPLE",
// Note: we can't have a (function(){%output%})() output wrapper with
// WHITESPACE and SIMPLE modes. See this link for explanations:
// https://groups.google.com/forum/#!topic/plovr/gQyZEa2NpsU
"output-wrapper": "%output%"
}

View File

@@ -0,0 +1,41 @@
{
"id": "ol-whitespace",
// If ambiguate-properties and disambiguate-properties are set to true
// we get function names like "ol_control_Control_prototype$setMap" in
// the compiled code when using the SIMPLE compilation. It looks like
// "ambiguate-properties" and "disambiguate-properties" are only
// appropriate for ADVANCED compilation. To be sure we also don't
// set them for WHITESPACE.
"ambiguate-properties": false,
"disambiguate-properties": false,
"externs": [
"//json.js",
"../externs/bingmaps.js",
"../externs/geojson.js",
"../externs/oli.js",
"../externs/proj4js.js",
"../externs/tilejson.js",
"../externs/w3c_device_sensor_event.js"
],
"inherits": "ol.json",
"inputs": [
"../build/src/internal/src/requireall.js",
"../build/src/internal/src/types.js"
],
"mode": "WHITESPACE",
// Note: we can't have a (function(){%output%})() output wrapper with
// WHITESPACE and SIMPLE modes. See this link for explanations:
// https://groups.google.com/forum/#!topic/plovr/gQyZEa2NpsU
"output-wrapper": "%output%",
"pretty-print": true
}

39
buildcfg/ol.json Normal file
View File

@@ -0,0 +1,39 @@
{
"id": "ol",
"css-allowed-unrecognized-properties": [
"user-select"
],
"css-inputs": [
"../css/ol.css"
],
"css-output-file": "../build/ol.css",
"externs": [
"//json.js",
"../build/src/external/externs/types.js",
"../externs/bingmaps.js",
"../externs/geojson.js",
"../externs/oli.js",
"../externs/proj4js.js",
"../externs/tilejson.js",
"../externs/w3c_device_sensor_event.js"
],
"inherits": "base.json",
"inputs": [
"../build/src/external/src/exports.js",
"../build/src/external/src/types.js"
],
"output-wrapper": "(function(){%output%})();",
"paths": [
"../src"
]
}

16
buildcfg/test.json Normal file
View File

@@ -0,0 +1,16 @@
{
"id": "test",
"inherits": "base.json",
"inputs": [
"../build/test/requireall.js"
],
"paths": [
"../src",
"../test"
]
}

204
css/ol.css Normal file
View File

@@ -0,0 +1,204 @@
.ol-attribution {
position: absolute;
text-align: right;
color: #eeeeee;
bottom: 0;
right: 0;
background: rgba(0,60,136,0.3);
font-family: 'Lucida Grande',Verdana,Geneva,Lucida,Arial,Helvetica,sans-serif;
padding: 6px;
}
.ol-attribution a {
color: white;
text-decoration: none;
}
.ol-attribution ul {
margin: 0;
padding: 0;
font-size: 10px;
line-height: 12px;
}
.ol-attribution li {
display: inline;
list-style: none;
line-height: inherit;
}
.ol-attribution li:not(:last-child):after {
content: "\2003";
}
.ol-dragbox {
position: absolute;
border: 2px solid red;
}
.ol-full-screen {
background: rgba(255,255,255,0.4);
border-radius: 4px;
padding: 2px;
position: absolute;
right: 8px;
top: 8px;
}
@media print {
.ol-full-screen {
display: none;
}
}
.ol-full-screen a {
background: rgba(0,60,136,0.5);
color: white;
display: block;
font-family: 'Lucida Grande',Verdana,Geneva,Lucida,Arial,Helvetica,sans-serif;
font-size: 18px;
font-weight: bold;
height: 22px;
line-height: 19px;
margin: 1px;
padding: 0;
text-align: center;
text-decoration: none;
width: 22px;
}
a.ol-full-screen-false:after {
content: "\2194";
}
a.ol-full-screen-true:after {
content: "\00d7";
}
.ol-full-screen div {
border-radius: 2px;
}
.ol-full-screen div a {
border-radius: 2px;
}
.ol-full-screen a:hover {
background: rgba(0,60,136,0.7);
}
.ol-logo {
bottom: 0;
left: 0;
padding: 2px;
position: absolute;
}
.ol-logo ul {
margin: 0;
}
.ol-logo ul li {
display: inline;
list-style: none;
}
.ol-mouse-position {
top: 8px;
right: 8px;
position: absolute;
}
.ol-scale-line {
background: rgba(0,60,136,0.3);
border-radius: 4px;
bottom: 8px;
left: 8px;
padding: 2px;
position: absolute;
}
.ol-scale-line-inner {
border: 1px solid #eeeeee;
border-top: none;
color: #eeeeee;
font-size: 10px;
font-family: 'Lucida Grande',Verdana,Geneva,Lucida,Arial,Helvetica,sans-serif;
text-align: center;
margin: 1px;
padding: 0px 2px;
}
.ol-unsupported {
display: none;
}
.ol-viewport .ol-unselectable {
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
-webkit-tap-highlight-color: rgba(0,0,0,0);
}
.ol-zoom {
position: absolute;
top: 8px;
left: 8px;
background: rgba(255,255,255,0.4);
border-radius: 4px;
padding: 2px;
}
@media print {
.ol-zoom {
display: none;
}
}
.ol-zoom a {
display: block;
margin: 1px;
padding: 0;
color: white;
font-size: 18px;
font-family: 'Lucida Grande',Verdana,Geneva,Lucida,Arial,Helvetica,sans-serif;
font-weight: bold;
text-decoration: none;
text-align: center;
height: 22px;
width: 22px;
line-height: 19px;
background: rgba(0,60,136,0.5);
}
.ol-touch .ol-zoom a {
font-size: 20px;
height: 30px;
width: 30px;
line-height: 26px;
}
.ol-zoom a:hover {
background: rgba(0,60,136,0.7);
}
.ol-zoom-in {
border-radius: 2px 2px 0 0;
}
.ol-zoom-in:before {
content: "+";
}
.ol-zoom-out {
border-radius: 0 0 2px 2px;
}
.ol-zoom-out:before {
content: "\2212";
}
.ol-zoomslider {
position: absolute;
top: 67px;
left: 8px;
background: rgba(255, 255, 255, 0.4);
border-radius: 4px;
width: 28px;
height: 200px;
outline: none;
overflow: hidden;
padding: 0;
margin: 0;
}
.ol-zoomslider-thumb {
position: absolute;
display: block;
padding: 0;
margin: 2px;
background: rgba(0,60,136,0.5);
border-radius: 2px;
outline: none;
overflow: hidden;
height: 20px;
width: 24px;
}

30
doc/conf.json Normal file
View File

@@ -0,0 +1,30 @@
{
"opts": {
"recurse": true,
"template": "doc/template",
"tutorials": "doc/tutorials"
},
"tags": {
"allowUnknownTags": true
},
"source": {
"includePattern": ".+\\.js(doc)?$",
"excludePattern": "(^|\\/|\\\\)_"
},
"plugins": [
"plugins/markdown",
"doc/plugins/inheritdoc",
"doc/plugins/exports"
],
"markdown": {
"parser": "gfm"
},
"templates": {
"cleverLinks": false,
"monospaceLinks": false,
"default": {
"outputSourceFiles": true
}
},
"jsVersion": 180
}

17
doc/index.md Normal file
View File

@@ -0,0 +1,17 @@
Finding your way around
-----------------------
See the class list to the right and especially take a look at {@link ol.Map} and {@link ol.layer.Layer} because those are the central objects.
In general every use of OpenLayers starts by initializing a map, then adding the required layers. Controls and interactions can be added to change the behavior of the map.
Projections
-----------
A {@link ol.Projection} defines which point on earth is represented by a pair of coordinates. Coordinates within OpenLayers can be used in various projections where some common projections are always supported, others can be used via Proj4js.
Maps and Layers
---------------
A map in OpenLayers is essentially a staple of layers that is viewed from the top. Layers are responsible for retieving data and displaying it.
Contributing
------------
See CONTRIBUTING.md for instructions on building and tesing OpenLayers. The file does also describe how to commit your changes to OpenLayers.

94
doc/plugins/exports.js Normal file
View File

@@ -0,0 +1,94 @@
/*
* This plugin parses goog.exportSymbol and goog.exportProperty calls to build
* a list of API symbols and properties. Everything else is marked undocumented,
* which will remove it from the docs.
*/
var api = [];
function collectExports(source) {
var i, ii, symbol, property;
var syms = source.match(/goog\.exportSymbol\([^\)]*\)/g);
if (syms) {
i = 0; ii = syms.length;
for (; i < ii; ++i) {
symbol = syms[i].match(/'([^']*)'/)[1];
api.push(symbol);
}
}
var props = source.match(/goog\.exportProperty\([^\)]*\)/g);
if (props) {
i = 0; ii = props.length;
for (; i < ii; ++i) {
property = props[i].match(/[^,]*,[^,]*,\r?\n? *([^\)]*)\)/)[1]
.replace('.prototype.', '#');
api.push(property);
}
}
}
var encoding = env.conf.encoding || 'utf8';
var fs = require('jsdoc/fs');
collectExports(fs.readFileSync('build/src/external/src/exports.js', encoding));
collectExports(fs.readFileSync('build/src/external/src/types.js', encoding));
exports.handlers = {
beforeParse: function(e) {
if (/\.js$/.test(e.filename)) {
collectExports(e.source);
}
},
newDoclet: function(e) {
if (api.indexOf(e.doclet.longname) > -1) {
// Add params of API symbols to the API
var names, name;
var params = e.doclet.params;
if (params) {
for (var i = 0, ii = params.length; i < ii; ++i) {
names = params[i].type.names;
if (names) {
for (var j = 0, jj=names.length; j < jj; ++j) {
name = names[j];
if (api.indexOf(name) === -1) {
api.push(name);
}
}
}
}
}
}
}
};
function filter(e) {
if (e.doclet) {
var fqn = e.doclet.longname;
if (fqn) {
e.doclet.undocumented = (api.indexOf(fqn) === -1);
// Remove parents that are not part of the API
var parent;
var parents = e.doclet.augments;
if (parents) {
for (var i = parents.length - 1; i >= 0; --i) {
parent = parents[i];
if (api.indexOf(parent) === -1) {
parents.splice(i, 1);
}
}
}
}
}
}
exports.nodeVisitor = {
visitNode: function(node, e, parser, currentSourceName) {
// filter out non-API symbols before the addDocletRef finisher is called
e.finishers.unshift(filter);
}
};

16
doc/plugins/inheritdoc.js Normal file
View File

@@ -0,0 +1,16 @@
/*
* This is a hack to prevent inheritDoc and override tags from entirely removing
* documentation of the method that inherits the documentation.
*
* TODO: Remove this hack when https://github.com/jsdoc3/jsdoc/issues/53
* is addressed.
*/
exports.nodeVisitor = {
visitNode: function(node, e, parser, currentSourceName) {
if (/@(inheritDoc|override)(\n|\r)/.test(e.comment)) {
e.preventDefault = true;
}
}
};

1
doc/template/README.md vendored Normal file
View File

@@ -0,0 +1 @@
The default template for JSDoc 3 uses: [the Taffy Database library](http://taffydb.com/) and the [Underscore Template library](http://documentcloud.github.com/underscore/#template).

392
doc/template/publish.js vendored Normal file
View File

@@ -0,0 +1,392 @@
/*global env: true */
var template = require('jsdoc/template'),
fs = require('fs'),
path = require('path'),
taffy = require('taffydb').taffy,
helper = require('jsdoc/util/templateHelper'),
scopeToPunc = helper.scopeToPunc,
hasOwnProp = Object.prototype.hasOwnProperty,
data,
view,
outdir = env.opts.destination;
function find(spec) {
return helper.find(data, spec);
}
function tutoriallink(tutorial) {
return helper.toTutorial(tutorial, null, { tag: 'em', classname: 'disabled', prefix: 'Tutorial: ' });
}
function getAncestorLinks(doclet) {
return helper.getAncestorLinks(data, doclet);
}
var linkto = helper.linkto;
var htmlsafe = helper.htmlsafe;
function hashToLink(doclet, hash) {
if ( !/^(#.+)/.test(hash) ) { return hash; }
var url = helper.createLink(doclet);
url = url.replace(/(#.+|$)/, hash);
return '<a href="' + url + '">' + hash + '</a>';
}
function addSignatureParams(f) {
var params = helper.getSignatureParams(f, 'optional');
f.signature = (f.signature || '') + '('+params.join(', ')+')';
}
function addSignatureReturns(f) {
var returnTypes = helper.getSignatureReturns(f);
f.signature = '<span class="signature">'+(f.signature || '') + '</span>' + '<span class="type-signature">'+(returnTypes.length? ' &rarr; {'+returnTypes.join('|')+'}' : '')+'</span>';
}
function addSignatureTypes(f) {
var types = helper.getSignatureTypes(f);
f.signature = (f.signature || '') + '<span class="type-signature">'+(types.length? ' :'+types.join('|') : '')+'</span>';
}
function addAttribs(f) {
var attribs = helper.getAttribs(f);
f.attribs = '<span class="type-signature">'+htmlsafe(attribs.length? '<'+attribs.join(', ')+'> ' : '')+'</span>';
}
function generate(title, docs, filename) {
var docData = {
title: title,
docs: docs
};
var outpath = path.join(outdir, filename),
html = view.render('container.tmpl', docData);
html = helper.resolveLinks(html); // turn {@link foo} into <a href="foodoc.html">foo</a>
fs.writeFileSync(outpath, html, 'utf8');
}
/**
* Create the navigation sidebar.
* @param {object} members The members that will be used to create the sidebar.
* @param {array<object>} members.classes
* @param {array<object>} members.externals
* @param {array<object>} members.globals
* @param {array<object>} members.mixins
* @param {array<object>} members.modules
* @param {array<object>} members.namespaces
* @param {array<object>} members.tutorials
* @return {string} The HTML for the navigation sidebar.
*/
function buildNav(members) {
var nav = '<h2><a href="index.html">Index</a></h2>',
seen = {};
/**
* Sorts elements by their qualified names (property longname).
* See https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/sort
* @param {object} a
* @param {object} b
* @return {number}
*/
function byLongName(a, b){
if(a.longname===b.longname){
return 0;
} else if(a.longname < b.longname){
return -1;
} else {
return 1;
}
}
if (members.modules.length) {
nav += '<h3>Modules</h3><ul>';
members.modules.sort(byLongName).forEach(function(m) {
if ( !hasOwnProp.call(seen, m.longname) ) {
nav += '<li>'+linkto(m.longname, m.longname)+'</li>';
}
seen[m.longname] = true;
});
nav += '</ul>';
}
if (members.externals.length) {
nav += '<h3>Externals</h3><ul>';
members.externals.sort(byLongName).forEach(function(e) {
if ( !hasOwnProp.call(seen, e.longname) ) {
nav += '<li>'+linkto( e.longname, e.name.replace(/(^"|"$)/g, '') )+'</li>';
}
seen[e.longname] = true;
});
nav += '</ul>';
}
if (members.classes.length) {
var moduleClasses = 0;
members.classes.sort(byLongName).forEach(function(c) {
var moduleSameName = find({kind: 'module', longname: c.longname});
if (moduleSameName.length) {
c.name = c.name.replace('module:', 'require("')+'")';
moduleClasses++;
moduleSameName[0].module = c;
}
if (moduleClasses !== -1 && moduleClasses < members.classes.length) {
nav += '<h3>Classes</h3><ul>';
moduleClasses = -1;
}
if ( !hasOwnProp.call(seen, c.longname) ) {
nav += '<li>'+linkto(c.longname, c.longname)+'</li>';
}
seen[c.longname] = true;
});
nav += '</ul>';
}
if (members.namespaces.length) {
nav += '<h3>Namespaces</h3><ul>';
members.namespaces.sort(byLongName).forEach(function(n) {
if ( !hasOwnProp.call(seen, n.longname) ) {
nav += '<li>'+linkto(n.longname, n.longname)+'</li>';
}
seen[n.longname] = true;
});
nav += '</ul>';
}
if (members.mixins.length) {
nav += '<h3>Mixins</h3><ul>';
members.mixins.sort(byLongName).forEach(function(m) {
if ( !hasOwnProp.call(seen, m.longname) ) {
nav += '<li>'+linkto(m.longname, m.longname)+'</li>';
}
seen[m.longname] = true;
});
nav += '</ul>';
}
if (members.tutorials.length) {
nav += '<h3>Tutorials</h3><ul>';
members.tutorials.sort(byLongName).forEach(function(t) {
nav += '<li>'+tutoriallink(t.name)+'</li>';
});
nav += '</ul>';
}
if (members.globals.length) {
nav += '<h3>Global</h3><ul>';
members.globals.sort(byLongName).forEach(function(g) {
if ( g.kind !== 'typedef' && !hasOwnProp.call(seen, g.longname) ) {
nav += '<li>'+linkto(g.longname, g.longname)+'</li>';
}
seen[g.longname] = true;
});
nav += '</ul>';
}
return nav;
}
/**
@param {TAFFY} taffyData See <http://taffydb.com/>.
@param {object} opts
@param {Tutorial} tutorials
*/
exports.publish = function(taffyData, opts, tutorials) {
data = taffyData;
var templatePath = opts.template;
view = new template.Template(templatePath + '/tmpl');
// set up templating
view.layout = 'layout.tmpl';
// set up tutorials for helper
helper.setTutorials(tutorials);
data = helper.prune(data);
data.sort('longname, version, since');
data().each(function(doclet) {
doclet.attribs = '';
if (doclet.examples) {
doclet.examples = doclet.examples.map(function(example) {
var caption, code;
if (example.match(/^\s*<caption>([\s\S]+?)<\/caption>(\s*[\n\r])([\s\S]+)$/i)) {
caption = RegExp.$1;
code = RegExp.$3;
}
return {
caption: caption || '',
code: code || example
};
});
}
if (doclet.see) {
doclet.see.forEach(function(seeItem, i) {
doclet.see[i] = hashToLink(doclet, seeItem);
});
}
});
// update outdir if necessary, then create outdir
var packageInfo = ( find({kind: 'package'}) || [] ) [0];
if (packageInfo && packageInfo.name) {
outdir = path.join(outdir, packageInfo.name, packageInfo.version);
}
fs.mkPath(outdir);
// copy static files to outdir
var fromDir = path.join(templatePath, 'static'),
staticFiles = fs.ls(fromDir, 3);
staticFiles.forEach(function(fileName) {
var toDir = fs.toDir( fileName.replace(fromDir, outdir) );
fs.mkPath(toDir);
fs.copyFileSync(fileName, toDir);
});
data().each(function(doclet) {
var url = helper.createLink(doclet);
helper.registerLink(doclet.longname, url);
});
data().each(function(doclet) {
var url = helper.longnameToUrl[doclet.longname];
if (url.indexOf('#') > -1) {
doclet.id = helper.longnameToUrl[doclet.longname].split(/#/).pop();
}
else {
doclet.id = doclet.name;
}
if (doclet.kind === 'function' || doclet.kind === 'class') {
addSignatureParams(doclet);
addSignatureReturns(doclet);
addAttribs(doclet);
}
});
// do this after the urls have all been generated
data().each(function(doclet) {
doclet.ancestors = getAncestorLinks(doclet);
doclet.signature = '';
if (doclet.kind === 'member') {
addSignatureTypes(doclet);
addAttribs(doclet);
}
if (doclet.kind === 'constant') {
addSignatureTypes(doclet);
addAttribs(doclet);
doclet.kind = 'member';
}
});
var members = helper.getMembers(data);
members.tutorials = tutorials.children;
// add template helpers
view.find = find;
view.linkto = linkto;
view.tutoriallink = tutoriallink;
view.htmlsafe = htmlsafe;
// once for all
view.nav = buildNav(members);
for (var longname in helper.longnameToUrl) {
if ( hasOwnProp.call(helper.longnameToUrl, longname) ) {
// reuse 'members', which speeds things up a bit
var classes = taffy(members.classes);
classes = helper.find(classes, {longname: longname});
if (classes.length) {
generate('Class: ' + classes[0].longname, classes, helper.longnameToUrl[longname]);
}
var modules = taffy(members.modules);
modules = helper.find(modules, {longname: longname});
if (modules.length) {
generate('Module: ' + modules[0].longname, modules, helper.longnameToUrl[longname]);
}
var namespaces = taffy(members.namespaces);
namespaces = helper.find(namespaces, {longname: longname});
if (namespaces.length) {
generate('Namespace: ' + namespaces[0].longname, namespaces, helper.longnameToUrl[longname]);
}
var mixins = taffy(members.mixins);
mixins = helper.find(mixins, {longname: longname});
if (mixins.length) {
generate('Mixin: ' + mixins[0].longname, mixins, helper.longnameToUrl[longname]);
}
var externals = taffy(members.externals);
externals = helper.find(externals, {longname: longname});
if (externals.length) {
generate('External: ' + externals[0].longname, externals, helper.longnameToUrl[longname]);
}
}
}
if (members.globals.length) { generate('Global', members.globals, 'global.html'); }
// index page displays information from package.json and lists files
var files = find({kind: 'file'}),
packages = find({kind: 'package'});
generate('Index',
packages.concat(
[{kind: 'mainpage', readme: opts.readme, longname: (opts.mainpagetitle) ? opts.mainpagetitle : 'Main Page'}]
).concat(files),
'index.html');
// TODO: move the tutorial functions to templateHelper.js
function generateTutorial(title, tutorial, filename) {
var tutorialData = {
title: title,
header: tutorial.title,
content: tutorial.parse(),
children: tutorial.children
};
var tutorialPath = path.join(outdir, filename),
html = view.render('tutorial.tmpl', tutorialData);
// yes, you can use {@link} in tutorials too!
html = helper.resolveLinks(html); // turn {@link foo} into <a href="foodoc.html">foo</a>
fs.writeFileSync(tutorialPath, html, 'utf8');
}
// tutorials can have only one parent so there is no risk for loops
function saveChildren(node) {
node.children.forEach(function(child) {
generateTutorial('Tutorial: ' + child.title, child, helper.tutorialToUrl(child.name));
saveChildren(child);
});
}
saveChildren(tutorials);
};

View File

@@ -0,0 +1,202 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

View File

@@ -0,0 +1,2 @@
PR.registerLangHandler(PR.createSimpleLexer([["pln",/^[\t\n\f\r ]+/,null," \t\r\n "]],[["str",/^"(?:[^\n\f\r"\\]|\\(?:\r\n?|\n|\f)|\\[\S\s])*"/,null],["str",/^'(?:[^\n\f\r'\\]|\\(?:\r\n?|\n|\f)|\\[\S\s])*'/,null],["lang-css-str",/^url\(([^"')]*)\)/i],["kwd",/^(?:url|rgb|!important|@import|@page|@media|@charset|inherit)(?=[^\w-]|$)/i,null],["lang-css-kw",/^(-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*)\s*:/i],["com",/^\/\*[^*]*\*+(?:[^*/][^*]*\*+)*\//],["com",
/^(?:<\!--|--\>)/],["lit",/^(?:\d+|\d*\.\d+)(?:%|[a-z]+)?/i],["lit",/^#[\da-f]{3,6}/i],["pln",/^-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*/i],["pun",/^[^\s\w"']+/]]),["css"]);PR.registerLangHandler(PR.createSimpleLexer([],[["kwd",/^-?(?:[_a-z]|\\[\da-f]+ ?)(?:[\w-]|\\\\[\da-f]+ ?)*/i]]),["css-kw"]);PR.registerLangHandler(PR.createSimpleLexer([],[["str",/^[^"')]+/]]),["css-str"]);

View File

@@ -0,0 +1,28 @@
var q=null;window.PR_SHOULD_USE_CONTINUATION=!0;
(function(){function L(a){function m(a){var f=a.charCodeAt(0);if(f!==92)return f;var b=a.charAt(1);return(f=r[b])?f:"0"<=b&&b<="7"?parseInt(a.substring(1),8):b==="u"||b==="x"?parseInt(a.substring(2),16):a.charCodeAt(1)}function e(a){if(a<32)return(a<16?"\\x0":"\\x")+a.toString(16);a=String.fromCharCode(a);if(a==="\\"||a==="-"||a==="["||a==="]")a="\\"+a;return a}function h(a){for(var f=a.substring(1,a.length-1).match(/\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\[0-3][0-7]{0,2}|\\[0-7]{1,2}|\\[\S\s]|[^\\]/g),a=
[],b=[],o=f[0]==="^",c=o?1:0,i=f.length;c<i;++c){var j=f[c];if(/\\[bdsw]/i.test(j))a.push(j);else{var j=m(j),d;c+2<i&&"-"===f[c+1]?(d=m(f[c+2]),c+=2):d=j;b.push([j,d]);d<65||j>122||(d<65||j>90||b.push([Math.max(65,j)|32,Math.min(d,90)|32]),d<97||j>122||b.push([Math.max(97,j)&-33,Math.min(d,122)&-33]))}}b.sort(function(a,f){return a[0]-f[0]||f[1]-a[1]});f=[];j=[NaN,NaN];for(c=0;c<b.length;++c)i=b[c],i[0]<=j[1]+1?j[1]=Math.max(j[1],i[1]):f.push(j=i);b=["["];o&&b.push("^");b.push.apply(b,a);for(c=0;c<
f.length;++c)i=f[c],b.push(e(i[0])),i[1]>i[0]&&(i[1]+1>i[0]&&b.push("-"),b.push(e(i[1])));b.push("]");return b.join("")}function y(a){for(var f=a.source.match(/\[(?:[^\\\]]|\\[\S\s])*]|\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\\d+|\\[^\dux]|\(\?[!:=]|[()^]|[^()[\\^]+/g),b=f.length,d=[],c=0,i=0;c<b;++c){var j=f[c];j==="("?++i:"\\"===j.charAt(0)&&(j=+j.substring(1))&&j<=i&&(d[j]=-1)}for(c=1;c<d.length;++c)-1===d[c]&&(d[c]=++t);for(i=c=0;c<b;++c)j=f[c],j==="("?(++i,d[i]===void 0&&(f[c]="(?:")):"\\"===j.charAt(0)&&
(j=+j.substring(1))&&j<=i&&(f[c]="\\"+d[i]);for(i=c=0;c<b;++c)"^"===f[c]&&"^"!==f[c+1]&&(f[c]="");if(a.ignoreCase&&s)for(c=0;c<b;++c)j=f[c],a=j.charAt(0),j.length>=2&&a==="["?f[c]=h(j):a!=="\\"&&(f[c]=j.replace(/[A-Za-z]/g,function(a){a=a.charCodeAt(0);return"["+String.fromCharCode(a&-33,a|32)+"]"}));return f.join("")}for(var t=0,s=!1,l=!1,p=0,d=a.length;p<d;++p){var g=a[p];if(g.ignoreCase)l=!0;else if(/[a-z]/i.test(g.source.replace(/\\u[\da-f]{4}|\\x[\da-f]{2}|\\[^UXux]/gi,""))){s=!0;l=!1;break}}for(var r=
{b:8,t:9,n:10,v:11,f:12,r:13},n=[],p=0,d=a.length;p<d;++p){g=a[p];if(g.global||g.multiline)throw Error(""+g);n.push("(?:"+y(g)+")")}return RegExp(n.join("|"),l?"gi":"g")}function M(a){function m(a){switch(a.nodeType){case 1:if(e.test(a.className))break;for(var g=a.firstChild;g;g=g.nextSibling)m(g);g=a.nodeName;if("BR"===g||"LI"===g)h[s]="\n",t[s<<1]=y++,t[s++<<1|1]=a;break;case 3:case 4:g=a.nodeValue,g.length&&(g=p?g.replace(/\r\n?/g,"\n"):g.replace(/[\t\n\r ]+/g," "),h[s]=g,t[s<<1]=y,y+=g.length,
t[s++<<1|1]=a)}}var e=/(?:^|\s)nocode(?:\s|$)/,h=[],y=0,t=[],s=0,l;a.currentStyle?l=a.currentStyle.whiteSpace:window.getComputedStyle&&(l=document.defaultView.getComputedStyle(a,q).getPropertyValue("white-space"));var p=l&&"pre"===l.substring(0,3);m(a);return{a:h.join("").replace(/\n$/,""),c:t}}function B(a,m,e,h){m&&(a={a:m,d:a},e(a),h.push.apply(h,a.e))}function x(a,m){function e(a){for(var l=a.d,p=[l,"pln"],d=0,g=a.a.match(y)||[],r={},n=0,z=g.length;n<z;++n){var f=g[n],b=r[f],o=void 0,c;if(typeof b===
"string")c=!1;else{var i=h[f.charAt(0)];if(i)o=f.match(i[1]),b=i[0];else{for(c=0;c<t;++c)if(i=m[c],o=f.match(i[1])){b=i[0];break}o||(b="pln")}if((c=b.length>=5&&"lang-"===b.substring(0,5))&&!(o&&typeof o[1]==="string"))c=!1,b="src";c||(r[f]=b)}i=d;d+=f.length;if(c){c=o[1];var j=f.indexOf(c),k=j+c.length;o[2]&&(k=f.length-o[2].length,j=k-c.length);b=b.substring(5);B(l+i,f.substring(0,j),e,p);B(l+i+j,c,C(b,c),p);B(l+i+k,f.substring(k),e,p)}else p.push(l+i,b)}a.e=p}var h={},y;(function(){for(var e=a.concat(m),
l=[],p={},d=0,g=e.length;d<g;++d){var r=e[d],n=r[3];if(n)for(var k=n.length;--k>=0;)h[n.charAt(k)]=r;r=r[1];n=""+r;p.hasOwnProperty(n)||(l.push(r),p[n]=q)}l.push(/[\S\s]/);y=L(l)})();var t=m.length;return e}function u(a){var m=[],e=[];a.tripleQuotedStrings?m.push(["str",/^(?:'''(?:[^'\\]|\\[\S\s]|''?(?=[^']))*(?:'''|$)|"""(?:[^"\\]|\\[\S\s]|""?(?=[^"]))*(?:"""|$)|'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$))/,q,"'\""]):a.multiLineStrings?m.push(["str",/^(?:'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$)|`(?:[^\\`]|\\[\S\s])*(?:`|$))/,
q,"'\"`"]):m.push(["str",/^(?:'(?:[^\n\r'\\]|\\.)*(?:'|$)|"(?:[^\n\r"\\]|\\.)*(?:"|$))/,q,"\"'"]);a.verbatimStrings&&e.push(["str",/^@"(?:[^"]|"")*(?:"|$)/,q]);var h=a.hashComments;h&&(a.cStyleComments?(h>1?m.push(["com",/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,q,"#"]):m.push(["com",/^#(?:(?:define|elif|else|endif|error|ifdef|include|ifndef|line|pragma|undef|warning)\b|[^\n\r]*)/,q,"#"]),e.push(["str",/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h|[a-z]\w*)>/,q])):m.push(["com",/^#[^\n\r]*/,
q,"#"]));a.cStyleComments&&(e.push(["com",/^\/\/[^\n\r]*/,q]),e.push(["com",/^\/\*[\S\s]*?(?:\*\/|$)/,q]));a.regexLiterals&&e.push(["lang-regex",/^(?:^^\.?|[!+-]|!=|!==|#|%|%=|&|&&|&&=|&=|\(|\*|\*=|\+=|,|-=|->|\/|\/=|:|::|;|<|<<|<<=|<=|=|==|===|>|>=|>>|>>=|>>>|>>>=|[?@[^]|\^=|\^\^|\^\^=|{|\||\|=|\|\||\|\|=|~|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\s*(\/(?=[^*/])(?:[^/[\\]|\\[\S\s]|\[(?:[^\\\]]|\\[\S\s])*(?:]|$))+\/)/]);(h=a.types)&&e.push(["typ",h]);a=(""+a.keywords).replace(/^ | $/g,
"");a.length&&e.push(["kwd",RegExp("^(?:"+a.replace(/[\s,]+/g,"|")+")\\b"),q]);m.push(["pln",/^\s+/,q," \r\n\t\xa0"]);e.push(["lit",/^@[$_a-z][\w$@]*/i,q],["typ",/^(?:[@_]?[A-Z]+[a-z][\w$@]*|\w+_t\b)/,q],["pln",/^[$_a-z][\w$@]*/i,q],["lit",/^(?:0x[\da-f]+|(?:\d(?:_\d+)*\d*(?:\.\d*)?|\.\d\+)(?:e[+-]?\d+)?)[a-z]*/i,q,"0123456789"],["pln",/^\\[\S\s]?/,q],["pun",/^.[^\s\w"-$'./@\\`]*/,q]);return x(m,e)}function D(a,m){function e(a){switch(a.nodeType){case 1:if(k.test(a.className))break;if("BR"===a.nodeName)h(a),
a.parentNode&&a.parentNode.removeChild(a);else for(a=a.firstChild;a;a=a.nextSibling)e(a);break;case 3:case 4:if(p){var b=a.nodeValue,d=b.match(t);if(d){var c=b.substring(0,d.index);a.nodeValue=c;(b=b.substring(d.index+d[0].length))&&a.parentNode.insertBefore(s.createTextNode(b),a.nextSibling);h(a);c||a.parentNode.removeChild(a)}}}}function h(a){function b(a,d){var e=d?a.cloneNode(!1):a,f=a.parentNode;if(f){var f=b(f,1),g=a.nextSibling;f.appendChild(e);for(var h=g;h;h=g)g=h.nextSibling,f.appendChild(h)}return e}
for(;!a.nextSibling;)if(a=a.parentNode,!a)return;for(var a=b(a.nextSibling,0),e;(e=a.parentNode)&&e.nodeType===1;)a=e;d.push(a)}var k=/(?:^|\s)nocode(?:\s|$)/,t=/\r\n?|\n/,s=a.ownerDocument,l;a.currentStyle?l=a.currentStyle.whiteSpace:window.getComputedStyle&&(l=s.defaultView.getComputedStyle(a,q).getPropertyValue("white-space"));var p=l&&"pre"===l.substring(0,3);for(l=s.createElement("LI");a.firstChild;)l.appendChild(a.firstChild);for(var d=[l],g=0;g<d.length;++g)e(d[g]);m===(m|0)&&d[0].setAttribute("value",
m);var r=s.createElement("OL");r.className="linenums";for(var n=Math.max(0,m-1|0)||0,g=0,z=d.length;g<z;++g)l=d[g],l.className="L"+(g+n)%10,l.firstChild||l.appendChild(s.createTextNode("\xa0")),r.appendChild(l);a.appendChild(r)}function k(a,m){for(var e=m.length;--e>=0;){var h=m[e];A.hasOwnProperty(h)?window.console&&console.warn("cannot override language handler %s",h):A[h]=a}}function C(a,m){if(!a||!A.hasOwnProperty(a))a=/^\s*</.test(m)?"default-markup":"default-code";return A[a]}function E(a){var m=
a.g;try{var e=M(a.h),h=e.a;a.a=h;a.c=e.c;a.d=0;C(m,h)(a);var k=/\bMSIE\b/.test(navigator.userAgent),m=/\n/g,t=a.a,s=t.length,e=0,l=a.c,p=l.length,h=0,d=a.e,g=d.length,a=0;d[g]=s;var r,n;for(n=r=0;n<g;)d[n]!==d[n+2]?(d[r++]=d[n++],d[r++]=d[n++]):n+=2;g=r;for(n=r=0;n<g;){for(var z=d[n],f=d[n+1],b=n+2;b+2<=g&&d[b+1]===f;)b+=2;d[r++]=z;d[r++]=f;n=b}for(d.length=r;h<p;){var o=l[h+2]||s,c=d[a+2]||s,b=Math.min(o,c),i=l[h+1],j;if(i.nodeType!==1&&(j=t.substring(e,b))){k&&(j=j.replace(m,"\r"));i.nodeValue=
j;var u=i.ownerDocument,v=u.createElement("SPAN");v.className=d[a+1];var x=i.parentNode;x.replaceChild(v,i);v.appendChild(i);e<o&&(l[h+1]=i=u.createTextNode(t.substring(b,o)),x.insertBefore(i,v.nextSibling))}e=b;e>=o&&(h+=2);e>=c&&(a+=2)}}catch(w){"console"in window&&console.log(w&&w.stack?w.stack:w)}}var v=["break,continue,do,else,for,if,return,while"],w=[[v,"auto,case,char,const,default,double,enum,extern,float,goto,int,long,register,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"],
"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"],F=[w,"alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,dynamic_cast,explicit,export,friend,inline,late_check,mutable,namespace,nullptr,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"],G=[w,"abstract,boolean,byte,extends,final,finally,implements,import,instanceof,null,native,package,strictfp,super,synchronized,throws,transient"],
H=[G,"as,base,by,checked,decimal,delegate,descending,dynamic,event,fixed,foreach,from,group,implicit,in,interface,internal,into,is,lock,object,out,override,orderby,params,partial,readonly,ref,sbyte,sealed,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,var"],w=[w,"debugger,eval,export,function,get,null,set,undefined,var,with,Infinity,NaN"],I=[v,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"],
J=[v,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"],v=[v,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"],K=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float)\d*)/,N=/\S/,O=u({keywords:[F,H,w,"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END"+
I,J,v],hashComments:!0,cStyleComments:!0,multiLineStrings:!0,regexLiterals:!0}),A={};k(O,["default-code"]);k(x([],[["pln",/^[^<?]+/],["dec",/^<!\w[^>]*(?:>|$)/],["com",/^<\!--[\S\s]*?(?:--\>|$)/],["lang-",/^<\?([\S\s]+?)(?:\?>|$)/],["lang-",/^<%([\S\s]+?)(?:%>|$)/],["pun",/^(?:<[%?]|[%?]>)/],["lang-",/^<xmp\b[^>]*>([\S\s]+?)<\/xmp\b[^>]*>/i],["lang-js",/^<script\b[^>]*>([\S\s]*?)(<\/script\b[^>]*>)/i],["lang-css",/^<style\b[^>]*>([\S\s]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),
["default-markup","htm","html","mxml","xhtml","xml","xsl"]);k(x([["pln",/^\s+/,q," \t\r\n"],["atv",/^(?:"[^"]*"?|'[^']*'?)/,q,"\"'"]],[["tag",/^^<\/?[a-z](?:[\w-.:]*\w)?|\/?>$/i],["atn",/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^\s"'>]*(?:[^\s"'/>]|\/(?=\s)))/],["pun",/^[/<->]+/],["lang-js",/^on\w+\s*=\s*"([^"]+)"/i],["lang-js",/^on\w+\s*=\s*'([^']+)'/i],["lang-js",/^on\w+\s*=\s*([^\s"'>]+)/i],["lang-css",/^style\s*=\s*"([^"]+)"/i],["lang-css",/^style\s*=\s*'([^']+)'/i],["lang-css",
/^style\s*=\s*([^\s"'>]+)/i]]),["in.tag"]);k(x([],[["atv",/^[\S\s]+/]]),["uq.val"]);k(u({keywords:F,hashComments:!0,cStyleComments:!0,types:K}),["c","cc","cpp","cxx","cyc","m"]);k(u({keywords:"null,true,false"}),["json"]);k(u({keywords:H,hashComments:!0,cStyleComments:!0,verbatimStrings:!0,types:K}),["cs"]);k(u({keywords:G,cStyleComments:!0}),["java"]);k(u({keywords:v,hashComments:!0,multiLineStrings:!0}),["bsh","csh","sh"]);k(u({keywords:I,hashComments:!0,multiLineStrings:!0,tripleQuotedStrings:!0}),
["cv","py"]);k(u({keywords:"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",hashComments:!0,multiLineStrings:!0,regexLiterals:!0}),["perl","pl","pm"]);k(u({keywords:J,hashComments:!0,multiLineStrings:!0,regexLiterals:!0}),["rb"]);k(u({keywords:w,cStyleComments:!0,regexLiterals:!0}),["js"]);k(u({keywords:"all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,true,try,unless,until,when,while,yes",
hashComments:3,cStyleComments:!0,multilineStrings:!0,tripleQuotedStrings:!0,regexLiterals:!0}),["coffee"]);k(x([],[["str",/^[\S\s]+/]]),["regex"]);window.prettyPrintOne=function(a,m,e){var h=document.createElement("PRE");h.innerHTML=a;e&&D(h,e);E({g:m,i:e,h:h});return h.innerHTML};window.prettyPrint=function(a){function m(){for(var e=window.PR_SHOULD_USE_CONTINUATION?l.now()+250:Infinity;p<h.length&&l.now()<e;p++){var n=h[p],k=n.className;if(k.indexOf("prettyprint")>=0){var k=k.match(g),f,b;if(b=
!k){b=n;for(var o=void 0,c=b.firstChild;c;c=c.nextSibling)var i=c.nodeType,o=i===1?o?b:c:i===3?N.test(c.nodeValue)?b:o:o;b=(f=o===b?void 0:o)&&"CODE"===f.tagName}b&&(k=f.className.match(g));k&&(k=k[1]);b=!1;for(o=n.parentNode;o;o=o.parentNode)if((o.tagName==="pre"||o.tagName==="code"||o.tagName==="xmp")&&o.className&&o.className.indexOf("prettyprint")>=0){b=!0;break}b||((b=(b=n.className.match(/\blinenums\b(?::(\d+))?/))?b[1]&&b[1].length?+b[1]:!0:!1)&&D(n,b),d={g:k,h:n,i:b},E(d))}}p<h.length?setTimeout(m,
250):a&&a()}for(var e=[document.getElementsByTagName("pre"),document.getElementsByTagName("code"),document.getElementsByTagName("xmp")],h=[],k=0;k<e.length;++k)for(var t=0,s=e[k].length;t<s;++t)h.push(e[k][t]);var e=q,l=Date;l.now||(l={now:function(){return+new Date}});var p=0,d,g=/\blang(?:uage)?-([\w.]+)(?!\S)/;m()};window.PR={createSimpleLexer:x,registerLangHandler:k,sourceDecorator:u,PR_ATTRIB_NAME:"atn",PR_ATTRIB_VALUE:"atv",PR_COMMENT:"com",PR_DECLARATION:"dec",PR_KEYWORD:"kwd",PR_LITERAL:"lit",
PR_NOCODE:"nocode",PR_PLAIN:"pln",PR_PUNCTUATION:"pun",PR_SOURCE:"src",PR_STRING:"str",PR_TAG:"tag",PR_TYPE:"typ"}})();

View File

@@ -0,0 +1,285 @@
html
{
overflow: auto;
background-color: #fff;
}
body
{
font: 14px "DejaVu Sans Condensed", "Liberation Sans", "Nimbus Sans L", Tahoma, Geneva, "Helvetica Neue", Helvetica, Arial, sans serif;
line-height: 130%;
color: #000;
background-color: #fff;
}
a {
color: #444;
}
a:visited {
color: #444;
}
a:active {
color: #444;
}
header
{
display: block;
padding: 6px 4px;
}
.class-description {
font-style: italic;
font-family: Palatino, 'Palatino Linotype', serif;
font-size: 130%;
line-height: 140%;
margin-bottom: 1em;
margin-top: 1em;
}
#main {
float: left;
width: 100%;
}
section
{
display: block;
background-color: #fff;
padding: 12px 24px;
border-bottom: 1px solid #ccc;
margin-right: 240px;
}
.variation {
display: none;
}
.optional:after {
content: "opt";
font-size: 60%;
color: #aaa;
font-style: italic;
font-weight: lighter;
}
nav
{
display: block;
float: left;
margin-left: -230px;
margin-top: 28px;
width: 220px;
border-left: 1px solid #ccc;
padding-left: 9px;
}
nav ul {
font-family: 'Lucida Grande', 'Lucida Sans Unicode', arial, sans-serif;
font-size: 100%;
line-height: 17px;
padding:0;
margin:0;
list-style-type:none;
}
nav h2 a, nav h2 a:visited {
color: #A35A00;
text-decoration: none;
}
nav h3 {
margin-top: 12px;
}
nav li {
margin-top: 6px;
}
nav a {
color: #5C5954;
}
nav a:visited {
color: #5C5954;
}
nav a:active {
color: #5C5954;
}
footer {
display: block;
padding: 6px;
margin-top: 12px;
font-style: italic;
font-size: 90%;
}
h1
{
font-size: 200%;
font-weight: bold;
letter-spacing: -0.01em;
margin: 6px 0 9px 0;
}
h2
{
font-size: 170%;
font-weight: bold;
letter-spacing: -0.01em;
margin: 6px 0 3px 0;
}
h3
{
font-size: 150%;
font-weight: bold;
letter-spacing: -0.01em;
margin-top: 16px;
margin: 6px 0 3px 0;
}
h4
{
font-size: 130%;
font-weight: bold;
letter-spacing: -0.01em;
margin-top: 16px;
margin: 18px 0 3px 0;
color: #A35A00;
}
h5, .container-overview .subsection-title
{
font-size: 120%;
font-weight: bold;
letter-spacing: -0.01em;
margin: 8px 0 3px -16px;
}
h6
{
font-size: 100%;
letter-spacing: -0.01em;
margin: 6px 0 3px 0;
font-style: italic;
}
.protected {
display: none;
}
dt.tag-source, dd.tag-source {
display: none;
}
.ancestors { color: #999; }
.ancestors a
{
color: #999 !important;
text-decoration: none;
}
.important
{
font-weight: bold;
color: #950B02;
}
.yes-def {
text-indent: -1000px;
}
.type-signature {
color: #aaa;
}
.name, .signature {
font-family: Consolas, "Lucida Console", Monaco, monospace;
}
.details { margin-top: 14px; }
.details dt { width:110px; float:left; border-left: 2px solid #DDD; padding-left: 10px; padding-top: 6px; }
.details dd { margin-left: 50px; }
.details ul { margin: 0; }
.details ul { list-style-type: none; }
.details li { margin-left: 30px; padding-top: 6px; }
.description {
margin-bottom: 1em;
margin-left: -16px;
margin-top: 1em;
}
.code-caption
{
font-style: italic;
font-family: Palatino, 'Palatino Linotype', serif;
font-size: 107%;
margin: 0;
}
.prettyprint
{
border: 1px solid #ddd;
width: 80%;
}
.prettyprint code
{
font-family: Consolas, 'Lucida Console', Monaco, monospace;
font-size: 100%;
line-height: 18px;
display: block;
padding: 4px 12px;
margin: 0;
background-color: #fff;
color: #000;
border-left: 3px #ddd solid;
}
.params, .props
{
border-spacing: 0;
border: 0;
border-collapse: collapse;
}
.params .name, .props .name, .name code {
color: #A35A00;
font-family: Consolas, 'Lucida Console', Monaco, monospace;
font-size: 100%;
}
.params td, .params th, .props td, .props th
{
border: 1px solid #ddd;
margin: 0px;
text-align: left;
vertical-align: top;
padding: 4px 6px;
display: table-cell;
}
.params thead tr, .props thead tr
{
background-color: #ddd;
font-weight: bold;
}
.params .params thead tr, .props .props thead tr
{
background-color: #fff;
font-weight: bold;
}
.params th, .props th { border-right: 1px solid #aaa; }
.params thead .last, .props thead .last { border-right: 1px solid #ddd; }
.disabled {
color: #454545;
}

View File

@@ -0,0 +1,111 @@
/* JSDoc prettify.js theme */
/* plain text */
.pln {
color: #000000;
font-weight: normal;
font-style: normal;
}
/* string content */
.str {
color: #006400;
font-weight: normal;
font-style: normal;
}
/* a keyword */
.kwd {
color: #000000;
font-weight: bold;
font-style: normal;
}
/* a comment */
.com {
font-weight: normal;
font-style: italic;
}
/* a type name */
.typ {
color: #000000;
font-weight: normal;
font-style: normal;
}
/* a literal value */
.lit {
color: #006400;
font-weight: normal;
font-style: normal;
}
/* punctuation */
.pun {
color: #000000;
font-weight: bold;
font-style: normal;
}
/* lisp open bracket */
.opn {
color: #000000;
font-weight: bold;
font-style: normal;
}
/* lisp close bracket */
.clo {
color: #000000;
font-weight: bold;
font-style: normal;
}
/* a markup tag name */
.tag {
color: #006400;
font-weight: normal;
font-style: normal;
}
/* a markup attribute name */
.atn {
color: #006400;
font-weight: normal;
font-style: normal;
}
/* a markup attribute value */
.atv {
color: #006400;
font-weight: normal;
font-style: normal;
}
/* a declaration */
.dec {
color: #000000;
font-weight: bold;
font-style: normal;
}
/* a variable name */
.var {
color: #000000;
font-weight: normal;
font-style: normal;
}
/* a function name */
.fun {
color: #000000;
font-weight: bold;
font-style: normal;
}
/* Specify class=linenums on a pre to get line numbering */
ol.linenums {
margin-top: 0;
margin-bottom: 0;
}

View File

@@ -0,0 +1,132 @@
/* Tomorrow Theme */
/* Original theme - https://github.com/chriskempson/tomorrow-theme */
/* Pretty printing styles. Used with prettify.js. */
/* SPAN elements with the classes below are added by prettyprint. */
/* plain text */
.pln {
color: #4d4d4c; }
@media screen {
/* string content */
.str {
color: #718c00; }
/* a keyword */
.kwd {
color: #8959a8; }
/* a comment */
.com {
color: #8e908c; }
/* a type name */
.typ {
color: #4271ae; }
/* a literal value */
.lit {
color: #f5871f; }
/* punctuation */
.pun {
color: #4d4d4c; }
/* lisp open bracket */
.opn {
color: #4d4d4c; }
/* lisp close bracket */
.clo {
color: #4d4d4c; }
/* a markup tag name */
.tag {
color: #c82829; }
/* a markup attribute name */
.atn {
color: #f5871f; }
/* a markup attribute value */
.atv {
color: #3e999f; }
/* a declaration */
.dec {
color: #f5871f; }
/* a variable name */
.var {
color: #c82829; }
/* a function name */
.fun {
color: #4271ae; } }
/* Use higher contrast and text-weight for printable form. */
@media print, projection {
.str {
color: #060; }
.kwd {
color: #006;
font-weight: bold; }
.com {
color: #600;
font-style: italic; }
.typ {
color: #404;
font-weight: bold; }
.lit {
color: #044; }
.pun, .opn, .clo {
color: #440; }
.tag {
color: #006;
font-weight: bold; }
.atn {
color: #404; }
.atv {
color: #060; } }
/* Style */
/*
pre.prettyprint {
background: white;
font-family: Menlo, Monaco, Consolas, monospace;
font-size: 12px;
line-height: 1.5;
border: 1px solid #ccc;
padding: 10px; }
*/
/* Specify class=linenums on a pre to get line numbering */
ol.linenums {
margin-top: 0;
margin-bottom: 0; }
/* IE indents via margin-left */
li.L0,
li.L1,
li.L2,
li.L3,
li.L4,
li.L5,
li.L6,
li.L7,
li.L8,
li.L9 {
/* */ }
/* Alternate shading for lines */
li.L1,
li.L3,
li.L5,
li.L7,
li.L9 {
/* */ }

143
doc/template/tmpl/container.tmpl vendored Normal file
View File

@@ -0,0 +1,143 @@
<?js
var self = this;
docs.forEach(function(doc, i) {
?>
<?js if (doc.kind === 'mainpage' || (doc.kind === 'package')) { ?>
<?js= self.partial('mainpage.tmpl', doc) ?>
<?js } else { ?>
<section>
<header>
<h2><?js if (doc.ancestors && doc.ancestors.length) { ?>
<span class="ancestors"><?js= doc.ancestors.join('') ?></span>
<?js } ?>
<?js= doc.longname ?>
<?js if (doc.variation) { ?>
<sup class="variation"><?js= doc.variation ?></sup>
<?js } ?></h2>
<?js if (doc.classdesc) { ?>
<div class="class-description"><?js= doc.classdesc ?></div>
<?js } ?>
</header>
<article>
<div class="container-overview">
<?js if (doc.kind === 'module' && doc.module) { ?>
<?js= self.partial('method.tmpl', doc.module) ?>
<?js } ?>
<?js if (doc.kind === 'class') { ?>
<?js= self.partial('method.tmpl', doc) ?>
<?js } else { ?>
<?js if (doc.description) { ?>
<div class="description"><?js= doc.description ?></div>
<?js } ?>
<?js= self.partial('details.tmpl', doc) ?>
<?js if (doc.examples && doc.examples.length) { ?>
<h3>Example<?js= doc.examples.length > 1? 's':'' ?></h3>
<?js= self.partial('examples.tmpl', doc.examples) ?>
<?js } ?>
<?js } ?>
</div>
<?js if (doc.augments && doc.augments.length) { ?>
<h3 class="subsection-title">Extends</h3>
<ul><?js doc.augments.forEach(function(a) { ?>
<li><?js= self.linkto(a, a) ?></li>
<?js }); ?></ul>
<?js } ?>
<?js if (doc.mixes && doc.mixes.length) { ?>
<h3 class="subsection-title">Mixes In</h3>
<ul><?js doc.mixes.forEach(function(a) { ?>
<li><?js= self.linkto(a, a) ?></li>
<?js }); ?></ul>
<?js } ?>
<?js if (doc.requires && doc.requires.length) { ?>
<h3 class="subsection-title">Requires</h3>
<ul><?js doc.requires.forEach(function(r) { ?>
<li><?js= self.linkto(r, r) ?></li>
<?js }); ?></ul>
<?js } ?>
<?js
var classes = self.find({kind: 'class', memberof: doc.longname});
if (doc.kind !== 'globalobj' && classes && classes.length) {
?>
<h3 class="subsection-title">Classes</h3>
<dl><?js classes.forEach(function(c) { ?>
<dt><?js= self.linkto(c.longname, c.longname) ?></dt>
<dd><?js if (c.summary) { ?><?js= c.summary ?><?js } ?></dd>
<?js }); ?></dl>
<?js } ?>
<?js
var namespaces = self.find({kind: 'namespace', memberof: doc.longname});
if (doc.kind !== 'globalobj' && namespaces && namespaces.length) {
?>
<h3 class="subsection-title">Namespaces</h3>
<dl><?js namespaces.forEach(function(n) { ?>
<dt><a href="namespaces.html#<?js= n.longname ?>"><?js= self.linkto(n.longname, n.longname) ?></a></dt>
<dd><?js if (n.summary) { ?><?js= n.summary ?><?js } ?></dd>
<?js }); ?></dl>
<?js } ?>
<?js
var members = self.find({kind: 'member', memberof: title === 'Globals'? {isUndefined: true} : doc.longname});
if (members && members.length && members.forEach) {
?>
<h3 class="subsection-title">Members</h3>
<dl><?js members.forEach(function(p) { ?>
<?js= self.partial('members.tmpl', p) ?>
<?js }); ?></dl>
<?js } ?>
<?js
var methods = self.find({kind: 'function', memberof: title === 'Globals'? {isUndefined: true} : doc.longname});
if (methods && methods.length && methods.forEach) {
?>
<h3 class="subsection-title">Methods</h3>
<dl><?js methods.forEach(function(m) { ?>
<?js= self.partial('method.tmpl', m) ?>
<?js }); ?></dl>
<?js } ?>
<?js
var typedefs = self.find({kind: 'typedef', memberof: doc.longname});
if (typedefs && typedefs.length && typedefs.forEach) {
?>
<h3 class="subsection-title">TypeDefs</h3>
<dl><?js typedefs.forEach(function(e) { ?>
<?js= self.partial('members.tmpl', e) ?>
<?js }); ?></dl>
<?js } ?>
<?js
var events = self.find({kind: 'event', memberof: doc.longname});
if (events && events.length && events.forEach) {
?>
<h3 class="subsection-title">Events</h3>
<dl><?js events.forEach(function(e) { ?>
<?js= self.partial('method.tmpl', e) ?>
<?js }); ?></dl>
<?js } ?>
</article>
</section>
<?js } ?>
<?js }); ?>

96
doc/template/tmpl/details.tmpl vendored Normal file
View File

@@ -0,0 +1,96 @@
<?js
var data = obj;
var self = this;
?>
<dl class="details">
<?js
var properties = data.properties;
if (properties && properties.length && properties.forEach) {
?>
<h5 class="subsection-title">Properties:</h5>
<dl><?js= this.partial('properties.tmpl', properties) ?></dl>
<?js } ?>
<?js if (data.version) {?>
<dt class="tag-version">Version:</dt>
<dd class="tag-version"><ul class="dummy"><li><?js= version ?></li></ul></dd>
<?js } ?>
<?js if (data.since) {?>
<dt class="tag-since">Since:</dt>
<dd class="tag-since"><ul class="dummy"><li><?js= since ?></dd>
<?js } ?>
<?js if (data.inherited && data.inherits) { ?>
<dt class="inherited-from">Inherited From:</dt>
<dd class="inherited-from"><ul class="dummy"><li>
<?js= this.linkto(data.inherits, this.htmlsafe(data.inherits)) ?>
</li></dd>
<?js } ?>
<?js if (data.deprecated) { ?>
<dt class="important tag-deprecated">Deprecated:</dt><?js
if (data.deprecated === true) { ?><dd class="yes-def tag-deprecated"><ul class="dummy"><li>Yes</li></ul></dd><?js }
else { ?><dd><ul class="dummy"><li><?js= data.deprecated ?></li><ul></dd><?js }
?>
<?js } ?>
<?js if (data.author && author.length) {?>
<dt class="tag-author">Author:</dt>
<dd class="tag-author">
<ul><?js author.forEach(function(a) { ?>
<li><?js= a ?></li>
<?js }); ?></ul>
</dd>
<?js } ?>
<?js if (data.copyright) {?>
<dt class="tag-copyright">Copyright:</dt>
<dd class="tag-copyright"><ul class="dummy"><li><?js= copyright ?></li></ul></dd>
<?js } ?>
<?js if (data.license) {?>
<dt class="tag-license">License:</dt>
<dd class="tag-license"><ul class="dummy"><li><?js= license ?></li></ul></dd>
<?js } ?>
<?js if (data.defaultvalue) {?>
<dt class="tag-default">Default Value:</dt>
<dd class="tag-default"><ul class="dummy"><li><?js= data.defaultvalue ?></li></ul></dd>
<?js } ?>
<?js if (data.meta) {?>
<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li><?js= meta.filename ?>, line <?js= meta.lineno ?></li></ul></dd>
<?js } ?>
<?js if (data.tutorials && tutorials.length) {?>
<dt class="tag-tutorial">Tutorials:</dt>
<dd class="tag-tutorial">
<ul><?js tutorials.forEach(function(t) { ?>
<li><?js= self.tutoriallink(t) ?></li>
<?js }); ?></ul>
</dd>
<?js } ?>
<?js if (data.see && see.length) {?>
<dt class="tag-see">See:</dt>
<dd class="tag-see">
<ul><?js see.forEach(function(s) { ?>
<li><?js= self.linkto(s) ?></li>
<?js }); ?></ul>
</dd>
<?js } ?>
<?js if (data.todo && todo.length) {?>
<dt class="tag-todo">To Do:</dt>
<dd class="tag-todo">
<ul><?js todo.forEach(function(t) { ?>
<li><?js= t ?></li>
<?js }); ?></ul>
</dd>
<?js } ?>
</dl>

2
doc/template/tmpl/example.tmpl vendored Normal file
View File

@@ -0,0 +1,2 @@
<?js var data = obj; ?>
<pre><code><?js= data ?></code></pre>

11
doc/template/tmpl/examples.tmpl vendored Normal file
View File

@@ -0,0 +1,11 @@
<?js
var data = obj;
data.forEach(function(example) {
if (example.caption) {
?>
<p class="code-caption"><?js= example.caption ?></p>
<?js } ?>
<pre class="prettyprint"><code><?js= example.code ?></code></pre>
<?js
});
?>

19
doc/template/tmpl/exceptions.tmpl vendored Normal file
View File

@@ -0,0 +1,19 @@
<?js
var data = obj;
if (data.description) {
?>
<div class="param-desc">
<?js= description ?>
</div>
<?js } ?>
<?js if (data.type && data.type.names) {?>
<dl>
<dt>
Type
</dt>
<dd>
<?js= this.partial('type.tmpl', data.type.names) ?>
</dd>
</dl>
<?js } ?>

4
doc/template/tmpl/fires.tmpl vendored Normal file
View File

@@ -0,0 +1,4 @@
<?js var data = obj; ?>
<li>
<?js= data ?>
</li>

52
doc/template/tmpl/layout.tmpl vendored Normal file
View File

@@ -0,0 +1,52 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>OpenLayers 3 API Documentation - <?js= title ?></title>
<script src="scripts/prettify/prettify.js"> </script>
<script src="scripts/prettify/lang-css.js"> </script>
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<link type="text/css" rel="stylesheet" href="styles/prettify-jsdoc.css">
<link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">
<link rel="stylesheet" href="../resources/bootstrap/css/bootstrap.min.css" type="text/css">
<link rel="stylesheet" href="../resources/layout.css" type="text/css">
<link rel="stylesheet" href="../resources/bootstrap/css/bootstrap-responsive.min.css" type="text/css">
</head>
<body>
<div class="navbar navbar-inverse navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<a class="brand" href="./">OpenLayers 3 API Documentation - <?js= title ?></a>
<ul class="nav pull-right">
<li><iframe class="github-watch-button" src="http://ghbtns.com/github-btn.html?user=openlayers&repo=ol3&type=watch&count=true"
allowtransparency="true" frameborder="0" scrolling="0" height="20" width="90"></iframe></li>
<li><a href="https://twitter.com/share" class="twitter-share-button" data-count="none" data-hashtags="openlayers">&nbsp;</a></li>
<li><div class="g-plusone-wrapper"><div class="g-plusone" data-size="medium" data-annotation="none"></div></div></li>
</ul>
</div>
</div>
</div>
<div id="main">
<?js= content ?>
</div>
<nav>
<?js= this.nav ?>
</nav>
<br clear="both">
<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3</a>
</footer>
<script> prettyPrint(); </script>
<script src="../resources/social-links.js" type="text/javascript"></script>
</body>
</html>

14
doc/template/tmpl/mainpage.tmpl vendored Normal file
View File

@@ -0,0 +1,14 @@
<?js
var data = obj;
var self = this;
?>
<?js if (data.kind === 'package') { ?>
<h3><?js= data.name ?> <?js= data.version ?></h3>
<?js } ?>
<?js if (data.readme) { ?>
<section>
<article><?js= data.readme ?></article>
</section>
<?js } ?>

22
doc/template/tmpl/members.tmpl vendored Normal file
View File

@@ -0,0 +1,22 @@
<?js var data = obj; ?>
<dt class="<?js= data.access ?>">
<h4 class="name" id="<?js= id ?>"><?js= data.attribs + name + data.signature ?></h4>
<?js if (data.summary) { ?>
<p class="summary"><?js= summary ?></p>
<?js } ?>
</dt>
<dd class="<?js= data.access ?>">
<?js if (data.description) { ?>
<div class="description">
<?js= data.description ?>
</div>
<?js } ?>
<?js= this.partial('details.tmpl', data) ?>
<?js if (data.examples && examples.length) { ?>
<h5>Example<?js= examples.length > 1? 's':'' ?></h5>
<?js= this.partial('examples.tmpl', examples) ?>
<?js } ?>
</dd>

76
doc/template/tmpl/method.tmpl vendored Normal file
View File

@@ -0,0 +1,76 @@
<?js
var data = obj;
var self = this;
?>
<dt>
<h4 class="name" id="<?js= id ?>"><?js= data.attribs + (kind == 'class'? 'new ':'') + name + data.signature ?></h4>
<?js if (data.summary) { ?>
<p class="summary"><?js= summary ?></p>
<?js } ?>
</dt>
<dd>
<?js if (data.description) { ?>
<div class="description">
<?js= data.description ?>
</div>
<?js } ?>
<?js if (kind === 'event' && data.type && data.type.names) {?>
<h5>Type:</h5>
<ul>
<li>
<?js= self.partial('type.tmpl', data.type.names) ?>
</li>
</ul>
<?js } ?>
<?js if (data['this']) { ?>
<h5>This:</h5>
<ul><li><?js= this.linkto(data['this'], data['this']) ?></li></ul>
<?js } ?>
<?js if (data.params && params.length) { ?>
<h5>Parameters:</h5>
<?js= this.partial('params.tmpl', params) ?>
<?js } ?>
<?js= this.partial('details.tmpl', data) ?>
<?js if (data.fires && fires.length) { ?>
<h5>Fires:</h5>
<ul><?js fires.forEach(function(f) { ?>
<?js= self.partial('fires.tmpl', self.linkto(f) ) ?>
<?js }); ?></ul>
<?js } ?>
<?js if (data.exceptions && exceptions.length) { ?>
<h5>Throws:</h5>
<?js if (exceptions.length > 1) { ?><ul><?js
exceptions.forEach(function(r) { ?>
<li><?js= self.partial('exceptions.tmpl', r) ?></li>
<?js });
?></ul><?js } else {
exceptions.forEach(function(r) { ?>
<?js= self.partial('exceptions.tmpl', r) ?>
<?js });
} } ?>
<?js if (data.returns && returns.length) { ?>
<h5>Returns:</h5>
<?js if (returns.length > 1) { ?><ul><?js
returns.forEach(function(r) { ?>
<li><?js= self.partial('returns.tmpl', r) ?></li>
<?js });
?></ul><?js } else {
returns.forEach(function(r) { ?>
<?js= self.partial('returns.tmpl', r) ?>
<?js });
} } ?>
<?js if (data.examples && examples.length) { ?>
<h5>Example<?js= examples.length > 1? 's':'' ?></h5>
<?js= this.partial('examples.tmpl', examples) ?>
<?js } ?>
</dd>

108
doc/template/tmpl/params.tmpl vendored Normal file
View File

@@ -0,0 +1,108 @@
<?js
var params = obj;
/* sort subparams under their parent params (like opts.classname) */
var parentParam = null;
params.forEach(function(param, i) {
if (!param) { return; }
if ( parentParam && param.name && param.name.indexOf(parentParam.name + '.') === 0 ) {
param.name = param.name.substr(parentParam.name.length+1);
parentParam.subparams = parentParam.subparams || [];
parentParam.subparams.push(param);
params[i] = null;
}
else {
parentParam = param;
}
});
/* determine if we need extra columns, "attributes" and "default" */
params.hasAttributes = false;
params.hasDefault = false;
params.hasName = false;
params.forEach(function(param) {
if (!param) { return; }
if (param.optional || param.nullable) {
params.hasAttributes = true;
}
if (param.name) {
params.hasName = true;
}
if (typeof param.defaultvalue !== 'undefined') {
params.hasDefault = true;
}
});
?>
<table class="params">
<thead>
<tr>
<?js if (params.hasName) {?>
<th>Name</th>
<?js } ?>
<th>Type</th>
<?js if (params.hasAttributes) {?>
<th>Argument</th>
<?js } ?>
<?js if (params.hasDefault) {?>
<th>Default</th>
<?js } ?>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<?js
var self = this;
params.forEach(function(param) {
if (!param) { return; }
?>
<tr>
<?js if (params.hasName) {?>
<td class="name"><code><?js= param.name.replace(/^opt_/, "") ?></code></td>
<?js } ?>
<td class="type">
<?js if (param.type && param.type.names) {?>
<?js= self.partial('type.tmpl', param.type.names) ?>
<?js } ?>
</td>
<?js if (params.hasAttributes) {?>
<td class="attributes">
<?js if (param.optional) { ?>
&lt;optional><br>
<?js } ?>
<?js if (param.nullable) { ?>
&lt;nullable><br>
<?js } ?>
</td>
<?js } ?>
<?js if (params.hasDefault) {?>
<td class="default">
<?js if (typeof param.defaultvalue !== 'undefined') { ?>
<?js= self.htmlsafe(param.defaultvalue) ?>
<?js } ?>
</td>
<?js } ?>
<td class="description last"><?js= (param.optional ? "(Optional) " : "") + param.description ?><?js if (param.subparams) { ?>
<h6>Properties</h6>
<?js= self.partial('params.tmpl', param.subparams) ?>
<?js } ?></td>
</tr>
<?js }); ?>
</tbody>
</table>

107
doc/template/tmpl/properties.tmpl vendored Normal file
View File

@@ -0,0 +1,107 @@
<?js
var props = obj;
/* sort subprops under their parent props (like opts.classname) */
var parentProp = null;
props.forEach(function(prop, i) {
if (!prop) { return; }
if ( parentProp && prop.name.indexOf(parentProp.name + '.') === 0 ) {
prop.name = prop.name.substr(parentProp.name.length+1);
parentProp.subprops = parentProp.subprops || [];
parentProp.subprops.push(prop);
props[i] = null;
}
else {
parentProp = prop;
}
});
/* determine if we need extra columns, "attributes" and "default" */
props.hasAttributes = false;
props.hasDefault = false;
props.hasName = false;
props.forEach(function(prop) {
if (!prop) { return; }
if (prop.optional || prop.nullable) {
props.hasAttributes = true;
}
if (prop.name) {
props.hasName = true;
}
if (typeof prop.defaultvalue !== 'undefined') {
props.hasDefault = true;
}
});
?>
<table class="props">
<thead>
<tr>
<?js if (props.hasName) {?>
<th>Name</th>
<?js } ?>
<th>Type</th>
<?js if (props.hasAttributes) {?>
<th>Argument</th>
<?js } ?>
<?js if (props.hasDefault) {?>
<th>Default</th>
<?js } ?>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<?js
var self = this;
props.forEach(function(prop) {
if (!prop) { return; }
?>
<tr>
<?js if (props.hasName) {?>
<td class="name"><code><?js= prop.name ?></code></td>
<?js } ?>
<td class="type">
<?js if (prop.type && prop.type.names) {?>
<?js= self.partial('type.tmpl', prop.type.names) ?>
<?js } ?>
</td>
<?js if (props.hasAttributes) {?>
<td class="attributes">
<?js if (prop.optional) { ?>
&lt;optional><br>
<?js } ?>
<?js if (prop.nullable) { ?>
&lt;nullable><br>
<?js } ?>
</td>
<?js } ?>
<?js if (props.hasDefault) {?>
<td class="default">
<?js if (typeof prop.defaultvalue !== 'undefined') { ?>
<?js= self.htmlsafe(prop.defaultvalue) ?>
<?js } ?>
</td>
<?js } ?>
<td class="description last"><?js= prop.description ?><?js if (prop.subprops) { ?>
<h6>Properties</h6><?js= self.partial('properties.tmpl', prop.subprops) ?>
<?js } ?></td>
</tr>
<?js }); ?>
</tbody>
</table>

19
doc/template/tmpl/returns.tmpl vendored Normal file
View File

@@ -0,0 +1,19 @@
<?js
var data = obj;
if (data.description) {
?>
<div class="param-desc">
<?js= description ?>
</div>
<?js } ?>
<?js if (data.type && data.type.names) {?>
<dl>
<dt>
Type
</dt>
<dd>
<?js= this.partial('type.tmpl', data.type.names) ?>
</dd>
</dl>
<?js } ?>

8
doc/template/tmpl/source.tmpl vendored Normal file
View File

@@ -0,0 +1,8 @@
<?js
var data = obj;
?>
<section>
<article>
<pre class="prettyprint source"><code><?js= data.code ?></code></pre>
</article>
</section>

19
doc/template/tmpl/tutorial.tmpl vendored Normal file
View File

@@ -0,0 +1,19 @@
<section>
<header>
<?js if (children.length > 0) { ?>
<ul><?js
var self = this;
children.forEach(function(t) { ?>
<li><?js= self.tutoriallink(t.name) ?></li>
<?js }); ?></ul>
<?js } ?>
<h2><?js= header ?></h2>
</header>
<article>
<?js= content ?>
</article>
</section>

7
doc/template/tmpl/type.tmpl vendored Normal file
View File

@@ -0,0 +1,7 @@
<?js
var data = obj;
var self = this;
data.forEach(function(name, i) { ?>
<span class="param-type"><?js= self.linkto(name, self.htmlsafe(name)) ?></span>
<?js if (i < data.length-1) { ?>|<?js } ?>
<?js }); ?>

3
doc/tutorials/ol3.json Normal file
View File

@@ -0,0 +1,3 @@
{
"title": "OpenLayers 3 Architecture"
}

274
doc/tutorials/ol3.md Normal file
View File

@@ -0,0 +1,274 @@
CLASS HIERARCHY
===============
```
goog.math.Coordinate // Simple 2D point
|
+- TileCoord
goog.math.Box
|
+- Extent // The extent of a single object in two dimensions, projection not stored
|
+- TileBounds // A range of tiles in two dimensions, integer coordinates, z not stored
Projection
goog.events.EventTarget
|
+- MVCObject
| |
| +- Camera
| |
| +- Control
| | |
| | +- ?
| |
| +- Layer
| | |
| | +- TileLayer
| | | |
| | | +- TMSTileLayer
| | | |
| | | +- WMTSTileLayer
| | | |
| | | +- XYZTileLayer / OSMTileLayer
| | |
| | +- VectorLayer
| | |
| | +- ImageLayer
| |
| +- LayerRenderer
| |
| +- LayerRendererOptions
| |
| +- Map
| |
| +- MapRenderer
| | |
| | +- HTMLMapRenderer
| | |
| | +- WebGLMapRenderer
| |
| +- MVCArray
| | |
| | +- ControlArray
| | |
| | +- LayerViewArray
|
| +- TileQueue
|
+- Tile
```
Layer renderer hierarchy
------------------------
```
goog.events.EventTarget
|
+- MVCObject
|
+- LayerRenderer
|
+- SingleTileLayerRenderer
| |
| +- HTMLSingleTileLayerRenderer
| |
| +- WebGLSingleTileLayerRenderer
|
+- TileLayerRenderer
| |
| +- HTMLTileLayerRenderer
| |
| +- WebGLTileLayerRenderer
|
+- VectorLayerRenderer
| |
| +- HTMLVectorLayerRenderer
| | |
| | +- SVGHTMLVectorLayerRenderer
| | |
| | +- Canvas2DHTMLVectorLayerRenderer
| | |
| | +- VMLHTMLVectorLayerRenderer
| |
| +- WebGLVectorLayerRenderer
```
OBJECT PROPERTIES AND METHODS
=============================
Notation:
- `property type` property with type, trailing ? indicates unsure, getters and setters are assumed to exist.
- `f(args) -> type` function taking args returning type.
- `f(args) -> type = something` f is a trivial wrapper around something.
- `fires 'x'` fires events of type 'x'.
Principles:
- All non-trivial objects inherit from `MVCObject`.
- All non-trivial collections are either `MVCArrays` or a child class thereof.
- Resolutions are `Array.<number>`, infinitely scalable resources (e.g. vectore layers) have resolutions == null.
```
MVCObject
as Google Maps MVCObject
freeze()
unfreeze()
TileCoord
clone() -> TileCoord
getHash() -> number
TileBounds
forEachTileCoord(z, function(tileCoord))
Tile
tileCoord TileCoord
url string
state UNLOADED | LOADING | LOADED
fires 'loaded' // when loaded
fires 'aborted' // when loading is aborted
Camera
position goog.math.Coordinate
resolution number
rotation number
Layer
projections Array.<Projection>
extent Extent
getResolutions() -> Array.<number>|null
fires 'change' // when data changes
LayerArray
getResolutions() -> Array.<number>|null
getMaxResolution() = this.getResolutions()[0] | null
LayerRendererOptions
layer Layer
visible boolean
opacity number
brightness number
color number
hue number
saturation number
Map
projection Projection
renderer Renderer
layers LayerArray
addLayer(layer) = layers.push(layer)
getExtent() -> Extent
getMaxResolution() = layers.getMaxResolution()
TileGrid
resolutions Array.<number>
extent ol.Extent
xEast boolean
ySouth boolean
origin(s) Coord|Array.<Coord>
tileSize goog.math.Size
forEachTileCoordChild(tileCoord, function(z, TileBounds))
forEachTileCoordParent(tileCoord, function(z, TileBounds))
getExtentTileBounds(z, extent) -> TileBounds
getTileCoord(coordinate) -> TileCoord
getTileCoordCenter(tileCoord) -> goog.math.Coordinate
getTileCoordExtent(tileCoord) -> ol.Extent
getTileCoordResolution(tileCoord) -> number
getZForResolution(resolution) -> number
TileLayer
tileGrid TileGrid
tileUrl function(tileCoord) -> string
getTileCoordUrl(tileCoord) -> string = this.tileUrl(tileCoord)
TileQueue
camera Camera // or maybe MVCArray.<Camera> ?
getTileCoordPriority(tileCoord) -> number // private
enqueueTile(Tile)
VectorLayer
forEachFeature(resolution, extent, projection, function(Feature))
Renderer
target HTMLDivElement
map Map
camera Camera
getCapabilities() -> Array.<string> // maybe ?
```
Questions:
- Store tile layer extent in TileLayer or in TileGrid? (not clear)
Two concepts: tile coordinate system range and and available data extent.
TileGrid extent is range (or validity extent) of the tile coordinate system.
TileLayer extent is the available data extent. A particular TileGrid may range
from 0,0 to 10,10. My cache may conform to that grid but I may only have tiles
ranging from 2,2 to 8,8. When you need to wrap multiple worlds, you pay
attention to the TileGrid extent. When you need to decide whether or not to
bother requesting a tile, you pay attention to the TileLayer extent.
- Who determines "best" resolution? (static function?)
Todo: if tile layer extent stored in TileLayer rather than TileGrid then extent
will occasionally need to be passed to TileGrid functions for cropping.
DESIGN ASSERTIONS
=================
Map
- A map has a renderer (the map renderer).
- A map has a camera.
- Multiple maps can share the same camera.
- A map has a layer list.
Layer
- A layer can have multiple projections (the supported projections).
- A layer advertizes the projections it supports.
- A layer returns no data if asked data for an unsupported projection.
LayerRendererOptions
- A layer renderer options object stores view-related states for a layer.
- Options include visibility, opacity, saturation, hue, etc.
- A layer renderer options object has a layer.
- Multiple layer renderer options can share the same layer.
- In other words a layer can be viewed in different manners.
Renderer
- The map renderer responds to events.
- The map renderer receives events from the camera.
- The map renderer creates layer renderers.
Control
- A control may listen to map events.
- A control may listen to camera events.
- A map navigation control acts on the camera.
MVC
- Types can be described in MVC terms.
- Models don't know what rendering means.
- Maps are models.
- Layers are models.
- Layer views are models (sorry!).
- Cameras are models.
- Layer lists are collections.
- Renderers are views.
- Controls are views or controllers or both.
- An attribution control is a view.
- A map navigation control is a controller.
- A zoom slider control is both a view and a controller.

View File

@@ -1,113 +0,0 @@
Format: 1.52
# This is the Natural Docs languages file for this project. If you change
# anything here, it will apply to THIS PROJECT ONLY. If you'd like to change
# something for all your projects, edit the Languages.txt in Natural Docs'
# Config directory instead.
# You can prevent certain file extensions from being scanned like this:
# Ignore Extensions: [extension] [extension] ...
#-------------------------------------------------------------------------------
# SYNTAX:
#
# Unlike other Natural Docs configuration files, in this file all comments
# MUST be alone on a line. Some languages deal with the # character, so you
# cannot put comments on the same line as content.
#
# Also, all lists are separated with spaces, not commas, again because some
# languages may need to use them.
#
# Language: [name]
# Alter Language: [name]
# Defines a new language or alters an existing one. Its name can use any
# characters. If any of the properties below have an add/replace form, you
# must use that when using Alter Language.
#
# The language Shebang Script is special. It's entry is only used for
# extensions, and files with those extensions have their shebang (#!) lines
# read to determine the real language of the file. Extensionless files are
# always treated this way.
#
# The language Text File is also special. It's treated as one big comment
# so you can put Natural Docs content in them without special symbols. Also,
# if you don't specify a package separator, ignored prefixes, or enum value
# behavior, it will copy those settings from the language that is used most
# in the source tree.
#
# Extensions: [extension] [extension] ...
# [Add/Replace] Extensions: [extension] [extension] ...
# Defines the file extensions of the language's source files. You can
# redefine extensions found in the main languages file. You can use * to
# mean any undefined extension.
#
# Shebang Strings: [string] [string] ...
# [Add/Replace] Shebang Strings: [string] [string] ...
# Defines a list of strings that can appear in the shebang (#!) line to
# designate that it's part of the language. You can redefine strings found
# in the main languages file.
#
# Ignore Prefixes in Index: [prefix] [prefix] ...
# [Add/Replace] Ignored Prefixes in Index: [prefix] [prefix] ...
#
# Ignore [Topic Type] Prefixes in Index: [prefix] [prefix] ...
# [Add/Replace] Ignored [Topic Type] Prefixes in Index: [prefix] [prefix] ...
# Specifies prefixes that should be ignored when sorting symbols in an
# index. Can be specified in general or for a specific topic type.
#
#------------------------------------------------------------------------------
# For basic language support only:
#
# Line Comments: [symbol] [symbol] ...
# Defines a space-separated list of symbols that are used for line comments,
# if any.
#
# Block Comments: [opening sym] [closing sym] [opening sym] [closing sym] ...
# Defines a space-separated list of symbol pairs that are used for block
# comments, if any.
#
# Package Separator: [symbol]
# Defines the default package separator symbol. The default is a dot.
#
# [Topic Type] Prototype Enders: [symbol] [symbol] ...
# When defined, Natural Docs will attempt to get a prototype from the code
# immediately following the topic type. It stops when it reaches one of
# these symbols. Use \n for line breaks.
#
# Line Extender: [symbol]
# Defines the symbol that allows a prototype to span multiple lines if
# normally a line break would end it.
#
# Enum Values: [global|under type|under parent]
# Defines how enum values are referenced. The default is global.
# global - Values are always global, referenced as 'value'.
# under type - Values are under the enum type, referenced as
# 'package.enum.value'.
# under parent - Values are under the enum's parent, referenced as
# 'package.value'.
#
# Perl Package: [perl package]
# Specifies the Perl package used to fine-tune the language behavior in ways
# too complex to do in this file.
#
#------------------------------------------------------------------------------
# For full language support only:
#
# Full Language Support: [perl package]
# Specifies the Perl package that has the parsing routines necessary for full
# language support.
#
#-------------------------------------------------------------------------------
# The following languages are defined in the main file, if you'd like to alter
# them:
#
# Text File, Shebang Script, C/C++, C#, Java, JavaScript, Perl, Python,
# PHP, SQL, Visual Basic, Pascal, Assembly, Ada, Tcl, Ruby, Makefile,
# ActionScript, ColdFusion, R, Fortran
# If you add a language that you think would be useful to other developers
# and should be included in Natural Docs by default, please e-mail it to
# languages [at] naturaldocs [dot] org.

View File

@@ -1,473 +0,0 @@
Format: 1.52
Title: OpenLayers
SubTitle: JavaScript Mapping Library
# You can add a footer to your documentation like this:
# Footer: [text]
# If you want to add a copyright notice, this would be the place to do it.
# You can add a timestamp to your documentation like one of these:
# Timestamp: Generated on month day, year
# Timestamp: Updated mm/dd/yyyy
# Timestamp: Last updated mon day
#
# m - One or two digit month. January is "1"
# mm - Always two digit month. January is "01"
# mon - Short month word. January is "Jan"
# month - Long month word. January is "January"
# d - One or two digit day. 1 is "1"
# dd - Always two digit day. 1 is "01"
# day - Day with letter extension. 1 is "1st"
# yy - Two digit year. 2006 is "06"
# yyyy - Four digit year. 2006 is "2006"
# year - Four digit year. 2006 is "2006"
# --------------------------------------------------------------------------
#
# Cut and paste the lines below to change the order in which your files
# appear on the menu. Don't worry about adding or removing files, Natural
# Docs will take care of that.
#
# You can further organize the menu by grouping the entries. Add a
# "Group: [name] {" line to start a group, and add a "}" to end it.
#
# You can add text and web links to the menu by adding "Text: [text]" and
# "Link: [name] ([URL])" lines, respectively.
#
# The formatting and comments are auto-generated, so don't worry about
# neatness when editing the file. Natural Docs will clean it up the next
# time it is run. When working with groups, just deal with the braces and
# forget about the indentation and comments.
#
# --------------------------------------------------------------------------
Group: OpenLayers {
File: OpenLayers (no auto-title, OpenLayers.js)
Group: BaseTypes {
File: Base Types (no auto-title, OpenLayers/BaseTypes.js)
File: Bounds (no auto-title, OpenLayers/BaseTypes/Bounds.js)
File: Class (no auto-title, OpenLayers/BaseTypes/Class.js)
File: Date (no auto-title, OpenLayers/BaseTypes/Date.js)
File: Element (no auto-title, OpenLayers/BaseTypes/Element.js)
File: LonLat (no auto-title, OpenLayers/BaseTypes/LonLat.js)
File: Pixel (no auto-title, OpenLayers/BaseTypes/Pixel.js)
File: Size (no auto-title, OpenLayers/BaseTypes/Size.js)
} # Group: BaseTypes
File: Console (no auto-title, OpenLayers/Console.js)
Group: Control {
File: Control (no auto-title, OpenLayers/Control.js)
File: ArgParser (no auto-title, OpenLayers/Control/ArgParser.js)
File: Attribution (no auto-title, OpenLayers/Control/Attribution.js)
File: Button (no auto-title, OpenLayers/Control/Button.js)
File: DragFeature (no auto-title, OpenLayers/Control/DragFeature.js)
File: DragPan (no auto-title, OpenLayers/Control/DragPan.js)
File: DrawFeature (no auto-title, OpenLayers/Control/DrawFeature.js)
File: EditingToolbar (no auto-title, OpenLayers/Control/EditingToolbar.js)
File: Geolocate (no auto-title, OpenLayers/Control/Geolocate.js)
File: GetFeature (no auto-title, OpenLayers/Control/GetFeature.js)
File: Graticule (no auto-title, OpenLayers/Control/Graticule.js)
File: KeyboardDefaults (no auto-title, OpenLayers/Control/KeyboardDefaults.js)
File: LayerSwitcher (no auto-title, OpenLayers/Control/LayerSwitcher.js)
File: Measure (no auto-title, OpenLayers/Control/Measure.js)
File: ModifyFeature (no auto-title, OpenLayers/Control/ModifyFeature.js)
File: MousePosition (no auto-title, OpenLayers/Control/MousePosition.js)
File: Navigation (no auto-title, OpenLayers/Control/Navigation.js)
File: NavigationHistory (no auto-title, OpenLayers/Control/NavigationHistory.js)
File: NavToolbar (no auto-title, OpenLayers/Control/NavToolbar.js)
File: OverviewMap (no auto-title, OpenLayers/Control/OverviewMap.js)
File: Pan (no auto-title, OpenLayers/Control/Pan.js)
File: Panel (no auto-title, OpenLayers/Control/Panel.js)
File: PanPanel (no auto-title, OpenLayers/Control/PanPanel.js)
File: PanZoom (no auto-title, OpenLayers/Control/PanZoom.js)
File: PanZoomBar (no auto-title, OpenLayers/Control/PanZoomBar.js)
File: Permalink (no auto-title, OpenLayers/Control/Permalink.js)
File: PinchZoom (no auto-title, OpenLayers/Control/PinchZoom.js)
File: Scale (no auto-title, OpenLayers/Control/Scale.js)
File: ScaleLine (no auto-title, OpenLayers/Control/ScaleLine.js)
File: SelectFeature (no auto-title, OpenLayers/Control/SelectFeature.js)
File: SLDSelect (no auto-title, OpenLayers/Control/SLDSelect.js)
File: Snapping (no auto-title, OpenLayers/Control/Snapping.js)
File: Split (no auto-title, OpenLayers/Control/Split.js)
File: TouchNavigation (no auto-title, OpenLayers/Control/TouchNavigation.js)
File: TransformFeature (no auto-title, OpenLayers/Control/TransformFeature.js)
File: WMSGetFeatureInfo (no auto-title, OpenLayers/Control/WMSGetFeatureInfo.js)
File: WMTSGetFeatureInfo (no auto-title, OpenLayers/Control/WMTSGetFeatureInfo.js)
File: ZoomBox (no auto-title, OpenLayers/Control/ZoomBox.js)
File: ZoomIn (no auto-title, OpenLayers/Control/ZoomIn.js)
File: ZoomOut (no auto-title, OpenLayers/Control/ZoomOut.js)
File: ZoomPanel (no auto-title, OpenLayers/Control/ZoomPanel.js)
File: ZoomToMaxExtent (no auto-title, OpenLayers/Control/ZoomToMaxExtent.js)
} # Group: Control
File: Events (no auto-title, OpenLayers/Events.js)
Group: Feature {
File: Feature (no auto-title, OpenLayers/Feature.js)
File: Vector (no auto-title, OpenLayers/Feature/Vector.js)
} # Group: Feature
Group: Filter {
File: Filter (no auto-title, OpenLayers/Filter.js)
File: Comparison (no auto-title, OpenLayers/Filter/Comparison.js)
File: FeatureId (no auto-title, OpenLayers/Filter/FeatureId.js)
File: Function (no auto-title, OpenLayers/Filter/Function.js)
File: Logical (no auto-title, OpenLayers/Filter/Logical.js)
File: Spatial (no auto-title, OpenLayers/Filter/Spatial.js)
} # Group: Filter
Group: Format {
File: Format (no auto-title, OpenLayers/Format.js)
File: ArcXML (no auto-title, OpenLayers/Format/ArcXML.js)
File: ArcXML.Features (no auto-title, OpenLayers/Format/ArcXML/Features.js)
File: Atom (no auto-title, OpenLayers/Format/Atom.js)
File: Context (no auto-title, OpenLayers/Format/Context.js)
File: CQL (no auto-title, OpenLayers/Format/CQL.js)
File: CSWGetDomain (no auto-title, OpenLayers/Format/CSWGetDomain.js)
File: CSWGetDomain.v2_0_2 (no auto-title, OpenLayers/Format/CSWGetDomain/v2_0_2.js)
File: CSWGetRecords (no auto-title, OpenLayers/Format/CSWGetRecords.js)
File: CSWGetRecords.v2_0_2 (no auto-title, OpenLayers/Format/CSWGetRecords/v2_0_2.js)
Group: Filter {
File: Filter (no auto-title, OpenLayers/Format/Filter.js)
File: v1 (no auto-title, OpenLayers/Format/Filter/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/Filter/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/Filter/v1_1_0.js)
} # Group: Filter
Group: GML {
File: GML (no auto-title, OpenLayers/Format/GML.js)
File: Base (no auto-title, OpenLayers/Format/GML/Base.js)
File: v2 (no auto-title, OpenLayers/Format/GML/v2.js)
File: v3 (no auto-title, OpenLayers/Format/GML/v3.js)
} # Group: GML
Group: SLD {
File: SLD (no auto-title, OpenLayers/Format/SLD.js)
File: v1 (no auto-title, OpenLayers/Format/SLD/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/SLD/v1_0_0.js)
} # Group: SLD
File: GeoJSON (no auto-title, OpenLayers/Format/GeoJSON.js)
File: GeoRSS (no auto-title, OpenLayers/Format/GeoRSS.js)
File: GPX (no auto-title, OpenLayers/Format/GPX.js)
File: JSON (no auto-title, OpenLayers/Format/JSON.js)
File: KML (no auto-title, OpenLayers/Format/KML.js)
File: OGCExceptionReport (no auto-title, OpenLayers/Format/OGCExceptionReport.js)
File: OSM (no auto-title, OpenLayers/Format/OSM.js)
Group: OWSCommon {
File: OWSCommon (no auto-title, OpenLayers/Format/OWSCommon.js)
File: v1 (no auto-title, OpenLayers/Format/OWSCommon/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/OWSCommon/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/OWSCommon/v1_1_0.js)
} # Group: OWSCommon
File: OWSContext (no auto-title, OpenLayers/Format/OWSContext.js)
File: OWSContext.v0_3_1 (no auto-title, OpenLayers/Format/OWSContext/v0_3_1.js)
File: QueryStringFilter (no auto-title, OpenLayers/Format/QueryStringFilter.js)
File: SOSCapabilities (no auto-title, OpenLayers/Format/SOSCapabilities.js)
File: SOSCapabilities.v1_0_0 (no auto-title, OpenLayers/Format/SOSCapabilities/v1_0_0.js)
File: SOSGetFeatureOfInterest (no auto-title, OpenLayers/Format/SOSGetFeatureOfInterest.js)
File: SOSGetObservation (no auto-title, OpenLayers/Format/SOSGetObservation.js)
File: Text (no auto-title, OpenLayers/Format/Text.js)
File: VersionedOGC (OpenLayers/Format/XML/VersionedOGC.js)
File: WCSGetCoverage version 1.1.0 (no auto-title, OpenLayers/Format/WCSGetCoverage.js)
File: WFS (no auto-title, OpenLayers/Format/WFS.js)
Group: WFSCapabilities {
File: WFSCapabilities (no auto-title, OpenLayers/Format/WFSCapabilities.js)
File: v1 (no auto-title, OpenLayers/Format/WFSCapabilities/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/WFSCapabilities/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/WFSCapabilities/v1_1_0.js)
} # Group: WFSCapabilities
Group: WFST {
File: WFST (no auto-title, OpenLayers/Format/WFST.js)
File: v1 (no auto-title, OpenLayers/Format/WFST/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/WFST/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/WFST/v1_1_0.js)
} # Group: WFST
Group: WMC {
File: WMC (no auto-title, OpenLayers/Format/WMC.js)
File: v1 (no auto-title, OpenLayers/Format/WMC/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Format/WMC/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/WMC/v1_1_0.js)
} # Group: WMC
Group: WMSCapabilities {
File: WMSCapabilities (no auto-title, OpenLayers/Format/WMSCapabilities.js)
File: v1 (no auto-title, OpenLayers/Format/WMSCapabilities/v1.js)
File: v1_1 (no auto-title, OpenLayers/Format/WMSCapabilities/v1_1.js)
File: v1_1_0 (no auto-title, OpenLayers/Format/WMSCapabilities/v1_1_0.js)
File: v1_1_1 (no auto-title, OpenLayers/Format/WMSCapabilities/v1_1_1.js)
File: v1_3 (no auto-title, OpenLayers/Format/WMSCapabilities/v1_3.js)
File: v1_3_0 (no auto-title, OpenLayers/Format/WMSCapabilities/v1_3_0.js)
File: WMSCapabilities/v1_1_1_WMSC (no auto-title, OpenLayers/Format/WMSCapabilities/v1_1_1_WMSC.js)
} # Group: WMSCapabilities
Group: WMSDescribeLayer {
File: WMSDescribeLayer (no auto-title, OpenLayers/Format/WMSDescribeLayer.js)
File: v1_1 (no auto-title, OpenLayers/Format/WMSDescribeLayer/v1_1.js)
} # Group: WMSDescribeLayer
File: WFSDescribeFeatureType (no auto-title, OpenLayers/Format/WFSDescribeFeatureType.js)
File: WKT (no auto-title, OpenLayers/Format/WKT.js)
File: WMSGetFeatureInfo (no auto-title, OpenLayers/Format/WMSGetFeatureInfo.js)
File: WMTSCapabilities (no auto-title, OpenLayers/Format/WMTSCapabilities.js)
File: WMTSCapabilities.v1_0_0 (no auto-title, OpenLayers/Format/WMTSCapabilities/v1_0_0.js)
File: WPSCapabilities (no auto-title, OpenLayers/Format/WPSCapabilities.js)
File: WPSCapabilities.v1_0_0 (no auto-title, OpenLayers/Format/WPSCapabilities/v1_0_0.js)
File: WPSDescribeProcess (no auto-title, OpenLayers/Format/WPSDescribeProcess.js)
File: WPSExecute version 1.0.0 (no auto-title, OpenLayers/Format/WPSExecute.js)
File: XLS (no auto-title, OpenLayers/Format/XLS.js)
File: XLS.v1 (no auto-title, OpenLayers/Format/XLS/v1.js)
File: XLS.v1_1_0 (no auto-title, OpenLayers/Format/XLS/v1_1_0.js)
File: XML (no auto-title, OpenLayers/Format/XML.js)
} # Group: Format
Group: Geometry {
File: Geometry (no auto-title, OpenLayers/Geometry.js)
File: Collection (no auto-title, OpenLayers/Geometry/Collection.js)
File: Curve (no auto-title, OpenLayers/Geometry/Curve.js)
File: LinearRing (no auto-title, OpenLayers/Geometry/LinearRing.js)
File: LineString (no auto-title, OpenLayers/Geometry/LineString.js)
File: MultiLineString (no auto-title, OpenLayers/Geometry/MultiLineString.js)
File: MultiPoint (no auto-title, OpenLayers/Geometry/MultiPoint.js)
File: MultiPolygon (no auto-title, OpenLayers/Geometry/MultiPolygon.js)
File: Point (no auto-title, OpenLayers/Geometry/Point.js)
File: Polygon (no auto-title, OpenLayers/Geometry/Polygon.js)
} # Group: Geometry
Group: Handler {
File: Handler (no auto-title, OpenLayers/Handler.js)
File: Box (no auto-title, OpenLayers/Handler/Box.js)
File: Click (no auto-title, OpenLayers/Handler/Click.js)
File: Drag (no auto-title, OpenLayers/Handler/Drag.js)
File: Feature (no auto-title, OpenLayers/Handler/Feature.js)
File: Hover (no auto-title, OpenLayers/Handler/Hover.js)
File: Keyboard (no auto-title, OpenLayers/Handler/Keyboard.js)
File: MouseWheel (no auto-title, OpenLayers/Handler/MouseWheel.js)
File: Path (no auto-title, OpenLayers/Handler/Path.js)
File: Pinch (no auto-title, OpenLayers/Handler/Pinch.js)
File: Point (no auto-title, OpenLayers/Handler/Point.js)
File: Polygon (no auto-title, OpenLayers/Handler/Polygon.js)
File: RegularPolygon (no auto-title, OpenLayers/Handler/RegularPolygon.js)
} # Group: Handler
File: Icon (no auto-title, OpenLayers/Icon.js)
File: Kinetic (no auto-title, OpenLayers/Kinetic.js)
Group: Lang {
File: Lang (no auto-title, OpenLayers/Lang.js)
File: ar (no auto-title, OpenLayers/Lang/ar.js)
File: be-tarask (no auto-title, OpenLayers/Lang/be-tarask.js)
File: bg (no auto-title, OpenLayers/Lang/bg.js)
File: br (no auto-title, OpenLayers/Lang/br.js)
File: ca (no auto-title, OpenLayers/Lang/ca.js)
File: cs-CZ (no auto-title, OpenLayers/Lang/cs-CZ.js)
File: da-DK (no auto-title, OpenLayers/Lang/da-DK.js)
File: de (no auto-title, OpenLayers/Lang/de.js)
File: en (no auto-title, OpenLayers/Lang/en.js)
File: en-CA (no auto-title, OpenLayers/Lang/en-CA.js)
File: es (no auto-title, OpenLayers/Lang/es.js)
File: el (no auto-title, OpenLayers/Lang/el.js)
File: fi (no auto-title, OpenLayers/Lang/fi.js)
File: fr (no auto-title, OpenLayers/Lang/fr.js)
File: fur (no auto-title, OpenLayers/Lang/fur.js)
File: gl (no auto-title, OpenLayers/Lang/gl.js)
File: gsw (no auto-title, OpenLayers/Lang/gsw.js)
File: hr (no auto-title, OpenLayers/Lang/hr.js)
File: hsb (no auto-title, OpenLayers/Lang/hsb.js)
File: hu (no auto-title, OpenLayers/Lang/hu.js)
File: ia (no auto-title, OpenLayers/Lang/ia.js)
File: id (no auto-title, OpenLayers/Lang/id.js)
File: io (no auto-title, OpenLayers/Lang/io.js)
File: is (no auto-title, OpenLayers/Lang/is.js)
File: it (no auto-title, OpenLayers/Lang/it.js)
File: ja (no auto-title, OpenLayers/Lang/ja.js)
File: km (no auto-title, OpenLayers/Lang/km.js)
File: ksh (no auto-title, OpenLayers/Lang/ksh.js)
File: lt (no auto-title, OpenLayers/Lang/lt.js)
File: nds (no auto-title, OpenLayers/Lang/nds.js)
File: nb (no auto-title, OpenLayers/Lang/nb.js)
File: nl (no auto-title, OpenLayers/Lang/nl.js)
File: nn (no auto-title, OpenLayers/Lang/nn.js)
File: oc (no auto-title, OpenLayers/Lang/oc.js)
File: pl (no auto-title, OpenLayers/Lang/pl.js)
File: pt (no auto-title, OpenLayers/Lang/pt.js)
File: pt-BR (no auto-title, OpenLayers/Lang/pt-BR.js)
File: ru (no auto-title, OpenLayers/Lang/ru.js)
File: sk (no auto-title, OpenLayers/Lang/sk.js)
File: sv-SE (no auto-title, OpenLayers/Lang/sv-SE.js)
File: te (no auto-title, OpenLayers/Lang/te.js)
File: vi (no auto-title, OpenLayers/Lang/vi.js)
File: zh-CN (no auto-title, OpenLayers/Lang/zh-CN.js)
File: zh-TW (no auto-title, OpenLayers/Lang/zh-TW.js)
} # Group: Lang
Group: Layer {
File: Layer (no auto-title, OpenLayers/Layer.js)
File: ArcGISCache.js (no auto-title, OpenLayers/Layer/ArcGISCache.js)
File: ArcGIS93Rest (no auto-title, OpenLayers/Layer/ArcGIS93Rest.js)
File: ArcIMS (no auto-title, OpenLayers/Layer/ArcIMS.js)
File: Bing (no auto-title, OpenLayers/Layer/Bing.js)
File: Boxes (no auto-title, OpenLayers/Layer/Boxes.js)
File: EventPane (no auto-title, OpenLayers/Layer/EventPane.js)
File: FixedZoomLevels (no auto-title, OpenLayers/Layer/FixedZoomLevels.js)
File: GeoRSS (no auto-title, OpenLayers/Layer/GeoRSS.js)
File: Google (no auto-title, OpenLayers/Layer/Google.js)
File: Google.v3 (no auto-title, OpenLayers/Layer/Google/v3.js)
File: Grid (no auto-title, OpenLayers/Layer/Grid.js)
File: HTTPRequest (no auto-title, OpenLayers/Layer/HTTPRequest.js)
File: Image (no auto-title, OpenLayers/Layer/Image.js)
File: KaMap (no auto-title, OpenLayers/Layer/KaMap.js)
File: KaMapCache (no auto-title, OpenLayers/Layer/KaMapCache.js)
File: MapGuide (no auto-title, OpenLayers/Layer/MapGuide.js)
File: MapServer (no auto-title, OpenLayers/Layer/MapServer.js)
File: Markers (no auto-title, OpenLayers/Layer/Markers.js)
File: PointGrid (no auto-title, OpenLayers/Layer/PointGrid.js)
File: PointTrack (no auto-title, OpenLayers/Layer/PointTrack.js)
File: SphericalMercator (no auto-title, OpenLayers/Layer/SphericalMercator.js)
File: Text (no auto-title, OpenLayers/Layer/Text.js)
File: TileCache (no auto-title, OpenLayers/Layer/TileCache.js)
File: TMS (no auto-title, OpenLayers/Layer/TMS.js)
File: Vector (no auto-title, OpenLayers/Layer/Vector.js)
File: Vector.RootContainer (no auto-title, OpenLayers/Layer/Vector/RootContainer.js)
File: WMS (no auto-title, OpenLayers/Layer/WMS.js)
File: WMTS (no auto-title, OpenLayers/Layer/WMTS.js)
File: WorldWind (no auto-title, OpenLayers/Layer/WorldWind.js)
File: XYZ (no auto-title, OpenLayers/Layer/XYZ.js)
File: Zoomify (no auto-title, OpenLayers/Layer/Zoomify.js)
} # Group: Layer
File: Map (no auto-title, OpenLayers/Map.js)
Group: Marker {
File: Marker (no auto-title, OpenLayers/Marker.js)
File: Box (no auto-title, OpenLayers/Marker/Box.js)
} # Group: Marker
Group: Popup {
File: Popup (no auto-title, OpenLayers/Popup.js)
File: Anchored (no auto-title, OpenLayers/Popup/Anchored.js)
File: Framed (no auto-title, OpenLayers/Popup/Framed.js)
File: FramedCloud (no auto-title, OpenLayers/Popup/FramedCloud.js)
} # Group: Popup
File: Projection (no auto-title, OpenLayers/Projection.js)
Group: Protocol {
File: Protocol (no auto-title, OpenLayers/Protocol.js)
File: HTTP (no auto-title, OpenLayers/Protocol/HTTP.js)
Group: WFS {
File: WFS (no auto-title, OpenLayers/Protocol/WFS.js)
File: v1 (no auto-title, OpenLayers/Protocol/WFS/v1.js)
File: v1_0_0 (no auto-title, OpenLayers/Protocol/WFS/v1_0_0.js)
File: v1_1_0 (no auto-title, OpenLayers/Protocol/WFS/v1_1_0.js)
} # Group: WFS
File: Script (no auto-title, OpenLayers/Protocol/Script.js)
File: SOS.DEFAULTS (no auto-title, OpenLayers/Protocol/SOS.js)
File: SOS.v1_0_0 (no auto-title, OpenLayers/Protocol/SOS/v1_0_0.js)
} # Group: Protocol
Group: Renderer {
File: Renderer (no auto-title, OpenLayers/Renderer.js)
File: Canvas (no auto-title, OpenLayers/Renderer/Canvas.js)
File: ElementsIndexer (no auto-title, OpenLayers/Renderer/Elements.js)
File: SVG (no auto-title, OpenLayers/Renderer/SVG.js)
File: VML (no auto-title, OpenLayers/Renderer/VML.js)
} # Group: Renderer
Group: Request {
File: Request (no auto-title, OpenLayers/Request.js)
File: XMLHttpRequest (no auto-title, OpenLayers/Request/XMLHttpRequest.js)
} # Group: Request
File: Rule (no auto-title, OpenLayers/Rule.js)
File: SingleFile.js (no auto-title, OpenLayers/SingleFile.js)
Group: Strategy {
File: Strategy (no auto-title, OpenLayers/Strategy.js)
File: BBOX (no auto-title, OpenLayers/Strategy/BBOX.js)
File: Cluster (no auto-title, OpenLayers/Strategy/Cluster.js)
File: Filter (no auto-title, OpenLayers/Strategy/Filter.js)
File: Fixed (no auto-title, OpenLayers/Strategy/Fixed.js)
File: Paging (no auto-title, OpenLayers/Strategy/Paging.js)
File: Refresh (no auto-title, OpenLayers/Strategy/Refresh.js)
File: Save (no auto-title, OpenLayers/Strategy/Save.js)
} # Group: Strategy
File: Style (no auto-title, OpenLayers/Style.js)
File: Style2 (no auto-title, OpenLayers/Style2.js)
File: StyleMap (no auto-title, OpenLayers/StyleMap.js)
Group: Symbolizer {
File: Symbolizer (no auto-title, OpenLayers/Symbolizer.js)
File: Line (no auto-title, OpenLayers/Symbolizer/Line.js)
File: Point (no auto-title, OpenLayers/Symbolizer/Point.js)
File: Polygon (no auto-title, OpenLayers/Symbolizer/Polygon.js)
File: Raster (no auto-title, OpenLayers/Symbolizer/Raster.js)
File: Text (no auto-title, OpenLayers/Symbolizer/Text.js)
} # Group: Symbolizer
Group: Tile {
File: Tile (no auto-title, OpenLayers/Tile.js)
File: Image (no auto-title, OpenLayers/Tile/Image.js)
File: Image.IFrame (no auto-title, OpenLayers/Tile/Image/IFrame.js)
} # Group: Tile
File: Tween (no auto-title, OpenLayers/Tween.js)
File: Util (no auto-title, OpenLayers/Util.js)
File: Spherical (no auto-title, OpenLayers/Spherical.js)
File: Deprecated (no auto-title, deprecated.js)
} # Group: OpenLayers
Group: Index {
Index: Everything
Class Index: Classes
Constant Index: Constants
Function Index: Functions
Property Index: Properties
File Index: Files
Constructor Index: Constructor
} # Group: Index

View File

@@ -1,20 +0,0 @@
p {
text-indent: 0; margin-bottom: 1em;
}
.MGroup {
font-variant: normal;
margin: 0.4em 0 0em 10px
}
.MTitle {
font-variant: normal;
}
.CGroup .CTitle {
font-variant: normal;
}
.SGroup .SEntry {
font-variant: normal;
}

View File

@@ -1,102 +0,0 @@
Format: 1.52
# This is the Natural Docs topics file for this project. If you change anything
# here, it will apply to THIS PROJECT ONLY. If you'd like to change something
# for all your projects, edit the Topics.txt in Natural Docs' Config directory
# instead.
# If you'd like to prevent keywords from being recognized by Natural Docs, you
# can do it like this:
# Ignore Keywords: [keyword], [keyword], ...
#
# Or you can use the list syntax like how they are defined:
# Ignore Keywords:
# [keyword]
# [keyword], [plural keyword]
# ...
#-------------------------------------------------------------------------------
# SYNTAX:
#
# Topic Type: [name]
# Alter Topic Type: [name]
# Creates a new topic type or alters one from the main file. Each type gets
# its own index and behavior settings. Its name can have letters, numbers,
# spaces, and these charaters: - / . '
#
# Plural: [name]
# Sets the plural name of the topic type, if different.
#
# Keywords:
# [keyword]
# [keyword], [plural keyword]
# ...
# Defines or adds to the list of keywords for the topic type. They may only
# contain letters, numbers, and spaces and are not case sensitive. Plural
# keywords are used for list topics. You can redefine keywords found in the
# main topics file.
#
# Index: [yes|no]
# Whether the topics get their own index. Defaults to yes. Everything is
# included in the general index regardless of this setting.
#
# Scope: [normal|start|end|always global]
# How the topics affects scope. Defaults to normal.
# normal - Topics stay within the current scope.
# start - Topics start a new scope for all the topics beneath it,
# like class topics.
# end - Topics reset the scope back to global for all the topics
# beneath it.
# always global - Topics are defined as global, but do not change the scope
# for any other topics.
#
# Class Hierarchy: [yes|no]
# Whether the topics are part of the class hierarchy. Defaults to no.
#
# Page Title If First: [yes|no]
# Whether the topic's title becomes the page title if it's the first one in
# a file. Defaults to no.
#
# Break Lists: [yes|no]
# Whether list topics should be broken into individual topics in the output.
# Defaults to no.
#
# Can Group With: [type], [type], ...
# Defines a list of topic types that this one can possibly be grouped with.
# Defaults to none.
#-------------------------------------------------------------------------------
# The following topics are defined in the main file, if you'd like to alter
# their behavior or add keywords:
#
# Generic, Class, Interface, Section, File, Group, Function, Variable,
# Property, Type, Constant, Enumeration, Event, Delegate, Macro,
# Database, Database Table, Database View, Database Index, Database
# Cursor, Database Trigger, Cookie, Build Target
# If you add something that you think would be useful to other developers
# and should be included in Natural Docs by default, please e-mail it to
# topics [at] naturaldocs [dot] org.
Topic Type: Constructor
Class Hierarchy: Yes
Keywords:
constructor
initialize
Alter Topic Type: Function
Add Keywords:
apimethod
apifunction
Alter Topic Type: Property
Add Keywords:
apiproperty

View File

@@ -1,57 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>OpenLayers KML Parser Example</title>
<link rel="stylesheet" href="style.css" type="text/css">
<script src="../lib/OpenLayers.js"></script>
<script type="text/javascript">
function parseData(req) {
g = new OpenLayers.Format.KML({extractStyles: true});
html = "";
features = g.read(req.responseText);
for(var feat in features) {
html += "Feature: Geometry: "+ features[feat].geometry+",";
html += "<ul>";
for (var j in features[feat].attributes) {
html += "<li>Attribute "+j+":"+features[feat].attributes[j]+"</li>";
}
html += "</ul>";
html += "<ul>";
for (var j in features[feat].style) {
html += "<li>Style "+j+":"+features[feat].style[j]+"</li>";
}
html += "</ul>"
}
document.getElementById('output').innerHTML = html;
}
function load() {
OpenLayers.Request.GET({
url: "kml/lines.kml",
success: parseData
});
}
</script>
</head>
<body onload="load()">
<h1 id="title">KML Parser Example</h1>
<div id="tags">
KML, parsing, format
</div>
<p id="shortdesc">
Demonstrate the operation of the KML parser.
</p>
<div id="output"></div>
<div id="docs">
<p>This script reads data from a KML file and parses out the
coordinates, appending them to a HTML string with markup tags.
This markup is dumped to an element in the page.</p>
</div>
</body>
</html>

View File

@@ -1,202 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>OpenLayers SLD based selection control</title>
<link rel="stylesheet" href="../theme/default/style.css" type="text/css">
<link rel="stylesheet" href="style.css" type="text/css">
<style type="text/css">
.olControlSLDSelectBoxActive {
cursor: crosshair;
}
.olControlSLDSelectPolygonActive {
cursor: crosshair;
}
.olControlSLDSelectLineActive {
cursor: crosshair;
}
.olControlSLDSelectPointActive {
cursor: pointer;
}
</style>
<script src="../lib/OpenLayers.js"></script>
<script type="text/javascript">
var map, controls, layers;
function init(){
OpenLayers.ProxyHost= "proxy.cgi?url=";
map = new OpenLayers.Map('map', {allOverlays: true, controls: []});
var url = "http://demo.opengeo.org/geoserver/wms";
layers = {
states: new OpenLayers.Layer.WMS("State boundary", url,
{layers: 'topp:tasmania_state_boundaries', format: 'image/gif', transparent: 'TRUE'},
{singleTile: true}),
roads: new OpenLayers.Layer.WMS("Roads", url,
{layers: 'topp:tasmania_roads', format: 'image/gif', transparent: 'TRUE'},
{singleTile: true}),
waterbodies: new OpenLayers.Layer.WMS("Water bodies", url,
{layers: 'topp:tasmania_water_bodies', format: 'image/gif', transparent: 'TRUE'},
{singleTile: true}),
cities: new OpenLayers.Layer.WMS("Cities", url,
{layers: 'topp:tasmania_cities', format: 'image/gif', transparent: 'TRUE'},
{singleTile: true})
};
for (var key in layers) {
map.addLayer(layers[key]);
}
map.setCenter(new OpenLayers.LonLat(146.65748632815,-42.230763671875), 7);
map.addControl(new OpenLayers.Control.LayerSwitcher());
controls = {
navigation: new OpenLayers.Control.Navigation(),
box: new OpenLayers.Control.SLDSelect(
OpenLayers.Handler.RegularPolygon,
{
displayClass: 'olControlSLDSelectBox',
layers: [layers['waterbodies']],
handlerOptions: {irregular: true}
}
),
polygon: new OpenLayers.Control.SLDSelect(
OpenLayers.Handler.Polygon,
{
displayClass: 'olControlSLDSelectPolygon',
layers: [layers['waterbodies']]
}
),
line: new OpenLayers.Control.SLDSelect(
OpenLayers.Handler.Path,
{
displayClass: 'olControlSLDSelectLine',
layers: [layers['waterbodies']]
}
),
point: new OpenLayers.Control.SLDSelect(
OpenLayers.Handler.Click,
{
displayClass: 'olControlSLDSelectPoint',
layers: [layers['waterbodies']]
}
),
circle: new OpenLayers.Control.SLDSelect(
OpenLayers.Handler.RegularPolygon,
{
displayClass: 'olControlSLDSelectBox',
layers: [layers['waterbodies']],
handlerOptions: {sides: 30}
}
)
};
for(var key in controls) {
map.addControl(controls[key]);
}
}
function toggleControl(element) {
for(var key in controls) {
var control = controls[key];
if(element.value == key && element.checked) {
control.activate();
} else {
control.deactivate();
}
}
}
function toggleSelectionLayer(element) {
var selectLayers = [];
var elements = element.value.split("_");
for (var key in layers) {
var layer = layers[key];
for (var i=0, len=elements.length; i<len; i++) {
var value = elements[i];
if (value == key && element.checked) {
selectLayers.push(layer);
}
}
}
for (var i=0, len=this.map.controls.length; i<len; i++) {
var control = this.map.controls[i];
if (control instanceof OpenLayers.Control.SLDSelect) {
control.setLayers(selectLayers);
}
}
}
</script>
</head>
<body onload="init()">
<h1 id="title">SLD based selection on WMS layers</h1>
<div id="tags">
sld, sldselect, styling, style
</div>
<div id="shortdesc">Using Styled Layer Descriptors to make a selection on WMS layers</div>
<div id="map" style="width: 512px; height: 256px; border: 1px solid red;"></div>
<div id="docs">
This example uses the OpenLayers.Control.SLDSelect to select features in a WMS
layer. The features are highlighted using Styled Layer Descriptors (SLD). The
control supports point, box, line and polygon selection modes by configuring the
appriopriate handler.
</div>
<div id="controls">
<ul id="controlToggle"><b>Map Controls</b>
<li>
<input type="radio" name="control" value="navigation" id="noneToggle" onclick="toggleControl(this);" CHECKED>
<label for="noneToggle">navigate</label>
</li>
<li>
<input type="radio" name="control" value="box" id="boxToggle" onclick="toggleControl(this);">
<label for="boxToggle">SLD select with box</label>
</li>
<li>
<input type="radio" name="control" value="polygon" id="polygonToggle" onclick="toggleControl(this);">
<label for="polygonToggle">SLD select with polygon</label>
</li>
<li>
<input type="radio" name="control" value="line" id="lineToggle" onclick="toggleControl(this);">
<label for="lineToggle">SLD select with line</label>
</li>
<li>
<input type="radio" name="control" value="point" id="pointToggle" onclick="toggleControl(this);">
<label for="pointToggle">SLD select with point</label>
</li>
<li>
<input type="radio" name="control" value="circle" id="circleToggle" onclick="toggleControl(this);">
<label for="circleToggle">SLD select with circle</label>
</li>
</ul>
</div>
<div id="layers">
<ul id="layerToggle"><b>Selection layer</b>
<li>
<input type="radio" name="layer" value="waterbodies" id="waterbodiesToggle" onclick="toggleSelectionLayer(this);" CHECKED>
<label for="noneToggle">Water bodies</label>
</li>
<li>
<input type="radio" name="layer" value="cities" id="citiesToggle" onclick="toggleSelectionLayer(this);">
<label for="citiesToggle">Cities</label>
</li>
<li>
<input type="radio" name="layer" value="roads" id="roadsToggle" onclick="toggleSelectionLayer(this);">
<label for="roadsToggle">Roads</label>
</li>
<li>
<input type="radio" name="layer" value="roads_cities" id="roadsCitiesToggle" onclick="toggleSelectionLayer(this);">
<label for="roadsCitiesToggle">Roads and cities</label>
</li>
</ul>
</div>
</body>
</html>

View File

@@ -1,52 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>OpenLayers WMSDescribeLayer Parser Example</title>
<link rel="stylesheet" href="style.css" type="text/css">
<script src="../lib/OpenLayers.js"></script>
<script type="text/javascript">
function parseData(req) {
format = new OpenLayers.Format.WMSDescribeLayer();
html = "<br>";
resp = format.read(req.responseText);
var layerDescriptions = resp.layerDescriptions;
for(var i = 0; i < layerDescriptions.length; i++) {
html += "Layer: typeName: "+layerDescriptions[i].typeName+",";
html += "<ul>";
html += "<li>owsURL: "+layerDescriptions[i].owsURL+"</li>";
html += "<li>owsType: "+layerDescriptions[i].owsType+"</li>";
html += "</ul>"
}
document.getElementById('output').innerHTML = html;
}
function load() {
OpenLayers.Request.GET({
url: "xml/wmsdescribelayer.xml",
success: parseData
});
}
</script>
</head>
<body onload="load()">
<h1 id="title">WMSDescribeLayer Parser Example</h1>
<div id="tags">
wmsdescribelayer, parser, cleanup
</div>
<p id="shortdesc">
Demonstrate the operation of the WMSDescribeLayer parser.
</p>
<div id="output"></div>
<div id="docs">
<p>This script reads data from a file and parses out the coordinates,
appending them to a HTML string with markup tags. This markup is
dumped to an element in the page.</p>
</div>
</body>
</html>

View File

@@ -1,100 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>OpenLayers Accelerometer Usage</title>
<link rel="stylesheet" href="../theme/default/style.css" type="text/css">
<link rel="stylesheet" href="style.css" type="text/css">
<script type="text/javascript" src="browser.js"></script>
<style type="text/css">
.olControlAttribution {
bottom: 5px;
}
</style>
<script type="text/javascript">
function init() {
if (isEventSupported('deviceorientation', window) || isEventSupported('mozorientation', window) || isEventSupported('devicemotion', window)) {
if (window.DeviceOrientationEvent) {
window.addEventListener("deviceorientation", function (event) {
document.getElementById('resultDeviceOrientation').innerHTML = '';
if (typeof(event.alpha) != 'undefined') {
document.getElementById('resultDeviceOrientation').innerHTML = document.getElementById('resultDeviceOrientation').innerHTML + "Alpha: " + event.alpha + "<br>";
document.getElementById('resultDeviceOrientation').innerHTML = document.getElementById('resultDeviceOrientation').innerHTML + "Beta: " + event.beta + "<br>";
document.getElementById('resultDeviceOrientation').innerHTML = document.getElementById('resultDeviceOrientation').innerHTML + "Gamma: " + event.gamma + "<br>";
}
if (typeof(event.absolute) != 'undefined') {
document.getElementById('resultDeviceOrientation').innerHTML = document.getElementById('resultDeviceOrientation').innerHTML + "Gamma: " + event.absolute + "<br>";
}
if (typeof(event.compassCalibrate) != 'undefined') {
document.getElementById('resultDeviceOrientation').innerHTML = document.getElementById('resultDeviceOrientation').innerHTML + "Gamma: " + event.compassCalibrated + "<br>";
}
}, true);
}
if (window.DeviceMotionEvent) {
window.addEventListener('devicemotion', function (event) {
document.getElementById('resultDeviceMotion').innerHTML = '';
if (typeof(event.accelerationIncludingGravity) != 'undefined') {
document.getElementById('resultDeviceMotion').innerHTML = document.getElementById('resultDeviceMotion').innerHTML + "accelerationIncludingGravity.x: " + event.accelerationIncludingGravity.x + "<br>";
document.getElementById('resultDeviceMotion').innerHTML = document.getElementById('resultDeviceMotion').innerHTML + "accelerationIncludingGravity.y: " + event.accelerationIncludingGravity.y + "<br>";
document.getElementById('resultDeviceMotion').innerHTML = document.getElementById('resultDeviceMotion').innerHTML + "accelerationIncludingGravity.z: " + event.accelerationIncludingGravity.z + "<br>";
}
if (typeof(event.acceleration) != 'undefined') {
document.getElementById('resultDeviceMotion').innerHTML = document.getElementById('resultDeviceMotion').innerHTML + "acceleration.x: " + event.acceleration.x + "<br>";
document.getElementById('resultDeviceMotion').innerHTML = document.getElementById('resultDeviceMotion').innerHTML + "acceleration.y: " + event.acceleration.y + "<br>";
document.getElementById('resultDeviceMotion').innerHTML = document.getElementById('resultDeviceMotion').innerHTML + "acceleration.z: " + event.acceleration.z + "<br>";
}
if (typeof(event.rotationRate) != 'undefined') {
document.getElementById('resultDeviceMotion').innerHTML = document.getElementById('resultDeviceMotion').innerHTML + "rotationRate.alpha: " + event.rotationRate.alpha + "<br>";
document.getElementById('resultDeviceMotion').innerHTML = document.getElementById('resultDeviceMotion').innerHTML + "rotationRate.beta: " + event.rotationRate.beta + "<br>";
document.getElementById('resultDeviceMotion').innerHTML = document.getElementById('resultDeviceMotion').innerHTML + "rotationRate.gamma: " + event.rotationRate.gamma + "<br>";
}
}, true);
}
if (window.MozOrientation) {
window.addEventListener("MozOrientation", function (orientation) {
document.getElementById('resultMozOrientation').innerHTML = "orientation.x: " + orientation.x + "<br>";
document.getElementById('resultMozOrientation').innerHTML = document.getElementById('resultMozOrientation').innerHTML + "orientation.y: " + orientation.y + "<br>";
document.getElementById('resultMozOrientation').innerHTML = document.getElementById('resultMozOrientation').innerHTML + "orientation.z: " + orientation.z + "<br>";
}, true);
}
} else {
alert("Unfortunately, your brower doesn't support the orientation usage");
}
}
</script>
</head>
<body onload="init()">
<h1 id="title">Accelerometer</h1>
<p id="shortdesc">
The goal of this script is to demonstrate the usage of accelerometer.
</p>
<p>
The orientation specification can be found <a href="http://dev.w3.org/geo/api/spec-source-orientation.html">here</a>.
</p>
<div id="tags">
browser, vendor, mobile, orientation
</div>
<h1>Device motion</h1>
<div id="resultDeviceMotion">
</div>
<h1>Device orientation</h1>
<div id="resultDeviceOrientation">
</div>
<h1>MOZ orientation</h1>
<div id="resultMozOrientation">
</div>
</body>
</html>

View File

@@ -1,69 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>Accessible Custom Click Control</title>
<link rel="stylesheet" href="../theme/default/style.css" type="text/css">
<link rel="stylesheet" href="style.css" type="text/css">
<style type="text/css">
<style type="text/css">
a {
text-decoration: none;
font-size: 1.2em;
}
a em {
font-style: normal;
font-weight: normal;
text-decoration: underline;
}
a:hover {
text-decoration: underline;
}
a.api {
font-size:1em;
text-decoration:underline;
}
a.accesskey {
color: white;
}
a.accesskey:focus {
color: #436976;
}
a.zoom {
padding-right: 20px;
}
</style>
<script src="../lib/Firebug/firebug.js"></script>
<script src="../lib/OpenLayers.js"></script>
<script src="accessible-click-control.js"></script>
</head>
<body onload="init()">
<h1 id="title">An accessible click control implementation</h1>
<div id="tags">
click, control, accessibility
</div>
<a class="accesskey"
href=""
accesskey="1"
onclick="document.getElementById('map').focus();return false;">
Jump to map
</a>
<div id="map" class="smallmap" tabindex="0"></div>
<p id="desc">
Demonstrate the KeyboardDefaults control as well as a control that
allows clicking on the map using the keyboard.
First focus the map (using tab key or mouse), then press the 'i'
key to activate the query control. You can then move the point
using arrow keys. Press 'RETURN' to get the coordinate. Press 'i'
again to deactivate the control.
</p>
</body>
</html>

View File

@@ -1,199 +0,0 @@
var map, navigationControl, queryControl;
function init(){
map = new OpenLayers.Map('map', {controls: []});
var layer = new OpenLayers.Layer.WMS(
"OpenLayers WMS",
"http://vmap0.tiles.osgeo.org/wms/vmap0",
{layers: 'basic'}
);
map.addLayers([layer]);
navigationControl = new OpenLayers.Control.KeyboardDefaults({
observeElement: 'map'
});
map.addControl(navigationControl);
queryControl = new OpenLayers.Control.KeyboardClick({
observeElement: 'map'
});
map.addControl(queryControl);
map.zoomToMaxExtent();
}
/**
* Class: OpenLayers.Control.KeyboardClick
*
* A custom control that (a) adds a vector point that can be moved using the
* arrow keys of the keyboard, and (b) displays a browser alert window when the
* RETURN key is pressed. The control can be activated/deactivated using the
* "i" key. When activated the control deactivates any KeyboardDefaults control
* in the map so that the map is not moved when the arrow keys are pressed.
*
* This control relies on the OpenLayers.Handler.KeyboardPoint custom handler.
*/
OpenLayers.Control.KeyboardClick = OpenLayers.Class(OpenLayers.Control, {
initialize: function(options) {
OpenLayers.Control.prototype.initialize.apply(this, [options]);
var observeElement = this.observeElement || document;
this.handler = new OpenLayers.Handler.KeyboardPoint(this, {
done: this.onClick,
cancel: this.deactivate
}, {
observeElement: observeElement
});
OpenLayers.Event.observe(
observeElement,
"keydown",
OpenLayers.Function.bindAsEventListener(
function(evt) {
if (evt.keyCode == 73) { // "i"
if (this.active) {
this.deactivate();
} else {
this.activate();
}
}
},
this
)
);
},
onClick: function(geometry) {
alert("You clicked near " + geometry.x + " N, " +
geometry.y + " E");
},
activate: function() {
if(!OpenLayers.Control.prototype.activate.apply(this, arguments)) {
return false;
}
// deactivate any KeyboardDefaults control
var keyboardDefaults = this.map.getControlsByClass(
'OpenLayers.Control.KeyboardDefaults')[0];
if (keyboardDefaults) {
keyboardDefaults.deactivate();
}
return true;
},
deactivate: function() {
if(!OpenLayers.Control.prototype.deactivate.apply(this, arguments)) {
return false;
}
// reactivate any KeyboardDefaults control
var keyboardDefaults = this.map.getControlsByClass(
'OpenLayers.Control.KeyboardDefaults')[0];
if (keyboardDefaults) {
keyboardDefaults.activate();
}
return true;
}
});
/**
* Class: OpenLayers.Handler.KeyboardPoint
*
* A custom handler that displays a vector point that can be moved
* using the arrow keys of the keyboard.
*/
OpenLayers.Handler.KeyboardPoint = OpenLayers.Class(OpenLayers.Handler, {
KEY_EVENTS: ["keydown"],
initialize: function(control, callbacks, options) {
OpenLayers.Handler.prototype.initialize.apply(this, arguments);
// cache the bound event listener method so it can be unobserved later
this.eventListener = OpenLayers.Function.bindAsEventListener(
this.handleKeyEvent, this
);
},
activate: function() {
if(!OpenLayers.Handler.prototype.activate.apply(this, arguments)) {
return false;
}
this.layer = new OpenLayers.Layer.Vector(this.CLASS_NAME);
this.map.addLayer(this.layer);
this.observeElement = this.observeElement || document;
for (var i=0, len=this.KEY_EVENTS.length; i<len; i++) {
OpenLayers.Event.observe(
this.observeElement, this.KEY_EVENTS[i], this.eventListener);
}
if(!this.point) {
this.createFeature();
}
return true;
},
deactivate: function() {
if (!OpenLayers.Handler.prototype.deactivate.apply(this, arguments)) {
return false;
}
for (var i=0, len=this.KEY_EVENTS.length; i<len; i++) {
OpenLayers.Event.stopObserving(
this.observeElement, this.KEY_EVENTS[i], this.eventListener);
}
this.map.removeLayer(this.layer);
this.destroyFeature();
return true;
},
handleKeyEvent: function (evt) {
switch(evt.keyCode) {
case OpenLayers.Event.KEY_LEFT:
this.modifyFeature(-3, 0);
break;
case OpenLayers.Event.KEY_RIGHT:
this.modifyFeature(3, 0);
break;
case OpenLayers.Event.KEY_UP:
this.modifyFeature(0, 3);
break;
case OpenLayers.Event.KEY_DOWN:
this.modifyFeature(0, -3);
break;
case OpenLayers.Event.KEY_RETURN:
this.callback('done', [this.point.geometry.clone()]);
break;
case OpenLayers.Event.KEY_ESC:
this.callback('cancel');
break;
}
},
modifyFeature: function(lon, lat) {
if(!this.point) {
this.createFeature();
}
var resolution = this.map.getResolution();
this.point.geometry.x = this.point.geometry.x + lon * resolution;
this.point.geometry.y = this.point.geometry.y + lat * resolution;
this.callback("modify", [this.point.geometry, this.point, false]);
this.point.geometry.clearBounds();
this.drawFeature();
},
createFeature: function() {
var center = this.map.getCenter();
var geometry = new OpenLayers.Geometry.Point(
center.lon, center.lat
);
this.point = new OpenLayers.Feature.Vector(geometry);
this.callback("create", [this.point.geometry, this.point]);
this.point.geometry.clearBounds();
this.layer.addFeatures([this.point], {silent: true});
},
destroyFeature: function() {
this.layer.destroyFeatures([this.point]);
this.point = null;
},
drawFeature: function() {
this.layer.drawFeature(this.point, this.style);
}
});

View File

@@ -1,130 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>Custom and accessible panel</title>
<link rel="stylesheet" href="../theme/default/style.css" type="text/css">
<link rel="stylesheet" href="style.css" type="text/css">
<style type="text/css">
.olControlPanel button {
position: relative;
display: block;
margin: 2px;
border: 1px solid;
padding: 0 5px;
border-radius: 4px;
height: 35px;
background-color: white;
float: left;
overflow: visible; /* needed to remove padding from buttons in IE */
}
.olControlPanel button span {
padding-left: 25px;
}
.olControlPanel button span:first-child {
padding-left: 0;
display: block;
position: absolute;
left: 2px;
}
.olControlPanel .olControlDrawFeatureItemActive span:first-child {
background-image: url("../theme/default/img/draw_line_on.png");
height: 22px;
width: 24px;
top: 5px;
}
.olControlPanel .olControlDrawFeatureItemInactive span:first-child {
background-image: url("../theme/default/img/draw_line_off.png");
height: 22px;
width: 24px;
top: 5px;
}
.olControlPanel .olControlZoomBoxItemInactive span:first-child {
background-image: url("../img/drag-rectangle-off.png");
height: 29px;
width: 29px;
top: 2px;
}
.olControlPanel .olControlZoomBoxItemActive span:first-child {
background-image: url("../img/drag-rectangle-on.png");
height: 29px;
width: 29px;
top: 2px;
}
.olControlPanel .olControlZoomToMaxExtentItemInactive span:first-child {
background-image: url("../img/zoom-world-mini.png");
height: 18px;
width: 18px;
top: 8px;
}
.olControlPanel .navHistory span:first-child {
background-image: url("../theme/default/img/navigation_history.png");
height: 24px;
width: 24px;
top: 4px;
}
.olControlPanel .navHistoryPreviousItemActive span:first-child {
background-position: 0 0;
}
.olControlPanel .navHistoryPreviousItemInactive span:first-child {
background-position: 0 -24px;
}
.olControlPanel .navHistoryNextItemActive span:first-child {
background-position: -24px 0;
}
.olControlPanel .navHistoryNextItemInactive span:first-child {
background-position: -24px -24px;
}
</style>
<script src="../lib/OpenLayers.js"></script>
<script src="accessible-panel.js"></script>
</head>
<body onload="init()">
<h1 id="title">Custom and accessible panel</h1>
<div id="tags">
panels, CSS, style, accessibility, button
</div>
<p id="shortdesc">
Create a custom and accessible panel, styled entirely with
CSS.
</p>
<div id="panel"></div>
<div id="map" class="smallmap"></div>
<div id="docs">
<p>An accessible panel:
<ul>
<li>The buttons are actual HTML buttons. You can therefore
use the TAB key to give the focus to the panel's buttons, and the "ENTER"
key to activate or trigger the corresponding control.</li>
<li>The buttons include text and titles (displayed when a button
is hovered).</li>
<li>If you remove colors from the page (for example using FireFox's <a
href="https://addons.mozilla.org/en-US/firefox/addon/no-color/">No
Color extension</a>) the buttons are still visible, and
accessible using the keyboard.</li>
</ul>
</p>
<p>By default a panel creates buttons as divs. In this example the
<code>createControlMarkup</code> panel function is overridden to create
a more accessible markup for the buttons. See the <a
href="accessible-panel.js" target="_blank"> accessible-panel.js
source</a> to see how this is done.</p>
<p>Note: in IE 8, when a button is pressed its content shifts by 1 pixel.
This is a <a
href="http://labs.findsubstance.com/2009/05/21/ie8-form-button-with-background-image-on-click-css-bug/">known
IE8 bug</a>, with known workarounds. No workaround is applied in this
example though.</p>
</div>
</body>
</html>

View File

@@ -1,64 +0,0 @@
var lon = 5;
var lat = 40;
var zoom = 5;
var map, layer;
function init() {
map = new OpenLayers.Map( 'map', { controls: [] } );
layer = new OpenLayers.Layer.WMS( "OpenLayers WMS",
"http://vmap0.tiles.osgeo.org/wms/vmap0", {layers: 'basic'} );
map.addLayer(layer);
vlayer = new OpenLayers.Layer.Vector( "Editable" );
map.addLayer(vlayer);
zb = new OpenLayers.Control.ZoomBox({
title: "Zoom box: zoom clicking and dragging",
text: "Zoom"
});
var panel = new OpenLayers.Control.Panel({
defaultControl: zb,
createControlMarkup: function(control) {
var button = document.createElement('button'),
iconSpan = document.createElement('span'),
textSpan = document.createElement('span');
iconSpan.innerHTML = '&nbsp;';
button.appendChild(iconSpan);
if (control.text) {
textSpan.innerHTML = control.text;
}
button.appendChild(textSpan);
return button;
}
});
panel.addControls([
zb,
new OpenLayers.Control.DrawFeature(vlayer, OpenLayers.Handler.Path,
{title:'Draw a feature', text: 'Draw'}),
new OpenLayers.Control.ZoomToMaxExtent({
title:"Zoom to the max extent",
text: "World"
})
]);
nav = new OpenLayers.Control.NavigationHistory({
previousOptions: {
title: "Go to previous map position",
text: "Prev"
},
nextOptions: {
title: "Go to next map position",
text: "Next"
},
displayClass: "navHistory"
});
// parent control must be added to the map
map.addControl(nav);
panel.addControls([nav.next, nav.previous]);
map.addControl(panel);
map.setCenter(new OpenLayers.LonLat(lon, lat), zoom);
}

View File

@@ -1,167 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>OpenLayers Accessible Example</title>
<link rel="stylesheet" href="../theme/default/style.css" type="text/css">
<link rel="stylesheet" href="style.css" type="text/css">
<style type="text/css">
table {
border: 1 px solid white;
padding: 0;
}
td {
text-align: center;
}
a {
text-decoration: none;
font-size: 1.2em;
}
a em {
font-style: normal;
font-weight: normal;
text-decoration: underline;
}
a:hover {
text-decoration: underline;
}
a.api {
font-size:1em;
text-decoration:underline;
}
a.accesskey {
color: white;
}
a.accesskey:focus {
color: #436976;
}
a.zoom {
padding-right: 20px;
}
</style>
<script src="../lib/OpenLayers.js"></script>
<script type="text/javascript">
var map = null;
function init(){
var options = {
controls: [
new OpenLayers.Control.KeyboardDefaults({
observeElement: 'map'
})
]
};
map = new OpenLayers.Map('map', options);
var wms = new OpenLayers.Layer.WMS(
"OpenLayers WMS",
"http://vmap0.tiles.osgeo.org/wms/vmap0?",
{layers: 'basic'}
);
map.addLayer(wms);
map.zoomToMaxExtent();
}
</script>
</head>
<body onload="init()">
<h1 id="title">Accessible Example</h1>
<div id="tags">
keyboard, pan, panning, zoom, zooming, accesskey
</div>
<a class="accesskey"
href=""
accesskey="1"
onclick="document.getElementById('map').focus(); return false;">
Go to map
</a>
<p id="shortdesc">
Demonstrate the KeyboardDefaults control and how to use links
with Access Keys to navigate the map with the keyboard.
</p>
<a class="zoom"
href="javascript: void map.zoomIn();"
accesskey="i">
zoom <em>i</em>n</a>
<a class="zoom"
href="javascript: void map.zoomOut();"
accesskey="o">
zoom <em>o</em>ut</a>
<table>
<tbody>
<tr>
<td>&nbsp;</td>
<td>
<a href="javascript: void map.pan(0, -map.getSize().h / 4);"
accesskey="n">
pan <em>n</em>orth
</a>
</td>
</tr>
<tr>
<td>
<a href="javascript: void map.pan(-map.getSize().w / 4, 0);"
accesskey="w">
pan <em>w</em>est
</a>
</td>
<td id="map" class="smallmap" tabindex="0"></td>
<td>
<a href="javascript: void map.pan(map.getSize().w / 4, 0);"
accesskey="e">
pan <em>e</em>ast
</a>
</td>
</tr>
<tr>
<td>&nbsp;</td>
<td>
<a href="javascript: void map.pan(0, map.getSize().h / 4);"
accesskey="s">
pan <em>s</em>outh
</a>
</td>
<td>&nbsp;</td>
</tr>
</tbody>
</table>
<div id="docs">
<p>Navigate the map in one of three ways:</p>
<ol>
<li>Use Access Key "1" (alt + 1) to focus the map element, and
use following keys to pan and zoom:
<ul>
<li>+ (zoom in)</li>
<li>- (zoom out)</li>
<li>up-arrow (pan north)</li>
<li>down-arrow (pan south)</li>
<li>left-arrow (pan east)</li>
<li>right-arrow (pan west)</li>
</ul>
See <a href=http://en.wikipedia.org/wiki/Access_key>wikipedia</a> for
more detail about Access Keys.
</li>
<li>Navigate to pan and zoom links using the "tab" key, and
press "enter" to pan and zoom</li>
<li>If Access Keys work for links in your browser, use:
<ul>
<li>i (zoom in)</li>
<li>o (zoom out)</li>
<li>n (pan north)</li>
<li>s (pan south)</li>
<li>e (pan east)</li>
<li>w (pan west)</li>
</ul>
</li>
</ol>
<p>
This is an example of using alternate methods to control panning and zooming. This approach uses map.pan() and map.zoom(). You'll note that to pan, additional math is necessary along with map.size() in order to set the distance to pan.
</div>
</body>
</html>

View File

@@ -1,34 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>OpenLayers All Overlays with Google and OSM</title>
<link rel="stylesheet" href="../theme/default/style.css" type="text/css">
<link rel="stylesheet" href="style.css" type="text/css">
<script src="http://maps.google.com/maps/api/js?v=3&amp;sensor=false"></script>
<script src="../lib/OpenLayers.js"></script>
<script src="all-overlays-google.js"></script>
</head>
<body onload="init()">
<h1 id="title">All Overlays with Google and OSM</h1>
<div id="tags">
overlay, baselayer, google, osm, openstreetmap, light
</div>
<p id="shortdesc">
Using the Google and OSM layers as overlays.
</p>
<div id="map" class="smallmap"></div>
<div id="docs">
<p>
Using the allOverlays property on the map, the first layer added
must initially be visible. This example demonstrates the use of
a Google layer and an OSM layer treated as overlays.
</p><p>
See the <a href="all-overlays-google.js" target="_blank">
all-overlays-google.js source</a> to see how this is done.
</p>
</div>
</body>
</html>

View File

@@ -1,19 +0,0 @@
var map;
function init() {
map = new OpenLayers.Map({
div: "map",
allOverlays: true
});
var osm = new OpenLayers.Layer.OSM();
var gmap = new OpenLayers.Layer.Google("Google Streets", {visibility: false});
// note that first layer must be visible
map.addLayers([osm, gmap]);
map.addControl(new OpenLayers.Control.LayerSwitcher());
map.zoomToMaxExtent();
}

View File

@@ -1,76 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>All Overlays Example</title>
<link rel="stylesheet" href="../theme/default/style.css" type="text/css">
<link rel="stylesheet" href="style.css" type="text/css">
<script src="../lib/OpenLayers.js"></script>
<script type="text/javascript">
var map;
function init() {
map = new OpenLayers.Map({
div: "map",
allOverlays: true,
maxExtent: new OpenLayers.Bounds(
1549471.9221, 6403610.94, 1550001.32545, 6404015.8
)
});
// give the features some style
var styles = new OpenLayers.StyleMap({
"default": {
strokeWidth: 2
},
"select": {
strokeColor: "#0099cc",
strokeWidth: 4
}
});
// add rules from the above lookup table
styles.addUniqueValueRules("default", "RP_TYPE", {
10: {strokeColor: "#000000", strokeWidth: 2},
12: {strokeColor: "#222222", strokeWidth: 2},
14: {strokeColor: "#444444", strokeWidth: 2},
16: {strokeColor: "#666666", strokeWidth: 2},
18: {strokeColor: "#888888", strokeWidth: 2},
19: {strokeColor: "#666666", strokeWidth: 1}
});
var vectors = new OpenLayers.Layer.Vector("Lines", {
strategies: [new OpenLayers.Strategy.Fixed()],
protocol: new OpenLayers.Protocol.HTTP({
url: "data/roads.json",
format: new OpenLayers.Format.GeoJSON()
}),
styleMap: styles
});
map.addLayer(vectors);
map.addControl(new OpenLayers.Control.LayerSwitcher());
map.zoomToMaxExtent();
}
</script>
</head>
<body onload="init()">
<h1 id="title">OpenLayers Overlays Only Example</h1>
<div id="tags">
overlay, baselayer, light
</div>
<p id="shortdesc">
Demonstrates a map with overlays only.
</p>
<div id="map" class="smallmap"></div>
<div id="docs">
To create a map that allows any draw order with all layer types
and lets you set the visibility of any layer independently, set
the allOverlays property on the map to true.
</div>
</body>
</html>

View File

@@ -1,29 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<link rel="stylesheet" href="../theme/default/style.css" type="text/css">
<link rel="stylesheet" href="style.css" type="text/css">
<title>AnchorPermalink Example</title>
<script src="../lib/OpenLayers.js"></script>
<script src="anchor-permalink.js"></script>
</head>
<body onload="init()">
<h1 id="title">AnchorPermalink Example</h1>
<div id="tags">
anchor, permalink
</div>
<p id="shortdesc">
Place a permalink in the anchor of the url.
</p>
<div id="map" class="smallmap"></div>
<div id="docs">
<p>
See the <a href="anchor-permalink.js" target="_blank">anchor-permalink.js
source</a> to see how this is done.
</p>
</div>
</body>
</html>

View File

@@ -1,13 +0,0 @@
function init() {
var map = new OpenLayers.Map({
div: "map",
projection: new OpenLayers.Projection("EPSG:900913"),
displayProjection: new OpenLayers.Projection("EPSG:4326"),
layers: [
new OpenLayers.Layer.OSM()
]
});
if (!map.getCenter()) map.zoomToMaxExtent();
map.addControl(new OpenLayers.Control.Permalink({anchor: true}));
}

View File

@@ -1,98 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>Animated Panning of the Map via map.panTo</title>
<link rel="stylesheet" href="../theme/default/style.css" type="text/css">
<link rel="stylesheet" href="style.css" type="text/css">
<script src="../lib/OpenLayers.js"></script>
<script type="text/javascript">
var map, layer, running = false;
OpenLayers.Control.Click = OpenLayers.Class(OpenLayers.Control, {
defaultHandlerOptions: {
'single': true,
'delay': 200
},
initialize: function(options) {
this.handlerOptions = OpenLayers.Util.extend(
{}, this.defaultHandlerOptions
);
OpenLayers.Control.prototype.initialize.apply(
this, arguments
);
this.handler = new OpenLayers.Handler.Click(
this, {
'click': this.onClick
}, this.handlerOptions
);
},
onClick: function(evt) {
map.panTo(map.getLonLatFromPixel(evt.xy));
}
});
function init(){
map = new OpenLayers.Map('map', {numZoomLevels: 2});
layer = new OpenLayers.Layer.WMS( "OpenLayers WMS",
"http://vmap0.tiles.osgeo.org/wms/vmap0", {layers: 'basic'} );
map.addLayer(layer);
map.zoomToMaxExtent();
var click = new OpenLayers.Control.Click();
map.addControl(click);
click.activate();
map.addControl(new OpenLayers.Control.OverviewMap());
map2 = new OpenLayers.Map('map2', {'panMethod': null, numZoomLevels: 2} );
layer = new OpenLayers.Layer.WMS( "OpenLayers WMS",
"http://vmap0.tiles.osgeo.org/wms/vmap0", {layers: 'basic'} );
map2.addLayer(layer);
map2.zoomToMaxExtent();
}
function setCenterInterval() {
if (!running) {
setCenter();
running = setInterval('setCenter()', 500);
} else {
clearInterval(running);
running = false;
}
}
function setCenter() {
var lon = Math.random() * 360 - 180;
var lat = Math.random() * 180 - 90;
var lonlat = new OpenLayers.LonLat(lon, lat);
map.panTo(lonlat);
}
</script>
</head>
<body onload="init()">
<h1 id="title">map.panTo Example</h1>
<div id="tags">
panning, animation, effect, smooth, panMethod
</div>
<div id="shortdesc">Show animated panning effects in the map</div>
<div id="map" class="smallmap"></div>
<div id="docs">
<p>This is an example of transition effects. If the new random center is in the current extent, the map will pan smoothly. <br>
The random selection will continue until you press it again. Additionally, you can single click in the map to pan smoothly
to that area, or use the pan control to pan smoothly.
</p>
</div>
<button onclick="setCenterInterval()">Start/stop random recenter</button>
<div id="map2" class="smallmap"></div>
<div>
<p>To turn off Animated Panning, create a map with an panMethod set to
null. </p>
</div>
</body>
</html>

68
examples/animation.html Normal file
View File

@@ -0,0 +1,68 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="chrome=1">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no, width=device-width">
<link rel="stylesheet" href="../resources/bootstrap/css/bootstrap.min.css" type="text/css">
<link rel="stylesheet" href="../resources/layout.css" type="text/css">
<link rel="stylesheet" href="../resources/bootstrap/css/bootstrap-responsive.min.css" type="text/css">
<title>Animation example</title>
</head>
<body>
<div class="navbar navbar-inverse navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<a class="brand" href="./">OpenLayers 3 Examples</a>
<ul class="nav pull-right">
<li><iframe class="github-watch-button" src="http://ghbtns.com/github-btn.html?user=openlayers&repo=ol3&type=watch&count=true"
allowtransparency="true" frameborder="0" scrolling="0" height="20" width="90"></iframe></li>
<li><a href="https://twitter.com/share" class="twitter-share-button" data-count="none" data-hashtags="openlayers">&nbsp;</a></li>
<li><div class="g-plusone-wrapper"><div class="g-plusone" data-size="medium" data-annotation="none"></div></div></li>
</ul>
</div>
</div>
</div>
<div class="container-fluid">
<div class="row-fluid">
<div class="span12">
<div id="map" class="map"></div>
</div>
</div>
<div class="row-fluid">
<div class="span12">
<button id="rotate-left"><i class="icon-arrow-left"></i></button>
<button id="rotate-right"><i class="icon-arrow-right"></i></button>
<button id="pan-to-london">Pan to London</button>
<button id="elastic-to-moscow">Elastic to Moscow</button>
<button id="bounce-to-istanbul">Bounce to Istanbul</button>
<button id="spin-to-rome">Spin to Rome</button>
<button id="fly-to-bern">Fly to Bern</button>
<button id="spiral-to-madrid">Spiral to Madrid</button>
</div>
</div>
<div class="row-fluid">
<div class="span12">
<h4 id="title">Animation example</h4>
<p id="shortdesc">Demonstrates animated pan, zoom, and rotation.</p>
<div id="docs">
<p>See the <a href="animation.js" target="_blank">animation.js source</a> to see how this is done.</p>
</div>
<div id="tags">animation</div>
</div>
</div>
</div>
<script src="loader.js?id=animation" type="text/javascript"></script>
<script src="../resources/social-links.js" type="text/javascript"></script>
</body>
</html>

Some files were not shown because too many files have changed in this diff Show More