Inline goog.isDef() calls for properties

This commit is contained in:
Tim Schaub
2015-09-27 10:40:20 -06:00
parent 36e336f406
commit 83c59ee255
44 changed files with 200 additions and 198 deletions

View File

@@ -181,22 +181,23 @@ ol.Map = function(options) {
* @type {boolean}
* @private
*/
this.loadTilesWhileAnimating_ = goog.isDef(options.loadTilesWhileAnimating) ?
options.loadTilesWhileAnimating : false;
this.loadTilesWhileAnimating_ =
options.loadTilesWhileAnimating !== undefined ?
options.loadTilesWhileAnimating : false;
/**
* @type {boolean}
* @private
*/
this.loadTilesWhileInteracting_ =
goog.isDef(options.loadTilesWhileInteracting) ?
options.loadTilesWhileInteracting !== undefined ?
options.loadTilesWhileInteracting : false;
/**
* @private
* @type {number}
*/
this.pixelRatio_ = goog.isDef(options.pixelRatio) ?
this.pixelRatio_ = options.pixelRatio !== undefined ?
options.pixelRatio : ol.has.DEVICE_PIXEL_RATIO;
/**
@@ -1486,7 +1487,7 @@ ol.Map.createOptionsInternal = function(options) {
values[ol.MapProperty.TARGET] = options.target;
values[ol.MapProperty.VIEW] = goog.isDef(options.view) ?
values[ol.MapProperty.VIEW] = options.view !== undefined ?
options.view : new ol.View();
/**