Move ol defines from browserfeature.js to ol.js
This commit is contained in:
@@ -2,76 +2,11 @@ goog.provide('ol.BrowserFeature');
|
|||||||
|
|
||||||
goog.require('goog.dom');
|
goog.require('goog.dom');
|
||||||
goog.require('goog.dom.TagName');
|
goog.require('goog.dom.TagName');
|
||||||
goog.require('goog.userAgent');
|
goog.require('ol');
|
||||||
goog.require('ol.dom');
|
goog.require('ol.dom');
|
||||||
goog.require('ol.webgl');
|
goog.require('ol.webgl');
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @define {boolean} Assume touch.
|
|
||||||
*/
|
|
||||||
ol.ASSUME_TOUCH = false;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @define {boolean} Whether to enable canvas.
|
|
||||||
*/
|
|
||||||
ol.ENABLE_CANVAS = true;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @define {boolean} Whether to enable DOM.
|
|
||||||
*/
|
|
||||||
ol.ENABLE_DOM = true;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @define {boolean} Whether to enable rendering of image layers.
|
|
||||||
*/
|
|
||||||
ol.ENABLE_IMAGE = true;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @define {boolean} Whether to enable rendering of tile layers.
|
|
||||||
*/
|
|
||||||
ol.ENABLE_TILE = true;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @define {boolean} Whether to enable rendering of vector layers.
|
|
||||||
*/
|
|
||||||
ol.ENABLE_VECTOR = true;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @define {boolean} Whether to enable WebGL.
|
|
||||||
*/
|
|
||||||
ol.ENABLE_WEBGL = true;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @define {boolean} Whether to support legacy IE (7-8).
|
|
||||||
*/
|
|
||||||
ol.LEGACY_IE_SUPPORT = false;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* The page is loaded using HTTPS.
|
|
||||||
* @const
|
|
||||||
* @type {boolean}
|
|
||||||
*/
|
|
||||||
ol.IS_HTTPS = goog.global.location.protocol === 'https:';
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Whether the current browser is legacy IE
|
|
||||||
* @const
|
|
||||||
* @type {boolean}
|
|
||||||
*/
|
|
||||||
ol.IS_LEGACY_IE = goog.userAgent.IE &&
|
|
||||||
!goog.userAgent.isVersionOrHigher('9.0') && goog.userAgent.VERSION !== '';
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The ratio between physical pixels and device-independent pixels
|
* The ratio between physical pixels and device-independent pixels
|
||||||
* (dips) on the device (`window.devicePixelRatio`).
|
* (dips) on the device (`window.devicePixelRatio`).
|
||||||
|
|||||||
69
src/ol/ol.js
69
src/ol/ol.js
@@ -1,9 +1,76 @@
|
|||||||
|
goog.require('goog.userAgent');
|
||||||
|
|
||||||
goog.provide('ol');
|
goog.provide('ol');
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @define {boolean} Assume touch.
|
||||||
|
*/
|
||||||
|
ol.ASSUME_TOUCH = false;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @define {boolean} Whether to enable canvas.
|
||||||
|
*/
|
||||||
|
ol.ENABLE_CANVAS = true;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @define {boolean} Whether to enable DOM.
|
||||||
|
*/
|
||||||
|
ol.ENABLE_DOM = true;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @define {boolean} Whether to enable rendering of image layers.
|
||||||
|
*/
|
||||||
|
ol.ENABLE_IMAGE = true;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @define {boolean} Whether to enable rendering of tile layers.
|
||||||
|
*/
|
||||||
|
ol.ENABLE_TILE = true;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @define {boolean} Whether to enable rendering of vector layers.
|
||||||
|
*/
|
||||||
|
ol.ENABLE_VECTOR = true;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @define {boolean} Whether to enable WebGL.
|
||||||
|
*/
|
||||||
|
ol.ENABLE_WEBGL = true;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @define {boolean} Whether to support legacy IE (7-8).
|
||||||
|
*/
|
||||||
|
ol.LEGACY_IE_SUPPORT = false;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The page is loaded using HTTPS.
|
||||||
|
* @const
|
||||||
|
* @type {boolean}
|
||||||
|
*/
|
||||||
|
ol.IS_HTTPS = goog.global.location.protocol === 'https:';
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Whether the current browser is legacy IE
|
||||||
|
* @const
|
||||||
|
* @type {boolean}
|
||||||
|
*/
|
||||||
|
ol.IS_LEGACY_IE = goog.userAgent.IE &&
|
||||||
|
!goog.userAgent.isVersionOrHigher('9.0') && goog.userAgent.VERSION !== '';
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ol.inherits is an alias to the goog.inherits function. It is exported
|
* ol.inherits is an alias to the goog.inherits function. It is exported
|
||||||
* for use in non-compiled application code. See ol.exports.
|
* for use in non-compiled application code.
|
||||||
*
|
*
|
||||||
* FIXME: We use a new line to fake the linter. Without the new line the
|
* FIXME: We use a new line to fake the linter. Without the new line the
|
||||||
* linter complains with:
|
* linter complains with:
|
||||||
|
|||||||
Reference in New Issue
Block a user