Commit Graph

2459 Commits

Author SHA1 Message Date
Tim Schaub d10eff97a2 Allow getMetersPerUnit to work without units identifier (see #814) 2013-06-24 11:34:16 -06: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 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
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
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 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 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
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
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