Named exports from ol/dom
This commit is contained in:
@@ -7,7 +7,7 @@ import {inherits} from '../index.js';
|
||||
import _ol_array_ from '../array.js';
|
||||
import _ol_control_Control_ from '../control/Control.js';
|
||||
import _ol_css_ from '../css.js';
|
||||
import _ol_dom_ from '../dom.js';
|
||||
import {removeNode, replaceNode} from '../dom.js';
|
||||
import _ol_events_ from '../events.js';
|
||||
import _ol_events_EventType_ from '../events/EventType.js';
|
||||
import _ol_layer_Layer_ from '../layer/Layer.js';
|
||||
@@ -273,7 +273,7 @@ _ol_control_Attribution_.prototype.insertLogos_ = function(frameState) {
|
||||
|
||||
for (logo in logoElements) {
|
||||
if (!(logo in logos)) {
|
||||
_ol_dom_.removeNode(logoElements[logo]);
|
||||
removeNode(logoElements[logo]);
|
||||
delete logoElements[logo];
|
||||
}
|
||||
}
|
||||
@@ -321,9 +321,9 @@ _ol_control_Attribution_.prototype.handleClick_ = function(event) {
|
||||
_ol_control_Attribution_.prototype.handleToggle_ = function() {
|
||||
this.element.classList.toggle('ol-collapsed');
|
||||
if (this.collapsed_) {
|
||||
_ol_dom_.replaceNode(this.collapseLabel_, this.label_);
|
||||
replaceNode(this.collapseLabel_, this.label_);
|
||||
} else {
|
||||
_ol_dom_.replaceNode(this.label_, this.collapseLabel_);
|
||||
replaceNode(this.label_, this.collapseLabel_);
|
||||
}
|
||||
this.collapsed_ = !this.collapsed_;
|
||||
};
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
import {inherits, nullFunction} from '../index.js';
|
||||
import _ol_MapEventType_ from '../MapEventType.js';
|
||||
import _ol_Object_ from '../Object.js';
|
||||
import _ol_dom_ from '../dom.js';
|
||||
import {removeNode} from '../dom.js';
|
||||
import _ol_events_ from '../events.js';
|
||||
|
||||
/**
|
||||
@@ -82,7 +82,7 @@ inherits(_ol_control_Control_, _ol_Object_);
|
||||
* @inheritDoc
|
||||
*/
|
||||
_ol_control_Control_.prototype.disposeInternal = function() {
|
||||
_ol_dom_.removeNode(this.element);
|
||||
removeNode(this.element);
|
||||
_ol_Object_.prototype.disposeInternal.call(this);
|
||||
};
|
||||
|
||||
@@ -107,7 +107,7 @@ _ol_control_Control_.prototype.getMap = function() {
|
||||
*/
|
||||
_ol_control_Control_.prototype.setMap = function(map) {
|
||||
if (this.map_) {
|
||||
_ol_dom_.removeNode(this.element);
|
||||
removeNode(this.element);
|
||||
}
|
||||
for (var i = 0, ii = this.listenerKeys.length; i < ii; ++i) {
|
||||
_ol_events_.unlistenByKey(this.listenerKeys[i]);
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
import {inherits} from '../index.js';
|
||||
import _ol_control_Control_ from '../control/Control.js';
|
||||
import _ol_css_ from '../css.js';
|
||||
import _ol_dom_ from '../dom.js';
|
||||
import {replaceNode} from '../dom.js';
|
||||
import _ol_events_ from '../events.js';
|
||||
import _ol_events_EventType_ from '../events/EventType.js';
|
||||
|
||||
@@ -143,10 +143,10 @@ _ol_control_FullScreen_.prototype.handleFullScreenChange_ = function() {
|
||||
var map = this.getMap();
|
||||
if (_ol_control_FullScreen_.isFullScreen()) {
|
||||
button.className = this.cssClassName_ + '-true';
|
||||
_ol_dom_.replaceNode(this.labelActiveNode_, this.labelNode_);
|
||||
replaceNode(this.labelActiveNode_, this.labelNode_);
|
||||
} else {
|
||||
button.className = this.cssClassName_ + '-false';
|
||||
_ol_dom_.replaceNode(this.labelNode_, this.labelActiveNode_);
|
||||
replaceNode(this.labelNode_, this.labelActiveNode_);
|
||||
}
|
||||
if (map) {
|
||||
map.updateSize();
|
||||
|
||||
@@ -14,7 +14,7 @@ import _ol_ViewProperty_ from '../ViewProperty.js';
|
||||
import _ol_control_Control_ from '../control/Control.js';
|
||||
import _ol_coordinate_ from '../coordinate.js';
|
||||
import _ol_css_ from '../css.js';
|
||||
import _ol_dom_ from '../dom.js';
|
||||
import {replaceNode} from '../dom.js';
|
||||
import _ol_events_ from '../events.js';
|
||||
import _ol_events_EventType_ from '../events/EventType.js';
|
||||
import {containsExtent, getBottomLeft, getBottomRight, getTopLeft, getTopRight, scaleFromCenter} from '../extent.js';
|
||||
@@ -492,9 +492,9 @@ _ol_control_OverviewMap_.prototype.handleClick_ = function(event) {
|
||||
_ol_control_OverviewMap_.prototype.handleToggle_ = function() {
|
||||
this.element.classList.toggle('ol-collapsed');
|
||||
if (this.collapsed_) {
|
||||
_ol_dom_.replaceNode(this.collapseLabel_, this.label_);
|
||||
replaceNode(this.collapseLabel_, this.label_);
|
||||
} else {
|
||||
_ol_dom_.replaceNode(this.label_, this.collapseLabel_);
|
||||
replaceNode(this.label_, this.collapseLabel_);
|
||||
}
|
||||
this.collapsed_ = !this.collapsed_;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user