Set constants of KML format even if a default style is provided
This commit is contained in:
@@ -51,6 +51,10 @@ ol.format.KML = function(opt_options) {
|
|||||||
|
|
||||||
ol.format.XMLFeature.call(this);
|
ol.format.XMLFeature.call(this);
|
||||||
|
|
||||||
|
if (!ol.format.KML.DEFAULT_STYLE_ARRAY_) {
|
||||||
|
ol.format.KML.createStyleDefaults_();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @inheritDoc
|
* @inheritDoc
|
||||||
*/
|
*/
|
||||||
@@ -61,8 +65,7 @@ ol.format.KML = function(opt_options) {
|
|||||||
* @type {Array.<ol.style.Style>}
|
* @type {Array.<ol.style.Style>}
|
||||||
*/
|
*/
|
||||||
this.defaultStyle_ = options.defaultStyle ?
|
this.defaultStyle_ = options.defaultStyle ?
|
||||||
options.defaultStyle :
|
options.defaultStyle : ol.format.KML.DEFAULT_STYLE_ARRAY_;
|
||||||
(ol.format.KML.DEFAULT_STYLE_ARRAY_ || ol.format.KML.createStyleDefaults_());
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @private
|
* @private
|
||||||
|
|||||||
+2808
-2762
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user