diff options
author | Lauren Budorick <lauren@mapbox.com> | 2018-04-16 17:38:53 -0700 |
---|---|---|
committer | Lauren Budorick <lauren@mapbox.com> | 2018-04-16 17:38:53 -0700 |
commit | cfd97e5ceaa7b88d591bdb730ae1e9b70dcaa5f5 (patch) | |
tree | 781f03674488d8a5cc1e8388d5b85c9a0766bb0c /platform/android/scripts/generate-style-code.js | |
parent | 8b10bb38c0a7d6e0a1225e185acde5ec8a604bdc (diff) | |
download | qtlocation-mapboxgl-cfd97e5ceaa7b88d591bdb730ae1e9b70dcaa5f5.tar.gz |
Bump gl-js pin: ignore line-gradient properties + shaders, use new expression style-spec taxonomyupstream/expression-spec
Diffstat (limited to 'platform/android/scripts/generate-style-code.js')
-rwxr-xr-x | platform/android/scripts/generate-style-code.js | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/platform/android/scripts/generate-style-code.js b/platform/android/scripts/generate-style-code.js index 6e6d3cfa67..91713edcb7 100755 --- a/platform/android/scripts/generate-style-code.js +++ b/platform/android/scripts/generate-style-code.js @@ -30,6 +30,8 @@ var layers = Object.keys(spec.layer.type.values).map((type) => { const paintProperties = Object.keys(spec[`paint_${type}`]).reduce((memo, name) => { // disabled for now, see https://github.com/mapbox/mapbox-gl-native/issues/11172 if (name === 'heatmap-color') return memo; + // not yet implemented + if (name === 'line-gradient') return memo; spec[`paint_${type}`][name].name = name; memo.push(spec[`paint_${type}`][name]); @@ -252,9 +254,13 @@ global.propertyValueDoc = function (property, value) { }; global.isDataDriven = function (property) { - return property['property-function'] === true; + return property['property-type'] === 'data-driven' || property['property-type'] === 'cross-faded-data-driven'; }; +global.isInterpolable = function(property) { + return property.expression && property.expression.interpolated; +} + global.isLightProperty = function (property) { return property['light-property'] === true; }; @@ -302,11 +308,11 @@ global.evaluatedType = function (property) { }; global.supportsZoomFunction = function (property) { - return property['zoom-function'] === true; + return property.expression && property.expression.parameters.indexOf('zoom') > -1; }; global.supportsPropertyFunction = function (property) { - return property['property-function'] === true; + return property['property-type'] === 'data-driven' || property['property-type'] === 'cross-faded-data-driven'; }; // Template processing // |