Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

docs for zoomMax & include #80

Merged
merged 5 commits into from

1 participant

Commits on May 23, 2012
  1. @ryanttb
  2. @ryanttb
Commits on May 24, 2012
  1. @ryanttb

    docs - refresh force argument

    ryanttb authored
Commits on Jun 4, 2012
  1. @ryanttb

    refresh docs update

    ryanttb authored
Commits on Jun 8, 2012
  1. @ryanttb
This page is out of date. Refresh to see the latest.
View
25 README.md
@@ -66,6 +66,24 @@ In lieu of a formal styleguide, take care to maintain the existing coding style.
* geomap - clamp measure labels to [0, 0]
* geo - clamp centroid to bbox
* geomap - measure label for polygon should be in centroid
+* geomap - merge interactive pan and zoom into one, faster system (pan/zoom rewrite)
+* geomap - [bug] iOS - panning is visually jumpy but settles on the correct bbox in the end
+* geomap - pinch-zoom doesn't follow user's fingers close enough when scaling
+* geomap - [bug] pinch zoom on iPad 2 (iOS 5) doesn't refresh tiles when zooming out
+* geomap - request new image in shingled service during interactive pan
+* geomap - [bug] zoom in more than once with zoom method moves tiles to the wrong spot
+* geomap - [bug] only services that have finished refreshing move when the user pans
+* geomap - [bug] map panning is jumpy, appears to be related to shapes and/or drawing context
+* geomap - [bug] pan sometimes lags on first drag
+* geomap - tiled data-scaleOrigin should be stored as an array
+* geomap - android - [bug] cannot always pan map after appending shapes
+* geomap - android - browser stops pan/zoom after 7 logos on logo demo
+* geomap - [bug] mouse wheel on bad or missing tile doesn't zoom out on first rotate
+* geomap - increase mobile performance by 9000
+* docs - geomap - add argument to refresh to force reload of images for dynamic data
+* docs - geomap - allow service-level refresh
+* docs - geomap - zoomMax option (tiled & shingled)
+* docs - geo - include method for bbox
### 1.0a4 (2012-02-19)
* geomap - [bug] changing the tilingScheme doesn't update pixelSize, maxPixelSize, center or centerMax
@@ -119,7 +137,7 @@ In lieu of a formal styleguide, take care to maintain the existing coding style.
* geomap - [bug] mouse wheel doesn't work with jQuery 1.7
** upgrade to latest jquery.mousewheel plugin
* geomap - service object visibility and opacity options should be moved to a style property
-* geomap - use _currentServices in all functions unless we actually need to update the public options services object
+* geomap - use currentServices in all functions unless we actually need to update the public options services object
* geomap - don't change user's service objects in opacity/toggle
* geomap - show attr text
* docs - geomap - selector argument to find method
@@ -133,12 +151,13 @@ In lieu of a formal styleguide, take care to maintain the existing coding style.
* geomap - don't request tiles that are -y index
* geomap - [bug] initializing tiled map by non-geodetic bbox always causes zoom level 0
* docs - geomap - empty string needed for label element
+* geomap - label divs should have class="geo-label" & style="position: absolute;"
* geomap - [bug] double tap to end shapes adds two points before ending the shape, in different places
* geomap - [bug] lifting fingers after pinch zoom in drawLineString or drawPolygon modes sometimes adds fake visual coordinate on touch point last lifted
* docs - upgrade to jQuery 1.7.1
* geomap - [bug] scroll=off doesn't zoom map but also doesn't allow document scroll
* geomap - [bug] changing mode does not reset measure drawing
-* geomap - [bug] jQuery UI Widget Factory no longer passes pageX & pageY event properties during _trigger when using jQuery 1.7
+* geomap - [bug] jQuery UI Widget Factory no longer passes pageX & pageY event properties during trigger when using jQuery 1.7
** upgrade to Widget Factory 1.8.17
* examples - all demo (shingled)
* docs - geomap - custom modes
@@ -171,7 +190,7 @@ In lieu of a formal styleguide, take care to maintain the existing coding style.
* docs - geomap - zoom method
* geomap - zoom method
* geo - calculate bbox in projected coordinates
-* docs - proj - mention that *Geodetic methods can also do bbox
+* docs - proj - mention that Geodetic methods can also do bbox
* geo - geometry - bbox function
* docs - geomap - destroy method
* geo - bbox - center function
View
164 dev-journal-ryan.txt
@@ -1,92 +1,44 @@
== to do ==
=== b1 ===
+* geomap - allow service-level refresh
* geomap - loadstart, loadend events
+* geomap - [bug] dragBbox doesn't include the bbox property in the shape
* geomap - allow append to take an array of shapes
* geomap - allow remove to take an array of shapes
-* docs - geomap - add argument to refresh to force reload of images (in case of dynamic data)
* geomap - add argument to refresh to force reload of images (in case of dynamic data)
-* docs - geomap - zoomMax option (tiled & shingled)
* geomap - zoomMax option
-* docs - geomap - allow template for label argument to append
-* geomap - allow template for label argument to append
-* docs - geomap - allow template for properties on style argument to append
-* geomap - allow template for properties on style argument to append
-* docs - geomap - shapeLabel property
-** template for labels for all shapes added via append
-* geomap - shapeLabel property
-* docs - geomap - allow template for properties on shapeStyle option
-* geomap - allow template for properties on shapeStyle option
-* docs - geo - include method for bbox
** accept null first argument and coordinate or bbox second argument
* geo - include method for bbox
-* geomap - cache label coordinates (the labelPixel cannot be cached, it will change each refresh)
-* geomap - rotate label based on segment
-* geomap - use pointer-events: none where appropriate
* geomap - test changing shingled service URL to get updated images (in case of dynamic data)
-* geomap - replace data-geo attributes with classes
-* geomap - don't redraw graphics if the map doesn't move during pan
-* geographics - draw all labels to a string or document fragment and append to DOM once
-* geomap - compile shingled & tiled string src templates for re-use
-** be sure their template names are unique so they don't overwrite each other
-* docs - warn users about potential CSS/JavaScript issues relating to generated elements
-** ul, li, div, span, img
* geomap - [bug] there's an extra service.refresh call after a non-mousedown touchmove after a refresh
** most noticeable on shingled services
-* geomap - [bug] tiled services with pixelSizes set do not render zoom level 0?
-* geomap - [bug] pinch-zoom doesn't follow user's fingers close enough when scaling
-* docs - geomap - describe "graphic service" as shingled with src set to empty string or null
+* geomap - [bug] tiled services with pixelSizes set do not render zoom level 0
* geomap - [bug] errors when setting src to empty string
** "When I added services for my graphics layers with src set to an empty string I got very weird results -- I was seeing the single image from my inset map repeated over and over. I had to set it to a function that returns an empty string for it to work."
** possibly an object reference error when multiple maps are created
* geomap - [bug] if panning is false, mode is draw*, and user attempts to pan, the drawing begins (or another point is added) on the touchstop point
** a failed pan shouldn't add a point to drawCoords
-* geomap - Firefox - [bug] inertial pan is choppy post touchstop
* geomap - iPad 2 - [bug] pointAlong doesn't take last point into account in all browsers
** cannot reproduce; possibly axisLayout image only
* geomap - ie - [bug] ie highlights entire map div during shift-zoom
-* geomap - [bug] iPad 2 panning is visually jumpy but settles on the correct bbox in the end
** possibly only when axisLayout is image
* geomap - [bug] iPad 2 measureLength puts current length on second to last coord instead of last coord
-* geomap - [bug] pinch zoom on iPad 2 (iOS 5) doesn't refresh tiles when zooming out
-** oddly, iPod Touch 4 (iOS 4) is fine
* geomap - [bug] first use of mouse/touch in any mode moves map by one pixel on mousedown/touch
** possibly only when axisLayout is image
+* geomap - [bug] after one finger is removed, stop processing as if multitouch is still on
* geomap - [bug] multiples of the same event trigger after creating more than one map on the same div, even after destroy
** destroy should unbind all geomap events
-* geomap - add delegate handler for image load instead of one load handler per image
-* geomap - remove this-style state properties
-* geomap - remove "px" from .css calls
-* geo - use Array.push instead of $.merge where needed
-* geomap - [bug] changing services array (without changing all services) after initialization fails
-* geomap - [bug] multiple maps do not work on the same page
-* docs - upgrade to jQuery Mobile 1.0.1
-* docs - non-mobile version via adaptive check
-* geomap - create _defaultState object, use for widget-local _widgetState property, reinit _widgetState on _createWidget
-* geomap - don't redraw shapes after interactiveScale, they've already been drawn at new scale
+* geomap - verify that multiple maps work on the same page
* geomap - [bug] exception when calling destroy on uninitialized div
-* geographics - try removing the blit canvas from the DOM, i.e., don't attach
-* geomap - maybe throw an error when setting center to an invalid object, such as the first number in a coordinate array: coordinates[ 0 ] <== wrong!
-* geomap - merge interactive pan and zoom into one, faster system (pan/zoom rewrite)
-** pan and zoom in same interactive session (_interactiveCenter & _interactivePixelSize)
-** delay image loading more during movement
-* geomap - request new image in shingled service during interactive pan (after pan/zoom rewrite)
-* docs - geomap - view.service.row & view.service.column to string multiple services together or repeat horizontal tiles
-* geomap - view.service.row & view.service.column to string multiple services together or repeat horizontal tiles
-* geomap - repeat horizontal tiles
-* geomap - don't request tiles that > max possible y for scale
* geomap - do not interactiveScale non-tiled maps out past pixelSizeMax
-* geomap - [bug] zoom in more than once with zoom method moves tiles to the wrong spot
-** postponed until after pan/zoom rewrite
-* geomap - [bug] only services that have finished refreshing move when the user pans
-** check by zooming in then panning shingled demo with forest layer on
-** for a4: hide unfinished services; for b1: properly move the already zoomed service after pan/zoom rewrite
-* geomap - [bug] map panning is jumpy, appears to be related to shapes and/or drawing context
-** postponed until after pan/zoom rewrite
-* geomap - [bug] pan sometimes lags on first drag
-** cannot reproduce effectively, test again after pan/zoom rewrite
-* geomap - use CSS transition or transform for smoother tiling
-* geomap - implement service-level shape redrawing during interactive movement
+** pixelSizeMax calculated by zoomMax on non-tiled maps
+* expose jQuery Geo as an AMD module so asynchronous loaders like RequireJS and curl.js can use it
+* geomap - [bug] when a singled image hasn't loaded after pan and you double click on empty space, the zoomed bbox seems wrong
+* cdn - test cache headers with http://redbot.org/ before release
+
+=== examples ===
+
* examples - jQuery Mobile
* examples - MBCR: http://www.mbta.com/rider_tools/developers/default.asp?id=21899
* examples - drag shapes
@@ -95,18 +47,59 @@
* examples - make OSM editing simple
** http://www.maploser.com/2012/03/29/all-i-want-for-openstreetmap-is-simple/
** http://jvectormap.owl-hollow.net/ ( found via http://www.moretechtips.net/2011/12/22-most-popular-jquery-plugins-of-2011.html )
-* expose jQuery Geo as an AMD module so asynchronous loaders like RequireJS and curl.js can use it
* examples - geomap resize method
* examples - Codecademy course
-* geomap - [bug] when a singled image hasn't loaded after pan and you double click on empty space, the zoomed bbox seems wrong
-* cdn - test cache headers with http://redbot.org/ before release
+* examples - SVG & other neat elements/media in labels
+* examples - continent puzzle
+** http://stephanmendler.de/thinkmaps/puzzle/index_en.html
=== future ===
-* geomap - integrate resize with interactiveTransform
+* geomap - don't repeat attr text if the same as one previously added
+* docs - geomap - zoomMin, zoomMax on service object
+* geomap - zoomMin, zoomMax on service object
+* geomap - remove this-style state properties
+* geomap - add delegate handler for image load instead of one load handler per image
+* geomap - remove "px" from .css calls
+* geo - use Array.push instead of $.merge where needed
+* docs - upgrade to jQuery Mobile 1.1.0
+* docs - non-mobile version via adaptive check
+* geomap - [bug] changing services array (without changing all services) after initialization fails
+* geomap - create _defaultState object, use for widget-local _widgetState property, reinit _widgetState on _createWidget
+* geographics - draw to img elements to include in interactiveTransform
+* geographics - try removing the blit canvas from the DOM, i.e., don't attach
+* geomap - maybe throw an error when setting center to an invalid object, such as the first number in a coordinate array: coordinates[ 0 ] <== wrong!
+** oddly, iPod Touch 4 (iOS 4) is fine
+** might be related to the jQuery UI bug I found
+* geomap - implement service-level shape redrawing during interactive movement
+* geomap - use CSS transition or transform for smoother tiling
+* geomap - don't request tiles that > max possible y for scale
+* docs - geomap - view.service.row & view.service.column to string multiple services together or repeat horizontal tiles
+* geomap - Firefox - [bug] inertial pan is choppy post touchstop
+** post inertial pan rewrite
+* docs - geomap - describe "graphic service" as shingled with src set to empty string or null
+* docs - warn users about potential CSS/JavaScript issues relating to generated elements
+** ul, li, div, span, img
+* geographics - draw all labels to a string or document fragment and append to DOM once
+* geomap - compile shingled & tiled string src templates for re-use
+** be sure their template names are unique so they don't overwrite each other
+* geomap - don't redraw graphics if the map doesn't move during pan
+* geomap - replace data-geo attributes with classes
+* geomap - cache label coordinates (the labelPixel cannot be cached, it will change each refresh)
+* geomap - rotate label based on segment
+* geomap - use pointer-events: none where appropriate
+* docs - geomap - allow template for label argument to append
+* geomap - allow template for label argument to append
+* docs - geomap - allow template for properties on style argument to append
+* geomap - allow template for properties on style argument to append
+* docs - geomap - shapeLabel property
+** template for labels for all shapes added via append
+* geomap - shapeLabel property
+* docs - geomap - allow template for properties on shapeStyle option
+* geomap - allow template for properties on shapeStyle option
+* geomap - better integrate resize with interactiveTransform
* geomap - determine if moz-transform improves speed in Firefox
* geomap - [bug] once we detect a pan, disable the ability to go to multitouch
-* geomap - [bug] after one finger is removed, stop processing as if multitouch is still on
* geomap - [bug] verify label clamping is correct in axisLayout=image maps
* docs - geomap - pass the service id (if there is one) to the src callback as a view property
* geomap - pass the service id (if there is one) to the src callback as a view property
@@ -123,22 +116,17 @@
* geomap - pan events (pattern after HTML5 drag)
* geomap - zoom events (pattern after HTML5 drag)
* geomap - test jQuery widget call chaining when setting option values
-* geomap - tiled data-scaleOrigin should be stored as an array
* geomap - when scroll is zoom, attempt to not zoom while user is scrolling the page anyway
-* geomap - allow src to return a callback function or Promise to delay image requests for some reason (multiple requests, etc.)
-* docs - geomap - document the correct way to add a service after init
-* geomap - remember last map unit type set with bbox and center, return all coords and arguments in that type
+* docs - geomap - document the correct way to add/change a service after init
* geomap - unbind keydown handler on destroy, it's on the document
* geomap - use requestAnimationFrame instead of setTimeout when waiting to move the map during intractiveTransform
* docs - $.geo.WKT object
* geo - $.geo.WKT object
-* geomap - panning cursor (for when user is actually panning)
+* geomap - panning cursor (closed hand, for when user is actually panning)
* geomap - completely original cursor set for pan, zoom, draw, etc.
* docs - geomap - replace method
* geomap - replace method
-* docs - geomap - allow service-level refresh
-* geomap - allow service-level refresh
-* geomap - reenable graphics redraw on interactiveScale, if canvas...and scale canvas
+* geomap - draw shapes to img and integrate with interactiveTransform
* docs & examples - settle on the word "option" in all text (instead of property) to match widget function
* docs - make all map examples live
* docs - explain the 96px scale bar, why 96?
@@ -153,7 +141,6 @@
* geo - support up to GeometryCollection in centroid
* geomap - stop using $.data to store bbox since it's only used for drawing; store on _graphicShapes instead
* geomap - show a drawPoint style while the mouse is down, hide if toolPan or dbltap scale
-* geomap - android - [bug] cannot always pan map after appending shapes
* geomap - audit allocations and reduce garbage
** see http://www.scirra.com/blog/76/how-to-write-low-garbage-real-time-javascript
* geomap - re-use services that have the same id as existing services
@@ -168,28 +155,23 @@
* docs - internal - explain what projection is and which one we use by default (3395) and maybe why we call it web mercator & why we can't get to +/- 90 lat
* docs - internal - document how geomap draws shapes, the geomapgraphics widget and the reason shapeStyle is a method
* docs - demo - location based notes/to do list
-* geomap - label divs should have class="geo-label" & style="position: relative;"
* geomap - find should check labels first
* geo - geometry - implement JTS note: "The centroid is equal to the centroid of the set of component Geometries of highest dimension (since the lower-dimension geometries contribute zero "weight" to the centroid)"
-* geo - Support WKT with $.geo.parseWKT & $.geo.textify
-* geo - All bbox operations should be done in non-geodetic coordinates for accuracy
+* geo - all bbox operations should be done in non-geodetic coordinates for accuracy
* geo - support bbox in distance ( fix geomap.find )
* geomap - perf test putting all containers that need to move with panning in a single super-container
* docs - geomap - multiple labels
* geomap - multiple labels
-* geomap - [bug] mouse wheel on bad or missing tile doesn't zoom out on first rotate
* docs/geomap - store WKT input for each service
* geographics - rename the generated style properties to something simple or get better control over closure compiler
* geomap - document and implement find's callback syntax
-* geomap - repeat horizontal tiles
* geomap - custering demo/support
* proj - take scale factor into account when calculating distance in web mercator
-* geographics - Disable fill by setting style.fill to "" & stroke by style.stroke to ""
+* geographics - disable fill by setting style.fill to "" & stroke by style.stroke to ""
* graphics - See Modernizr for comment on BB Storm & canvas detection
* geographics - document graphics widget
* geographics - support border, padding, and margin
* geographics - undo manual outer div style changes
-* geomap - [BUG] Android browser stops pan/zoom after 7 logos on logo demo
* geomap - store a copy of shapes as WKT in a hidden input
* geomap - only update WKT copy if shape is appended with refresh argument set to true
* geomap - find - [maybe] after flatten, check more cached bboxes for non-Point geometrie
@@ -197,11 +179,9 @@
* geomap - support TMS
* docs - geomap - toDataURL method
* geomap - toDataURL method
-* docs - geomap - SVG & other neat elements/media in labels
* docs - geo - $.geo.guessLocation function
* geo - $.geo.guessLocation function
* docs - services - document the plugin architecture
-** create must return a jQuery collection where geomap can store state info
* docs - geomap - drawPush function
** in the drawing modes, this function starts drawing or adds a point into the already-started shape at the given coordinate
** immediately triggers the shape event if mode is drawPoint
@@ -215,6 +195,13 @@
* geomap - use profiling to improve pan performance
* geo - potentially add address cracking
+==2012-06-07==
+===vacation===
+I've been away for almost two weeks. Time to finish b1.
+
+===zoomMax===
+This is where I left off. I'm also considering zoomMin and zoomMax on service objects but that's not until later if needed.
+
==2012-05-23==
===tiled===
The new origin stuff appears to work better. I'm going to run through the other examples & see if I'm ready for a build.
@@ -233,6 +220,17 @@ The programatic changes are going to be a part of this, too. I need a way to tur
===programatic===
I updated all the programatic calls to use the new system with the ability to say not to trigger. I will need to test these but for now, I do think I'm finally ready to merge.
+===merge===
+I merged the interactive rewrite into b1. There are bugs that I will have to work through before this becomes beta.
+
+===initial zoom===
+No matter what your initial zoom is, you can see the map at zoom 0 before the new tiles show up. That makes sense given the changes I've made.
+
+ok, the area that handles init options checks to see if the widget has been created before heading into intractiveTransform mode.
+
+===ie8===
+I *know* ie8 support is broken. I haven't even tried it yet. We will keep supporting that browser, though.
+
==2012-05-22==
===mouseup===
I'm ignoring rogue mouseup events now. Hopefully, that will clean resize up a bit on Chrome & Firefox.
View
59 docs/geo/include.html
@@ -0,0 +1,59 @@
+<!doctype html>
+
+<html lang="en" class="no-js">
+<head>
+ <meta charset="utf-8">
+
+ <title>include | $.geo</title>
+ <meta name="description" content="jQuery Geo include method">
+ <meta name="author" content="Ryan Westphal">
+
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
+
+ <link rel="stylesheet" href="../css/style.css?v=2">
+ <link rel="stylesheet" href="http://code.jquery.com/mobile/1.0/jquery.mobile-1.0.min.css" />
+</head>
+
+<body>
+
+ <div id="include" data-role="page">
+ <div data-role="header" data-theme="b">
+ <h1>include</h1>
+ </div>
+
+ <div data-role="content">
+ <table>
+ <tr>
+ <th>return type</th>
+ <td>Array ( <a href="http://geojson.org/geojson-spec.html#bounding-boxes" rel="external">GeoJSON bounding box</a> ) </td>
+ </tr>
+ <tr>
+ <th>syntax</th>
+ <td>$.geo.include( null | Array bbox ( <a href="http://geojson.org/geojson-spec.html#bounding-boxes" rel="external">GeoJSON bounding box</a> ), Array position ( <a href="http://geojson.org/geojson-spec.html#positions" rel="external">GeoJSON position</a> ) | Array bbox ( <a href="http://geojson.org/geojson-spec.html#bounding-boxes" rel="external">GeoJSON bounding box</a> ) )</td>
+ </tr>
+ <tr>
+ <th>usage</th>
+ <td><pre><code>var bboxOfCoord = $.geo.include( null, [ -70, 42 ] );
+var sameAsSecondArgument = $.geo.include( null, [ -71, 41, -69, 43 ] );
+var includeCoord = $.geo.include( bbox, [ -70, 42 ] );
+var includeBbox = $.geo.include( bbox, [ -71, 41, -69, 43 ] );</code></pre></td>
+ </tr>
+ </table>
+
+ <p>The include method expands a bbox to include either a coordinate or another bbox. The expanded bbox is returned.</p>
+
+ <p>If the first argument is null or undefined, the result is a new bbox and will contain the second argument.</p>
+
+ <p>For efficency, if the second argument is a valid bbox, it is modified in place and a reference is returned.</p>
+
+ <p>This function is similar to Envelope.expandToInclude in JTS.</p>
+ </div>
+ </div> <!-- end of #container -->
+
+ <script src="http://code.jquery.com/jquery-1.7.1.min.js"></script>
+ <script src="http://code.jquerygeo.com/jquery.geo-1.0a4.min.js"></script>
+ <script src="../js/script.js"></script>
+ <script src="http://code.jquery.com/mobile/1.0/jquery.mobile-1.0.min.js"></script>
+</body>
+</html>
+
View
1  docs/geo/index.html
@@ -47,6 +47,7 @@
<li><a href="width.html">width</a></li>
<li><a href="expandBy.html">expandBy</a></li>
<li><a href="scaleBy.html">scaleBy</a></li>
+ <li><a href="include.html">include</a></li>
<li><a href="reaspect.html">reaspect</a></li>
<li><a href="recenter.html">recenter</a></li>
<li><a href="polygonize.html">polygonize</a></li>
View
1  docs/geomap/index.html
@@ -59,6 +59,7 @@
<li><a href="bboxMax.html"><h3>bboxMax</h3><p>bounds of maximum viewport for non-tiled maps</p></a></li>
<li><a href="center.html"><h3>center</h3><p>center of the currently visible viewport</p></a></li>
<li><a href="zoom.html"><h3>zoom</h3><p>zoom level of the currently visible viewport</p></a></li>
+ <li><a href="zoomMax.html"><h3>zoomMax</h3><p>maximum zoom level for all services in the map</p></a></li>
<li><a href="pixelSize.html"><h3>pixelSize</h3><p>read-only Earth-size of a pixel in the current map viewport</p></a></li>
<li><a href="mode.html"><h3>mode</h3><p class="ui-li-desc">determines how the map, user, &amp; developer interact</p></a></li>
<li><a href="pannable.html"><h3>pannable</h3><p class="ui-li-desc">allow or prohit map panning</p></a>
View
53 docs/geomap/refresh.html
@@ -29,16 +29,59 @@
</tr>
<tr>
<th>syntax</th>
- <td>.geomap( &quot;refresh&quot; )</td>
+ <td>$( <i>map or service selector</i> ).geomap( &quot;refresh&quot; [ , Boolean force ] )</td>
</tr>
<tr>
<th>usage</th>
- <td><pre><code>$(&quot;#map&quot;).geomap( &quot;refresh&quot; )</code></pre></td>
+ <td><pre><code>$(&quot;#map&quot;).geomap( &quot;refresh&quot; )
+
+$(&quot;#map&quot;).geomap( &quot;refresh&quot;, true )
+
+$(&quot;#map .my-dynamic-service&quot;).geomap( &quot;refresh&quot;, true )</code></pre></td>
</tr>
</table>
- <p>
- This method refreshes
- all services and graphics in the map. Usually, changing geomap properties or calling methods automatically refreshes the map appropriately. However, you can call this after you have added or removed shapes to geomap by passing false as the refresh argument to the append, remove, or empty methods.</p>
+
+ <p>This method refreshes one or more services and shapes in the map. Usually, changing geomap options or calling methods automatically refreshes the map appropriately. However, you can call this after you have added or removed shapes to geomap by passing false as the refresh argument to the append, remove, or empty methods. This method is also useful in the case of dynamic server data.</p>
+
+ <p>Without a service selector, all services on the map will be refreshed.</p>
+
+ <p>The force option will re-request images for tiles already in the map view. Keep in mind, though, that this does not guarantee you will get updated images. See the Dynamic Data section below for tips.</p>
+
+ <h2>Dynamic Data</h2>
+
+ <p>There are three factors that can prevent jQuery Geo from getting a fresh image from a web server.</p>
+
+ <ul>
+ <li>if the user does not interact with the map and you do not call refresh, jQuery Geo will not request new images</li>
+ <li>if the user does interact with the map, you call refresh with no arguments, or you call .geomap( &quot;refresh&quot;, false ):
+ <ul>
+ <li>for tiled services: jQuery Geo will only request images for tiles that it does not already have</li>
+ <li>for shingeld services: a new image is always requested but the browser may supply a cached image</li>
+ </ul>
+ </li>
+ <li>if you call .geomap( &quot;refresh&quot;, true ), jQuery Geo will:
+ <ul>
+ <li>for tiled services: request a new image for existing tiles but the web browser is free to supply a cached image instead of retriving one from the web server</li>
+ <li>for shinged services: this is also true; if the final image URL is the same as a previous image URL the browser may supply a cached image</li>
+ </ul>
+ </li>
+ </ul>
+
+ <p>A web browser will normally cache images that have already been loaded. On top of that, jQuery Geo will not, by default, request images for tiles that it has already placed. In the case of dynamic data, where you want to update what's on the map without requiring a pan or zoom or also update tiles that have already been placed, you have a couple options.</p>
+
+ <h3>use uncachable URLs</h3>
+
+ <p>The first option is to use a function for the <a href="services.html">src property of your service object</a>. In that function, return a different URL every time even if all of the properties of the view object are the same as a previous call. If we were to use jQuery's implementation of the cache option in $.ajax as inspiration, our src function could look similar to:</p>
+
+ <pre><code>src: function( view ) {
+ return &quot;my.dynamic.tile.service/&quot; + view.zoom + &quot;/&quot; + view.tile.column + &quot;/&quot; + view.tile.row + &quot;.png?_=&quot; + $.now( );
+}</code></pre>
+
+ <p>The _ input in the query string will be a different number on every request, regardless of the value of zoom, column, and row. Most services will ignore extraneous query string inputs and the web browser will not be able to cache the image.</p>
+
+ <h3>use the Cache-Control HTTP header</h3>
+
+ <p>Another way to achieve the same result without modifying your image URLs is to use the HTTP header: Cache-Control. By returning this header with the no-cache value, you can tell the web browser to not cache the image. Then, when you call .geomap( &quot;refresh&quot;, true ), the web browser will re-request images for tiles even if it has done so one already. This option is only possible if you have some control over the web server that supplies map images. How to add the header is specific to your web server and beyond the scope of these docs. It can usually be done in the web server's configuration file or in the web service itself where you generate the images.</p>
</div>
</div> <!-- end of #container -->
View
14 docs/geomap/zoom.html
@@ -44,11 +44,17 @@
<td><pre><code>$( <i>selector</i> ).geomap( &quot;option&quot;, &quot;zoom&quot;, 7 );</code></pre></td>
</tr>
</table>
- <p>The zoom property gets or sets the current zoom of the map view.</p>
- <p>For tiled services the zoom property's range is zero to the current geomap tilingScheme's levels property minus one.</p>
- <p>For shingled services, the zoom property is based on the ratio between sizes of the bbox and bboxMax properties. If they are equal, the zoom property is 0. Smaller bbox areas will have larger zoom values.</p>
+
+ <p>The zoom option gets or sets the current zoom of the map view.</p>
+
+ <p>For tiled maps, the zoom option's range starts at zero and goes to either the current geomap tilingScheme's levels property minus one or the length of the tilingScheme's pixelSize array (depending on how the tilingScheme option is declared).</p>
+
+
+ <p>For non-tiled maps, i.e., tilingScheme is null and you're using all shingled services, the zoom option is based on the ratio between sizes of the bbox and bboxMax properties. If they are equal, the zoom option is 0. Smaller bbox areas will have larger zoom values.</p>
+
<p>If you attempt to initialize both zoom and bbox at the same time when creating a geomap widget, bbox will be applied and zoom will modify the final bbox.</p>
- <p>Apart from setting the zoom property directly, you can use the <a href="zoommethod.html">zoom method</a> to change the zoom by relative amounts.</p>
+
+ <p>Apart from setting the zoom option directly, you can use the <a href="zoommethod.html">zoom method</a> to change the zoom by relative amounts.</p>
</div>
</div> <!-- end of #container -->
View
64 docs/geomap/zoomMax.html
@@ -0,0 +1,64 @@
+<!doctype html>
+
+<html lang="en" class="no-js">
+<head>
+ <meta charset="utf-8">
+
+ <title>zoomMax | geomap</title>
+ <meta name="description" content="geomap zoomMax option">
+ <meta name="author" content="Ryan Westphal">
+
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
+
+ <link rel="stylesheet" href="../css/style.css?v=2">
+ <link rel="stylesheet" href="http://code.jquery.com/mobile/1.0/jquery.mobile-1.0.min.css" />
+</head>
+
+<body>
+
+ <div id="zoomMax" data-role="page">
+ <div data-role="header" data-theme="f">
+ <h1>zoomMax</h1>
+ </div>
+
+ <div data-role="content">
+ <table>
+ <tr>
+ <th>type</th>
+ <td>Number</td>
+ </tr>
+ <tr>
+ <th>default</th>
+ <td>Number.POSITIVE_INFINITY</td>
+ </tr>
+ <tr>
+ <th>init</th>
+ <td><pre><code>$( <i>selector</i> ).geomap( { zoomMax: 17 } );</code></pre></td>
+ </tr>
+ <tr>
+ <th>get</th>
+ <td><pre><code>var zoomMax = $( <i>selector</i> ).geomap( &quot;option&quot;, &quot;zoomMax&quot; );</code></pre></td>
+ </tr>
+ <tr>
+ <th>set</th>
+ <td><pre><code>$( <i>selector</i> ).geomap( &quot;option&quot;, &quot;zoomMax&quot;, 7 );</code></pre></td>
+ </tr>
+ </table>
+
+ <p>The zoomMax option gets or sets the maximum value of the <a href="zoom.html">zoom option</a> for the map.</p>
+
+ <p>For tiled maps, this option overrides the <a href="tilingScheme.html">tilingScheme option</a> when it is smaller than what you've specified in the tilingScheme. For example, if the tilingScheme has a total of 18 levels but you set the zoomMax option to 7, the user will not be able to zoom past level 7.</p>
+
+ <p>For non-tiled maps, i.e., tilingScheme is null and you're using all shingled services, this option determines the maximum zoom (and therefore pixelSize) a user can achieve. Without setting this option for non-tiled maps, users will be able to infinitely zoom in to fully dynamic maps which is likely not what you want. Non-tiled maps require the <a href="bboxMax.html">bboxMax option</a> to determine what zoom level 0 means. This option represents the other side of the zoom range.</p>
+
+ <p>This option also overrides programmatic changes. If zoomMax is 7 and you try to set the zoom option to 8 using JavaScript, it will be set to 7 instead.</p>
+ </div>
+ </div> <!-- end of #container -->
+
+ <script src="http://code.jquery.com/jquery-1.7.1.min.js"></script>
+ <script src="http://code.jquerygeo.com/jquery.geo-1.0a4.min.js"></script>
+ <script src="../js/script.js"></script>
+ <script src="http://code.jquery.com/mobile/1.0/jquery.mobile-1.0.min.js"></script>
+</body>
+</html>
+
View
99 docs/jquery.geo-test.js
@@ -4328,7 +4328,7 @@ $.Widget.prototype = {
this._setOption("center", this._initOptions.center, false);
}
if (this._initOptions.zoom !== undefined) {
- this._setZoom(this._initOptions.zoom, false, false);
+ this._setOption("zoom", this._initOptions.zoom, false);
}
}
@@ -4354,32 +4354,62 @@ $.Widget.prototype = {
this._panFinalize();
}
+ var center, pixelSize, zoom;
+
switch (key) {
case "bbox":
- this._clearInteractiveTimeout( );
+ if ( this._created ) {
+ this._clearInteractiveTimeout( );
+ }
this._userGeodetic = $.geo.proj && $.geo._isGeodetic( value );
if ( this._userGeodetic ) {
value = $.geo.proj.fromGeodetic( value );
}
- this._setBbox(value, false, refresh);
- this._setInteractiveTimeout( false );
+ center = [value[0] + (value[2] - value[0]) / 2, value[1] + (value[3] - value[1]) / 2];
+ pixelSize = Math.max($.geo.width(value, true) / this._contentBounds.width, $.geo.height(value, true) / this._contentBounds.height);
+
+ if (this._options["tilingScheme"]) {
+ zoom = this._getZoom( center, pixelSize );
+ pixelSize = this._getPixelSize( zoom );
+ } else {
+ if ( this._getZoom( center, pixelSize ) < 0 ) {
+ pixelSize = this._pixelSizeMax;
+ }
+ }
+
+ if ( this._created ) {
+ this._centerInteractive = center;
+ this._pixelSizeInteractive = pixelSize;
+
+ this._setInteractiveTimeout( false );
+ } else {
+ this._center = center;
+ this._pixelSize = pixelSize;
+ }
value = this._getBbox();
break;
case "center":
- this._clearInteractiveTimeout( );
+ if ( this._created ) {
+ this._clearInteractiveTimeout( );
+ }
this._userGeodetic = $.geo.proj && $.geo._isGeodetic( value );
if ( this._userGeodetic ) {
value = $.geo.proj.fromGeodetic( value );
}
- this._centerInteractive[ 0 ] = value[ 0 ];
- this._centerInteractive[ 1 ] = value[ 1 ];
- this._setInteractiveTimeout( false );
+ if ( this._created ) {
+ this._centerInteractive[ 0 ] = value[ 0 ];
+ this._centerInteractive[ 1 ] = value[ 1 ];
+ this._setInteractiveTimeout( false );
+ } else {
+ this._center[ 0 ] = value[ 0 ];
+ this._center[ 1 ] = value[ 1 ];
+ }
break;
case "measureLabels":
@@ -4411,7 +4441,12 @@ $.Widget.prototype = {
break;
case "zoom":
- this._setZoom(value, false, refresh);
+ if ( this._created ) {
+ this._setZoom(value, false, refresh);
+ } else {
+ value = Math.max( value, 0 );
+ this._pixelSize = this._getPixelSize( value );
+ }
break;
}
@@ -4931,7 +4966,6 @@ $.Widget.prototype = {
labelShape.coordinates[ 0 ].push( coords[ 0 ] );
label = $.render[ this._tmplAreaId ]( { area: $.geo.area( labelShape, true ) } );
- //labelPixel = $.merge( [], pixels[ pixels.length - 1 ] );
labelPixel = this._toPixel( $.geo.centroid( labelShape ).coordinates );
pixels = [ pixels ];
break;
@@ -5126,9 +5160,6 @@ $.Widget.prototype = {
if (this._wheelLevel !== 0) {
var wheelCenterAndSize = this._getZoomCenterAndSize( this._anchor, this._wheelLevel, this._options[ "tilingScheme" ] !== null );
- // #newpanzoom
- //this._setCenterAndSize(wheelCenterAndSize.center, wheelCenterAndSize.pixelSize, true, true);
-
this._wheelLevel = 0;
} else if ( refresh ) {
this._refresh();
@@ -5145,12 +5176,6 @@ $.Widget.prototype = {
dxMap = -dx * this._pixelSize,
dyMap = ( image ? -1 : 1 ) * dy * this._pixelSize;
- //this._$panContainer.css({ left: 0, top: 0 });
- //this._$servicesContainer.find( ".geo-shapes-container" ).css( { left: 0, top: 0 } );
-
- // #newpanzoom
- //this._setCenterAndSize([this._center[0] + dxMap, this._center[1] + dyMap], this._pixelSize, true, true);
-
this._$eventTarget.css("cursor", this._options["cursors"][this._options["mode"]]);
this._inOp = false;
@@ -5197,8 +5222,6 @@ $.Widget.prototype = {
this._timeoutInteractive = null;
return true;
} else {
- //console.log( "clearInteractiveTimeout( " + this._center.join( ", " ) + ", " + this._pixelSize + ")" );
-
this._centerInteractive[ 0 ] = this._center[ 0 ];
this._centerInteractive[ 1 ] = this._center[ 1 ];
this._pixelSizeInteractive = this._pixelSize;
@@ -5258,8 +5281,6 @@ $.Widget.prototype = {
},
_setCenterAndSize: function (center, pixelSize, trigger, refresh) {
- //console.log( "setCenterAndSize( " + center.join( ", " ) + ", " + pixelSize + ")" );
-
if ( ! $.isArray( center ) || center.length != 2 || typeof center[ 0 ] !== "number" || typeof center[ 1 ] !== "number" ) {
return;
}
@@ -5439,9 +5460,6 @@ $.Widget.prototype = {
return;
}
- // #newpanzoom
- //this._panFinalize();
-
if (this._drawTimeout) {
window.clearTimeout(this._drawTimeout);
this._drawTimeout = null;
@@ -5503,13 +5521,6 @@ $.Widget.prototype = {
return;
}
- // #newpanzoom
- //this._panFinalize();
- //this._mouseWheelFinish( false );
-
- //console.log("start centerI: " + this._centerInteractive.toString());
- //console.log("start pixelSizeI: " + this._pixelSizeInteractive);
-
var doInteractiveTimeout = this._clearInteractiveTimeout( );
var offset = $(e.currentTarget).offset(),
@@ -5603,9 +5614,6 @@ $.Widget.prototype = {
return;
}
- //console.log("move centerI: " + this._centerInteractive.toString());
- //console.log("move pixelSizeI: " + this._pixelSizeInteractive);
-
var doInteractiveTimeout = this._clearInteractiveTimeout( );
var offset = this._$eventTarget.offset(),
@@ -5615,14 +5623,10 @@ $.Widget.prototype = {
service,
i = 0;
- // $("h1").text("s: " + this._pixelSizeInteractive);
-
if ( this._supportTouch ) {
if ( !this._isMultiTouch && touches[ 0 ].identifier !== this._multiTouchAnchor[ 0 ].identifier ) {
// switch to multitouch
this._mouseDown = false;
- //this._dragTarget_touchstop( e );
-
this._isMultiTouch = true;
this._wheelLevel = 0;
@@ -5673,8 +5677,6 @@ $.Widget.prototype = {
this._wheelLevel = wheelLevel;
- //$("h1").text("w: " + delta + ", s: " + this._pixelSizeInteractive);
-
var pinchCenterAndSize = this._getZoomCenterAndSize( this._anchor, delta, false );
this._centerInteractive = pinchCenterAndSize.center;
@@ -5790,7 +5792,7 @@ $.Widget.prototype = {
// we fake regular click here to cause soft dblclick
this._eventTarget_touchstart(e);
} else {
- // Chrome & Firefox trigger an rogue mouseup event when doing a dblclick maximize in Windows(/Linux?)
+ // Chrome & Firefox trigger a rogue mouseup event when doing a dblclick maximize in Windows(/Linux?)
// ignore it
return false;
}
@@ -5798,9 +5800,6 @@ $.Widget.prototype = {
var doInteractiveTimeout = this._clearInteractiveTimeout( );
- //console.log("stop centerI: " + this._centerInteractive.toString());
- //console.log("stop pixelSizeI: " + this._pixelSizeInteractive);
-
var mouseWasDown = this._mouseDown,
wasToolPan = this._toolPan,
offset = this._$eventTarget.offset(),
@@ -5836,11 +5835,6 @@ $.Widget.prototype = {
e.preventDefault( );
this._isMultiTouch = false;
- //var pinchCenterAndSize = this._getZoomCenterAndSize( this._anchor, this._wheelLevel, false );
-
- // #newpanzoom
- //this._setCenterAndSize(pinchCenterAndSize.center, pinchCenterAndSize.pixelSize, true, true);
-
this._wheelLevel = 0;
if ( doInteractiveTimeout ) {
@@ -5883,7 +5877,6 @@ $.Widget.prototype = {
bbox = $.geo.scaleBy( this._getBbox( $.geo.center( bbox, true ) ), 0.5, true );
}
- // #newpanzoom
this._setBbox(bbox, true, true);
doInteractiveTimeout = true;
} else {
@@ -5983,8 +5976,6 @@ $.Widget.prototype = {
e.preventDefault();
- //this._panFinalize();
-
if ( this._mouseDown ) {
return false;
}
View
2  docs/jquery.geo-test.min.js
1 addition, 1 deletion not shown
View
99 js/jquery.geo.geomap.js
@@ -283,7 +283,7 @@
this._setOption("center", this._initOptions.center, false);
}
if (this._initOptions.zoom !== undefined) {
- this._setZoom(this._initOptions.zoom, false, false);
+ this._setOption("zoom", this._initOptions.zoom, false);
}
}
@@ -309,32 +309,62 @@
this._panFinalize();
}
+ var center, pixelSize, zoom;
+
switch (key) {
case "bbox":
- this._clearInteractiveTimeout( );
+ if ( this._created ) {
+ this._clearInteractiveTimeout( );
+ }
this._userGeodetic = $.geo.proj && $.geo._isGeodetic( value );
if ( this._userGeodetic ) {
value = $.geo.proj.fromGeodetic( value );
}
- this._setBbox(value, false, refresh);
- this._setInteractiveTimeout( false );
+ center = [value[0] + (value[2] - value[0]) / 2, value[1] + (value[3] - value[1]) / 2];
+ pixelSize = Math.max($.geo.width(value, true) / this._contentBounds.width, $.geo.height(value, true) / this._contentBounds.height);
+
+ if (this._options["tilingScheme"]) {
+ zoom = this._getZoom( center, pixelSize );
+ pixelSize = this._getPixelSize( zoom );
+ } else {
+ if ( this._getZoom( center, pixelSize ) < 0 ) {
+ pixelSize = this._pixelSizeMax;
+ }
+ }
+
+ if ( this._created ) {
+ this._centerInteractive = center;
+ this._pixelSizeInteractive = pixelSize;
+
+ this._setInteractiveTimeout( false );
+ } else {
+ this._center = center;
+ this._pixelSize = pixelSize;
+ }
value = this._getBbox();
break;
case "center":
- this._clearInteractiveTimeout( );
+ if ( this._created ) {
+ this._clearInteractiveTimeout( );
+ }
this._userGeodetic = $.geo.proj && $.geo._isGeodetic( value );
if ( this._userGeodetic ) {
value = $.geo.proj.fromGeodetic( value );
}
- this._centerInteractive[ 0 ] = value[ 0 ];
- this._centerInteractive[ 1 ] = value[ 1 ];
- this._setInteractiveTimeout( false );
+ if ( this._created ) {
+ this._centerInteractive[ 0 ] = value[ 0 ];
+ this._centerInteractive[ 1 ] = value[ 1 ];
+ this._setInteractiveTimeout( false );
+ } else {
+ this._center[ 0 ] = value[ 0 ];
+ this._center[ 1 ] = value[ 1 ];
+ }
break;
case "measureLabels":
@@ -366,7 +396,12 @@
break;
case "zoom":
- this._setZoom(value, false, refresh);
+ if ( this._created ) {
+ this._setZoom(value, false, refresh);
+ } else {
+ value = Math.max( value, 0 );
+ this._pixelSize = this._getPixelSize( value );
+ }
break;
}
@@ -886,7 +921,6 @@
labelShape.coordinates[ 0 ].push( coords[ 0 ] );
label = $.render[ this._tmplAreaId ]( { area: $.geo.area( labelShape, true ) } );
- //labelPixel = $.merge( [], pixels[ pixels.length - 1 ] );
labelPixel = this._toPixel( $.geo.centroid( labelShape ).coordinates );
pixels = [ pixels ];
break;
@@ -1081,9 +1115,6 @@
if (this._wheelLevel !== 0) {
var wheelCenterAndSize = this._getZoomCenterAndSize( this._anchor, this._wheelLevel, this._options[ "tilingScheme" ] !== null );
- // #newpanzoom
- //this._setCenterAndSize(wheelCenterAndSize.center, wheelCenterAndSize.pixelSize, true, true);
-
this._wheelLevel = 0;
} else if ( refresh ) {
this._refresh();
@@ -1100,12 +1131,6 @@
dxMap = -dx * this._pixelSize,
dyMap = ( image ? -1 : 1 ) * dy * this._pixelSize;
- //this._$panContainer.css({ left: 0, top: 0 });
- //this._$servicesContainer.find( ".geo-shapes-container" ).css( { left: 0, top: 0 } );
-
- // #newpanzoom
- //this._setCenterAndSize([this._center[0] + dxMap, this._center[1] + dyMap], this._pixelSize, true, true);
-
this._$eventTarget.css("cursor", this._options["cursors"][this._options["mode"]]);
this._inOp = false;
@@ -1152,8 +1177,6 @@
this._timeoutInteractive = null;
return true;
} else {
- //console.log( "clearInteractiveTimeout( " + this._center.join( ", " ) + ", " + this._pixelSize + ")" );
-
this._centerInteractive[ 0 ] = this._center[ 0 ];
this._centerInteractive[ 1 ] = this._center[ 1 ];
this._pixelSizeInteractive = this._pixelSize;
@@ -1213,8 +1236,6 @@
},
_setCenterAndSize: function (center, pixelSize, trigger, refresh) {
- //console.log( "setCenterAndSize( " + center.join( ", " ) + ", " + pixelSize + ")" );
-
if ( ! $.isArray( center ) || center.length != 2 || typeof center[ 0 ] !== "number" || typeof center[ 1 ] !== "number" ) {
return;
}
@@ -1394,9 +1415,6 @@
return;
}
- // #newpanzoom
- //this._panFinalize();
-
if (this._drawTimeout) {
window.clearTimeout(this._drawTimeout);
this._drawTimeout = null;
@@ -1458,13 +1476,6 @@
return;
}
- // #newpanzoom
- //this._panFinalize();
- //this._mouseWheelFinish( false );
-
- //console.log("start centerI: " + this._centerInteractive.toString());
- //console.log("start pixelSizeI: " + this._pixelSizeInteractive);
-
var doInteractiveTimeout = this._clearInteractiveTimeout( );
var offset = $(e.currentTarget).offset(),
@@ -1558,9 +1569,6 @@
return;
}
- //console.log("move centerI: " + this._centerInteractive.toString());
- //console.log("move pixelSizeI: " + this._pixelSizeInteractive);
-
var doInteractiveTimeout = this._clearInteractiveTimeout( );
var offset = this._$eventTarget.offset(),
@@ -1570,14 +1578,10 @@
service,
i = 0;
- // $("h1").text("s: " + this._pixelSizeInteractive);
-
if ( this._supportTouch ) {
if ( !this._isMultiTouch && touches[ 0 ].identifier !== this._multiTouchAnchor[ 0 ].identifier ) {
// switch to multitouch
this._mouseDown = false;
- //this._dragTarget_touchstop( e );
-
this._isMultiTouch = true;
this._wheelLevel = 0;
@@ -1628,8 +1632,6 @@
this._wheelLevel = wheelLevel;
- //$("h1").text("w: " + delta + ", s: " + this._pixelSizeInteractive);
-
var pinchCenterAndSize = this._getZoomCenterAndSize( this._anchor, delta, false );
this._centerInteractive = pinchCenterAndSize.center;
@@ -1745,7 +1747,7 @@
// we fake regular click here to cause soft dblclick
this._eventTarget_touchstart(e);
} else {
- // Chrome & Firefox trigger an rogue mouseup event when doing a dblclick maximize in Windows(/Linux?)
+ // Chrome & Firefox trigger a rogue mouseup event when doing a dblclick maximize in Windows(/Linux?)
// ignore it
return false;
}
@@ -1753,9 +1755,6 @@
var doInteractiveTimeout = this._clearInteractiveTimeout( );
- //console.log("stop centerI: " + this._centerInteractive.toString());
- //console.log("stop pixelSizeI: " + this._pixelSizeInteractive);
-
var mouseWasDown = this._mouseDown,
wasToolPan = this._toolPan,
offset = this._$eventTarget.offset(),
@@ -1791,11 +1790,6 @@
e.preventDefault( );
this._isMultiTouch = false;
- //var pinchCenterAndSize = this._getZoomCenterAndSize( this._anchor, this._wheelLevel, false );
-
- // #newpanzoom
- //this._setCenterAndSize(pinchCenterAndSize.center, pinchCenterAndSize.pixelSize, true, true);
-
this._wheelLevel = 0;
if ( doInteractiveTimeout ) {
@@ -1838,7 +1832,6 @@
bbox = $.geo.scaleBy( this._getBbox( $.geo.center( bbox, true ) ), 0.5, true );
}
- // #newpanzoom
this._setBbox(bbox, true, true);
doInteractiveTimeout = true;
} else {
@@ -1938,8 +1931,6 @@
e.preventDefault();
- //this._panFinalize();
-
if ( this._mouseDown ) {
return false;
}
Something went wrong with that request. Please try again.