Fix checks for undefined in fullscreencontrol

This commit is contained in:
Guillaume Beraudo
2016-02-10 14:26:17 +01:00
parent 9703be932d
commit a513754d25

View File

@@ -37,9 +37,10 @@ ol.control.FullScreen = function(opt_options) {
* @private
* @type {string}
*/
this.cssClassName_ = options.className ? options.className : 'ol-full-screen';
this.cssClassName_ = options.className !== undefined ? options.className :
'ol-full-screen';
var label = options.label ? options.label : '\u2922';
var label = options.label !== undefined ? options.label : '\u2922';
/**
* @private
@@ -48,7 +49,7 @@ ol.control.FullScreen = function(opt_options) {
this.labelNode_ = typeof label === 'string' ?
document.createTextNode(label) : label;
var labelActive = options.labelActive ? options.labelActive : '\u00d7';
var labelActive = options.labelActive !== undefined ? options.labelActive : '\u00d7';
/**
* @private