Rename _ol_layer_Vector_ to VectorLayer
This commit is contained in:
@@ -22,7 +22,7 @@ import Polygon, {fromCircle, makeRegular} from '../geom/Polygon.js';
|
||||
import DrawEventType from '../interaction/DrawEventType.js';
|
||||
import _ol_interaction_Pointer_ from '../interaction/Pointer.js';
|
||||
import _ol_interaction_Property_ from '../interaction/Property.js';
|
||||
import _ol_layer_Vector_ from '../layer/Vector.js';
|
||||
import VectorLayer from '../layer/Vector.js';
|
||||
import _ol_source_Vector_ from '../source/Vector.js';
|
||||
import _ol_style_Style_ from '../style/Style.js';
|
||||
|
||||
@@ -249,7 +249,7 @@ var Draw = function(options) {
|
||||
* @type {ol.layer.Vector}
|
||||
* @private
|
||||
*/
|
||||
this.overlay_ = new _ol_layer_Vector_({
|
||||
this.overlay_ = new VectorLayer({
|
||||
source: new _ol_source_Vector_({
|
||||
useSpatialIndex: false,
|
||||
wrapX: options.wrapX ? options.wrapX : false
|
||||
|
||||
@@ -13,7 +13,7 @@ import Point from '../geom/Point.js';
|
||||
import {fromExtent as polygonFromExtent} from '../geom/Polygon.js';
|
||||
import _ol_interaction_ExtentEventType_ from '../interaction/ExtentEventType.js';
|
||||
import _ol_interaction_Pointer_ from '../interaction/Pointer.js';
|
||||
import _ol_layer_Vector_ from '../layer/Vector.js';
|
||||
import VectorLayer from '../layer/Vector.js';
|
||||
import _ol_source_Vector_ from '../source/Vector.js';
|
||||
import _ol_style_Style_ from '../style/Style.js';
|
||||
|
||||
@@ -93,7 +93,7 @@ var _ol_interaction_Extent_ = function(opt_options) {
|
||||
* @type {ol.layer.Vector}
|
||||
* @private
|
||||
*/
|
||||
this.extentOverlay_ = new _ol_layer_Vector_({
|
||||
this.extentOverlay_ = new VectorLayer({
|
||||
source: new _ol_source_Vector_({
|
||||
useSpatialIndex: false,
|
||||
wrapX: !!opt_options.wrapX
|
||||
@@ -108,7 +108,7 @@ var _ol_interaction_Extent_ = function(opt_options) {
|
||||
* @type {ol.layer.Vector}
|
||||
* @private
|
||||
*/
|
||||
this.vertexOverlay_ = new _ol_layer_Vector_({
|
||||
this.vertexOverlay_ = new VectorLayer({
|
||||
source: new _ol_source_Vector_({
|
||||
useSpatialIndex: false,
|
||||
wrapX: !!opt_options.wrapX
|
||||
|
||||
@@ -18,7 +18,7 @@ import GeometryType from '../geom/GeometryType.js';
|
||||
import Point from '../geom/Point.js';
|
||||
import _ol_interaction_ModifyEventType_ from '../interaction/ModifyEventType.js';
|
||||
import _ol_interaction_Pointer_ from '../interaction/Pointer.js';
|
||||
import _ol_layer_Vector_ from '../layer/Vector.js';
|
||||
import VectorLayer from '../layer/Vector.js';
|
||||
import _ol_source_Vector_ from '../source/Vector.js';
|
||||
import VectorEventType from '../source/VectorEventType.js';
|
||||
import RBush from '../structs/RBush.js';
|
||||
@@ -157,7 +157,7 @@ var _ol_interaction_Modify_ = function(options) {
|
||||
* @type {ol.layer.Vector}
|
||||
* @private
|
||||
*/
|
||||
this.overlay_ = new _ol_layer_Vector_({
|
||||
this.overlay_ = new VectorLayer({
|
||||
source: new _ol_source_Vector_({
|
||||
useSpatialIndex: false,
|
||||
wrapX: !!options.wrapX
|
||||
|
||||
@@ -10,7 +10,7 @@ import _ol_events_condition_ from '../events/condition.js';
|
||||
import {TRUE} from '../functions.js';
|
||||
import GeometryType from '../geom/GeometryType.js';
|
||||
import Interaction from '../interaction/Interaction.js';
|
||||
import _ol_layer_Vector_ from '../layer/Vector.js';
|
||||
import VectorLayer from '../layer/Vector.js';
|
||||
import _ol_obj_ from '../obj.js';
|
||||
import _ol_source_Vector_ from '../source/Vector.js';
|
||||
import _ol_style_Style_ from '../style/Style.js';
|
||||
@@ -87,7 +87,7 @@ var _ol_interaction_Select_ = function(opt_options) {
|
||||
*/
|
||||
this.hitTolerance_ = options.hitTolerance ? options.hitTolerance : 0;
|
||||
|
||||
var featureOverlay = new _ol_layer_Vector_({
|
||||
var featureOverlay = new VectorLayer({
|
||||
source: new _ol_source_Vector_({
|
||||
useSpatialIndex: false,
|
||||
features: options.features,
|
||||
|
||||
@@ -5,7 +5,7 @@ import _ol_events_ from '../events.js';
|
||||
import {inherits} from '../index.js';
|
||||
import BaseObject from '../Object.js';
|
||||
import {createCanvasContext2D} from '../dom.js';
|
||||
import _ol_layer_Vector_ from '../layer/Vector.js';
|
||||
import VectorLayer from '../layer/Vector.js';
|
||||
import {clamp} from '../math.js';
|
||||
import _ol_obj_ from '../obj.js';
|
||||
import RenderEventType from '../render/EventType.js';
|
||||
@@ -54,7 +54,7 @@ var Heatmap = function(opt_options) {
|
||||
delete baseOptions.blur;
|
||||
delete baseOptions.shadow;
|
||||
delete baseOptions.weight;
|
||||
_ol_layer_Vector_.call(this, /** @type {olx.layer.VectorOptions} */ (baseOptions));
|
||||
VectorLayer.call(this, /** @type {olx.layer.VectorOptions} */ (baseOptions));
|
||||
|
||||
/**
|
||||
* @private
|
||||
@@ -136,7 +136,7 @@ var Heatmap = function(opt_options) {
|
||||
_ol_events_.listen(this, RenderEventType.RENDER, this.handleRender_, this);
|
||||
};
|
||||
|
||||
inherits(Heatmap, _ol_layer_Vector_);
|
||||
inherits(Heatmap, VectorLayer);
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -31,7 +31,7 @@ var Property = {
|
||||
* @param {olx.layer.VectorOptions=} opt_options Options.
|
||||
* @api
|
||||
*/
|
||||
var _ol_layer_Vector_ = function(opt_options) {
|
||||
var VectorLayer = function(opt_options) {
|
||||
var options = opt_options ?
|
||||
opt_options : /** @type {olx.layer.VectorOptions} */ ({});
|
||||
|
||||
@@ -101,13 +101,13 @@ var _ol_layer_Vector_ = function(opt_options) {
|
||||
|
||||
};
|
||||
|
||||
inherits(_ol_layer_Vector_, _ol_layer_Layer_);
|
||||
inherits(VectorLayer, _ol_layer_Layer_);
|
||||
|
||||
|
||||
/**
|
||||
* @return {boolean} Declutter.
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.getDeclutter = function() {
|
||||
VectorLayer.prototype.getDeclutter = function() {
|
||||
return this.declutter_;
|
||||
};
|
||||
|
||||
@@ -115,7 +115,7 @@ _ol_layer_Vector_.prototype.getDeclutter = function() {
|
||||
/**
|
||||
* @param {boolean} declutter Declutter.
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.setDeclutter = function(declutter) {
|
||||
VectorLayer.prototype.setDeclutter = function(declutter) {
|
||||
this.declutter_ = declutter;
|
||||
};
|
||||
|
||||
@@ -123,7 +123,7 @@ _ol_layer_Vector_.prototype.setDeclutter = function(declutter) {
|
||||
/**
|
||||
* @return {number|undefined} Render buffer.
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.getRenderBuffer = function() {
|
||||
VectorLayer.prototype.getRenderBuffer = function() {
|
||||
return this.renderBuffer_;
|
||||
};
|
||||
|
||||
@@ -132,7 +132,7 @@ _ol_layer_Vector_.prototype.getRenderBuffer = function() {
|
||||
* @return {function(ol.Feature, ol.Feature): number|null|undefined} Render
|
||||
* order.
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.getRenderOrder = function() {
|
||||
VectorLayer.prototype.getRenderOrder = function() {
|
||||
return (/** @type {ol.RenderOrderFunction|null|undefined} */ this.get(Property.RENDER_ORDER));
|
||||
};
|
||||
|
||||
@@ -143,7 +143,7 @@ _ol_layer_Vector_.prototype.getRenderOrder = function() {
|
||||
* @return {ol.source.Vector} Source.
|
||||
* @api
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.getSource;
|
||||
VectorLayer.prototype.getSource;
|
||||
|
||||
|
||||
/**
|
||||
@@ -153,7 +153,7 @@ _ol_layer_Vector_.prototype.getSource;
|
||||
* Layer style.
|
||||
* @api
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.getStyle = function() {
|
||||
VectorLayer.prototype.getStyle = function() {
|
||||
return this.style_;
|
||||
};
|
||||
|
||||
@@ -163,7 +163,7 @@ _ol_layer_Vector_.prototype.getStyle = function() {
|
||||
* @return {ol.StyleFunction|undefined} Layer style function.
|
||||
* @api
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.getStyleFunction = function() {
|
||||
VectorLayer.prototype.getStyleFunction = function() {
|
||||
return this.styleFunction_;
|
||||
};
|
||||
|
||||
@@ -172,7 +172,7 @@ _ol_layer_Vector_.prototype.getStyleFunction = function() {
|
||||
* @return {boolean} Whether the rendered layer should be updated while
|
||||
* animating.
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.getUpdateWhileAnimating = function() {
|
||||
VectorLayer.prototype.getUpdateWhileAnimating = function() {
|
||||
return this.updateWhileAnimating_;
|
||||
};
|
||||
|
||||
@@ -181,7 +181,7 @@ _ol_layer_Vector_.prototype.getUpdateWhileAnimating = function() {
|
||||
* @return {boolean} Whether the rendered layer should be updated while
|
||||
* interacting.
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.getUpdateWhileInteracting = function() {
|
||||
VectorLayer.prototype.getUpdateWhileInteracting = function() {
|
||||
return this.updateWhileInteracting_;
|
||||
};
|
||||
|
||||
@@ -190,7 +190,7 @@ _ol_layer_Vector_.prototype.getUpdateWhileInteracting = function() {
|
||||
* @param {ol.RenderOrderFunction|null|undefined} renderOrder
|
||||
* Render order.
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.setRenderOrder = function(renderOrder) {
|
||||
VectorLayer.prototype.setRenderOrder = function(renderOrder) {
|
||||
this.set(Property.RENDER_ORDER, renderOrder);
|
||||
};
|
||||
|
||||
@@ -206,7 +206,7 @@ _ol_layer_Vector_.prototype.setRenderOrder = function(renderOrder) {
|
||||
* style Layer style.
|
||||
* @api
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.setStyle = function(style) {
|
||||
VectorLayer.prototype.setStyle = function(style) {
|
||||
this.style_ = style !== undefined ? style : _ol_style_Style_.defaultFunction;
|
||||
this.styleFunction_ = style === null ?
|
||||
undefined : _ol_style_Style_.createFunction(this.style_);
|
||||
@@ -217,9 +217,9 @@ _ol_layer_Vector_.prototype.setStyle = function(style) {
|
||||
/**
|
||||
* @return {ol.layer.VectorRenderType|string} The render mode.
|
||||
*/
|
||||
_ol_layer_Vector_.prototype.getRenderMode = function() {
|
||||
VectorLayer.prototype.getRenderMode = function() {
|
||||
return this.renderMode_;
|
||||
};
|
||||
|
||||
|
||||
export default _ol_layer_Vector_;
|
||||
export default VectorLayer;
|
||||
|
||||
@@ -5,7 +5,7 @@ import {inherits} from '../index.js';
|
||||
import LayerType from '../LayerType.js';
|
||||
import {assert} from '../asserts.js';
|
||||
import _ol_layer_TileProperty_ from '../layer/TileProperty.js';
|
||||
import _ol_layer_Vector_ from '../layer/Vector.js';
|
||||
import VectorLayer from '../layer/Vector.js';
|
||||
import _ol_layer_VectorTileRenderType_ from '../layer/VectorTileRenderType.js';
|
||||
import _ol_obj_ from '../obj.js';
|
||||
|
||||
@@ -39,7 +39,7 @@ var _ol_layer_VectorTile_ = function(opt_options) {
|
||||
|
||||
delete baseOptions.preload;
|
||||
delete baseOptions.useInterimTilesOnError;
|
||||
_ol_layer_Vector_.call(this, /** @type {olx.layer.VectorOptions} */ (baseOptions));
|
||||
VectorLayer.call(this, /** @type {olx.layer.VectorOptions} */ (baseOptions));
|
||||
|
||||
this.setPreload(options.preload ? options.preload : 0);
|
||||
this.setUseInterimTilesOnError(options.useInterimTilesOnError ?
|
||||
@@ -54,7 +54,7 @@ var _ol_layer_VectorTile_ = function(opt_options) {
|
||||
|
||||
};
|
||||
|
||||
inherits(_ol_layer_VectorTile_, _ol_layer_Vector_);
|
||||
inherits(_ol_layer_VectorTile_, VectorLayer);
|
||||
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user