) or cancelled
@@ -41881,7 +41533,6 @@ return /******/ (function(modules) { // webpackBootstrap
* start point.
* @returns {geo.annotationLayer}
*/
- /////////////////////////////////////////////////////////////////////////////
var annotationLayer = function (args) {
'use strict';
if (!(this instanceof annotationLayer)) {
@@ -42482,11 +42133,9 @@ return /******/ (function(modules) { // webpackBootstrap
return value;
};
- ///////////////////////////////////////////////////////////////////////////
/**
* Update layer
*/
- ///////////////////////////////////////////////////////////////////////////
this._update = function (request) {
if (m_this.getMTime() > m_buildTime.getMTime()) {
/* Interally, we have a set of feature levels (to provide z-index
@@ -42594,13 +42243,11 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ///////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ///////////////////////////////////////////////////////////////////////////
this._init = function () {
- /// Call super class init
+ // Call super class init
s_init.call(m_this);
if (!m_this.map().interactor()) {
@@ -42617,13 +42264,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ///////////////////////////////////////////////////////////////////////////
/**
* Free all resources
*/
- ///////////////////////////////////////////////////////////////////////////
this._exit = function () {
- /// Call super class exit
+ // Call super class exit
s_exit.call(m_this);
m_annotations = [];
m_features = [];
@@ -42647,7 +42292,6 @@ return /******/ (function(modules) { // webpackBootstrap
var geo_event = __webpack_require__(9);
var registry = __webpack_require__(201);
- //////////////////////////////////////////////////////////////////////////////
/**
* Layer to draw points, lines, and polygons on the map The polydata layer
* provide mechanisms to create and draw geometrical shapes such as points,
@@ -42656,7 +42300,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.layer
* @returns {geo.featureLayer}
*/
- //////////////////////////////////////////////////////////////////////////////
var featureLayer = function (arg) {
'use strict';
if (!(this instanceof featureLayer)) {
@@ -42664,11 +42307,9 @@ return /******/ (function(modules) { // webpackBootstrap
}
layer.call(this, arg);
- ////////////////////////////////////////////////////////////////////////////
/**
* private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
m_features = [],
s_init = this._init,
@@ -42678,7 +42319,6 @@ return /******/ (function(modules) { // webpackBootstrap
s_selectionAPI = this.selectionAPI,
s_draw = this.draw;
- ////////////////////////////////////////////////////////////////////////////
/**
* Create feature give a name
*
@@ -42686,7 +42326,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {object} arg properties for the new feature
* @returns {geo.Feature} Will return a new feature
*/
- ////////////////////////////////////////////////////////////////////////////
this.createFeature = function (featureName, arg) {
var newFeature = registry.createFeature(
@@ -42697,13 +42336,11 @@ return /******/ (function(modules) { // webpackBootstrap
return newFeature;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Add a feature to the layer if it is not already present.
*
* @param {object} feature the feature to add.
*/
- ////////////////////////////////////////////////////////////////////////////
this.addFeature = function (feature) {
/* try to remove the feature first so that we don't have two copies */
this.removeFeature(feature);
@@ -42714,13 +42351,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Remove feature without destroying it
*
* @param {object} feature the feature to remove.
*/
- ////////////////////////////////////////////////////////////////////////////
this.removeFeature = function (feature) {
var pos;
@@ -42735,13 +42370,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Delete feature
*
* @param {object} feature the feature to delete.
*/
- ////////////////////////////////////////////////////////////////////////////
this.deleteFeature = function (feature) {
// call _exit first, as destroying the feature affect other features
@@ -42755,13 +42388,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set drawables
*
* @returns {Array}
*/
- ////////////////////////////////////////////////////////////////////////////
this.features = function (val) {
if (val === undefined) {
return m_features.slice();
@@ -42783,20 +42414,18 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function () {
if (m_this.initialized()) {
return m_this;
}
- /// Call super class init
+ // Call super class init
s_init.call(m_this, true);
- /// Bind events to handlers
+ // Bind events to handlers
m_this.geoOn(geo_event.resize, function (event) {
if (m_this.renderer()) {
m_this.renderer()._resize(event.x, event.y, event.width, event.height);
@@ -42831,11 +42460,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update layer
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function (request) {
var i;
@@ -42843,7 +42470,7 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
}
- /// Call base class update
+ // Call base class update
s_update.call(m_this, request);
if (m_this.dataTime().getMTime() > m_this.updateTime().getMTime()) {
@@ -42861,21 +42488,17 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Free all resources
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_this.clear();
s_exit();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Draw
*/
- ////////////////////////////////////////////////////////////////////////////
this.draw = function () {
if (m_this.visible()) {
// Call sceneObject.draw, which calls draw on all child objects.
@@ -42890,7 +42513,6 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set visibility of the layer
*
@@ -42899,7 +42521,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @return {boolean|object} either the visibility (if getting) or the layer
* (if setting).
*/
- ////////////////////////////////////////////////////////////////////////////
this.visible = function (val) {
if (val === undefined) {
return s_visible();
@@ -42920,7 +42541,6 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set selectionAPI of the layer
*
@@ -42929,7 +42549,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @return {boolean|object} either the selectionAPI state (if getting) or the
* layer (if setting).
*/
- ////////////////////////////////////////////////////////////////////////////
this.selectionAPI = function (val) {
if (val === undefined) {
return s_selectionAPI();
@@ -42947,11 +42566,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Clear all features in layer
*/
- ////////////////////////////////////////////////////////////////////////////
this.clear = function () {
while (m_features.length) {
m_this.deleteFeature(m_features[0]);
@@ -44026,7 +43643,6 @@ return /******/ (function(modules) { // webpackBootstrap
var util = __webpack_require__(83);
var Mousetrap = __webpack_require__(220);
- //////////////////////////////////////////////////////////////////////////////
/**
* The mapInteractor class is responsible for handling raw events from the
* browser and interpreting them as map navigation interactions. This class
@@ -44037,7 +43653,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.object
* @returns {geo.mapInteractor}
*/
- //////////////////////////////////////////////////////////////////////////////
var mapInteractor = function (args) {
'use strict';
if (!(this instanceof mapInteractor)) {
@@ -44287,147 +43902,68 @@ return /******/ (function(modules) { // webpackBootstrap
m_options.keyboard.actions = $.extend(true, {}, args.keyboard.actions);
}
- // options supported:
- // {
- // // throttle mouse events to at most this many milliseconds each (default 30)
- // throttle: number
- //
- // // Clamp zoom events to discrete (integer) zoom levels. If a number is
- // // provided then zoom events will be debounced (and accumulated)
- // // with the given delay. The default debounce interval is 400 ms.
- // discreteZoom: boolean | number > 0
- //
- // // A list of available actions. See above
- // actions: []
- //
- // // wheel scale factor to change the magnitude of wheel interactions
- // wheelScaleX: 1
- // wheelScaleY: 1
- //
- // // zoom scale factor to change the magnitude of zoom move interactions
- // zoomScale: 1
- //
- // // scale factor to change the magnitude of wheel rotation interactions
- // rotateWheelScale: 1
- //
- // // enable momentum when panning
- // momentum: {
- // enabled: true | false,
- // maxSpeed: number, // don't allow animation to pan faster than this
- // minSpeed: number, // stop animations if the speed is less than this
- // stopTime: number, // if the mouse hasn't moved for this many
- // // milliseconds, don't apply momentum
- // drag: number, // drag coefficient
- // actions: [geo_action.pan, geo_action.zoom]
- // // actions on which to apply momentum
- // }
- //
- // // enable spring clamping to screen edges to enforce clamping
- // spring: {
- // enabled: true | false,
- // springConstant: number,
- // }
- //
- // // enable animation for both discrete and continuous zoom
- // zoomAnimation: {
- // enabled: true | false,
- // duration: number, // milliseconds
- // ease: function // easing function
- // }
- //
- // // enable the "click" event
- // // A click will be registered when a mouse down is followed
- // // by a mouse up in less than the given number of milliseconds
- // // and the standard handler will *not* be called
- // // If the duration is <= 0, then clicks will only be canceled by
- // // a mousemove.
- // click: {
- // enabled: true | false,
- // buttons: {left: true, right: true, middle: true}
- // duration: 0,
- // cancelOnMove: true // cancels click if the mouse is moved before release
- // }
- // }
-
- // A bunch of type definitions for api documentation:
- /**
- * General representation of rectangular bounds in world coordinates
- * @typedef geo.geoBounds
- * @type {object}
- * @property {geo.geoPosition} upperLeft Upper left corner
- * @property {geo.geoPosition} upperRight Upper right corner
- * @property {geo.geoPosition} lowerLeft Lower left corner
- * @property {geo.geoPosition} lowerRight Lower right corner
- */
-
- /**
- * General representation of rectangular bounds in pixel coordinates
- * @typedef geo.screenBounds
- * @type {object}
- * @property {geo.screenPosition} upperLeft Upper left corner
- * @property {geo.screenPosition} upperRight Upper right corner
- * @property {geo.screenPosition} lowerLeft Lower left corner
- * @property {geo.screenPosition} lowerRight Lower right corner
- */
-
- /**
- * General representation of a point on the screen.
- * @typedef geo.screenPosition
- * @type {object}
- * @property {Number} x Horizontal coordinate in pixels
- * @property {Number} y Vertical coordinate in pixels
- */
-
- /**
- * General represention of a point on the earth.
- * @typedef geo.geoPosition
- * @type {object}
- * @property {Number} x Horizontal coordinate in degrees longitude
- * @property {Number} y Vertical coordinate in degrees latitude
- */
-
- /**
- * The status of all mouse buttons.
- * @typedef geo.mouseButtons
- * @type {object}
- * @property {true|false} left The left mouse button
- * @property {true|false} right The right mouse button
- * @property {true|false} middle The middle mouse button
- */
-
- /**
- * The status of all modifier keys these are copied from the
- * standard DOM events.
- * @typedef geo.modifierKeys
- * @type {object}
- * @property {true|false} alt Event.alt
- * @property {true|false} ctrl Event.ctrl
- * @property {true|false} shift Event.shift
- * @property {true|false} meta Event.meta
- */
-
- /**
- * Provides information about the state of the mouse
- * @typedef geo.mouseState
- * @type {object}
- * @property {geo.screenPosition} page Mouse location in pixel space
- * @property {geo.geoPosition} map Mouse location in world space
- * @property {geo.mouseButtons} buttons The current state of the mouse buttons
- * @property {geo.modifierKeys} modifiers The current state of all modifier keys
- * @property {Date} time The timestamp the event took place
- * @property {Number} deltaTime The time in milliseconds since the last mouse event
- * @property {geo.screenPosition} velocity The velocity of the mouse pointer
- * in pixels per second
- */
-
- /**
- * @typedef geo.brushSelection
- * @type {object}
- * @property {geo.screenBounds} display The selection bounds in pixel space
- * @property {geo.geoBounds} gcs The selection bounds in world space
- * @property {geo.mouseState} mouse The current mouse state
- * @property {geo.mouseState} origin The mouse state at the start of the
- * brush action
+ /*
+ * options supported:
+ * {
+ * * throttle mouse events to at most this many milliseconds each (default 30)
+ * throttle: number
+ *
+ * * Clamp zoom events to discrete (integer) zoom levels. If a number is
+ * * provided then zoom events will be debounced (and accumulated)
+ * * with the given delay. The default debounce interval is 400 ms.
+ * discreteZoom: boolean | number > 0
+ *
+ * * A list of available actions. See above
+ * actions: []
+ *
+ * * wheel scale factor to change the magnitude of wheel interactions
+ * wheelScaleX: 1
+ * wheelScaleY: 1
+ *
+ * * zoom scale factor to change the magnitude of zoom move interactions
+ * zoomScale: 1
+ *
+ * * scale factor to change the magnitude of wheel rotation interactions
+ * rotateWheelScale: 1
+ *
+ * * enable momentum when panning
+ * momentum: {
+ * enabled: true | false,
+ * maxSpeed: number, // don't allow animation to pan faster than this
+ * minSpeed: number, // stop animations if the speed is less than this
+ * stopTime: number, // if the mouse hasn't moved for this many
+ * * milliseconds, don't apply momentum
+ * drag: number, // drag coefficient
+ * actions: [geo_action.pan, geo_action.zoom]
+ * * actions on which to apply momentum
+ * }
+ *
+ * * enable spring clamping to screen edges to enforce clamping
+ * spring: {
+ * enabled: true | false,
+ * springConstant: number,
+ * }
+ *
+ * * enable animation for both discrete and continuous zoom
+ * zoomAnimation: {
+ * enabled: true | false,
+ * duration: number, * milliseconds
+ * ease: function * easing function
+ * }
+ *
+ * * enable the "click" event
+ * * A click will be registered when a mouse down is followed
+ * * by a mouse up in less than the given number of milliseconds
+ * * and the standard handler will *not* be called
+ * * If the duration is <= 0, then clicks will only be canceled by
+ * * a mousemove.
+ * click: {
+ * enabled: true | false,
+ * buttons: {left: true, right: true, middle: true}
+ * duration: 0,
+ * cancelOnMove: true // cancels click if the mouse is moved before release
+ * }
+ * }
*/
// default mouse object
@@ -44464,41 +44000,43 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- // The interactor state determines what actions are taken in response to
- // core browser events.
- //
- // i.e.
- // {
- // 'action': geo_action.pan, // an ongoing pan event
- // 'origin': {...}, // mouse object at the start of the action
- // 'delta': {x: *, y: *} // mouse movement since action start
- // // not including the current event
- // }
- //
- // {
- // 'action': geo_action.zoom, // an ongoing zoom event
- // ...
- // }
- //
- // {
- // 'action': geo_action.rotate, // an ongoing rotate event
- // 'origin': {...}, // mouse object at the start of the action
- // 'delta': {x: *, y: *} // mouse movement since action start
- // // not including the current event
- // }
- //
- // {
- // 'acton': geo_action.select,
- // 'origin': {...},
- // 'delta': {x: *, y: *}
- // }
- //
- // {
- // 'action': geo_action.momentum,
- // 'origin': {...},
- // 'handler': function () { }, // called in animation loop
- // 'timer': animate loop timer
- // }
+ /*
+ * The interactor state determines what actions are taken in response to
+ * core browser events.
+ *
+ * i.e.
+ * {
+ * 'action': geo_action.pan, * an ongoing pan event
+ * 'origin': {...}, * mouse object at the start of the action
+ * 'delta': {x: *, y: *} // mouse movement since action start
+ * * not including the current event
+ * }
+ *
+ * {
+ * 'action': geo_action.zoom, * an ongoing zoom event
+ * ...
+ * }
+ *
+ * {
+ * 'action': geo_action.rotate, * an ongoing rotate event
+ * 'origin': {...}, * mouse object at the start of the action
+ * 'delta': {x: *, y: *} // mouse movement since action start
+ * * not including the current event
+ * }
+ *
+ * {
+ * 'acton': geo_action.select,
+ * 'origin': {...},
+ * 'delta': {x: *, y: *}
+ * }
+ *
+ * {
+ * 'action': geo_action.momentum,
+ * 'origin': {...},
+ * 'handler': function () { }, // called in animation loop
+ * 'timer': animate loop timer
+ * }
+ */
m_state = {};
/**
@@ -44707,12 +44245,10 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Connects events to a map. If the map is not set, then this does nothing.
* @returns {geo.mapInteractor}
*/
- ////////////////////////////////////////////////////////////////////////////
this._connectEvents = function () {
if (!m_options.map) {
return m_this;
@@ -44800,13 +44336,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Disconnects events to a map. If the map is not set, then this does
* nothing.
* @returns {geo.mapInteractor}
*/
- ////////////////////////////////////////////////////////////////////////////
this._disconnectEvents = function () {
if (m_boundKeys) {
if (m_keyHandler) {
@@ -44829,14 +44363,12 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Sets or gets map for this interactor, adds draw region layer if needed
*
* @param {geo.map} newMap optional
* @returns {geo.interactorStyle|geo.map}
*/
- ////////////////////////////////////////////////////////////////////////////
this.map = function (val) {
if (val !== undefined) {
m_options.map = val;
@@ -44846,14 +44378,12 @@ return /******/ (function(modules) { // webpackBootstrap
return m_options.map;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Gets/sets the options object for the interactor.
*
* @param {object} opts optional
* @returns {geo.interactorStyle|object}
*/
- ////////////////////////////////////////////////////////////////////////////
this.options = function (opts) {
if (opts === undefined) {
return $.extend({}, m_options);
@@ -44865,11 +44395,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Stores the current mouse position from an event
+ *
+ * @param {jQuery.Event} evt JQuery event with the mouse position.
*/
- ////////////////////////////////////////////////////////////////////////////
this._getMousePosition = function (evt) {
var offset = $node.offset(), dt, t;
@@ -44894,17 +44424,13 @@ return /******/ (function(modules) { // webpackBootstrap
m_mouse.mapgcs = m_this.map().displayToGcs(m_mouse.map, null);
} catch (e) {
// catch georeferencing problems and move on
- // needed for handling the map before the base layer
- // is attached
m_mouse.geo = m_mouse.mapgcs = null;
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Stores the current mouse button
*/
- ////////////////////////////////////////////////////////////////////////////
this._getMouseButton = function (evt) {
for (var prop in m_mouse.buttons) {
if (m_mouse.buttons.hasOwnProperty(prop)) {
@@ -44925,11 +44451,9 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Stores the current keyboard modifiers
*/
- ////////////////////////////////////////////////////////////////////////////
this._getMouseModifiers = function (evt) {
m_mouse.modifiers.alt = evt.altKey;
m_mouse.modifiers.ctrl = evt.ctrlKey;
@@ -44937,13 +44461,12 @@ return /******/ (function(modules) { // webpackBootstrap
m_mouse.modifiers.shift = evt.shiftKey;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Compute a selection information object.
+ *
* @private
- * @returns {object}
+ * @returns {geo.brushSelection}
*/
- ////////////////////////////////////////////////////////////////////////////
this._getSelection = function () {
var origin = m_state.origin,
mouse = m_this.mouse(),
@@ -44994,7 +44517,6 @@ return /******/ (function(modules) { // webpackBootstrap
};
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Immediately cancel an ongoing action.
*
@@ -45003,7 +44525,6 @@ return /******/ (function(modules) { // webpackBootstrap
* canceled.
* @returns {bool} If an action was canceled
*/
- ////////////////////////////////////////////////////////////////////////////
this.cancel = function (action, keepQueue) {
var out;
if (!action) {
@@ -45021,12 +44542,10 @@ return /******/ (function(modules) { // webpackBootstrap
return out;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Set the value of whether a click is possible. Cancel any outstanding
* timer for this process.
*/
- ////////////////////////////////////////////////////////////////////////////
this._setClickMaybe = function (value) {
m_clickMaybe = value;
if (m_clickMaybeTimeout) {
@@ -45035,11 +44554,9 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Handle event when a mouse button is pressed
*/
- ////////////////////////////////////////////////////////////////////////////
this._handleMouseDown = function (evt) {
var action, actionRecord;
@@ -45136,11 +44653,9 @@ return /******/ (function(modules) { // webpackBootstrap
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Handle mouse move event
*/
- ////////////////////////////////////////////////////////////////////////////
this._handleMouseMove = function (evt) {
if (m_paused) {
return;
@@ -45239,11 +44754,9 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Handle mouse move event on the document (temporary bindings)
*/
- ////////////////////////////////////////////////////////////////////////////
this._handleMouseMoveDocument = function (evt) {
var dx, dy, selectionObj;
@@ -45396,7 +44909,6 @@ return /******/ (function(modules) { // webpackBootstrap
};
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Based on the screen coordinates of a selection, zoom or unzoom and
* recenter.
@@ -45409,7 +44921,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {object} upperRight the x and y coordinates of the upper right
* corner of the zoom rectangle.
*/
- ////////////////////////////////////////////////////////////////////////////
this._zoomFromSelection = function (action, lowerLeft, upperRight) {
if (action !== geo_action.zoomselect && action !== geo_action.unzoomselect) {
return;
@@ -45462,12 +44973,10 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Handle event when a mouse button is unpressed on the document.
* Removes temporary bindings.
*/
- ////////////////////////////////////////////////////////////////////////////
this._handleMouseUpDocument = function (evt) {
var selectionObj, oldAction;
@@ -45534,11 +45043,9 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Handle event when a mouse button is unpressed
*/
- ////////////////////////////////////////////////////////////////////////////
this._handleMouseUp = function (evt) {
if (m_paused) {
return;
@@ -45551,14 +45058,12 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Handle event when a mouse click is detected. A mouse click is a simulated
* event that occurs when the time between a mouse down and mouse up
* is less than the configured duration and (optionally) if no mousemove
* events were triggered in the interim.
*/
- ////////////////////////////////////////////////////////////////////////////
this._handleMouseClick = function (evt) {
/* Cancel a selection if it is occurring */
@@ -45588,13 +45093,11 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.map().geoTrigger(geo_event.mouseclick, details);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Private wrapper around the map zoom method that is debounced to support
* discrete zoom interactions.
* @param {number} deltaZ The zoom increment
*/
- ////////////////////////////////////////////////////////////////////////////
function debounced_zoom() {
var deltaZ = 0, delay = 400, origin, startZoom, targetZoom;
@@ -45689,13 +45192,11 @@ return /******/ (function(modules) { // webpackBootstrap
}
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Attaches wrapped methods for accumulating fast mouse wheel events and
* throttling map interactions.
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
function throttled_wheel() {
var my_queue = {};
@@ -45800,14 +45301,11 @@ return /******/ (function(modules) { // webpackBootstrap
}
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Handle mouse wheel event. (Defined inside _connectEvents).
*/
- ////////////////////////////////////////////////////////////////////////////
this._handleMouseWheel = function () {};
- ////////////////////////////////////////////////////////////////////////////
/**
* Start up a spring back action when the map bounds are out of range.
* Not to be user callable.
@@ -45815,7 +45313,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @protected
*
*/
- ////////////////////////////////////////////////////////////////////////////
this.springBack = function (initialVelocity, origAction) {
if (m_state.action === geo_action.momentum) {
return;
@@ -45892,19 +45389,15 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Handle double click event
*/
- ////////////////////////////////////////////////////////////////////////////
this._handleDoubleClick = function () {
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Public method that unbinds all events
*/
- ////////////////////////////////////////////////////////////////////////////
this.destroy = function () {
m_this._disconnectEvents();
if (m_this.map()) {
@@ -45913,20 +45406,16 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.map(null);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get current mouse information
*/
- ////////////////////////////////////////////////////////////////////////////
this.mouse = function () {
return $.extend(true, {}, m_mouse);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/set current keyboard information
*/
- ////////////////////////////////////////////////////////////////////////////
this.keyboard = function (newValue) {
if (newValue === undefined) {
return $.extend(true, {}, m_options.keyboard || {});
@@ -45934,16 +45423,15 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this.options({keyboard: newValue});
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get the current interactor state
+ *
+ * @returns {geo.interactorState}
*/
- ////////////////////////////////////////////////////////////////////////////
this.state = function () {
return $.extend(true, {}, m_state);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get or set the pause state of the interactor, which
* ignores all native mouse and keyboard events.
@@ -45952,7 +45440,6 @@ return /******/ (function(modules) { // webpackBootstrap
* current state.
* @returns {bool|this}
*/
- ////////////////////////////////////////////////////////////////////////////
this.pause = function (value) {
if (value === undefined) {
return m_paused;
@@ -46021,7 +45508,6 @@ return /******/ (function(modules) { // webpackBootstrap
return removed;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Simulate a DOM mouse event on connected map.
*
@@ -46040,7 +45526,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {object} options
* @returns {mapInteractor}
*/
- ////////////////////////////////////////////////////////////////////////////
this.simulateEvent = function (type, options) {
var evt, page, offset, which;
@@ -46137,7 +45622,6 @@ return /******/ (function(modules) { // webpackBootstrap
var inherit = __webpack_require__(8);
var feature = __webpack_require__(207);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class quadFeature
*
@@ -46177,7 +45661,6 @@ return /******/ (function(modules) { // webpackBootstrap
* attribute of the data item.
* @returns {geo.quadFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var quadFeature = function (arg) {
'use strict';
@@ -46190,11 +45673,9 @@ return /******/ (function(modules) { // webpackBootstrap
arg = arg || {};
feature.call(this, arg);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_init = this._init,
m_cacheQuads,
@@ -46260,7 +45741,6 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Point search method for selection api. Returns markers containing the
* given point.
@@ -46271,7 +45751,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @returns {Object} an object with 'index': a list of quad indices, and
* 'found': a list of quads that contain the specified coordinate.
*/
- ////////////////////////////////////////////////////////////////////////////
this.pointSearch = function (coordinate) {
var found = [], indices = [], extra = {},
poly1 = [{}, {}, {}, {}], poly2 = [{}, {}, {}, {}],
@@ -46331,7 +45810,6 @@ return /******/ (function(modules) { // webpackBootstrap
};
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set position
*
@@ -46340,7 +45818,6 @@ return /******/ (function(modules) { // webpackBootstrap
* position of each quad.
* @returns {geo.quadFeature}
*/
- ////////////////////////////////////////////////////////////////////////////
this.position = function (val) {
if (val === undefined) {
return m_this.style('position');
@@ -46590,11 +46067,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_quads;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
arg = arg || {};
s_init.call(m_this, arg);
@@ -46682,7 +46157,6 @@ return /******/ (function(modules) { // webpackBootstrap
var inherit = __webpack_require__(8);
var feature = __webpack_require__(207);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class choroplethFeature
*
@@ -46708,7 +46182,6 @@ return /******/ (function(modules) { // webpackBootstrap
* If undefined input, return all the choropleth values as an object.
* @returns {geo.choroplethFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var choroplethFeature = function (arg) {
'use strict';
if (!(this instanceof choroplethFeature)) {
@@ -46720,11 +46193,9 @@ return /******/ (function(modules) { // webpackBootstrap
var $ = __webpack_require__(1);
var ensureFunction = __webpack_require__(83).ensureFunction;
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var d3 = __webpack_require__(225),
m_this = this,
s_init = this._init,
@@ -46759,7 +46230,6 @@ return /******/ (function(modules) { // webpackBootstrap
},
arg.choropleth);
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set choropleth scalar data
*
@@ -46772,7 +46242,6 @@ return /******/ (function(modules) { // webpackBootstrap
* is d3.mean.
* @returns {geo.feature.choropleth}
*/
- ////////////////////////////////////////////////////////////////////////////
this.scalar = function (data, aggregator) {
var scalarId, scalarValue;
@@ -46805,7 +46274,6 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set choropleth accessor
*
@@ -46819,7 +46287,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {Object|String} [arg2] arg2 defines the value of the key (arg1).
* @returns {geo.feature.choropleth}
*/
- ////////////////////////////////////////////////////////////////////////////
this.choropleth = function (arg1, arg2) {
var choropleth;
@@ -46843,7 +46310,6 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set choropleth getter
*
@@ -46855,7 +46321,6 @@ return /******/ (function(modules) { // webpackBootstrap
* choropleth.
* @return {function}
*/
- ////////////////////////////////////////////////////////////////////////////
this.choropleth.get = function (key) {
var all = {}, k;
if (key === undefined) {
@@ -46869,7 +46334,6 @@ return /******/ (function(modules) { // webpackBootstrap
return ensureFunction(m_choropleth[key]);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* A method that adds a polygon feature to the current layer.
*
@@ -46877,7 +46341,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {geo.color} fillColor
* @return {geo.feature}
*/
- ////////////////////////////////////////////////////////////////////////////
this._addPolygonFeature = function (feature, fillColor) {
var newFeature = m_this.layer()
.createFeature('polygon', {});
@@ -46916,7 +46379,6 @@ return /******/ (function(modules) { // webpackBootstrap
return newFeature;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* A method that adds polygons from a given feature to the current layer.
*
@@ -46924,20 +46386,17 @@ return /******/ (function(modules) { // webpackBootstrap
* @param geo.color
* @return [{geo.feature}]
*/
- ////////////////////////////////////////////////////////////////////////////
this._featureToPolygons = function (feature, fillValue) {
return m_this
._addPolygonFeature(feature, fillValue);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* A method that sets a choropleth scale's domain and range.
*
* @param {undefined | function({})} valueAccessor
* @return {geo.feature.choropleth}
*/
- ////////////////////////////////////////////////////////////////////////////
this._generateScale = function (valueAccessor) {
var extent =
d3.extent(m_this.scalar(), valueAccessor || undefined);
@@ -46950,12 +46409,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Generate scale for choropleth.data(), make polygons from features.
* @returns: [ [geo.feature.polygon, ...] , ... ]
*/
- ////////////////////////////////////////////////////////////////////////////
this.createChoropleth = function () {
var choropleth = m_this.choropleth,
data = m_this.data(),
@@ -46983,11 +46440,9 @@ return /******/ (function(modules) { // webpackBootstrap
});
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
s_init.call(m_this, arg);
@@ -47017,7 +46472,6 @@ return /******/ (function(modules) { // webpackBootstrap
var inherit = __webpack_require__(8);
var feature = __webpack_require__(207);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class contourFeature
*
@@ -47026,7 +46480,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @returns {geo.contourFeature}
*
*/
- //////////////////////////////////////////////////////////////////////////////
var contourFeature = function (arg) {
'use strict';
if (!(this instanceof contourFeature)) {
@@ -47039,11 +46492,9 @@ return /******/ (function(modules) { // webpackBootstrap
arg = arg || {};
feature.call(this, arg);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
m_contour = {},
s_init = this._init,
@@ -47057,24 +46508,20 @@ return /******/ (function(modules) { // webpackBootstrap
m_contour = arg.contour;
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Override the parent data method to keep track of changes to the
* internal coordinates.
*/
- ////////////////////////////////////////////////////////////////////////////
this.data = function (arg) {
var ret = s_data(arg);
return ret;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set contour accessor
*
* @returns {geo.pointFeature}
*/
- ////////////////////////////////////////////////////////////////////////////
this.contour = function (arg1, arg2) {
if (arg1 === undefined) {
return m_contour;
@@ -47126,7 +46573,6 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* A uniform getter that always returns a function even for constant values.
* If undefined input, return all the contour values as an object.
@@ -47134,7 +46580,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {string|undefined} key
* @return {function}
*/
- ////////////////////////////////////////////////////////////////////////////
this.contour.get = function (key) {
if (key === undefined) {
var all = {}, k;
@@ -47148,13 +46593,11 @@ return /******/ (function(modules) { // webpackBootstrap
return util.ensureFunction(m_contour[key]);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set position accessor
*
* @returns {geo.pointFeature}
*/
- ////////////////////////////////////////////////////////////////////////////
this.position = function (val) {
if (val === undefined) {
return m_this.style('position');
@@ -47166,7 +46609,6 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Create a set of vertices, values at the vertices, and opacities at the
* vertices. Create a set of triangles of indices into the vertex array.
@@ -47177,7 +46619,6 @@ return /******/ (function(modules) { // webpackBootstrap
* contour data that can be used, only elements is guaranteed to
* exist, and it will be a zero-length array.
*/
- ////////////////////////////////////////////////////////////////////////////
this.createContours = function () {
var i, i3, j, idx, k, val, numPts, usedPts = 0, usePos, item,
idxMap = {},
@@ -47373,11 +46814,9 @@ return /******/ (function(modules) { // webpackBootstrap
return result;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
s_init.call(m_this, arg);
@@ -47527,7 +46966,6 @@ return /******/ (function(modules) { // webpackBootstrap
var $ = __webpack_require__(1);
- //////////////////////////////////////////////////////////////////////////////
/**
* This class implements a queue for Deferred objects. Whenever one of the
* objects in the queue completes (resolved or rejected), another item in the
@@ -47553,7 +46991,6 @@ return /******/ (function(modules) { // webpackBootstrap
* Deferred object and must return a truthy value if the object is still
* needed.
*/
- //////////////////////////////////////////////////////////////////////////////
var fetchQueue = function (options) {
if (!(this instanceof fetchQueue)) {
return new fetchQueue(options);
@@ -47757,7 +47194,6 @@ return /******/ (function(modules) { // webpackBootstrap
var featureLayer = __webpack_require__(219);
var object = __webpack_require__(203);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class fileReader
*
@@ -47765,7 +47201,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.object
* @returns {geo.fileReader}
*/
- //////////////////////////////////////////////////////////////////////////////
var fileReader = function (arg) {
'use strict';
if (!(this instanceof fileReader)) {
@@ -47773,11 +47208,9 @@ return /******/ (function(modules) { // webpackBootstrap
}
object.call(this);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
arg = arg || {};
if (!(arg.layer instanceof featureLayer)) {
@@ -47786,41 +47219,33 @@ return /******/ (function(modules) { // webpackBootstrap
var m_layer = arg.layer;
- ////////////////////////////////////////////////////////////////////////////
/**
* Get the feature layer attached to the reader
*/
- ////////////////////////////////////////////////////////////////////////////
this.layer = function () {
return m_layer;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Tells the caller if it can handle the given file by returning a boolean.
*/
- ////////////////////////////////////////////////////////////////////////////
this.canRead = function () {
return false;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Reads the file object and calls the done function when finished. As an
* argument to done, provides a boolean that reports if the read was a
* success. Possibly, it can call done with an object containing details
* of the read operation.
*/
- ////////////////////////////////////////////////////////////////////////////
this.read = function (file, done) {
done(false);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Return a FileReader with handlers attached.
*/
- ////////////////////////////////////////////////////////////////////////////
function newFileReader(done, progress) {
var reader = new FileReader();
if (progress) {
@@ -47835,24 +47260,20 @@ return /******/ (function(modules) { // webpackBootstrap
return reader;
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Private method for reading a file object as a string. Calls done with
* the string content when finished or an error object if unsuccessful.
* Optionally, the caller can provide a progress method that is called
* after reading each slice.
*/
- ////////////////////////////////////////////////////////////////////////////
this._getString = function (file, done, progress) {
var reader = newFileReader(done, progress);
reader.readAsText(file);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Like _getString, but returns an ArrayBuffer object.
*/
- ////////////////////////////////////////////////////////////////////////////
this._getArrayBuffer = function (file, done, progress) {
var reader = newFileReader(done, progress);
reader.readAsText(file);
@@ -47872,7 +47293,6 @@ return /******/ (function(modules) { // webpackBootstrap
var inherit = __webpack_require__(8);
var feature = __webpack_require__(207);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class graphFeature
*
@@ -47880,7 +47300,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.feature
* @returns {geo.graphFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var graphFeature = function (arg) {
'use strict';
@@ -47894,11 +47313,9 @@ return /******/ (function(modules) { // webpackBootstrap
var util = __webpack_require__(83);
var registry = __webpack_require__(201);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_draw = this.draw,
s_style = this.style,
@@ -47909,11 +47326,9 @@ return /******/ (function(modules) { // webpackBootstrap
s_init = this._init,
s_exit = this._exit;
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
s_init.call(m_this, arg);
@@ -47937,33 +47352,27 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.nodes(function (d) { return d; });
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Call child _build methods
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
m_this.children().forEach(function (child) {
child._build();
});
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Call child _update methods
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
m_this.children().forEach(function (child) {
child._update();
});
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Custom _exit method to remove all sub-features
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_this.data([]);
m_links.forEach(function (link) {
@@ -47977,11 +47386,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set style
*/
- ////////////////////////////////////////////////////////////////////////////
this.style = function (arg, arg2) {
var out = s_style.call(m_this, arg, arg2);
if (out !== m_this) {
@@ -47995,11 +47402,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set links accessor.
*/
- ////////////////////////////////////////////////////////////////////////////
this.links = function (arg) {
if (arg === undefined) {
return m_children;
@@ -48009,11 +47414,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set nodes
*/
- ////////////////////////////////////////////////////////////////////////////
this.nodes = function (val) {
if (val === undefined) {
return m_nodes;
@@ -48023,29 +47426,23 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get internal node feature
*/
- ////////////////////////////////////////////////////////////////////////////
this.nodeFeature = function () {
return m_points;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get internal link features
*/
- ////////////////////////////////////////////////////////////////////////////
this.linkFeatures = function () {
return m_links;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build the feature for drawing
*/
- ////////////////////////////////////////////////////////////////////////////
this.draw = function () {
var layer = m_this.layer(),
@@ -48113,7 +47510,6 @@ return /******/ (function(modules) { // webpackBootstrap
var feature = __webpack_require__(207);
var transform = __webpack_require__(11);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class heatmapFeature
*
@@ -48154,9 +47550,7 @@ return /******/ (function(modules) { // webpackBootstrap
* gaussian distribution.
* @returns {geo.heatmapFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
- //////////////////////////////////////////////////////////////////////////////
var heatmapFeature = function (arg) {
'use strict';
if (!(this instanceof heatmapFeature)) {
@@ -48165,11 +47559,9 @@ return /******/ (function(modules) { // webpackBootstrap
arg = arg || {};
feature.call(this, arg);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
m_position,
m_intensity,
@@ -48187,13 +47579,11 @@ return /******/ (function(modules) { // webpackBootstrap
m_binned = arg.binned !== undefined ? arg.binned : 'auto';
m_updateDelay = arg.updateDelay ? parseInt(arg.updateDelay, 10) : 1000;
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set maxIntensity
*
* @returns {geo.heatmap}
*/
- ////////////////////////////////////////////////////////////////////////////
this.maxIntensity = function (val) {
if (val === undefined) {
return m_maxIntensity;
@@ -48205,13 +47595,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set maxIntensity
*
* @returns {geo.heatmap}
*/
- ////////////////////////////////////////////////////////////////////////////
this.minIntensity = function (val) {
if (val === undefined) {
return m_minIntensity;
@@ -48223,13 +47611,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set updateDelay
*
* @returns {geo.heatmap}
*/
- ////////////////////////////////////////////////////////////////////////////
this.updateDelay = function (val) {
if (val === undefined) {
return m_updateDelay;
@@ -48239,13 +47625,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set binned
*
* @returns {geo.heatmap}
*/
- ////////////////////////////////////////////////////////////////////////////
this.binned = function (val) {
if (val === undefined) {
return m_binned;
@@ -48267,13 +47651,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set position accessor
*
* @returns {geo.heatmap}
*/
- ////////////////////////////////////////////////////////////////////////////
this.position = function (val) {
if (val === undefined) {
return m_position;
@@ -48285,25 +47667,21 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get pre-computed gcs position accessor
*
* @returns {geo.heatmap}
*/
- ////////////////////////////////////////////////////////////////////////////
this.gcsPosition = function () {
this._update();
return m_gcsPosition;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set intensity
*
* @returns {geo.heatmap}
*/
- ////////////////////////////////////////////////////////////////////////////
this.intensity = function (val) {
if (val === undefined) {
return m_intensity;
@@ -48315,11 +47693,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
s_init.call(m_this, arg);
@@ -48345,12 +47721,10 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
var data = m_this.data(),
intensity = null,
@@ -48405,7 +47779,6 @@ return /******/ (function(modules) { // webpackBootstrap
module.exports = (function () {
'use strict';
- //////////////////////////////////////////////////////////////////////////////
/**
* This class defines a tile that is part of a standard "image pyramid", such
* as an open street map tile set. Every tile is uniquely indexed by a row,
@@ -48435,7 +47808,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {number} [spec.overlap.x=0]
* @param {number} [spec.overlap.y=0]
*/
- //////////////////////////////////////////////////////////////////////////////
var imageTile = function (spec) {
if (!(this instanceof imageTile)) {
return new imageTile(spec);
@@ -48523,7 +47895,6 @@ return /******/ (function(modules) { // webpackBootstrap
var $ = __webpack_require__(1);
- //////////////////////////////////////////////////////////////////////////////
/**
* This class defines the raw interface for a "tile" on a map. A tile is
* defined as a rectangular section of a map. The base implementation
@@ -48550,7 +47921,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {Number} [spec.overlap.x=0]
* @param {Number} [spec.overlap.y=0]
*/
- //////////////////////////////////////////////////////////////////////////////
var tile = function (spec) {
if (!(this instanceof tile)) {
return new tile(spec);
@@ -48751,7 +48121,6 @@ return /******/ (function(modules) { // webpackBootstrap
var registerFileReader = __webpack_require__(201).registerFileReader;
var fileReader = __webpack_require__(229);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class jsonReader
*
@@ -48759,7 +48128,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.fileReader
* @returns {geo.jsonReader}
*/
- //////////////////////////////////////////////////////////////////////////////
var jsonReader = function (arg) {
'use strict';
if (!(this instanceof jsonReader)) {
@@ -49062,74 +48430,68 @@ return /******/ (function(modules) { // webpackBootstrap
var inherit = __webpack_require__(8);
var sceneObject = __webpack_require__(208);
- //////////////////////////////////////////////////////////////////////////////
/**
* Creates a new map object
*
- * Map coordinates for default world map, where c = half circumference at
- * equator in meters, o = origin:
- * (-c, c) + o (c, c) + o
- * (center.x, center.y) + o <-- center of viewport
- * (-c, -c) + o (c, -c) + o
- *
* @class
* @alias geo.map
* @extends geo.sceneObject
*
- * *** Always required ***
- * @param {string} node DOM selector for the map container
- *
- * *** Required when using a domain/CS different from OSM ***
- * @param {string|geo.transform} [gcs='EPSG:3857']
- * The main coordinate system of the map
- * @param {number} [maxZoom=16] The maximum zoom level
- * @param {string|geo.transform} [ingcs='EPSG:4326']
- * The default coordinate system of interface calls.
- * @param {number} [unitsPerPixel=156543] GCS to pixel unit scaling at zoom 0
- * (i.e. meters per pixel or degrees per pixel).
- * @param {object?} maxBounds The maximum visable map bounds
- * @param {number} [maxBounds.left=-20037508] The left bound
- * @param {number} [maxBounds.right=20037508] The right bound
- * @param {number} [maxBounds.bottom=-20037508] The bottom bound
- * @param {number} [maxBounds.top=20037508] The top bound
- *
- * *** Initial view ***
- * @param {number} [zoom=4] Initial zoom
- * @param {object?} center Map center
- * @param {number} [center.x=0]
- * @param {number} [center.y=0]
- * @param {number} [rotation=0] Clockwise rotation in radians
- * @param {number?} width The map width (default node width)
- * @param {number?} height The map height (default node height)
- *
- * *** Navigation ***
- * @param {number} [min=0] Minimum zoom level (though fitting to the viewport
- * may make it so this is smaller than the smallest possible value)
- * @param {number} [max=16] Maximum zoom level
- * @param {boolean} [discreteZoom=false] True to only allow integer zoom
- * levels. False for any zoom level.
- * @param {boolean} [allowRotation=true] False prevents rotation, true allows
- * any rotation. If a function, the function is called with a rotation
- * (angle in radians) and returns a valid rotation (this can be used to
- * constrain the rotation to a range or specific values).
- *
- * *** Advanced parameters ***
- * @param {geo.camera?} camera The camera to control the view
- * @param {geo.mapInteractor?} interactor The UI event handler
- * @param {array} [animationQueue] An array used to synchonize animations. If
- * specified, this should be an empty array or the same array as passed to
+ * @param {object} arg Options object
+ *
+ * @param {string} arg.node DOM selector for the map container.
+ * *** Always required ***
+ *
+ * @param {string|geo.transform} [arg.gcs='EPSG:3857']
+ * The main coordinate system of the map (this is often web Mercator).
+ * * Required when using a domain/CS different from OSM *
+ * @param {string|geo.transform} [arg.ingcs='EPSG:4326']
+ * The default coordinate system of interface calls (this is often latitude
+ * and longitude).
+ * @param {number} [arg.unitsPerPixel=156543] GCS to pixel unit scaling at zoom
+ * 0 (i.e. meters per pixel or degrees per pixel).
+ * @param {object?} [arg.maxBounds] The maximum visible map bounds.
+ * @param {number} [arg.maxBounds.left=-20037508] The left bound.
+ * @param {number} [arg.maxBounds.right=20037508] The right bound.
+ * @param {number} [arg.maxBounds.bottom=-20037508] The bottom bound.
+ * @param {number} [arg.maxBounds.top=20037508] The top bound.
+ *
+ * @param {number} [arg.zoom=4] Initial zoom.
+ * @param {object?} [arg.center] Initial map center.
+ * @param {number} arg.center.x=0
+ * @param {number} arg.center.y=0
+ * @param {number} [arg.rotation=0] Initial clockwise rotation in radians.
+ * @param {number?} [arg.width] The map width (default node width).
+ * @param {number?} [arg.height] The map height (default node height).
+ *
+ * @param {number} [arg.min=0] Minimum zoom level (though fitting to the
+ * viewport may make it so this is smaller than the smallest possible value).
+ * @param {number} [arg.max=16] Maximum zoom level.
+ * @param {boolean} [arg.discreteZoom=false] If `true`, only allow integer zoom
+ * levels. `false` for any zoom level.
+ * @param {boolean|function} [arg.allowRotation=true] `false` prevents
+ * rotation, `true` allows any rotation. If a function, the function is
+ * called with a rotation (angle in radians) and returns a valid rotation
+ * (this can be used to constrain the rotation to a range or specific to
+ * values).
+ *
+ * @param {geo.camera?} [arg.camera] The camera to control the view.
+ * @param {geo.mapInteractor?} [arg.interactor] The UI event handler. If
+ * `undefined`, a default interactor is created and used. If `null`, no
+ * interactor is attached to the map.
+ * @param {array} [arg.animationQueue] An array used to synchronize animations.
+ * If specified, this should be an empty array or the same array as passed to
* other map instances.
- * @param {boolean} [autoResize=true] Adjust map size on window resize
- * @param {boolean} [clampBoundsX=false] Prevent panning outside of the
+ * @param {boolean} [arg.autoResize=true] Adjust map size on window resize.
+ * @param {boolean} [arg.clampBoundsX=false] Prevent panning outside of the
* maximum bounds in the horizontal direction.
- * @param {boolean} [clampBoundsY=true] Prevent panning outside of the
+ * @param {boolean} [arg.clampBoundsY=true] Prevent panning outside of the
* maximum bounds in the vertical direction.
- * @param {boolean} [clampZoom=true] Prevent zooming out so that the map area
- * is smaller than the window.
+ * @param {boolean} [arg.clampZoom=true] Prevent zooming out so that the map
+ * area is smaller than the window.
*
* @returns {geo.map}
*/
- //////////////////////////////////////////////////////////////////////////////
var map = function (arg) {
'use strict';
if (!(this instanceof map)) {
@@ -49152,18 +48514,14 @@ return /******/ (function(modules) { // webpackBootstrap
var mapInteractor = __webpack_require__(221);
var uiLayer = __webpack_require__(236);
- ////////////////////////////////////////////////////////////////////////////
/**
* Private member variables
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_exit = this._exit,
// See https://en.wikipedia.org/wiki/Web_Mercator
// phiMax = 180 / Math.PI * (2 * Math.atan(Math.exp(Math.PI)) - Math.PI / 2),
- m_x = 0,
- m_y = 0,
m_node = $(arg.node),
m_width = arg.width || m_node.width() || 512,
m_height = arg.height || m_node.height() || 512,
@@ -49188,8 +48546,8 @@ return /******/ (function(modules) { // webpackBootstrap
m_clampBoundsY,
m_clampZoom,
m_animationQueue = arg.animationQueue || [],
- m_origin,
- m_scale = {x: 1, y: 1, z: 1}; // constant and ignored for the moment
+ m_autoResize = arg.autoResize === undefined ? true : arg.autoResize,
+ m_origin;
/* Compute the maximum bounds on our map projection. By default, x ranges
* from [-180, 180] in the interface projection, and y matches the x range in
@@ -49213,26 +48571,25 @@ return /******/ (function(modules) { // webpackBootstrap
m_maxBounds.right - m_maxBounds.left) / 256);
m_camera.viewport = {
- width: m_width, height: m_height,
- left: m_node.offset().left, top: m_node.offset().top
+ width: m_width,
+ height: m_height,
+ left: m_node.offset().left,
+ top: m_node.offset().top
};
arg.center = util.normalizeCoordinates(arg.center);
- arg.autoResize = arg.autoResize === undefined ? true : arg.autoResize;
m_clampBoundsX = arg.clampBoundsX === undefined ? false : arg.clampBoundsX;
m_clampBoundsY = arg.clampBoundsY === undefined ? true : arg.clampBoundsY;
m_clampZoom = arg.clampZoom === undefined ? true : arg.clampZoom;
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/set the number of world space units per display pixel at the given
* zoom level.
*
- * @param {Number} [zoom=0] The target zoom level
- * @param {Number?} unit If present, set the unitsPerPixel otherwise return
- * the current value.
- * @returns {Number|this}
+ * @param {number} [zoom=0] The target zoom level.
+ * @param {number?} [unit] If present, set the `unitsPerPixel` at the
+ * specified zoom level. Otherwise return the current value.
+ * @returns {number|this}
*/
- ////////////////////////////////////////////////////////////////////////////
this.unitsPerPixel = function (zoom, unit) {
zoom = zoom || 0;
if (unit) {
@@ -49246,15 +48603,65 @@ return /******/ (function(modules) { // webpackBootstrap
return Math.pow(2, -zoom) * m_unitsPerPixel;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get/set the clampBoundsX setting. If changed, adjust the bounds of the
+ * Get/set the animation queue. Two maps can share a single animation queue
+ * to ensure synchronized animations. When setting, the animation queue will
+ * merge values from the existing queue into the new queue.
+ *
+ * @param {array} [queue] The animation queue to use.
+ * @returns {array|this} The current animation queue or the current map.
+ */
+ this.animationQueue = function (queue) {
+ if (queue === undefined) {
+ return m_animationQueue;
+ }
+ if (queue !== m_animationQueue) {
+ if (m_animationQueue.length) {
+ /* If the specified queue already has data in, don't copy the 0th
+ * element of the existing queue, since the 0th element is always the
+ * actual requestAnimationFrame reference. In this case, cancel the
+ * existing requestAnimationFrame. By using a property of window,
+ * tests can override this if needed. */
+ if (queue.length && queue[0] !== m_animationQueue[0]) {
+ window['cancelAnimationFrame'](m_animationQueue[0]);
+ }
+ for (var i = queue.length ? 1 : 0; i < m_animationQueue.length; i += 1) {
+ queue.push(m_animationQueue[i]);
+ }
+ }
+ m_animationQueue = queue;
+ }
+ return this;
+ };
+
+ /**
+ * Get/set the autoResize flag.
+ *
+ * @param {boolean} [autoResize] Truthy to automaticaly resize the map when
+ * the size of the browser window changes.
+ * @returns {boolean|this} The current state of autoResize or the current map.
+ */
+ this.autoResize = function (autoResize) {
+ if (autoResize === undefined) {
+ return m_autoResize;
+ }
+ if (autoResize !== m_autoResize) {
+ $(window).off('resize', resizeSelf);
+ m_autoResize = autoResize;
+ if (m_autoResize) {
+ $(window).on('resize', resizeSelf);
+ }
+ }
+ return this;
+ };
+
+ /**
+ * Get/set the `clampBoundsX` setting. If changed, adjust the bounds of the
* map as needed.
*
- * @param {boolean?} clamp The new clamp value.
+ * @param {boolean} [clamp] The new clamp value.
* @returns {boolean|this}
*/
- ////////////////////////////////////////////////////////////////////////////
this.clampBoundsX = function (clamp) {
if (clamp === undefined) {
return m_clampBoundsX;
@@ -49266,15 +48673,13 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get/set the clampBoundsY setting. If changed, adjust the bounds of the
+ * Get/set the `clampBoundsY` setting. If changed, adjust the bounds of the
* map as needed.
*
- * @param {boolean?} clamp The new clamp value.
+ * @param {boolean} [clamp] The new clamp value.
* @returns {boolean|this}
*/
- ////////////////////////////////////////////////////////////////////////////
this.clampBoundsY = function (clamp) {
if (clamp === undefined) {
return m_clampBoundsY;
@@ -49286,15 +48691,13 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get/set the clampZoom setting. If changed, adjust the bounds of the map
+ * Get/set the `clampZoom` setting. If changed, adjust the bounds of the map
* as needed.
*
- * @param {boolean?} clamp The new clamp value.
+ * @param {boolean} [clamp] The new clamp value.
* @returns {boolean|this}
*/
- ////////////////////////////////////////////////////////////////////////////
this.clampZoom = function (clamp) {
if (clamp === undefined) {
return m_clampZoom;
@@ -49307,14 +48710,17 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get/set the allowRotation setting. If changed, adjust the map as needed.
+ * Get/set the `allowRotation` setting. If changed, adjust the map as
+ * needed.
*
- * @param {boolean|function} allowRotation the new allowRotation value.
+ * @param {boolean|function} [allowRotation] The new `allowRotation` value.
+ * `false` prevents rotation, `true` allows any rotation. If a function,
+ * the function is called with a rotation (angle in radians) and returns a
+ * valid rotation (this can be used to constrain the rotation to a range
+ * or to specific values).
* @returns {boolean|function|this}
*/
- ////////////////////////////////////////////////////////////////////////////
this.allowRotation = function (allowRotation) {
if (allowRotation === undefined) {
return m_allowRotation;
@@ -49329,46 +48735,29 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get the map's world coordinate origin in gcs coordinates
+ * Get the map's world coordinate origin in gcs coordinates.
*
- * @returns {object}
+ * @returns {geo.geoPosition}
*/
- ////////////////////////////////////////////////////////////////////////////
this.origin = function () {
return $.extend({}, m_origin);
};
- ////////////////////////////////////////////////////////////////////////////
- /**
- * Get the map's world coordinate scaling relative gcs units
- *
- * @returns {object}
- */
- ////////////////////////////////////////////////////////////////////////////
- this.scale = function () {
- return $.extend({}, m_scale);
- };
-
- ////////////////////////////////////////////////////////////////////////////
/**
* Get the camera
*
* @returns {geo.camera}
*/
- ////////////////////////////////////////////////////////////////////////////
this.camera = function () {
return m_camera;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get map gcs
+ * Get map gcs. This is the coordinate system used in drawing the map.
*
- * @returns {string}
+ * @returns {string} A string used by {@linkcode geo.transform}.
*/
- ////////////////////////////////////////////////////////////////////////////
this.gcs = function (arg) {
if (arg === undefined) {
return m_gcs;
@@ -49386,13 +48775,12 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get map interface gcs
+ * Get map interface gcs. This is the coordinate system used when getting or
+ * setting map bounds, center, and other values.
*
- * @returns {string}
+ * @returns {string} A string used by {@linkcode geo.transform}.
*/
- ////////////////////////////////////////////////////////////////////////////
this.ingcs = function (arg) {
if (arg === undefined) {
return m_ingcs;
@@ -49401,31 +48789,32 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get root node of the map
+ * Get root DOM node of the map.
*
* @returns {object}
*/
- ////////////////////////////////////////////////////////////////////////////
this.node = function () {
return m_node;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get/Set zoom level of the map
+ * Get/Set zoom level of the map.
*
- * @param {number} val if undefined, return the current zoom level.
+ * @param {number} [val] If `undefined`, return the current zoom level.
* Otherwise, the new zoom level to set.
- * @param {object} origin if present, an object with 'geo' containing the
- * gcs coordinates where the action started and 'map' containing the
- * display coordinates of the same location before the zoom is applied.
- * @param {boolean} ignoreDiscreteZoom if true, ignore the discreteZoom
+ * @param {object} [origin] If present, specifies the center of the zoom;
+ * otherwise the map's display center is used.
+ * @param {geo.geoPosition} origin.geo The gcs coordinates of the zoom
+ * center.
+ * @param {geo.screenPosition} origin.map The display coordinates of the zoom
+ * center.
+ * @param {boolean} [ignoreDiscreteZoom] If `true`, ignore the discreteZoom
* option when determining the new view.
- * @returns {Number|geo.map}
+ * @returns {number|this}
+ * @fires geo.event.zoom
+ * @fires geo.event.pan
*/
- ////////////////////////////////////////////////////////////////////////////
this.zoom = function (val, origin, ignoreDiscreteZoom) {
if (val === undefined) {
return m_zoom;
@@ -49450,7 +48839,6 @@ return /******/ (function(modules) { // webpackBootstrap
camera_bounds(bounds, m_rotation);
evt = {
- geo: {},
zoomLevel: m_zoom,
screenPosition: origin ? origin.map : undefined
};
@@ -49467,23 +48855,24 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Pan the map by (x: dx, y: dy) pixels.
+ * Pan the map by a number of display pixels.
*
- * @param {Object} delta x and y delta in display pixels
- * @param {boolean} ignoreDiscreteZoom if true, ignore the discreteZoom
+ * @param {object} delta Amount to pan in display pixels.
+ * @param {number} delta.x Horizontal distance on the display.
+ * @param {number} delta.y Vertical distance on the display.
+ * @param {boolean} [ignoreDiscreteZoom] If `true`, ignore the `discreteZoom`
* option when determining the new view.
- * @param {boolean} ignoreClampBounds if true or 'limited', ignore the
- * clampBoundsX options (up to a point, see fix_bounds) when determining
- * the new view.
- * @returns {geo.map}
- * @fires geo.event.event:pan
+ * @param {boolean|'limited'} [ignoreClampBounds] If `true` ignore the
+ * `clampBoundsX` and `clampBoundsY` options when determining the new
+ * view. When `'limited'`, the `clampBoundsX` and `clampBoundsY` options
+ * are selectively enforced so that the map will not end up more out of
+ * bounds than its current state.
+ * @returns {this}
+ * @fires geo.event.pan
*/
- ////////////////////////////////////////////////////////////////////////////
this.pan = function (delta, ignoreDiscreteZoom, ignoreClampBounds) {
var evt = {
- geo: {},
screenDelta: delta
};
@@ -49496,7 +48885,7 @@ return /******/ (function(modules) { // webpackBootstrap
y: (delta.x * sinr + (-delta.y) * cosr) * unit
});
}
- /* If m_clampBounds* is true, clamp the pan */
+ /* If m_clampBoundsX or m_clampBoundsY is true, clamp the pan */
var bounds = m_camera.bounds;
bounds = fix_bounds(bounds, m_rotation, ignoreClampBounds === 'limited' ? {
x: delta.x, y: delta.y, unit: unit} : undefined,
@@ -49526,18 +48915,24 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/set the map rotation. The rotation is performed around the current
- * view center. Rotation mostly ignores clampBoundsX, as the behavior
+ * view center. Rotation mostly ignores `clampBoundsX`, as the behavior
* feels peculiar otherwise.
*
- * @param {Object} rotation angle in radians (positive is clockwise)
- * @param {Object} origin is specified, rotate about this origin
- * @param {boolean} ignoreRotationFunc if true, don't constrain the rotation.
- * @returns {geo.map}
+ * @param {number} rotation Absolute angle in radians (positive is
+ * clockwise).
+ * @param {object} [origin] If specified, rotate about this origin.
+ * @param {geo.geoPosition} origin.geo The gcs coordinates of the
+ * rotation center.
+ * @param {geo.screenPosition} origin.map The display coordinates of the
+ * rotation center.
+ * @param {boolean} [ignoreRotationFunc] If `true`, don't constrain the
+ * rotation.
+ * @returns {number|this}
+ * @fires geo.event.rotate
+ * @fires geo.event.pan
*/
- ////////////////////////////////////////////////////////////////////////////
this.rotation = function (rotation, origin, ignoreRotationFunc) {
if (rotation === undefined) {
return m_rotation;
@@ -49557,7 +48952,6 @@ return /******/ (function(modules) { // webpackBootstrap
camera_bounds(bounds, m_rotation);
var evt = {
- geo: {},
rotation: m_rotation,
screenPosition: origin ? origin.map : undefined
};
@@ -49577,24 +48971,26 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Set center of the map to the given geographic coordinates, or get the
* current center. Uses bare objects {x: 0, y: 0}.
*
- * @param {Object} coordinates
- * @param {string|geo.transform} [gcs] undefined to use the interface gcs,
- * null to use the map gcs, or any other transform. If setting the
- * center, they are converted from this gcs to the map projection. The
- * returned center are converted from the map projection to this gcs.
- * @param {boolean} ignoreDiscreteZoom if true, ignore the discreteZoom
+ * @param {geo.geoPosition} coordinates If specified, the new center of the
+ * map.
+ * @param {string|geo.transform|null} [gcs] `undefined` to use the interface
+ * gcs, `null` to use the map gcs, or any other transform. If setting the
+ * center, it is converted from this gcs to the map projection. The
+ * returned center is converted from the map projection to this gcs.
+ * @param {boolean} [ignoreDiscreteZoom] If `true`, ignore the `discreteZoom`
* option when determining the new view.
- * @param {boolean} ignoreClampBounds if true or 'limited', ignore the
- * clampBoundsX options (up to a point, see fix_bounds) when determining
- * the new view.
- * @returns {Object|geo.map}
+ * @param {boolean|'limited'} [ignoreClampBounds] If `true` ignore the
+ * `clampBoundsX` and `clampBoundsY` options when determining the new
+ * view. When `'limited'`, the `clampBoundsX` and `clampBoundsY` options
+ * are selectively enforced so that the map will not end up more out of
+ * bounds than its current state.
+ * @returns {geo.geoPosition|this}
+ * @fires geo.event.pan
*/
- ////////////////////////////////////////////////////////////////////////////
this.center = function (coordinates, gcs, ignoreDiscreteZoom,
ignoreClampBounds) {
var center;
@@ -49612,20 +49008,19 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.modified();
// trigger a pan event
m_this.geoTrigger(geo_event.pan, {
- geo: coordinates,
- screenDelta: null
+ screenDelta: {x: 0, y: 0}
});
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Add layer to the map
+ * Add a layer to the map.
*
- * @param {geo.layer} layer to be added to the map
- * @return {geom.map}
+ * @param {string} layerName The type of layer to add to the map.
+ * @param {object} arg Parameters for the new layer.
+ * @return {geo.layer}
+ * @fires geo.event.layerAdd
*/
- ////////////////////////////////////////////////////////////////////////////
this.createLayer = function (layerName, arg) {
arg = arg || {};
var newLayer = registry.createLayer(
@@ -49642,7 +49037,6 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.modified();
m_this.geoTrigger(geo_event.layerAdd, {
- type: geo_event.layerAdd,
target: m_this,
layer: newLayer
});
@@ -49651,14 +49045,13 @@ return /******/ (function(modules) { // webpackBootstrap
return newLayer;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Remove layer from the map
+ * Remove a layer from the map.
*
- * @param {geo.layer} layer that should be removed from the map
- * @return {geo.map}
+ * @param {geo.layer?} layer Layer to remove from the map.
+ * @return {geo.layer}
+ * @fires geo.event.layerRemove
*/
- ////////////////////////////////////////////////////////////////////////////
this.deleteLayer = function (layer) {
if (layer !== null && layer !== undefined) {
@@ -49668,28 +49061,23 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.modified();
m_this.geoTrigger(geo_event.layerRemove, {
- type: geo_event.layerRemove,
target: m_this,
layer: layer
});
}
- /// Return deleted layer (similar to createLayer) as in the future
- /// we may provide extension of this method to support deletion of
- /// layer using id or some sort.
+ // Return deleted layer (similar to createLayer) as in the future
+ // we may provide extension of this method to support deletion of
+ // layer using id or some sort.
return layer;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get or set the size of the map.
*
- * @param {Object?} arg
- * @param {Number} arg.width width in pixels
- * @param {Number} arg.height height in pixels
- * @returns {Object} An object containing width and height as keys
+ * @param {geo.screenSize} [arg] Size in pixels.
+ * @returns {geo.screenSize|this} The size in pixels or the map object.
*/
- ////////////////////////////////////////////////////////////////////////////
this.size = function (arg) {
if (arg === undefined) {
return {
@@ -49697,51 +49085,10 @@ return /******/ (function(modules) { // webpackBootstrap
height: m_height
};
}
- m_this.resize(0, 0, arg.width, arg.height);
- return m_this;
- };
-
- ////////////////////////////////////////////////////////////////////////////
- /**
- * Get the rotated size of the map. This is the width and height of the
- * non-rotated area necessary to enclose the rotated area in pixels.
- *
- * @returns {Object} An object containing width and height as keys
- */
- ////////////////////////////////////////////////////////////////////////////
- this.rotatedSize = function () {
- if (!this.rotation()) {
- return {
- width: m_width,
- height: m_height
- };
- }
- var bds = rotate_bounds_center(
- {x: 0, y: 0}, {width: m_width, height: m_height}, this.rotation());
- return {
- width: Math.abs(bds.right - bds.left),
- height: Math.abs(bds.top - bds.bottom)
- };
- };
-
- ////////////////////////////////////////////////////////////////////////////
- /**
- * Resize map (deprecated)
- *
- * @param {Number} x x-offset in display space
- * @param {Number} y y-offset in display space
- * @param {Number} w width in display space
- * @param {Number} h height in display space
- */
- ////////////////////////////////////////////////////////////////////////////
- this.resize = function (x, y, w, h) {
-
// store the original center and restore it after the resize
var oldCenter = m_this.center();
- m_x = x;
- m_y = y;
- m_width = w || m_width;
- m_height = h || m_height;
+ m_width = arg.width || m_width;
+ m_height = arg.height || m_height;
reset_minimum_zoom();
var newZoom = fix_zoom(m_zoom);
@@ -49749,16 +49096,16 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.zoom(newZoom);
}
m_this.camera().viewport = {
- width: m_width, height: m_height,
- left: m_node.offset().left, top: m_node.offset().top
+ width: m_width,
+ height: m_height,
+ left: m_node.offset().left,
+ top: m_node.offset().top
};
m_this.center(oldCenter);
m_this.geoTrigger(geo_event.resize, {
type: geo_event.resize,
target: m_this,
- x: m_x,
- y: m_y,
width: m_width,
height: m_height
});
@@ -49767,17 +49114,35 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
+ /**
+ * Get the rotated size of the map. This is the width and height of the
+ * non-rotated area necessary to enclose the rotated area in pixels.
+ *
+ * @returns {geo.screenSize} The size that fits the rotated map.
+ */
+ this.rotatedSize = function () {
+ if (!this.rotation()) {
+ return {
+ width: m_width,
+ height: m_height
+ };
+ }
+ var bds = rotate_bounds_center(
+ {x: 0, y: 0}, {width: m_width, height: m_height}, this.rotation());
+ return {
+ width: Math.abs(bds.right - bds.left),
+ height: Math.abs(bds.top - bds.bottom)
+ };
+ };
+
/**
* Convert from gcs coordinates to map world coordinates.
- * @param {object} c The input coordinate to convert
- * @param {object} c.x
- * @param {object} c.y
- * @param {object} [c.z=0]
- * @param {string?} gcs The gcs of the input (map.gcs() by default)
- * @return {object} World space coordinates
+ *
+ * @param {geo.geoPosition} c The input coordinate to convert.
+ * @param {string|geo.transform|null} [gcs] Input gcs. `undefined` to use
+ * the interface gcs, `null` to use the map gcs, or any other transform.
+ * @return {geo.worldPosition} World space coordinates.
*/
- ////////////////////////////////////////////////////////////////////////////
this.gcsToWorld = function (c, gcs) {
gcs = (gcs === null ? m_gcs : (gcs === undefined ? m_ingcs : gcs));
if (gcs !== m_gcs) {
@@ -49794,18 +49159,14 @@ return /******/ (function(modules) { // webpackBootstrap
return c;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Convert from map world coordinates to gcs coordinates.
- * @param {object} c The input coordinate to convert
- * @param {object} c.x
- * @param {object} c.y
- * @param {object} [c.z=0]
- * @param {string|geo.transform} [gcs] undefined to use the interface gcs,
- * null to use the map gcs, or any other transform.
- * @return {object} GCS space coordinates
+ *
+ * @param {geo.worldPosition} c The input coordinate to convert.
+ * @param {string|geo.transform|null} [gcs] output gcs. `undefined` to use
+ * the interface gcs, `null` to use the map gcs, or any other transform.
+ * @return {geo.geoPosition} GCS space coordinates.
*/
- ////////////////////////////////////////////////////////////////////////////
this.worldToGcs = function (c, gcs) {
if (m_origin.x || m_origin.y || m_origin.z) {
c = transform.affineInverse(
@@ -49822,86 +49183,66 @@ return /******/ (function(modules) { // webpackBootstrap
return c;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Convert from gcs coordinates to display coordinates.
- *
- * gcsToWorld | worldToDisplay
+ * Convert from gcs coordinates to display coordinates. This is identical to
+ * calling `gcsToWorld` and then `worldToDisplay`.
*
- * @param {object} c The input coordinate to convert
- * @param {object} c.x
- * @param {object} c.y
- * @param {object} [c.z=0]
- * @param {string|geo.transform} [gcs] undefined to use the interface gcs,
- * null to use the map gcs, or any other transform.
- * @return {object} Display space coordinates
+ * @param {geo.geoPosition} c The input coordinate to convert.
+ * @param {string|geo.transform|null} [gcs] Input gcs. `undefined` to use
+ * the interface gcs, `null` to use the map gcs, or any other transform.
+ * @return {geo.screenPosition} Display space coordinates.
*/
- ////////////////////////////////////////////////////////////////////////////
this.gcsToDisplay = function (c, gcs) {
c = m_this.gcsToWorld(c, gcs);
return m_this.worldToDisplay(c);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Convert from world coordinates to display coordinates using the attached
* camera.
- * @param {object} c The input coordinate to convert
- * @param {object} c.x
- * @param {object} c.y
- * @param {object} [c.z=0]
- * @return {object} Display space coordinates
+ *
+ * @param {geo.worldPosition} c The input coordinate to convert.
+ * @return {geo.screenPosition} Display space coordinates.
*/
- ////////////////////////////////////////////////////////////////////////////
this.worldToDisplay = function (c) {
return m_camera.worldToDisplay(c);
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Convert from display to gcs coordinates
- *
- * displayToWorld | worldToGcs
+ * Convert from display to gcs coordinates. This is identical to calling
+ * `displayToWorld` and then `worldToGcs`.
*
- * @param {object} c The input display coordinate to convert
- * @param {object} c.x
- * @param {object} c.y
- * @param {object} [c.z=0]
- * @param {string|geo.transform} [gcs] undefined to use the interface gcs,
- * null to use the map gcs, or any other transform.
- * @return {object} GCS space coordinates
+ * @param {geo.screenPosition} c The input display coordinate to convert.
+ * @param {string|geo.transform|null} [gcs] Output gcs. `undefined` to use
+ * the interface gcs, `null` to use the map gcs, or any other transform.
+ * @return {geo.geoPosition} GCS space coordinates.
*/
- ////////////////////////////////////////////////////////////////////////////
this.displayToGcs = function (c, gcs) {
c = m_this.displayToWorld(c); // done via camera
return m_this.worldToGcs(c, gcs);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Convert from display coordinates to world coordinates using the attached
* camera.
- * @param {object} c The input coordinate to convert
- * @param {object} c.x
- * @param {object} c.y
- * @param {object} [c.z=0]
- * @return {object} World space coordinates
+ *
+ * @param {geo.screenPosition} c The input coordinate to convert.
+ * @return {geo.worldPosition} World space coordinates.
*/
- ////////////////////////////////////////////////////////////////////////////
this.displayToWorld = function (c) {
return m_camera.displayToWorld(c);
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Manually force to render map
+ * Redraw the map and all its layers.
+ *
+ * @fires geo.event.draw
+ * @fires geo.event.drawEnd
*/
- ////////////////////////////////////////////////////////////////////////////
this.draw = function () {
var i, layers = m_this.children();
m_this.geoTrigger(geo_event.draw, {
- type: geo_event.draw,
target: m_this
});
@@ -49912,26 +49253,24 @@ return /******/ (function(modules) { // webpackBootstrap
}
m_this.geoTrigger(geo_event.drawEnd, {
- type: geo_event.drawEnd,
target: m_this
});
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get, set, or create and set a file reader to a layer in the map to be used
* as a drop target.
*
- * @param {string|object|undefined} readerOrName: undefined to get the
- * current reader, an instance of a file reader to set the reader, or a
- * name to create a file reader (see utils.createFileReader for options).
- * @param {object} opts: options for creating a file reader. If this
- * includes layer, use that layer, otherwise create a layer using these
- * options.
+ * @param {string|object} [readerOrName] `undefined` to get the current
+ * reader, an instance of a file reader to set the reader, or a name to
+ * create a file reader.
+ * @param {object} [opts] options Parameters for creating a file reader when
+ * the reader is specified by name. If this includes `layer`, use that
+ * layer, otherwise create a layer using these options.
+ * @returns {geo.fileReader|this}
*/
- ////////////////////////////////////////////////////////////////////////////
this.fileReader = function (readerOrName, opts) {
if (readerOrName === undefined) {
return m_fileReader;
@@ -49949,11 +49288,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Initialize the map
+ * Initialize the map.
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function () {
if (m_node === undefined || m_node === null) {
@@ -49968,11 +49305,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Update map
+ * Update map. This updates all layers of the map.
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function (request) {
var i, layers = m_this.children();
for (i = 0; i < layers.length; i += 1) {
@@ -49981,11 +49316,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Exit this map
+ * Exit this map. This removes all layers, destroys current interactor, and
+ * empties the associated DOM node.
*/
- ////////////////////////////////////////////////////////////////////////////
this.exit = function () {
var i, layers = m_this.children();
for (i = layers.length - 1; i >= 0; i -= 1) {
@@ -50004,44 +49338,13 @@ return /******/ (function(modules) { // webpackBootstrap
s_exit();
};
- this._init(arg);
-
- // set up drag/drop handling
- this.node().on('dragover.geo', function (e) {
- var evt = e.originalEvent;
-
- if (m_this.fileReader()) {
- evt.stopPropagation();
- evt.preventDefault();
- evt.dataTransfer.dropEffect = 'copy';
- }
- })
- .on('drop.geo', function (e) {
- var evt = e.originalEvent, reader = m_this.fileReader(),
- i, file;
-
- function done() {
- m_this.draw();
- }
-
- if (reader) {
- evt.stopPropagation();
- evt.preventDefault();
-
- for (i = 0; i < evt.dataTransfer.files.length; i += 1) {
- file = evt.dataTransfer.files[i];
- if (reader.canRead(file)) {
- reader.read(file, done); // to do: trigger event on done
- }
- }
- }
- });
-
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get or set the map interactor
+ * Get or set the map interactor.
+ *
+ * @param {geo.mapInteractor} [arg] If specified, the map interactor to set.
+ * @returns {geo.mapInteractor|this} The current map interactor or the map
+ * object.
*/
- ////////////////////////////////////////////////////////////////////////////
this.interactor = function (arg) {
if (arg === undefined) {
return m_interactor;
@@ -50063,16 +49366,19 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get or set the min/max zoom range.
*
- * @param {Object} arg {min: minimumzoom, max: maximumzom}
- * @param {boolean} noRefresh if true, don't update the map if the zoom level
- * has changed.
- * @returns {Object|geo.map}
+ * @param {object} [arg] The zoom range.
+ * @param {number} [arg.min] The minimum zoom level.
+ * @param {number} [arg.max] The maximum zoom level.
+ * @param {boolean} [noRefresh] If `true`, don't update the map if the zoom
+ * level has changed.
+ * @returns {object|this} The current zoom range or the map object. The
+ * `min` value is the minimum value that the map can go to based on the
+ * current dimensions and settings, the `origMin` value is the value that
+ * was specified via this function or when the map was created.
*/
- ////////////////////////////////////////////////////////////////////////////
this.zoomRange = function (arg, noRefresh) {
if (arg === undefined) {
return $.extend({}, m_validZoomRange);
@@ -50090,36 +49396,49 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Start an animated zoom/pan/rotate. If a second transition is requested
- * while a transition is already in progress, a new transition is created
- * that is functionally from whereever the map has moved to (possibly partway
- * through the first transition) going to the end point of the new
- * transition.
- *
- * Options:
- *
- * opts = {
- * center: { x: ... , y: ... } // the new center
- * zoom: ... // the new zoom level
- * zoomOrigin: ... // an origin to use when zooming. Optional.
- * rotation: ... // the new rotation angle
- * duration: ... // the duration (in ms) of the transition
- * ease: ... // an easing function [0, 1] -> [0, 1]
- * }
- *
- *
- * Call with no arguments to return the current transition information.
- *
- * @param {object?} opts
- * @param {string|geo.transform} [gcs] undefined to use the interface gcs,
- * null to use the map gcs, or any other transform. Applies only to the
- * center coordinate of the opts and to converting zoom values to height,
+ * Get the current transition or start an animated zoom/pan/rotate. If a
+ * second transition is requested while a transition is already in progress,
+ * a new transition is created that is functionally from wherever the map has
+ * moved to (possibly partway through the first transition) going to the end
+ * point of the new transition.
+ *
+ * @param {object} [opts] Options for a transition, or `undefined` to get the
+ * current transition.
+ * @param {geo.geoPosition} [opts.center] A new map center.
+ * @param {number} [opts.zoom] A new map zoom level.
+ * @param {geo.geoPosition} [opts.zoomOrigin] An origin to use when zooming
+ * to a new zoom level.
+ * @param {number} [opts.rotation] A new map rotation.
+ * @param {number} [opts.duration=1000] Transition duration in milliseconds.
+ * @param {function} [opts.ease] Easing function for the transition. This is
+ * in the style of a d3 easing function.
+ * @param {function} [opts.interp] Function to use when interpolating
+ * between values. This gets passed two arrays, the start and end values
+ * for [`x`, `y`, `z` or `zoom`, `rotation`], and returns a function that,
+ * when passed a time value returns an array of the interpolated [`x`,
+ * `y`, `z` or `zoom`, `rotation`] values.
+ * @param {boolean} [opts.zCoord] If `true`, convert zoom values to z values
+ * for interpolation.
+ * @param {function} [opts.done] If specified, call this function when a
+ * transition completes. The function is called with an object that
+ * contains `cancel`: a boolean if the transition was canceled, `source`:
+ * a value based on what canceled a transition, `transition`: the current
+ * transition that just completed, `next`: a boolean if another transition
+ * follows immediately.
+ * @param {string|geo.transform|null} [gcs] Input gcs. `undefined` to use
+ * the interface gcs, `null` to use the map gcs, or any other transform.
+ * Applies only to `opts.center` and to converting zoom values to height,
* if specified.
+ * @param {number} [animTime] The animation frame time (from a
+ * `window.requestAnimationFrame` callback). Used if a new transition is
+ * requested because the current transition has completed to keep things
+ * synchronized.
* @returns {geo.map}
+ * @fires geo.event.transitionstart
+ * @fires geo.event.transitionend
+ * @fires geo.event.transitioncancel
*/
- ////////////////////////////////////////////////////////////////////////////
this.transition = function (opts, gcs, animTime) {
if (opts === undefined) {
@@ -50140,9 +49459,19 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
}
+ /* Basic linear interpolation between two values. */
function interp1(p0, p1, t) {
return p0 + (p1 - p0) * t;
}
+ /**
+ * Generate an interpolation function that interpolates all array entries.
+ *
+ * @param {array} p0 An array of numbers to interpolate from.
+ * @param {array} p1 An array of numbers to interpolate to.
+ * @returns {function} A function that, given `t`, returns an array of
+ * interpolated values.
+ * @private
+ */
function defaultInterp(p0, p1) {
return function (t) {
var result = [];
@@ -50155,7 +49484,7 @@ return /******/ (function(modules) { // webpackBootstrap
var units = m_this.unitsPerPixel(0);
- // Transform zoom level into z-coordinate and inverse
+ // Transform zoom level into z-coordinate and inverse.
function zoom2z(z) {
return vgl.zoomToHeight(z + 1, m_width, m_height) * units;
}
@@ -50216,6 +49545,13 @@ return /******/ (function(modules) { // webpackBootstrap
m_transition.end.rotation
]);
+ /**
+ * Process an animation from during a transition.
+ *
+ * @param {number} time The animation frame time. Used to ensure multiple
+ * transitions are smooth.
+ * @private
+ */
function anim(time) {
var done = m_transition.done,
next = m_queuedTransition;
@@ -50315,11 +49651,12 @@ return /******/ (function(modules) { // webpackBootstrap
* Cancel any existing transition. The transition will send a cancel event
* at the next animation frame, but no further activity occurs.
*
- * @param {string} [source] optional cause of the cancel. This can be any
- * value, but something like . is
- * recommended to allow other functions to determine the
- * source and cause of the transition being canceled.
- * @returns {bool} true if a transition was in progress.
+ * @param {string} [source] Optional cause of the cancel. This can be any
+ * value, but something like `(method name).(action)` is recommended to
+ * allow other functions to determine the source and cause of the
+ * transition being canceled.
+ * @returns {boolean} `true` if a transition was in progress.
+ * @fires geo.event.transitioncancel
*/
this.transitionCancel = function (source) {
if (m_transition && (m_transition.cancel !== true || m_queuedTransition)) {
@@ -50331,23 +49668,18 @@ return /******/ (function(modules) { // webpackBootstrap
return false;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get/set the locations of the current map corners as latitudes/longitudes.
- * When provided the argument should be an object containing the keys left,
- * top, right, bottom declaring the desired new map bounds. The new bounds
- * will contain at least the min/max lat/lngs provided modified by clamp
- * settings. In any case, the actual new bounds will be returned by this
- * function.
+ * Get/set the locations of the current map edges. When set, the left-top
+ * and right-bottom corners are transformed to the map's gcs and then used
+ * to set the bounds.
*
- * @param {geo.geoBounds} [bds] The requested map bounds
- * @param {string|geo.transform} [gcs] undefined to use the interface gcs,
- * null to use the map gcs, or any other transform. If setting the
+ * @param {geo.geoBounds} [bds] The requested map bounds.
+ * @param {string|geo.transform|null} [gcs] `undefined` to use the interface
+ * gcs, `null` to use the map gcs, or any other transform. If setting the
* bounds, they are converted from this gcs to the map projection. The
* returned bounds are converted from the map projection to this gcs.
- * @return {geo.geoBounds} The actual new map bounds
+ * @return {geo.geoBounds} The actual new map bounds.
*/
- ////////////////////////////////////////////////////////////////////////////
this.bounds = function (bds, gcs) {
var nav;
@@ -50376,6 +49708,17 @@ return /******/ (function(modules) { // webpackBootstrap
true);
};
+ /**
+ * Get/set the maximum view area of the map. If the map wraps, this is the
+ * unwrapped area.
+ *
+ * @param {geo.geoBounds} [bds] The map bounds.
+ * @param {string|geo.transform|null} [gcs] `undefined` to use the interface
+ * gcs, `null` to use the map gcs, or any other transform. If setting the
+ * bounds, they are converted from this gcs to the map projection. The
+ * returned bounds are converted from the map projection to this gcs.
+ * @return {geo.geoBounds|this} The map maximum bounds or the map object.
+ */
this.maxBounds = function (bounds, gcs) {
gcs = (gcs === null ? m_gcs : (gcs === undefined ? m_ingcs : gcs));
if (bounds === undefined) {
@@ -50414,17 +49757,17 @@ return /******/ (function(modules) { // webpackBootstrap
return this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get the center zoom level necessary to display the given lat/lon bounds.
+ * Get the center zoom level necessary to display the given bounds.
*
- * @param {geo.geoBounds} [bds] The requested map bounds
+ * @param {geo.geoBounds} bounds The requested map bounds. `right` must be
+ * greater than `left` and `bottom` must be greater than `top` in the
+ * map's gcs (after conversion from the provided gcs).
* @param {number} rotation Rotation in clockwise radians.
- * @param {string|geo.transform} [gcs] undefined to use the interface gcs,
- * null to use the map gcs, or any other transform.
- * @return {object} Object containing keys 'center' and 'zoom'
+ * @param {string|geo.transform|null} [gcs] `undefined` to use the interface
+ * gcs, `null` to use the map gcs, or any other transform.
+ * @return {geo.zoomAndCenter}
*/
- ////////////////////////////////////////////////////////////////////////////
this.zoomAndCenterFromBounds = function (bounds, rotation, gcs) {
var center, zoom;
@@ -50465,26 +49808,25 @@ return /******/ (function(modules) { // webpackBootstrap
};
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get the bounds that will be displayed with the given zoom and center.
*
* Note: the bounds may not have the requested zoom and center due to map
* restrictions.
*
- * @param {number} zoom The requested zoom level
- * @param {geo.geoPosition} center The requested center
- * @param {number} rotation The requested rotation
- * @param {string|geo.transform} [gcs] undefined to use the interface gcs,
- * null to use the map gcs, or any other transform.
- * @param {boolean} ignoreDiscreteZoom if true, ignore the discreteZoom
+ * @param {number} zoom The requested zoom level.
+ * @param {geo.geoPosition} center The requested center.
+ * @param {number} rotation The requested rotation in clockwise radians.
+ * @param {string|geo.transform|null} [gcs] `undefined` to use the interface
+ * gcs, `null` to use the map gcs, or any other transform.
+ * @param {boolean} ignoreDiscreteZoom If `true`, ignore the `discreteZoom`
* option when determining the new view.
- * @param {boolean} ignoreClampBounds if true or 'limited', ignore the
- * clampBoundsX options (up to a point, see fix_bounds) when determining
- * the new view.
+ * @param {boolean} [ignoreClampBounds] If `true` and `clampBoundsX` or
+ * `clampBoundsY` is set, allow the bounds to be less clamped.
+ * The map's `maxBounds` can be shifted so that they lie no further than
+ * the center of the bounds (rather than being forced to be at the edge).
* @return {geo.geoBounds}
*/
- ////////////////////////////////////////////////////////////////////////////
this.boundsFromZoomAndCenter = function (zoom, center, rotation, gcs,
ignoreDiscreteZoom, ignoreClampBounds) {
var width, height, halfw, halfh, bounds, units;
@@ -50538,15 +49880,13 @@ return /******/ (function(modules) { // webpackBootstrap
return bounds;
};
- ////////////////////////////////////////////////////////////////////////////
/**
- * Get/set the discrete zoom flag.
+ * Get/set the discrete zoom flag. If `true`, the map will snap to integer
+ * zoom levels.
*
- * @param {bool} If specified, the discrete zoom flag.
- * @return {bool} The current discrete zoom flag if no parameter is
- * specified, otherwise the map object.
+ * @param {boolean} [discreteZoom] If specified, the new discrete zoom flag.
+ * @return {boolean|this} The current discrete zoom flag or the map object.
*/
- ////////////////////////////////////////////////////////////////////////////
this.discreteZoom = function (discreteZoom) {
if (discreteZoom === undefined) {
return m_discreteZoom;
@@ -50562,16 +49902,13 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get the layers contained in the map.
* Alias of {@linkcode geo.sceneObject#children}.
* @method
*/
- ////////////////////////////////////////////////////////////////////////////
this.layers = this.children;
- ////////////////////////////////////////////////////////////////////////////
/**
* Update the attribution notice displayed on the bottom right corner of
* the map. The content of this notice is managed by individual layers.
@@ -50583,10 +49920,10 @@ return /******/ (function(modules) { // webpackBootstrap
* * geo.event.layerRemove
*
* In addition, layers should call this method when their own attribution
- * notices has changed. Users, in general, should not need to call this.
- * @returns {this} Chainable
+ * notices have changed. Users, in general, should not need to call this.
+ *
+ * @returns {this} Chainable.
*/
- ////////////////////////////////////////////////////////////////////////////
this.updateAttribution = function () {
// clear any existing attribution content
m_this.node().find('.geo-attribution').remove();
@@ -50616,57 +49953,40 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- /**
- * Draw a layer image to a canvas context. The layer's opacity and transform
- * is applied.
- *
- * @param {context} context: the 2d canvas context to draw into.
- * @param {number} opacity: the opacity in the range [0, 1].
- * @param {object} elem: the element that might have a transform.
- * @param {HTMLImageObject} img: the image or canvas to draw to the canvas.
- */
- function drawLayerImageToContext(context, opacity, elem, img) {
- context.globalAlpha = opacity;
- var transform = elem.css('transform');
- // if the canvas is being transformed, apply the same transformation
- if (transform && transform.substr(0, 7) === 'matrix(') {
- context.setTransform.apply(context, transform.substr(7, transform.length - 8).split(',').map(parseFloat));
- } else {
- context.setTransform(1, 0, 0, 1, 0, 0);
- }
- context.drawImage(img, 0, 0);
- }
-
/**
* Get a screen-shot of all or some of the canvas layers of map. Note that
* webGL layers are rerendered, even if
- * window.contextPreserveDrawingBuffer = true;
+ * `window.contextPreserveDrawingBuffer = true;`
* is set before creating the map object. Chrome, at least, may not keep the
* drawing buffers if the tab loses focus (and returning focus won't
* necessarily rerender).
*
- * @param {object|array|undefined} layers: either a layer, a list of layers,
- * falsy to get all layers, or an object that contains optional values of
- * layers, type, encoderOptions, and values listed in the opts param
- * (this last form allows a single argument for the function).
- * @param {string} type: see canvas.toDataURL. Defaults to 'image/png'.
- * Alternately, 'canvas' to return the canvas element (this can be used
- * to get the results as a blob, which can be faster for some operations
- * but is not supported as widely).
- * @param {Number} encoderOptions: see canvas.toDataURL.
- * @param {object} opts: additional screenshot options:
- * background: if false or null, don't prefill the background. If
- * undefined, use the default (white). Otherwise, a css color or
- * CanvasRenderingContext2D.fillStyle to fill the initial canvas.
- * This could match the background of the browser page, for instance.
- * wait: if 'idle', wait for the map to be idle and one animation frame to
- * occur. If truthy, wait for an animation frame to occur.
- * Otherwise, take the screenshot as sson as possible.
- * attribution: if null or unspecified, include the attribution only if
- * all layers are used. If false, never include the attribution. If
- * true, always include it.
- * @returns {deferred}: a jQuery Deferred object. The done function receives
- * either a data URL or the HTMLCanvasElement with the result.
+ * @param {geo.layer|geo.layer[]|false|object} [layers] Either a layer, a
+ * list of layers, falsy to get all layers, or an object that contains
+ * optional values of `layers`, `type`, `encoderOptions`, and additional
+ * values listed in the `opts` parameter (this last form allows a single
+ * argument for the function).
+ * @param {string} [type='image/png'] See {@link https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toDataURL
+ * canvas.toDataURL}. Use `'canvas'` to return the canvas element (this
+ * can be used to get the results as a blob, which can be faster for some
+ * operations but is not supported as widely).
+ * @param {number} [encoderOptions] See {@link https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toDataURL
+ * canvas.toDataURL}.
+ * @param {object} [opts] Additional screenshot options.
+ * @param {false|string|CanvasRenderingContext2D.fillStyle}
+ * [opts.background='white'] If `false` or `null`, don't prefill the
+ * background. Otherwise, a css color or
+ * `CanvasRenderingContext2D.fillStyle` to fill the initial canvas. This
+ * could match the background of the browser page, for instance.
+ * @param {boolean|'idle'} [opts.wait=false] If `'idle'`, wait for the map to
+ * be idle and one additional animation frame to occur. If truthy, wait
+ * for an animation frame to occur. Otherwise, take the screenshot as
+ * soon as possible.
+ * @param {boolean|null} [opts.attribution=null] If `null` or unspecified,
+ * include the attribution only if all layers are used. If false, never
+ * include the attribution. If `true`, always include it.
+ * @returns {deferred} A jQuery Deferred object. The done function receives
+ * either a data URL or an `HTMLCanvasElement` with the result.
*/
this.screenshot = function (layers, type, encoderOptions, opts) {
var defer;
@@ -50792,19 +50112,22 @@ return /******/ (function(modules) { // webpackBootstrap
};
/**
- * Instead of each function using window.requestAnimationFrame, schedule all
- * such frames here. This allows the callbacks to be reordered or removed as
- * needed and reduces overhead in Chrome a small amount. Also, if the
- * animation queue is shared between map instances, the callbacks will be
- * called as one, providing better synchronization.
+ * Instead of each function using `window.requestAnimationFrame`, schedule
+ * all such frames through this function. This allows the callbacks to be
+ * reordered or removed as needed and reduces overhead in Chrome a small
+ * amount. Also, if the animation queue is shared between map instances, the
+ * callbacks will be called in a single time slice, providing better
+ * synchronization.
*
- * @param {function} callback: function to call during the animation frame.
- * It is called with an animation epoch, exactly as requestAnimationFrame.
- * @param {string|boolean} action: falsy to only add the callback if it is
- * not already scheduled. 'remove' to remove the callback (use this
- * instead of cancelAnimationFrame). Any other truthy value moves the
- * callback to the end of the list.
- * @returns {integer} An integer as returned by window.requestAnimationFrame.
+ * @param {function} callback Function to call during the animation frame.
+ * It is called with an animation epoch, exactly as
+ * `requestAnimationFrame`.
+ * @param {boolean|'remove'} [action=false] Falsy to only add the callback if
+ * it is not already scheduled. `'remove'` to remove the callback (use
+ * this instead of `cancelAnimationFrame`). Any other truthy value moves
+ * the callback to the end of the list.
+ * @returns {integer} An integer as returned by
+ * `window.requestAnimationFrame`.
*/
this.scheduleAnimationFrame = function (callback, action) {
if (!m_animationQueue.length) {
@@ -50828,9 +50151,32 @@ return /******/ (function(modules) { // webpackBootstrap
return m_animationQueue[0];
};
+ /**
+ * Draw a layer image to a canvas context. The layer's opacity and transform
+ * are applied. This is used as part of making a screenshot.
+ *
+ * @param {context} context The 2d canvas context to draw into.
+ * @param {number} opacity The opacity in the range [0, 1].
+ * @param {object} elem A jQuery element that might have a transform.
+ * @param {HTMLImageObject} img The image or canvas to draw to the canvas.
+ * @private
+ */
+ function drawLayerImageToContext(context, opacity, elem, img) {
+ context.globalAlpha = opacity;
+ var transform = elem.css('transform');
+ // if the canvas is being transformed, apply the same transformation
+ if (transform && transform.substr(0, 7) === 'matrix(') {
+ context.setTransform.apply(context, transform.substr(7, transform.length - 8).split(',').map(parseFloat));
+ } else {
+ context.setTransform(1, 0, 0, 1, 0, 0);
+ }
+ context.drawImage(img, 0, 0);
+ }
+
/**
* Sevice the callback during an animation frame. This uses splice to modify
- * the animationQueue to allow multiple map instances to share the queue.
+ * the `animationQueue` to allow multiple map instances to share the queue.
+ * @private
*/
function processAnimationFrame() {
var queue = m_animationQueue.splice(0, m_animationQueue.length);
@@ -50841,22 +50187,22 @@ return /******/ (function(modules) { // webpackBootstrap
}
}
- ////////////////////////////////////////////////////////////////////////////
- //
- // The following are some private methods for interacting with the camera.
- // In order to hide the complexity of dealing with map aspect ratios,
- // clamping behavior, reseting zoom levels on resize, etc. from the
- // layers, the map handles camera movements directly. This requires
- // passing all camera movement events through the map initially. The
- // map uses these methods to fix up the events according to the constraints
- // of the display and passes the event to the layers.
- //
- ////////////////////////////////////////////////////////////////////////////
+ /*
+ * The following are some private methods for interacting with the camera.
+ * In order to hide the complexity of dealing with map aspect ratios,
+ * clamping behavior, resetting zoom levels on resize, etc. from the
+ * layers, the map handles camera movements directly. This requires
+ * passing all camera movement events through the map initially. The
+ * map uses these methods to fix up the events according to the constraints
+ * of the display and passes the event to the layers.
+ */
/**
- * Calculate the scaling factor to fit the given map bounds
- * into the viewport with the correct aspect ratio.
- * @param {object} bounds A desired bounds
- * @return {object} Multiplicative aspect ratio correction
+ * Calculate the scaling factor to fit the given map bounds into the viewport
+ * with the correct aspect ratio.
+ *
+ * @param {geo.geoBounds} bounds A desired bounds.
+ * @returns {object} Multiplicative aspect ratio correction with x and y
+ * values.
* @private
*/
function camera_scaling(bounds) {
@@ -50883,8 +50229,13 @@ return /******/ (function(modules) { // webpackBootstrap
}
/**
- * Adjust a set of bounds based on a rotation.
- * @private.
+ * Adjust a set of bounds based on a rotation. If a rotation exists, the
+ * returned bounds are typically larger than the source bounds.
+ *
+ * @param {geo.geoBounds} bounds Bounds to adjust.
+ * @param {number} rotation Angle in radians (positive is clockwise).
+ * @returns {geo.geoBounds}
+ * @private
*/
function rotate_bounds(bounds, rotation) {
if (rotation) {
@@ -50904,7 +50255,14 @@ return /******/ (function(modules) { // webpackBootstrap
/**
* Generate a set of bounds based on a center point, a width and height, and
* a rotation.
- * @private.
+ *
+ * @param {geo.geoPosition} center
+ * @param {object} size Size of the screen in map gcs.
+ * @param {number} size.width
+ * @param {number} size.height
+ * @param {number} rotation Angle in radians (positive is clockwise).
+ * @returns {geo.geoBounds}
+ * @private
*/
function rotate_bounds_center(center, size, rotation) {
// calculate the half width and height
@@ -50928,11 +50286,15 @@ return /******/ (function(modules) { // webpackBootstrap
}
/**
- * Calculate the minimum zoom level to fit the given
- * bounds inside the view port using the view port size,
- * the given bounds, and the number of units per
- * pixel. The method sets the valid zoom bounds as well
- * as the current zoom level to be within that range.
+ * Calculate the minimum zoom level to fit the given bounds inside the view
+ * port using the view port size, the given bounds, and the number of units
+ * per pixel. The method sets the valid zoom bounds as well as the current
+ * zoom level to be within that range.
+ *
+ * @param {geo.geoBounds} bounds Bounds to fit to the screen.
+ * @param {number} [rotation] Rotation in radians. If unspecified, use the
+ * current map rotation.
+ * @returns {number} The necessary zoom level.
* @private
*/
function calculate_zoom(bounds, rotation) {
@@ -50977,12 +50339,12 @@ return /******/ (function(modules) { // webpackBootstrap
/**
* Return the nearest valid zoom level to the requested zoom.
- * @private
- * @param {number} zoom a zoom level to adjust to current settings
- * @param {boolean} ignoreDiscreteZoom if true, ignore the discreteZoom
+ * @param {number} zoom A zoom level to adjust to current settings
+ * @param {boolean} ignoreDiscreteZoom If `true`, ignore the `discreteZoom`
* option when determining the new view.
- * @returns {number} the zoom level clamped to the allowed zoom range and
+ * @returns {number} The zoom level clamped to the allowed zoom range and
* with other settings applied.
+ * @private
*/
function fix_zoom(zoom, ignoreDiscreteZoom) {
zoom = Math.round(zoom * 1e6) / 1e6;
@@ -51004,6 +50366,15 @@ return /******/ (function(modules) { // webpackBootstrap
/**
* Return a valid rotation angle.
+ *
+ * @param {number} rotation Proposed rotation.
+ * @param {boolean} ignoreRotationFunc If truthy and rotations are allowed,
+ * allow any rotation. Otherwise, the rotation is passed through the
+ * `allowRotation` function.
+ * @param {boolean} noRangeLimit If falsy, ensure that the rotation is in the
+ * range [0, 2*PI). If it is very close to zero, it is snapped to zero.
+ * If true, the rotation can have any value.
+ * @returns {number} the validated rotation
* @private
*/
function fix_rotation(rotation, ignoreRotationFunc, noRangeLimit) {
@@ -51026,21 +50397,29 @@ return /******/ (function(modules) { // webpackBootstrap
/**
* Return the nearest valid bounds maintaining the width and height. Does
- * nothing if m_clampBounds* is false. If a delta is specified, will only
- * clamp if the out-of-bounds condition would be worse. If ignoreClampBounds
- * is true, clamping is applied only to prevent more than half the image from
- * being off screen.
- * @private
- * @param {object} bounds: the new bounds to apply in map gcs coordinates.
- * @param {number} rotation: the angle of rotation in radians. May be falsy
+ * nothing if `clampBoundsX` and `clampBoundsY` are false. If a delta is
+ * specified, will only clamp if the out-of-bounds condition would be worse.
+ * If `ignoreClampBounds` is true, clamping is applied only to prevent more
+ * than half the image from being off screen.
+ *
+ * @param {geo.geoBounds} bounds The new bounds to apply in map gcs
+ * coordinates.
+ * @param {number} [rotation] The angle of rotation in radians. May be falsy
* to have no rotation.
- * @param {object} delta: if present, the shift in position in screen
+ * @param {object} [delta] If present, the shift in position in screen
* coordinates. Bounds will only be adjusted if the bounds would be
* more out of position after the shift.
- * @param {boolean} ignoreClampBounds: if true and clampBoundX is set, allow
- * the bounds to be less clamped. Specifically, the map's maxBounds can
- * be shifted so that they lie no further than the center of the bounds
- * (rather than being forced to be at the edge).
+ * @param {number} delta.x
+ * @param {number} delta.y
+ * @param {number} delta.unit Units per pixel at the current zoom level.
+ * @param {boolean} [ignoreClampBounds] If `true` and `clampBoundsX` or
+ * `clampBoundsY` are set, allow the bounds to be less clamped.
+ * Specifically, the map's `maxBounds` can be shifted so that they lie no
+ * further than the center of the bounds (rather than being forced to be
+ * at the edge).
+ * @returns {geo.geoBounds} The adjusted bounds. This may be the same object
+ * passed in `bounds`.
+ * @private
*/
function fix_bounds(bounds, rotation, delta, ignoreClampBounds) {
if (!m_clampBoundsX && !m_clampBoundsY) {
@@ -51149,8 +50528,13 @@ return /******/ (function(modules) { // webpackBootstrap
}
/**
- * Call the camera bounds method with the given bounds, but
- * correct for the viewport aspect ratio.
+ * Call the camera bounds method with the given bounds, but correct for the
+ * viewport aspect ratio.
+ *
+ * @param {geo.geoBounds} bounds The bounds for the camera. If a rotation
+ * is specified, the bounds need to also contain the map gcs width and
+ * height.
+ * @param {number} [rotation] The map rotation in radians.
* @private
*/
function camera_bounds(bounds, rotation) {
@@ -51171,13 +50555,59 @@ return /******/ (function(modules) { // webpackBootstrap
};
}
- ////////////////////////////////////////////////////////////////////////////
- //
- // All the methods are now defined. From here, we are initializing all
- // internal variables and event handlers.
- //
- ////////////////////////////////////////////////////////////////////////////
+ /**
+ * Resize the map based on the size of the associated DOM node.
+ * @private
+ */
+ function resizeSelf() {
+ m_this.size({width: m_node.width(), height: m_node.height()});
+ }
+
+ /*
+ * All the methods are now defined. From here, we are initializing all
+ * internal variables and event handlers.
+ */
+
+ this._init(arg);
+
+ // set up drag/drop handling
+ this.node().on('dragover.geo', function (e) {
+ var evt = e.originalEvent;
+
+ if (m_this.fileReader()) {
+ evt.stopPropagation();
+ evt.preventDefault();
+ evt.dataTransfer.dropEffect = 'copy';
+ }
+ })
+ .on('drop.geo', function (e) {
+ var evt = e.originalEvent, reader = m_this.fileReader(),
+ i, file;
+
+ function done() {
+ m_this.draw();
+ }
+
+ if (reader) {
+ evt.stopPropagation();
+ evt.preventDefault();
+ for (i = 0; i < evt.dataTransfer.files.length; i += 1) {
+ file = evt.dataTransfer.files[i];
+ if (reader.canRead(file)) {
+ reader.read(file, done); // to do: trigger event on done
+ }
+ }
+ }
+ });
+
+ /*
+ * The map coordinates for the default world map, where c = half
+ * circumference at equator in meters, o = origin:
+ * (-c, c) + o (c, c) + o
+ * (center.x, center.y) + o <-- center of viewport
+ * (-c, -c) + o (c, -c) + o
+ */
// Set the world origin
m_origin = {x: 0, y: 0};
@@ -51192,12 +50622,8 @@ return /******/ (function(modules) { // webpackBootstrap
this.interactor(arg.interactor || mapInteractor({discreteZoom: m_discreteZoom}));
}
- function resizeSelf() {
- m_this.resize(0, 0, m_node.width(), m_node.height());
- }
-
- if (arg.autoResize) {
- $(window).resize(resizeSelf);
+ if (m_autoResize) {
+ $(window).on('resize', resizeSelf);
}
// attach attribution updates to layer events
@@ -51209,20 +50635,11 @@ return /******/ (function(modules) { // webpackBootstrap
return this;
};
- /**
- * General object specification for map types. Any additional
- * values in the object are passed to the map constructor.
- * @typedef geo.map.spec
- * @type {object}
- * @property {object[]} [data=[]] The default data array to
- * apply to each feature if none exists
- * @property {geo.layer.spec[]} [layers=[]] Layers to create
- */
-
/**
* Create a map from an object. Any errors in the creation
- * of the map will result in returning null.
- * @param {geo.map.spec} spec The object specification
+ * of the map will result in returning `null`.
+ *
+ * @param {geo.map.spec} spec The object specification.
* @returns {geo.map|null}
*/
map.create = function (spec) {
@@ -51261,7 +50678,6 @@ return /******/ (function(modules) { // webpackBootstrap
var registerLayer = __webpack_require__(201).registerLayer;
var layer = __webpack_require__(210);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class uiLayer
*
@@ -51269,7 +50685,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends {geo.layer}
* @returns {geo.gui.uiLayer}
*/
- //////////////////////////////////////////////////////////////////////////////
var uiLayer = function (arg) {
'use strict';
@@ -51287,13 +50702,11 @@ return /******/ (function(modules) { // webpackBootstrap
var m_this = this,
s_exit = this._exit;
- ////////////////////////////////////////////////////////////////////////////
/**
* Create a new ui control
*
* @returns {geo.gui.Widget} Will return a new control widget
*/
- ////////////////////////////////////////////////////////////////////////////
this.createWidget = function (widgetName, arg) {
var newWidget = createWidget(widgetName, m_this, arg);
@@ -51307,11 +50720,9 @@ return /******/ (function(modules) { // webpackBootstrap
return newWidget;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Delete a ui control
*/
- ////////////////////////////////////////////////////////////////////////////
this.deleteWidget = function (widget) {
widget._exit();
m_this.removeChild(widget);
@@ -51319,11 +50730,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Free memory and destroy the layer.
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_this.children().forEach(function (child) {
m_this.deleteWidget(child);
@@ -51351,7 +50760,6 @@ return /******/ (function(modules) { // webpackBootstrap
var registry = __webpack_require__(201);
var quadFeature = __webpack_require__(222);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of osmLayer
*
@@ -51362,7 +50770,6 @@ return /******/ (function(modules) { // webpackBootstrap
* imageFormat (such as png or jpeg), and displayLast
* (to decide whether or not render tiles from last zoom level).
*/
- //////////////////////////////////////////////////////////////////////////////
var osmLayer = function (arg) {
var imageTile = __webpack_require__(232);
@@ -51400,8 +50807,9 @@ return /******/ (function(modules) { // webpackBootstrap
queue: this._queue,
overlap: this._options.tileOverlap,
scale: this._options.tileScale,
- url: this._options.url(urlParams.x, urlParams.y, urlParams.level || 0,
- this._options.subdomains)
+ url: this._options.url.call(
+ this, urlParams.x, urlParams.y, urlParams.level || 0,
+ this._options.subdomains)
});
}.bind(this);
};
@@ -51456,32 +50864,65 @@ return /******/ (function(modules) { // webpackBootstrap
/**
* Pick a subdomain from a list of subdomains based on a the tile location.
*
- * @param {number} x: the x tile coordinate.
- * @param {number} y: the y tile coordinate.
- * @param {list} subdomains: the list of known subdomains.
+ * @param {number} x The x tile coordinate.
+ * @param {number} y The y tile coordinate.
+ * @param {number} z The tile layer.
+ * @param {string[]} subdomains The list of known subdomains.
+ * @returns {string} A subdomain based on the location.
*/
- function m_getTileSubdomain(x, y, subdomains) {
- return subdomains[modulo(x + y, subdomains.length)];
+ function m_getTileSubdomain(x, y, z, subdomains) {
+ return subdomains[modulo(x + y + z, subdomains.length)];
}
/**
* Returns an OSM tile server formatting function from a standard format
- * string. Replaces {s}, {z}, {x}, and {y}.
+ * string. Replaces `{s}`, `{z}`, `{x}`, and `{y}`. These may be any case
+ * and may be prefixed with `$` (e.g., `${X}` is the same as `{x}`). The
+ * subdomain can be specifed by a string of characters, listed as a range,
+ * or as a comma-separated list (e.g., `{s:abc}`, `{a-c}`, `{a,b,c}` are
+ * all equivalent. The comma-separated list can have subdimains that are of
+ * any length; the string and range both use one-character subdomains.
*
* @param {string} base The tile format string
- * @returns: a conversion function.
+ * @returns {function} A conversion function.
* @private.
*/
function m_tileUrlFromTemplate(base) {
+ var xPattern = new RegExp(/\$?\{[xX]\}/),
+ yPattern = new RegExp(/\$?\{[yY]\}/),
+ zPattern = new RegExp(/\$?\{[zZ]\}/),
+ sPattern = new RegExp(/\$?\{(s|S|[sS]:[^{}]+|[^-{}]-[^-{}]|([^,{}]+,)+[^,{}]+)\}/);
+ var url = base
+ .replace(sPattern, '{s}')
+ .replace(xPattern, '{x}')
+ .replace(yPattern, '{y}')
+ .replace(zPattern, '{z}');
+ var urlSubdomains;
+ var sMatch = base.match(sPattern);
+ if (sMatch) {
+ if (sMatch[2]) {
+ urlSubdomains = sMatch[1].split(',');
+ } else if (sMatch[1][1] === ':') {
+ urlSubdomains = sMatch[1].substr(2).split('');
+ } else if (sMatch[1][1] === '-') {
+ urlSubdomains = [];
+ var start = sMatch[1].charCodeAt(0),
+ end = sMatch[1].charCodeAt(2);
+ for (var i = Math.min(start, end); i <= Math.max(start, end); i += 1) {
+ urlSubdomains.push(String.fromCharCode(i));
+ }
+ }
+ }
+
return function (x, y, z, subdomains) {
- return base.replace('{s}', m_getTileSubdomain(x, y, subdomains))
- .replace('{z}', z)
+ return url
+ .replace('{s}', m_getTileSubdomain(x, y, z, urlSubdomains || subdomains))
.replace('{x}', x)
- .replace('{y}', y);
+ .replace('{y}', y)
+ .replace('{z}', z);
};
}
- //////////////////////////////////////////////////////////////////////////////
/**
* This method defines a tileLayer, which is an abstract class defining a
* layer divided into tiles of arbitrary data. Notably, this class provides
@@ -51577,7 +51018,6 @@ return /******/ (function(modules) { // webpackBootstrap
* local coordinates.
* @returns {geo.tileLayer}
*/
- //////////////////////////////////////////////////////////////////////////////
var tileLayer = function (options) {
'use strict';
if (!(this instanceof tileLayer)) {
@@ -51887,8 +51327,9 @@ return /******/ (function(modules) { // webpackBootstrap
index: index,
size: {x: this._options.tileWidth, y: this._options.tileHeight},
queue: this._queue,
- url: this._options.url(urlParams.x, urlParams.y, urlParams.level || 0,
- this._options.subdomains)
+ url: this._options.url.call(
+ this, urlParams.x, urlParams.y, urlParams.level || 0,
+ this._options.subdomains)
});
};
@@ -52204,7 +51645,6 @@ return /******/ (function(modules) { // webpackBootstrap
this._drawTile = function (tile) {
// Make sure this method is not called when there is
// a renderer attached.
- //
if (this.renderer() !== null) {
throw new Error('This draw method is not valid on renderer managed layers.');
}
@@ -52875,7 +52315,6 @@ return /******/ (function(modules) { // webpackBootstrap
return m_tileOffsetValues[level];
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set visibility of the layer
*
@@ -52884,7 +52323,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @return {boolean|object} either the visibility (if getting) or the layer
* (if setting).
*/
- ////////////////////////////////////////////////////////////////////////////
this.visible = function (val) {
if (val === undefined) {
return s_visible();
@@ -52971,7 +52409,6 @@ return /******/ (function(modules) { // webpackBootstrap
module.exports = (function () {
'use strict';
- //////////////////////////////////////////////////////////////////////////////
/**
* This class implements a simple cache for tile objects. Each tile is
* stored in cache object keyed by a configurable hashing function. Another
@@ -52983,7 +52420,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {object?} [options] A configuratoin object for the cache
* @param {number} [options.size=64] The maximum number of tiles to store
*/
- //////////////////////////////////////////////////////////////////////////////
var tileCache = function (options) {
if (!(this instanceof tileCache)) {
return new tileCache(options);
@@ -53126,7 +52562,6 @@ return /******/ (function(modules) { // webpackBootstrap
var inherit = __webpack_require__(8);
var feature = __webpack_require__(207);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class pathFeature
*
@@ -53134,7 +52569,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.feature
* @returns {geo.pathFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var pathFeature = function (arg) {
'use strict';
if (!(this instanceof pathFeature)) {
@@ -53143,22 +52577,18 @@ return /******/ (function(modules) { // webpackBootstrap
arg = arg || {};
feature.call(this, arg);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
m_position = arg.position === undefined ? [] : arg.position,
s_init = this._init;
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set positions
*
* @returns {geo.pathFeature}
*/
- ////////////////////////////////////////////////////////////////////////////
this.position = function (val) {
if (val === undefined) {
return m_position;
@@ -53170,11 +52600,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
s_init.call(m_this, arg);
@@ -53212,7 +52640,6 @@ return /******/ (function(modules) { // webpackBootstrap
var geo_event = __webpack_require__(9);
var util = __webpack_require__(83);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class imagemapFeature
*
@@ -53240,9 +52667,7 @@ return /******/ (function(modules) { // webpackBootstrap
* transformations for those two triangles.
* @returns {geo.pixelmapFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
- //////////////////////////////////////////////////////////////////////////////
var pixelmapFeature = function (arg) {
'use strict';
if (!(this instanceof pixelmapFeature)) {
@@ -53251,11 +52676,9 @@ return /******/ (function(modules) { // webpackBootstrap
arg = arg || {};
feature.call(this, arg);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
m_quadFeature,
m_srcImage,
@@ -53264,13 +52687,11 @@ return /******/ (function(modules) { // webpackBootstrap
s_init = this._init,
s_exit = this._exit;
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set position accessor
*
* @returns {geo.pixelmap}
*/
- ////////////////////////////////////////////////////////////////////////////
this.position = function (val) {
if (val === undefined) {
return m_this.style('position');
@@ -53282,13 +52703,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set url accessor
*
* @returns {geo.pixelmap}
*/
- ////////////////////////////////////////////////////////////////////////////
this.url = function (val) {
if (val === undefined) {
return m_this.style('url');
@@ -53301,14 +52720,12 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get the maximum index value from the pixelmap. This is a value present in
* the pixelmap.
*
* @returns {geo.pixelmap}
*/
- ////////////////////////////////////////////////////////////////////////////
this.maxIndex = function () {
if (m_info) {
/* This isn't just m_info.mappedColors.length - 1, since there
@@ -53325,13 +52742,11 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set color accessor
*
* @returns {geo.pixelmap}
*/
- ////////////////////////////////////////////////////////////////////////////
this.color = function (val) {
if (val === undefined) {
return m_this.style('color');
@@ -53369,11 +52784,9 @@ return /******/ (function(modules) { // webpackBootstrap
return {index: [], found: []};
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
/* Set the build time at the start of the call. A build can result in
* drawing a quad, which can trigger a full layer update, which in tern
@@ -53564,11 +52977,9 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
if (m_this.buildTime().getMTime() <= m_this.dataTime().getMTime() ||
@@ -53580,12 +52991,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Destroy
* @memberof geo.pixelmapFeature
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function (abc) {
if (m_quadFeature && m_this.layer()) {
m_this.layer().deleteFeature(m_quadFeature);
@@ -53595,11 +53004,9 @@ return /******/ (function(modules) { // webpackBootstrap
s_exit();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
arg = arg || {};
s_init.call(m_this, arg);
@@ -53662,12 +53069,227 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
/* 242 */
+/***/ (function(module, exports) {
+
+ /*
+ * Type definitions for jsdoc.
+ */
+
+ /**
+ * General object specification for map types. Any additional values in the
+ * object are passed to the map constructor.
+ *
+ * @typedef geo.map.spec
+ * @type {object}
+ * @property {object[]} [data=[]] The default data array to apply to each
+ * feature if none exists.
+ * @property {geo.layer.spec[]} [layers=[]] Layers to create.
+ */
+
+ /**
+ * General representation of rectangular bounds in world coordinates.
+ *
+ * @typedef geo.geoBounds
+ * @type {object}
+ * @property {number} left Horizontal coordinate of the top-left corner.
+ * @property {number} top Vertical coordinate of the top-left corner.
+ * @property {number} right Horizontal coordinate of the bottom-right corner.
+ * @property {number} bottom Vertical coordinate of the bottom-right corner.
+ */
+
+ /**
+ * A location and zoom value.
+ *
+ * @typedef geo.zoomAndCenter
+ * @type {object}
+ * @property {geo.geoPosition} center The center coordinates.
+ * @property {number} zoom The zoom level.
+ */
+
+ /**
+ * General representation of rectangular bounds in pixel coordinates.
+ *
+ * @typedef geo.screenBounds
+ * @type {object}
+ * @property {geo.screenPosition} upperLeft Upper left corner.
+ * @property {geo.screenPosition} upperRight Upper right corner.
+ * @property {geo.screenPosition} lowerLeft Lower left corner.
+ * @property {geo.screenPosition} lowerRight Lower right corner.
+ */
+
+ /**
+ * General representation of a point on the screen.
+ *
+ * @typedef geo.screenPosition
+ * @type {object}
+ * @property {number} x Horizontal coordinate in pixels.
+ * @property {number} y Vertical coordinate in pixels.
+ */
+
+ /**
+ * General represention of a point on the earth. The coordinates are most
+ * commonly in longitude and latitude, but the coordinate system is changed
+ * by the interface gcs.
+ *
+ * @typedef geo.geoPosition
+ * @type {object}
+ * @property {number} x Horizontal coordinate, often degrees longitude.
+ * @property {number} y Vertical coordinate, often degrees latitude.
+ * @property {number} [z=0] Altitude coordinate.
+ */
+
+ /**
+ * Represention of a point on the map. The coordinates are in the map's
+ * reference system, possibly with an affine transformation.
+ *
+ * @typedef geo.worldPosition
+ * @type {object}
+ * @property {number} x Horizontal coordinate in map coordinates.
+ * @property {number} y Vertical coordinate in map coordinates.
+ * @property {number} [z=0] Altitude coordinate, often zero.
+ */
+
+ /**
+ * Represention of a size in pixels.
+ *
+ * @typedef geo.screenSize
+ * @type {object}
+ * @property {number} width Width in pixels.
+ * @property {number} height Height in pixels.
+ */
+
+ /**
+ * The status of all mouse buttons.
+ *
+ * @typedef geo.mouseButtons
+ * @type {object}
+ * @property {boolean} left True if the left mouse button is down.
+ * @property {boolean} right True if the right mouse button is down.
+ * @property {boolean} middle True if the middle mouse button is down.
+ */
+
+ /**
+ * The status of all modifier keys. These are usually copied from the
+ * standard DOM events.
+ *
+ * @typedef geo.modifierKeys
+ * @type {object}
+ * @property {boolean} alt True if the alt or option key is down.
+ * @property {boolean} ctrl True if the control key is down.
+ * @property {boolean} shift True if the shift key is down.
+ * @property {boolean} meta True if the meta, windows, or command key
+ * is down.
+ */
+
+ /**
+ * The state of the mouse.
+ *
+ * @typedef geo.mouseState
+ * @type {object}
+ * @property {geo.screenPosition} page Mouse location in pixel space.
+ * @property {geo.geoPosition} map Mouse location in gcs space.
+ * @property {geo.mouseButtons} buttons The current state of the mouse buttons.
+ * @property {geo.modifierKeys} modifiers The current state of all modifier
+ * keys.
+ * @property {Date} time The timestamp the event took place.
+ * @property {number} deltaTime The time in milliseconds since the last mouse
+ * event.
+ * @property {geo.screenPosition} velocity The velocity of the mouse pointer
+ * in pixels per millisecond.
+ */
+
+ /**
+ * The current brush selection (this is when a rectangular area is selected by
+ * dragging).
+ *
+ * @typedef geo.brushSelection
+ * @type {object}
+ * @property {geo.screenBounds} display The selection bounds in pixel space.
+ * @property {object} gcs The selection bounds in the map's gcs.
+ * @property {geo.geoPosition} gcs.upperLeft Upper left corner.
+ * @property {geo.geoPosition} gcs.upperRight Upper right corner.
+ * @property {geo.geoPosition} gcs.lowerLeft Lower left corner.
+ * @property {geo.geoPosition} gcs.lowerRight Lower right corner.
+ * @property {geo.mouseState} mouse The current mouse state.
+ * @property {geo.mouseState} origin The mouse state at the start of the
+ * brush action.
+ */
+
+ /**
+ * The conditions that are necessary to make an action occur.
+ *
+ * @typedef geo.actionRecord
+ * @type {object}
+ * @property {string} action The name of the action, from (@link geo.action}.
+ * @property {string} [owner] A name of an owning process that can be used to
+ * locate or filter actions.
+ * @property {string} [name] A human-readable name that can be used to locate
+ * or filter actions.
+ * @property {string|object} input The name of an input that is used for the
+ * action, or an object with input names as keys and boolean values of
+ * inputs that are required to occur or required to not occur to trigger
+ * the action. Input names include `left`, `right`, `middle` (for mouse
+ * buttons), `wheel` (the mouse wheel), `pan` (touch pan), `rotate` (touch
+ * rotate).
+ * @property {string|object} [modifiers] The name of a modifier key or an
+ * object with modifiers as the keys and boolean values. The listed
+ * modifiers must be set or unset depending on the boolean value.
+ * Modifiers include `shift`, `ctrl`, `alt`, and `meta`.
+ * @property {boolean|string} [selectionRectangle] If truthy, a selection
+ * rectangle is shown during the action. If a string, the name of an
+ * event that is triggered when the selection is complete.
+ */
+
+ /**
+ * The current action state a map interactor.
+ *
+ * @typedef geo.actionState
+ * @type {object}
+ * @property {string} action Name of the action that is being handled.
+ * @property {geo.actionRecord} actionRecord The action record which triggered
+ * the current action.
+ * @property {string} [origAction] The name of an action that triggered this
+ * action.
+ * @property {geo.mouseState} origin The mouse state at the start of the
+ * action.
+ * @property {number} initialZoom The zoom level at the start of the action.
+ * @property {number} initialRotation The map's rotation in radians at the
+ * start of the action.
+ * @property {number} initialEventRotation The rotation reported by the
+ * event that triggered this action. For example, this could be the
+ * angle between two multi-touch points.
+ * @property {object} delta The total movement of during the action in gcs
+ * coordinates.
+ * @property {number} delta.x The horizontal movement during the action.
+ * @property {number} delta.y The vertical movement during the action.
+ * @property {boolean} boundDocumentHandlers `true` if the mouse is down and
+ * being tracked.
+ * @property {Date} [start] The time when the action started.
+ * @property {function} [handler] A function to call on every animation from
+ * while the action is occurring.
+ * @property {geo.mouseState} [momentum] The mouse location when a momentum
+ * action starts.
+ * @property {boolean} [zoomrotateAllowRotation] Truthy if enough movement has
+ * occurred that rotations are allowed.
+ * @property {boolean} [zoomrotateAllowZoom] Truthy if enough movement has
+ * occurred that zooms are allowed.
+ * @property {boolean} [zoomrotateAllowPan] Truthy if enough movement has
+ * occurred that pans are allowed.
+ * @property {number} [lastRotationDelta] When rotating, the last amount that
+ * was rotated from the start of the action. This is used to debounce
+ * jitter on touch events.
+ * @property {geo.geoPosition} [initialEventGeo] The position of the mouse
+ * when significant movement first occurred.
+ */
+
+
+/***/ }),
+/* 243 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var feature = __webpack_require__(207);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class vectorFeature
*
@@ -53675,7 +53297,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.feature
* @returns {geo.vectorFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var vectorFeature = function (arg) {
'use strict';
if (!(this instanceof vectorFeature)) {
@@ -53687,22 +53308,18 @@ return /******/ (function(modules) { // webpackBootstrap
arg = arg || {};
feature.call(this, arg);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_init = this._init,
s_style = this.style;
- ////////////////////////////////////////////////////////////////////////////
/**
* Get or set the accessor for the origin of the vector. This is the point
* that the vector base resides at. Defaults to (0, 0, 0).
* @param {geo.accessor|geo.geoPosition} [accessor] The origin accessor
*/
- ////////////////////////////////////////////////////////////////////////////
this.origin = function (val) {
if (val === undefined) {
return s_style('origin');
@@ -53714,12 +53331,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get or set the accessor for the displacement (coordinates) of the vector.
* @param {geo.accessor|geo.geoPosition} [accessor] The accessor
*/
- ////////////////////////////////////////////////////////////////////////////
this.delta = function (val) {
if (val === undefined) {
return s_style('delta');
@@ -53731,12 +53346,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
s_init.call(m_this, arg);
@@ -53769,54 +53382,54 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 243 */
+/* 244 */
/***/ (function(module, exports, __webpack_require__) {
- module.exports = ("0.12.1");
+ module.exports = ("0.12.2");
/***/ }),
-/* 244 */
+/* 245 */
/***/ (function(module, exports, __webpack_require__) {
- module.exports = ("31bf6e5d4db730197fdb407e8d8c23b36b69b1fb");
+ module.exports = ("bd5c88ae768f630b1de1f3cb8f1b35c28ad286c4");
/***/ }),
-/* 245 */
+/* 246 */
/***/ (function(module, exports, __webpack_require__) {
var geo_event = __webpack_require__(9);
geo_event.d3 = {
- rescale: __webpack_require__(246)
+ rescale: __webpack_require__(247)
};
/**
* @namespace geo.d3
*/
module.exports = {
- graphFeature: __webpack_require__(247),
- lineFeature: __webpack_require__(248),
- object: __webpack_require__(249),
- pathFeature: __webpack_require__(251),
- pointFeature: __webpack_require__(252),
- quadFeature: __webpack_require__(253),
- renderer: __webpack_require__(254),
- tileLayer: __webpack_require__(255),
- uniqueID: __webpack_require__(250),
- vectorFeature: __webpack_require__(256)
+ graphFeature: __webpack_require__(248),
+ lineFeature: __webpack_require__(249),
+ object: __webpack_require__(250),
+ pathFeature: __webpack_require__(252),
+ pointFeature: __webpack_require__(253),
+ quadFeature: __webpack_require__(254),
+ renderer: __webpack_require__(255),
+ tileLayer: __webpack_require__(256),
+ uniqueID: __webpack_require__(251),
+ vectorFeature: __webpack_require__(257)
};
/***/ }),
-/* 246 */
+/* 247 */
/***/ (function(module, exports) {
module.exports = 'geo_d3_rescale';
/***/ }),
-/* 247 */
+/* 248 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
@@ -53837,11 +53450,9 @@ return /******/ (function(modules) { // webpackBootstrap
}
graphFeature.call(this, arg);
- ////////////////////////////////////////////////////////////////////////////
/**
* Returns a d3 selection for the graph elements
*/
- ////////////////////////////////////////////////////////////////////////////
this.select = function () {
var renderer = m_this.renderer(),
selection = {},
@@ -53865,14 +53476,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 248 */
+/* 249 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
var lineFeature = __webpack_require__(206);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class lineFeature
*
@@ -53881,7 +53491,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.d3.object
* @returns {geo.d3.lineFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var d3_lineFeature = function (arg) {
'use strict';
if (!(this instanceof d3_lineFeature)) {
@@ -53889,7 +53498,7 @@ return /******/ (function(modules) { // webpackBootstrap
}
var d3 = __webpack_require__(225);
- var object = __webpack_require__(249);
+ var object = __webpack_require__(250);
var timestamp = __webpack_require__(209);
var util = __webpack_require__(83);
@@ -53897,34 +53506,28 @@ return /******/ (function(modules) { // webpackBootstrap
lineFeature.call(this, arg);
object.call(this);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_init = this._init,
m_buildTime = timestamp(),
m_maxIdx = 0,
s_update = this._update;
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
s_init.call(m_this, arg);
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
var data = m_this.data() || [],
s_style = m_this.style(),
@@ -53986,13 +53589,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
@@ -54020,26 +53621,24 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 249 */
+/* 250 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var sceneObject = __webpack_require__(208);
- //////////////////////////////////////////////////////////////////////////////
/**
* D3 specific subclass of object which adds an id property for d3 selections
* on groups of objects by class id.
* @class geo.d3.object
* @extends geo.sceneObject
*/
- //////////////////////////////////////////////////////////////////////////////
var d3_object = function (arg) {
'use strict';
var object = __webpack_require__(203);
- var uniqueID = __webpack_require__(250);
+ var uniqueID = __webpack_require__(251);
// this is used to extend other geojs classes, so only generate
// a new object when that is not the case... like if this === window
@@ -54057,31 +53656,25 @@ return /******/ (function(modules) { // webpackBootstrap
return m_id;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Returns a d3 selection for the feature elements
*/
- ////////////////////////////////////////////////////////////////////////////
this.select = function () {
return m_this.renderer().select(m_this._d3id());
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Redraw the object.
*/
- ////////////////////////////////////////////////////////////////////////////
this.draw = function () {
m_this._update();
s_draw();
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Removes the element from the svg and the renderer
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_this.renderer()._removeFeature(m_this._d3id());
s_exit();
@@ -54095,19 +53688,17 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 250 */
+/* 251 */
/***/ (function(module, exports) {
var chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz',
strLength = 8;
- //////////////////////////////////////////////////////////////////////////////
/**
* Get a random string to use as a div ID
* @function geo.d3.uniqueID
* @returns {string}
*/
- //////////////////////////////////////////////////////////////////////////////
var uniqueID = function () {
var strArray = [],
i;
@@ -54122,14 +53713,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 251 */
+/* 252 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
var pathFeature = __webpack_require__(240);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class pathFeature
*
@@ -54138,7 +53728,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.d3.object
* @returns {geo.d3.pathFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var d3_pathFeature = function (arg) {
'use strict';
if (!(this instanceof d3_pathFeature)) {
@@ -54147,18 +53736,16 @@ return /******/ (function(modules) { // webpackBootstrap
var $ = __webpack_require__(1);
var d3 = __webpack_require__(225);
- var object = __webpack_require__(249);
+ var object = __webpack_require__(250);
var timestamp = __webpack_require__(209);
arg = arg || {};
pathFeature.call(this, arg);
object.call(this);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_init = this._init,
m_buildTime = timestamp(),
@@ -54167,23 +53754,19 @@ return /******/ (function(modules) { // webpackBootstrap
m_style.style = {};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
s_init.call(m_this, arg);
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
var data = m_this.data() || [],
s_style = m_this.style(),
@@ -54230,13 +53813,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
@@ -54259,14 +53840,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 252 */
+/* 253 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
var pointFeature = __webpack_require__(212);
- //////////////////////////////////////////////////////////////////////////////
/**
*
* Create a new instance of pointFeature
@@ -54276,48 +53856,41 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.d3.object
* @returns {geo.d3.pointFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var d3_pointFeature = function (arg) {
'use strict';
if (!(this instanceof d3_pointFeature)) {
return new d3_pointFeature(arg);
}
- var d3_object = __webpack_require__(249);
+ var d3_object = __webpack_require__(250);
var timestamp = __webpack_require__(209);
arg = arg || {};
pointFeature.call(this, arg);
d3_object.call(this);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_init = this._init,
s_update = this._update,
m_buildTime = timestamp(),
m_style = {};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
s_init.call(m_this, arg);
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
var data = m_this.data(),
s_style = m_this.style.get(),
@@ -54356,13 +53929,11 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
@@ -54386,14 +53957,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 253 */
+/* 254 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
var quadFeature = __webpack_require__(222);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class quadFeature
*
@@ -54402,7 +53972,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.quadFeature
* @returns {geo.d3.quadFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var d3_quadFeature = function (arg) {
'use strict';
if (!(this instanceof d3_quadFeature)) {
@@ -54411,7 +53980,7 @@ return /******/ (function(modules) { // webpackBootstrap
var $ = __webpack_require__(1);
var d3 = __webpack_require__(225);
- var object = __webpack_require__(249);
+ var object = __webpack_require__(250);
quadFeature.call(this, arg);
object.call(this);
@@ -54422,11 +53991,9 @@ return /******/ (function(modules) { // webpackBootstrap
s_update = this._update,
m_quads;
- ////////////////////////////////////////////////////////////////////////////
/**
* Build this feature
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
if (!this.position()) {
return;
@@ -54581,11 +54148,9 @@ return /******/ (function(modules) { // webpackBootstrap
this.buildTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
if (m_this.buildTime().getMTime() <= m_this.dataTime().getMTime() ||
@@ -54595,20 +54160,16 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function () {
s_init.call(m_this, arg);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Destroy
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
s_exit.call(m_this);
};
@@ -54633,14 +54194,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 254 */
+/* 255 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerRenderer = __webpack_require__(201).registerRenderer;
var renderer = __webpack_require__(202);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class d3Renderer
*
@@ -54648,15 +54208,14 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.renderer
* @returns {geo.d3.d3Renderer}
*/
- //////////////////////////////////////////////////////////////////////////////
var d3Renderer = function (arg) {
'use strict';
var d3 = __webpack_require__(225);
- var object = __webpack_require__(249);
+ var object = __webpack_require__(250);
var util = __webpack_require__(83);
var geo_event = __webpack_require__(9);
- var d3Rescale = __webpack_require__(246);
+ var d3Rescale = __webpack_require__(247);
if (!(this instanceof d3Renderer)) {
return new d3Renderer(arg);
@@ -54683,12 +54242,10 @@ return /******/ (function(modules) { // webpackBootstrap
m_svg = null,
m_defs = null;
- ////////////////////////////////////////////////////////////////////////////
/**
* Set attributes to a d3 selection.
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
function setAttrs(select, attrs) {
var key;
for (key in attrs) {
@@ -54698,12 +54255,10 @@ return /******/ (function(modules) { // webpackBootstrap
}
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Meta functions for converting from geojs styles to d3.
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
this._convertColor = function (f, g) {
f = util.ensureFunction(f);
g = g || function () { return true; };
@@ -54728,12 +54283,10 @@ return /******/ (function(modules) { // webpackBootstrap
};
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Set styles to a d3 selection. Ignores unkown style keys.
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
function setStyles(select, styles) {
var key, k, f;
function fillFunc() {
@@ -54793,14 +54346,12 @@ return /******/ (function(modules) { // webpackBootstrap
}
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Get the svg group element associated with this renderer instance, or of a
* group within the render instance.
*
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
function getGroup(parentId) {
if (parentId) {
return m_svg.select('.group-' + parentId);
@@ -54808,12 +54359,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_svg.select('.group-' + m_this._d3id());
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Set the initial lat-lon coordinates of the map view.
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
function initCorners() {
var layer = m_this.layer(),
map = layer.map(),
@@ -54827,19 +54376,17 @@ return /******/ (function(modules) { // webpackBootstrap
}
m_diagonal = Math.pow(width * width + height * height, 0.5);
m_corners = {
- upperLeft: map.displayToGcs({'x': 0, 'y': 0}, null),
- lowerRight: map.displayToGcs({'x': width, 'y': height}, null),
- center: map.displayToGcs({'x': width / 2, 'y': height / 2}, null)
+ upperLeft: map.displayToGcs({x: 0, y: 0}, null),
+ lowerRight: map.displayToGcs({x: width, y: height}, null),
+ center: map.displayToGcs({x: width / 2, y: height / 2}, null)
};
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Set the translation, scale, and zoom for the current view.
* @note rotation not yet supported
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
this._setTransform = function () {
if (!m_corners) {
initCorners();
@@ -54889,13 +54436,11 @@ return /******/ (function(modules) { // webpackBootstrap
m_transform.rotation = rotation;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Convert from screen pixel coordinates to the local coordinate system
* in the SVG group element taking into account the transform.
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
this.baseToLocal = function (pt) {
pt = {
x: (pt.x - m_transform.dx) / m_scale,
@@ -54913,13 +54458,11 @@ return /******/ (function(modules) { // webpackBootstrap
return pt;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Convert from the local coordinate system in the SVG group element
* to screen pixel coordinates.
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
this.localToBase = function (pt) {
if (m_transform.rotation) {
var sinr = Math.sin(m_transform.rotation),
@@ -54937,11 +54480,9 @@ return /******/ (function(modules) { // webpackBootstrap
return pt;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
if (!m_this.canvas()) {
var canvas;
@@ -55019,16 +54560,13 @@ return /******/ (function(modules) { // webpackBootstrap
m_this._setTransform();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get API used by the renderer
*/
- ////////////////////////////////////////////////////////////////////////////
this.api = function () {
return 'd3';
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Return the current scaling factor to build features that shouldn't
* change size during zooms. For example:
@@ -55039,16 +54577,13 @@ return /******/ (function(modules) { // webpackBootstrap
* This will create a circle element with radius r0 independent of the
* current zoom level.
*/
- ////////////////////////////////////////////////////////////////////////////
this.scaleFactor = function () {
return m_scale;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Handle resize event
*/
- ////////////////////////////////////////////////////////////////////////////
this._resize = function (x, y, w, h) {
if (!m_corners) {
initCorners();
@@ -55059,19 +54594,15 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.layer().geoTrigger(d3Rescale, { scale: m_scale }, true);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update noop for geo.d3.object api.
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Exit
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_features = {};
m_this.canvas().remove();
@@ -55084,17 +54615,14 @@ return /******/ (function(modules) { // webpackBootstrap
s_exit();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get the definitions dom element for the layer
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._definitions = function () {
return m_defs;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Create a new feature element from an object that describes the feature
* attributes. To be called from feature classes only.
@@ -55119,7 +54647,6 @@ return /******/ (function(modules) { // webpackBootstrap
* parentId: If set, the group ID of the parent element.
* }
*/
- ////////////////////////////////////////////////////////////////////////////
this._drawFeatures = function (arg) {
m_features[arg.id] = {
data: arg.data,
@@ -55136,12 +54663,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this.__render(arg.id, arg.parentId);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Updates a feature by performing a d3 data join. If no input id is
* provided then this method will update all features.
*/
- ////////////////////////////////////////////////////////////////////////////
this.__render = function (id, parentId) {
var key;
if (id === undefined) {
@@ -55206,20 +54731,16 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Returns a d3 selection for the given feature id.
*/
- ////////////////////////////////////////////////////////////////////////////
this.select = function (id, parentId) {
return getGroup(parentId).selectAll('.' + id);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Removes a feature from the layer.
*/
- ////////////////////////////////////////////////////////////////////////////
this._removeFeature = function (id) {
m_removeIds[id] = true;
m_this.layer().map().scheduleAnimationFrame(m_this._renderFrame);
@@ -55230,11 +54751,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Override draw method to do nothing.
*/
- ////////////////////////////////////////////////////////////////////////////
this.draw = function () {
};
@@ -55295,7 +54814,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 255 */
+/* 256 */
/***/ (function(module, exports, __webpack_require__) {
var registerLayerAdjustment = __webpack_require__(201).registerLayerAdjustment;
@@ -55390,14 +54909,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 256 */
+/* 257 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
- var vectorFeature = __webpack_require__(242);
+ var vectorFeature = __webpack_require__(243);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of vectorFeature
*
@@ -55406,14 +54924,13 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.d3.object
* @returns {geo.d3.vectorFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var d3_vectorFeature = function (arg) {
'use strict';
if (!(this instanceof d3_vectorFeature)) {
return new d3_vectorFeature(arg);
}
- var object = __webpack_require__(249);
+ var object = __webpack_require__(250);
var timestamp = __webpack_require__(209);
var d3 = __webpack_require__(225);
@@ -55421,11 +54938,9 @@ return /******/ (function(modules) { // webpackBootstrap
vectorFeature.call(this, arg);
object.call(this);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_init = this._init,
s_exit = this._exit,
@@ -55433,7 +54948,6 @@ return /******/ (function(modules) { // webpackBootstrap
m_buildTime = timestamp(),
m_style = {};
- ////////////////////////////////////////////////////////////////////////////
/**
* Generate a unique ID for a marker definition
* @private
@@ -55441,12 +54955,10 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {number} i The marker index
* @param {string} position The marker's vector position (head or tail)
*/
- ////////////////////////////////////////////////////////////////////////////
function markerID(d, i, position) {
return m_this._d3id() + '_marker_' + i + '_' + position;
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Add marker styles for vector arrows.
* @private
@@ -55456,7 +54968,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {function} originStyle The marker style for the vector head
* @param {function} endStyle The marker style for the vector tail
*/
- ////////////////////////////////////////////////////////////////////////////
function updateMarkers(data, stroke, opacity, originStyle, endStyle) {
var markerConfigs = {
@@ -55549,23 +55060,19 @@ return /******/ (function(modules) { // webpackBootstrap
sel.exit().remove();
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
s_init.call(m_this, arg);
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
var data = m_this.data(),
s_style = m_this.style.get(),
@@ -55651,12 +55158,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
@@ -55675,12 +55180,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Exit
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
s_exit.call(m_this);
m_style = {};
@@ -55699,33 +55202,32 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 257 */
+/* 258 */
/***/ (function(module, exports, __webpack_require__) {
/**
* @namespace geo.gl
*/
module.exports = {
- choroplethFeature: __webpack_require__(258),
- contourFeature: __webpack_require__(259),
- lineFeature: __webpack_require__(261),
- pointFeature: __webpack_require__(262),
- polygonFeature: __webpack_require__(263),
- quadFeature: __webpack_require__(265),
- tileLayer: __webpack_require__(266),
+ choroplethFeature: __webpack_require__(259),
+ contourFeature: __webpack_require__(260),
+ lineFeature: __webpack_require__(262),
+ pointFeature: __webpack_require__(263),
+ polygonFeature: __webpack_require__(264),
+ quadFeature: __webpack_require__(266),
+ tileLayer: __webpack_require__(267),
vglRenderer: __webpack_require__(200)
};
/***/ }),
-/* 258 */
+/* 259 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
var choroplethFeature = __webpack_require__(224);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of choroplethFeature
*
@@ -55733,7 +55235,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.choroplethFeature
* @returns {geo.gl.choroplethFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var gl_choroplethFeature = function (arg) {
'use strict';
@@ -55743,11 +55244,9 @@ return /******/ (function(modules) { // webpackBootstrap
arg = arg || {};
choroplethFeature.call(this, arg);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
m_gl_polygons = null,
s_exit = this._exit,
@@ -55773,34 +55272,28 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
s_init.call(m_this, arg);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
m_this.buildTime().modified();
return (m_gl_polygons = createGLChoropleth());
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
if (m_this.dataTime().getMTime() >= m_this.buildTime().getMTime() ||
@@ -55811,11 +55304,9 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.updateTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Destroy Polygon Sub-Features
*/
- ////////////////////////////////////////////////////////////////////////////
this._wipePolygons = function () {
if (m_gl_polygons) {
m_gl_polygons.map(function (polygon) {
@@ -55825,11 +55316,9 @@ return /******/ (function(modules) { // webpackBootstrap
m_gl_polygons = null;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Destroy
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_this._wipePolygons();
s_exit();
@@ -55848,14 +55337,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 259 */
+/* 260 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
var contourFeature = __webpack_require__(226);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of contourFeature
*
@@ -55863,7 +55351,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.contourFeature
* @returns {geo.gl.contourFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var gl_contourFeature = function (arg) {
'use strict';
@@ -55876,15 +55363,13 @@ return /******/ (function(modules) { // webpackBootstrap
var vgl = __webpack_require__(86);
var transform = __webpack_require__(11);
var util = __webpack_require__(83);
- var object = __webpack_require__(260);
+ var object = __webpack_require__(261);
object.call(this);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_exit = this._exit,
m_textureUnit = 7,
@@ -56017,11 +55502,9 @@ return /******/ (function(modules) { // webpackBootstrap
m_mapper.boundsDirtyTimestamp().modified();
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
var blend = vgl.blend(),
prog = vgl.shaderProgram(),
@@ -56087,13 +55570,11 @@ return /******/ (function(modules) { // webpackBootstrap
m_mapper.setGeometryData(geom);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
if (m_actor) {
m_this.renderer().contextRenderer().removeActor(m_actor);
@@ -56105,13 +55586,11 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.buildTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
@@ -56125,11 +55604,9 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.updateTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Destroy
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_this.renderer().contextRenderer().removeActor(m_actor);
s_exit();
@@ -56148,16 +55625,14 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 260 */
+/* 261 */
/***/ (function(module, exports, __webpack_require__) {
- //////////////////////////////////////////////////////////////////////////////
/**
* VGL specific subclass of object which rerenders when the object is drawn.
* @class geo.gl.object
* @extends geo.sceneObject
*/
- //////////////////////////////////////////////////////////////////////////////
var gl_object = function (arg) {
'use strict';
@@ -56173,11 +55648,9 @@ return /******/ (function(modules) { // webpackBootstrap
var m_this = this,
s_draw = this.draw;
- ////////////////////////////////////////////////////////////////////////////
/**
* Redraw the object.
*/
- ////////////////////////////////////////////////////////////////////////////
this.draw = function () {
m_this._update({mayDelay: true});
m_this.renderer()._render();
@@ -56193,7 +55666,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 261 */
+/* 262 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
@@ -56231,7 +55704,6 @@ return /******/ (function(modules) { // webpackBootstrap
debug: 1
};
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of lineFeature
*
@@ -56239,7 +55711,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.lineFeature
* @returns {geo.gl.lineFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var gl_lineFeature = function (arg) {
'use strict';
if (!(this instanceof gl_lineFeature)) {
@@ -56251,15 +55722,13 @@ return /******/ (function(modules) { // webpackBootstrap
var vgl = __webpack_require__(86);
var transform = __webpack_require__(11);
var util = __webpack_require__(83);
- var object = __webpack_require__(260);
+ var object = __webpack_require__(261);
object.call(this);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_exit = this._exit,
m_actor,
@@ -56734,35 +56203,29 @@ return /******/ (function(modules) { // webpackBootstrap
m_mapper.boundsDirtyTimestamp().modified();
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Return the arrangement of vertices used for each line segment.
*
* @returns {Number}
*/
- ////////////////////////////////////////////////////////////////////////////
this.featureVertices = function () {
// return [[0, -1], [0, 1], [1, -1], [1, 1], [1, -1], [0, 1]];
return [[0, 'corner', -1], [0, 'near', 1], [1, 'far', -1],
[1, 'corner', 1], [1, 'near', -1], [0, 'far', 1]];
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Return the number of vertices used for each line segment.
*
* @returns {Number}
*/
- ////////////////////////////////////////////////////////////////////////////
this.verticesPerFeature = function () {
return m_this.featureVertices().length;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
var prog = vgl.shaderProgram(),
vs = createVertexShader(),
@@ -56850,13 +56313,11 @@ return /******/ (function(modules) { // webpackBootstrap
m_mapper.setGeometryData(geom);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Return list of actors
*
* @returns {vgl.actor[]}
*/
- ////////////////////////////////////////////////////////////////////////////
this.actors = function () {
if (!m_actor) {
return [];
@@ -56864,13 +56325,11 @@ return /******/ (function(modules) { // webpackBootstrap
return [m_actor];
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
createGLLines();
@@ -56880,13 +56339,11 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.buildTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
@@ -56903,11 +56360,9 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.updateTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Destroy
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_this.renderer().contextRenderer().removeActor(m_actor);
m_actor = null;
@@ -56932,7 +56387,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 262 */
+/* 263 */
/***/ (function(module, exports, __webpack_require__) {
var $ = __webpack_require__(1);
@@ -56940,7 +56395,6 @@ return /******/ (function(modules) { // webpackBootstrap
var registerFeature = __webpack_require__(201).registerFeature;
var pointFeature = __webpack_require__(212);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of pointFeature
*
@@ -56948,7 +56402,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.pointFeature
* @returns {geo.gl.pointFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var gl_pointFeature = function (arg) {
'use strict';
if (!(this instanceof gl_pointFeature)) {
@@ -56960,15 +56413,13 @@ return /******/ (function(modules) { // webpackBootstrap
var vgl = __webpack_require__(86);
var transform = __webpack_require__(11);
var util = __webpack_require__(83);
- var object = __webpack_require__(260);
+ var object = __webpack_require__(261);
object.call(this);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_exit = this._exit,
m_actor = null,
@@ -57290,13 +56741,11 @@ return /******/ (function(modules) { // webpackBootstrap
m_mapper.boundsDirtyTimestamp().modified();
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Return list of actors
*
* @returns {vgl.actor[]}
*/
- ////////////////////////////////////////////////////////////////////////////
this.actors = function () {
if (!m_actor) {
return [];
@@ -57304,13 +56753,11 @@ return /******/ (function(modules) { // webpackBootstrap
return [m_actor];
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Return the number of vertices used for each point.
*
* @returns {Number}
*/
- ////////////////////////////////////////////////////////////////////////////
this.verticesPerFeature = function () {
var unit = pointPolygon(0, 0, 1, 1);
return unit.length / 2;
@@ -57391,11 +56838,9 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function () {
var prog = vgl.shaderProgram(),
vertexShader = createVertexShader(),
@@ -57492,13 +56937,11 @@ return /******/ (function(modules) { // webpackBootstrap
m_mapper.setGeometryData(geom);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
if (m_actor) {
@@ -57512,13 +56955,11 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.buildTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
@@ -57541,11 +56982,9 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.updateTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Destroy
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_this.renderer().contextRenderer().removeActor(m_actor);
m_actor = null;
@@ -57565,14 +57004,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 263 */
+/* 264 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
var polygonFeature = __webpack_require__(217);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of polygonFeature
*
@@ -57580,7 +57018,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.polygonFeature
* @returns {geo.gl.polygonFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var gl_polygonFeature = function (arg) {
'use strict';
if (!(this instanceof gl_polygonFeature)) {
@@ -57590,18 +57027,16 @@ return /******/ (function(modules) { // webpackBootstrap
polygonFeature.call(this, arg);
var vgl = __webpack_require__(86);
- var earcut = __webpack_require__(264);
+ var earcut = __webpack_require__(265);
var transform = __webpack_require__(11);
var util = __webpack_require__(83);
- var object = __webpack_require__(260);
+ var object = __webpack_require__(261);
object.call(this);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this,
s_exit = this._exit,
m_actor = vgl.actor(),
@@ -57833,12 +57268,10 @@ return /******/ (function(modules) { // webpackBootstrap
}
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
* @memberof geo.gl.polygonFeature
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function (arg) {
var prog = vgl.shaderProgram(),
posAttr = vgl.vertexAttribute('pos'),
@@ -57882,14 +57315,12 @@ return /******/ (function(modules) { // webpackBootstrap
s_init.call(m_this, arg);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Build
*
* @memberof geo.gl.polygonFeature
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
createGLPolygons(m_this.dataTime().getMTime() < m_this.buildTime().getMTime() && m_geometry);
@@ -57900,14 +57331,12 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.buildTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*
* @memberof geo.gl.polygonFeature
* @override
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function (opts) {
if (opts && opts.mayDelay) {
m_updateAnimFrameRef = m_this.layer().map().scheduleAnimationFrame(m_this._update);
@@ -57929,12 +57358,10 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.updateTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Destroy
* @memberof geo.gl.polygonFeature
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_this.renderer().contextRenderer().removeActor(m_actor);
s_exit();
@@ -57952,7 +57379,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 264 */
+/* 265 */
/***/ (function(module, exports) {
'use strict';
@@ -58602,14 +58029,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 265 */
+/* 266 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
var quadFeature = __webpack_require__(222);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class quadFeature
*
@@ -58618,7 +58044,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.quadFeature
* @returns {geo.gl.quadFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var gl_quadFeature = function (arg) {
'use strict';
if (!(this instanceof gl_quadFeature)) {
@@ -58628,7 +58053,7 @@ return /******/ (function(modules) { // webpackBootstrap
var $ = __webpack_require__(1);
var vgl = __webpack_require__(86);
- var object = __webpack_require__(260);
+ var object = __webpack_require__(261);
object.call(this);
@@ -58748,11 +58173,9 @@ return /******/ (function(modules) { // webpackBootstrap
m_glColorCompileTimestamp.modified();
}
- ////////////////////////////////////////////////////////////////////////////
/**
* Build this feature
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
var mapper, mat, prog, srctex, unicrop, geom;
@@ -58968,11 +58391,9 @@ return /******/ (function(modules) { // webpackBootstrap
mapper.undoBindVertexData(renderState);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
if (m_this.buildTime().getMTime() <= m_this.dataTime().getMTime() ||
@@ -58990,20 +58411,16 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.updateTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function () {
s_init.call(m_this, arg);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Destroy
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
if (m_actor_image) {
m_this.renderer().contextRenderer().removeActor(m_actor_image);
@@ -59036,7 +58453,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 266 */
+/* 267 */
/***/ (function(module, exports, __webpack_require__) {
var registerLayerAdjustment = __webpack_require__(201).registerLayerAdjustment;
@@ -59140,31 +58557,30 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 267 */
+/* 268 */
/***/ (function(module, exports, __webpack_require__) {
/**
* @namespace geo.canvas
*/
module.exports = {
- canvasRenderer: __webpack_require__(268),
- heatmapFeature: __webpack_require__(269),
- lineFeature: __webpack_require__(271),
- pixelmapFeature: __webpack_require__(272),
- quadFeature: __webpack_require__(273),
- tileLayer: __webpack_require__(274)
+ canvasRenderer: __webpack_require__(269),
+ heatmapFeature: __webpack_require__(270),
+ lineFeature: __webpack_require__(272),
+ pixelmapFeature: __webpack_require__(273),
+ quadFeature: __webpack_require__(274),
+ tileLayer: __webpack_require__(275)
};
/***/ }),
-/* 268 */
+/* 269 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerRenderer = __webpack_require__(201).registerRenderer;
var renderer = __webpack_require__(202);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class canvasRenderer
*
@@ -59173,7 +58589,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param canvas
* @returns {geo.canvas.canvasRenderer}
*/
- //////////////////////////////////////////////////////////////////////////////
var canvasRenderer = function (arg) {
'use strict';
@@ -59194,20 +58609,16 @@ return /******/ (function(modules) { // webpackBootstrap
m_clearCanvas = arg;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get API used by the renderer
*/
- ////////////////////////////////////////////////////////////////////////////
this.api = function () {
return 'canvas';
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function () {
if (m_this.initialized()) {
return m_this;
@@ -59230,11 +58641,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Handle resize event
*/
- ////////////////////////////////////////////////////////////////////////////
this._resize = function (x, y, w, h) {
m_this.canvas().attr('width', w);
m_this.canvas().attr('height', h);
@@ -59243,21 +58652,17 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Render
*/
- ////////////////////////////////////////////////////////////////////////////
this._render = function () {
m_this.layer().map().scheduleAnimationFrame(this._renderFrame);
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Render during an animation frame callback.
*/
- ////////////////////////////////////////////////////////////////////////////
this._renderFrame = function () {
var layer = m_this.layer(),
map = layer.map(),
@@ -59278,11 +58683,9 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Exit
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_this.canvas().remove();
s_exit();
@@ -59335,7 +58738,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 269 */
+/* 270 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
@@ -59343,7 +58746,6 @@ return /******/ (function(modules) { // webpackBootstrap
var heatmapFeature = __webpack_require__(231);
var timestamp = __webpack_require__(209);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class heatmapFeature
* Inspired from
@@ -59354,7 +58756,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.heatmapFeature
* @returns {canvas_heatmapFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var canvas_heatmapFeature = function (arg) {
'use strict';
@@ -59362,15 +58763,13 @@ return /******/ (function(modules) { // webpackBootstrap
return new canvas_heatmapFeature(arg);
}
heatmapFeature.call(this, arg);
- var object = __webpack_require__(270);
+ var object = __webpack_require__(271);
object.call(this);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var geo_event = __webpack_require__(9);
var m_this = this,
@@ -59384,12 +58783,10 @@ return /******/ (function(modules) { // webpackBootstrap
s_update = this._update,
m_renderTime = timestamp();
- ////////////////////////////////////////////////////////////////////////////
/**
* Meta functions for converting from geojs styles to canvas.
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
this._convertColor = function (c) {
var color;
if (c.hasOwnProperty('r') &&
@@ -59402,12 +58799,10 @@ return /******/ (function(modules) { // webpackBootstrap
return color;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Compute gradient (color lookup table)
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._computeGradient = function () {
var canvas, stop, context2d, gradient, colors;
@@ -59433,12 +58828,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Create circle for each data point
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._createCircle = function () {
var circle, ctx, r, r2, blur, gaussian;
r = m_this.style('radius');
@@ -59497,12 +58890,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Compute color for each pixel on the screen
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._colorize = function (pixels, gradient) {
var grad = new Uint32Array(gradient.buffer),
pixlen = pixels.length,
@@ -59523,7 +58914,6 @@ return /******/ (function(modules) { // webpackBootstrap
pixels.set(m_typedClampedBuffer);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Render individual data points on the canvas.
* @protected
@@ -59532,7 +58922,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {Array} data the main data array.
* @param {number} radius the sum of radius and blurRadius.
*/
- ////////////////////////////////////////////////////////////////////////////
this._renderPoints = function (context2d, map, data, radius) {
var position = m_this.gcsPosition(),
intensityFunc = m_this.intensity(),
@@ -59553,7 +58942,6 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Render data points on the canvas by binning.
* @protected
@@ -59563,7 +58951,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @param {number} radius the sum of radius and blurRadius.
* @param {number} binSize size of the bins in pixels.
*/
- ////////////////////////////////////////////////////////////////////////////
this._renderBinnedData = function (context2d, map, data, radius, binSize) {
var position = m_this.gcsPosition(),
intensityFunc = m_this.intensity(),
@@ -59653,14 +59040,12 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Render the data on the canvas, then colorize the resulting opacity map.
* @protected
* @param {object} context2d the canvas context to draw in.
* @param {object} map the parent map object.
*/
- ////////////////////////////////////////////////////////////////////////////
this._renderOnCanvas = function (context2d, map) {
if (m_renderTime.getMTime() < m_this.buildTime().getMTime()) {
@@ -59721,12 +59106,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function () {
s_init.call(m_this, arg);
@@ -59735,12 +59118,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
if (m_this.buildTime().getMTime() <= m_this.dataTime().getMTime() ||
@@ -59751,22 +59132,18 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update the css transform for the layer as part of an animation frame.
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._setTransform = function () {
m_this.layer().canvas()[0].style.transform = m_heatMapTransform;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Animate pan (and zoom)
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._animatePan = function (e) {
var map = m_this.layer().map(),
@@ -59815,12 +59192,10 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Destroy
* @protected
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
s_exit.call(m_this);
};
@@ -59837,19 +59212,17 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 270 */
+/* 271 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var sceneObject = __webpack_require__(208);
- //////////////////////////////////////////////////////////////////////////////
/**
* Canvas specific subclass of object which rerenders when the object is drawn.
* @class geo.canvas.object
* @extends geo.sceneObject
*/
- //////////////////////////////////////////////////////////////////////////////
var canvas_object = function (arg) {
'use strict';
@@ -59872,11 +59245,9 @@ return /******/ (function(modules) { // webpackBootstrap
this._renderOnCanvas = function () {
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Redraw the object.
*/
- ////////////////////////////////////////////////////////////////////////////
this.draw = function () {
m_this._update();
m_this.renderer()._render();
@@ -59893,14 +59264,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 271 */
+/* 272 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
var lineFeature = __webpack_require__(206);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class lineFeature
*
@@ -59909,34 +59279,29 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.canvas.object
* @returns {geo.canvas.lineFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var canvas_lineFeature = function (arg) {
'use strict';
if (!(this instanceof canvas_lineFeature)) {
return new canvas_lineFeature(arg);
}
- var object = __webpack_require__(270);
+ var object = __webpack_require__(271);
arg = arg || {};
lineFeature.call(this, arg);
object.call(this);
- ////////////////////////////////////////////////////////////////////////////
/**
* @private
*/
- ////////////////////////////////////////////////////////////////////////////
var m_this = this;
- ////////////////////////////////////////////////////////////////////////////
/**
* Render the data on the canvas.
* @protected
* @param {object} context2d the canvas context to draw in.
* @param {object} map the parent map object.
*/
- ////////////////////////////////////////////////////////////////////////////
this._renderOnCanvas = function (context2d, map) {
var data = m_this.data(),
posFunc = m_this.position(),
@@ -60015,14 +59380,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 272 */
+/* 273 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
var pixelmapFeature = __webpack_require__(241);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class pixelmapFeature
*
@@ -60031,7 +59395,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.pixelmapFeature
* @returns {canvas_pixelmapFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var canvas_pixelmapFeature = function (arg) {
'use strict';
@@ -60040,7 +59403,7 @@ return /******/ (function(modules) { // webpackBootstrap
}
pixelmapFeature.call(this, arg);
- var object = __webpack_require__(270);
+ var object = __webpack_require__(271);
object.call(this);
this._init(arg);
@@ -60055,14 +59418,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 273 */
+/* 274 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var registerFeature = __webpack_require__(201).registerFeature;
var quadFeature = __webpack_require__(222);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class quadFeature
*
@@ -60071,7 +59433,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.quadFeature
* @returns {geo.canvas.quadFeature}
*/
- //////////////////////////////////////////////////////////////////////////////
var canvas_quadFeature = function (arg) {
'use strict';
@@ -60080,7 +59441,7 @@ return /******/ (function(modules) { // webpackBootstrap
}
quadFeature.call(this, arg);
- var object = __webpack_require__(270);
+ var object = __webpack_require__(271);
object.call(this);
var $ = __webpack_require__(1);
@@ -60091,11 +59452,9 @@ return /******/ (function(modules) { // webpackBootstrap
s_update = this._update,
m_quads;
- ////////////////////////////////////////////////////////////////////////////
/**
* Build this feature
*/
- ////////////////////////////////////////////////////////////////////////////
this._build = function () {
if (!m_this.position()) {
return;
@@ -60167,11 +59526,9 @@ return /******/ (function(modules) { // webpackBootstrap
this._renderColorQuads(context, map);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Update
*/
- ////////////////////////////////////////////////////////////////////////////
this._update = function () {
s_update.call(m_this);
if (m_this.buildTime().getMTime() <= m_this.dataTime().getMTime() ||
@@ -60182,20 +59539,16 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.updateTime().modified();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Initialize
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function () {
s_init.call(m_this, arg);
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Destroy
*/
- ////////////////////////////////////////////////////////////////////////////
this._exit = function () {
s_exit.call(m_this);
@@ -60221,7 +59574,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 274 */
+/* 275 */
/***/ (function(module, exports, __webpack_require__) {
var registerLayerAdjustment = __webpack_require__(201).registerLayerAdjustment;
@@ -60321,27 +59674,27 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 275 */
+/* 276 */
/***/ (function(module, exports, __webpack_require__) {
/**
* @namespace geo.gui
*/
module.exports = {
- domWidget: __webpack_require__(276),
- legendWidget: __webpack_require__(278),
- sliderWidget: __webpack_require__(280),
- svgWidget: __webpack_require__(279),
+ domWidget: __webpack_require__(277),
+ legendWidget: __webpack_require__(279),
+ sliderWidget: __webpack_require__(281),
+ svgWidget: __webpack_require__(280),
uiLayer: __webpack_require__(236),
- widget: __webpack_require__(277)
+ widget: __webpack_require__(278)
};
/***/ }),
-/* 276 */
+/* 277 */
/***/ (function(module, exports, __webpack_require__) {
- var widget = __webpack_require__(277);
+ var widget = __webpack_require__(278);
var inherit = __webpack_require__(8);
var registerWidget = __webpack_require__(201).registerWidget;
@@ -60356,13 +59709,11 @@ return /******/ (function(modules) { // webpackBootstrap
var m_this = this,
m_default_canvas = 'div';
- ////////////////////////////////////////////////////////////////////////////
/**
* Initializes DOM Widget.
* Sets the canvas for the widget, does parent/child relationship management,
* appends it to it's parent and handles any positioning logic.
*/
- ////////////////////////////////////////////////////////////////////////////
this._init = function () {
if (arg.hasOwnProperty('parent')) {
arg.parent.addChild(m_this);
@@ -60378,12 +59729,10 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.reposition();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Creates the widget canvas.
* This is just a simple DOM element (based on args.el, or defaults to a div)
*/
- ////////////////////////////////////////////////////////////////////////////
this._createCanvas = function () {
m_this.canvas(document.createElement(arg.el || m_default_canvas));
};
@@ -60398,13 +59747,12 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 277 */
+/* 278 */
/***/ (function(module, exports, __webpack_require__) {
var inherit = __webpack_require__(8);
var sceneObject = __webpack_require__(208);
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class widget
*
@@ -60412,7 +59760,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends {geo.sceneObject}
* @returns {geo.gui.widget}
*/
- //////////////////////////////////////////////////////////////////////////////
var widget = function (arg) {
'use strict';
if (!(this instanceof widget)) {
@@ -60448,13 +59795,11 @@ return /******/ (function(modules) { // webpackBootstrap
s_exit();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Create feature give a name
*
* @returns {geo.Feature} Will return a new feature
*/
- ////////////////////////////////////////////////////////////////////////////
this._createFeature = function (featureName, arg) {
var newFeature = createFeature(
@@ -60465,40 +59810,32 @@ return /******/ (function(modules) { // webpackBootstrap
return newFeature;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Delete feature
*/
- ////////////////////////////////////////////////////////////////////////////
this._deleteFeature = function (feature) {
m_this.removeChild(feature);
feature._exit();
return m_this;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Return the layer associated with this widget.
*/
- ////////////////////////////////////////////////////////////////////////////
this.layer = function () {
return m_layer;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Create the canvas this widget will operate on.
*/
- ////////////////////////////////////////////////////////////////////////////
this._createCanvas = function () {
throw new Error('Must be defined in derived classes');
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get/Set the canvas for the widget
*/
- ////////////////////////////////////////////////////////////////////////////
this.canvas = function (val) {
if (val === undefined) {
return m_canvas;
@@ -60507,22 +59844,18 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Appends a child to the widget
* The widget determines how to append itself to a parent, the parent can either
* be another widget, or the UI Layer.
*/
- ////////////////////////////////////////////////////////////////////////////
this._appendChild = function () {
m_this.parentCanvas().appendChild(m_this.canvas());
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Get the parent canvas (top level widgets define their layer as their parent canvas)
*/
- ////////////////////////////////////////////////////////////////////////////
this.parentCanvas = function () {
if (m_this.parent === undefined) {
return m_this.layer().canvas();
@@ -60531,12 +59864,10 @@ return /******/ (function(modules) { // webpackBootstrap
}
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Gets the CSS positioning that a widget should be placed at.
* { top: 0, left: 0 } by default.
*/
- ////////////////////////////////////////////////////////////////////////////
this.position = function (pos) {
if (pos !== undefined) {
arg.position = pos;
@@ -60563,14 +59894,12 @@ return /******/ (function(modules) { // webpackBootstrap
return arg.position;
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Repositions a widget based on the argument passed, or calling position on
* the widget itself.
* @param {object} position A position with the form:
* { top: m, left: n }
*/
- ////////////////////////////////////////////////////////////////////////////
this.reposition = function (position) {
position = position || m_this.position();
m_this.canvas().style.position = 'absolute';
@@ -60593,11 +59922,9 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this.reposition();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Determines whether or not the widget is completely within the viewport.
*/
- ////////////////////////////////////////////////////////////////////////////
this.isInViewport = function () {
var position = m_this.position();
var layer = m_this.layer();
@@ -60618,14 +59945,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 278 */
+/* 279 */
/***/ (function(module, exports, __webpack_require__) {
- var svgWidget = __webpack_require__(279);
+ var svgWidget = __webpack_require__(280);
var inherit = __webpack_require__(8);
var registerWidget = __webpack_require__(201).registerWidget;
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class legendWidget
*
@@ -60633,7 +59959,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends geo.gui.svgWidget
* @returns {geo.gui.legendWidget}
*/
- //////////////////////////////////////////////////////////////////////////////
var legendWidget = function (arg) {
'use strict';
if (!(this instanceof legendWidget)) {
@@ -60655,7 +59980,6 @@ return /******/ (function(modules) { // webpackBootstrap
s_createCanvas = this._createCanvas,
s_appendChild = this._appendChild;
- //////////////////////////////////////////////////////////////////////////////
/**
* Get or set the category array associated with
* the legend. Each element of this array is
@@ -60681,7 +60005,6 @@ return /******/ (function(modules) { // webpackBootstrap
*
* @param {object[]?} categories The categories to display
*/
- //////////////////////////////////////////////////////////////////////////////
this.categories = function (arg) {
if (arg === undefined) {
return m_categories.slice();
@@ -60697,12 +60020,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- //////////////////////////////////////////////////////////////////////////////
/**
* Get the widget's size
* @return {{width: number, height: number}} The size in pixels
*/
- //////////////////////////////////////////////////////////////////////////////
this.size = function () {
var width = 1, height;
var test = d3.select(m_this.canvas()).append('text')
@@ -60721,11 +60042,9 @@ return /******/ (function(modules) { // webpackBootstrap
};
};
- //////////////////////////////////////////////////////////////////////////////
/**
* Redraw the legend
*/
- //////////////////////////////////////////////////////////////////////////////
this.draw = function () {
m_this._init();
@@ -60819,12 +60138,10 @@ return /******/ (function(modules) { // webpackBootstrap
return m_this;
};
- //////////////////////////////////////////////////////////////////////////////
/**
* Get scales for the x and y axis for the current size.
* @private
*/
- //////////////////////////////////////////////////////////////////////////////
this._scale = function () {
return {
x: d3.scale.linear()
@@ -60836,13 +60153,11 @@ return /******/ (function(modules) { // webpackBootstrap
};
};
- //////////////////////////////////////////////////////////////////////////////
/**
* Private initialization. Creates the widget's DOM container and internal
* variables.
* @private
*/
- //////////////////////////////////////////////////////////////////////////////
this._init = function () {
// adding categories redraws the entire thing by calling _init, see
// the m_top.remove() line below
@@ -60910,14 +60225,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 279 */
+/* 280 */
/***/ (function(module, exports, __webpack_require__) {
- var domWidget = __webpack_require__(276);
+ var domWidget = __webpack_require__(277);
var inherit = __webpack_require__(8);
var registerWidget = __webpack_require__(201).registerWidget;
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class geo.gui.svgWidget
*
@@ -60934,7 +60248,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @returns {geo.gui.svgWidget}
*
*/
- //////////////////////////////////////////////////////////////////////////////
var svgWidget = function (arg) {
'use strict';
if (!(this instanceof svgWidget)) {
@@ -60943,7 +60256,7 @@ return /******/ (function(modules) { // webpackBootstrap
domWidget.call(this, arg);
- var d3Renderer = __webpack_require__(254);
+ var d3Renderer = __webpack_require__(255);
var m_this = this,
m_renderer = null;
@@ -60966,13 +60279,11 @@ return /******/ (function(modules) { // webpackBootstrap
m_this.reposition();
};
- ////////////////////////////////////////////////////////////////////////////
/**
* Creates the canvas for the svg widget.
* This directly uses the {@link geo.d3.d3Renderer} as a helper to do all of the heavy
* lifting.
*/
- ////////////////////////////////////////////////////////////////////////////
this._createCanvas = function (d3Parent) {
var rendererOpts = {
layer: m_this.layer(),
@@ -61001,14 +60312,13 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ }),
-/* 280 */
+/* 281 */
/***/ (function(module, exports, __webpack_require__) {
- var svgWidget = __webpack_require__(279);
+ var svgWidget = __webpack_require__(280);
var inherit = __webpack_require__(8);
var registerWidget = __webpack_require__(201).registerWidget;
- //////////////////////////////////////////////////////////////////////////////
/**
* Create a new instance of class sliderWidget
*
@@ -61016,7 +60326,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @extends {geo.gui.svgWidget}
* @returns {geo.gui.sliderWidget}
*/
- //////////////////////////////////////////////////////////////////////////////
var sliderWidget = function (arg) {
'use strict';
if (!(this instanceof sliderWidget)) {
@@ -61056,7 +60365,6 @@ return /******/ (function(modules) { // webpackBootstrap
black: '#505050'
};
- //////////////////////////////////////////////////////////////////////////////
/**
* Add an icon from a path string. Returns a d3 group element.
*
@@ -61069,7 +60377,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @returns {object}
* @private
*/
- //////////////////////////////////////////////////////////////////////////////
function put_icon(icon, base, cx, cy, size) {
var g = base.append('g');
@@ -61093,7 +60400,6 @@ return /******/ (function(modules) { // webpackBootstrap
return {width: m_width, height: m_height};
};
- //////////////////////////////////////////////////////////////////////////////
/**
* Initialize the slider widget in the map.
*
@@ -61101,7 +60407,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @returns {geo.gui.sliderWidget}
* @private
*/
- //////////////////////////////////////////////////////////////////////////////
this._init = function () {
s_createCanvas();
s_appendChild();
@@ -61306,7 +60611,6 @@ return /******/ (function(modules) { // webpackBootstrap
m_this._update();
};
- //////////////////////////////////////////////////////////////////////////////
/**
* Removes the slider element from the map and unbinds all handlers.
*
@@ -61314,14 +60618,12 @@ return /******/ (function(modules) { // webpackBootstrap
* @returns {geo.gui.sliderWidget}
* @private
*/
- //////////////////////////////////////////////////////////////////////////////
this._exit = function () {
m_group.remove();
m_this.layer().geoOff(geo_event.zoom);
s_exit();
};
- //////////////////////////////////////////////////////////////////////////////
/**
* Update the slider widget state in reponse to map changes. I.e. zoom
* range changes.
@@ -61330,7 +60632,6 @@ return /******/ (function(modules) { // webpackBootstrap
* @returns {geo.gui.sliderWidget}
* @private
*/
- //////////////////////////////////////////////////////////////////////////////
this._update = function (obj) {
var map = m_this.layer().map(),
zoomRange = map.zoomRange(),
diff --git a/package-lock.json b/package-lock.json
index fb3b8d187c..c77b532bf2 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,6 +1,6 @@
{
"name": "geojs",
- "version": "0.12.1",
+ "version": "0.12.2",
"lockfileVersion": 1,
"dependencies": {
"abbrev": {
diff --git a/package.json b/package.json
index 1c5bd69ae5..3b383b262b 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "geojs",
- "version": "0.12.1",
+ "version": "0.12.2",
"description": "JavaScript Geo visualization and Analysis Library",
"homepage": "https://github.com/OpenGeoscience/geojs",
"license": "Apache-2.0",