Remove unnecessary local variable

This commit is contained in:
Frederic Junod
2014-08-20 11:17:44 +02:00
parent 27ae50e673
commit 7f086e138a

View File

@@ -31,15 +31,13 @@ ol.control.Rotate = function(opt_options) {
var className = goog.isDef(options.className) ?
options.className : 'ol-rotate';
var label = goog.dom.createDom(goog.dom.TagName.SPAN,
{ 'class': 'ol-compass' },
goog.isDef(options.label) ? options.label : '\u21E7');
/**
* @type {Element}
* @private
*/
this.label_ = label;
this.label_ = goog.dom.createDom(goog.dom.TagName.SPAN,
{ 'class': 'ol-compass' },
goog.isDef(options.label) ? options.label : '\u21E7');
var tipLabel = goog.isDef(options.tipLabel) ?
options.tipLabel : 'Reset rotation';
@@ -51,7 +49,7 @@ ol.control.Rotate = function(opt_options) {
'class': className + '-reset ol-has-tooltip',
'name' : 'ResetRotation',
'type' : 'button'
}, tip, label);
}, tip, this.label_);
var handler = new ol.pointer.PointerEventHandler(button);
this.registerDisposable(handler);