diff options
author | Konstantin Käfer <mail@kkaefer.com> | 2019-10-14 14:38:17 +0200 |
---|---|---|
committer | Konstantin Käfer <mail@kkaefer.com> | 2019-10-14 18:46:12 +0200 |
commit | 8206ce0e024a082f6979ce66f65909cb451e9d71 (patch) | |
tree | 70221509adc3a5a7ad68dcea1f4642c92e77a895 /platform/darwin | |
parent | e4e2a78033f25fd966fa9cbbd2babb7e7b499e18 (diff) | |
download | qtlocation-mapboxgl-8206ce0e024a082f6979ce66f65909cb451e9d71.tar.gz |
[core] map image type to string until we have a dedicated implementation
Diffstat (limited to 'platform/darwin')
-rwxr-xr-x | platform/darwin/scripts/generate-style-code.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/platform/darwin/scripts/generate-style-code.js b/platform/darwin/scripts/generate-style-code.js index 38066c9f43..75dbdf367c 100755 --- a/platform/darwin/scripts/generate-style-code.js +++ b/platform/darwin/scripts/generate-style-code.js @@ -159,6 +159,7 @@ global.objCTestValue = function (property, layerType, arraysAsStructs, indent) { `@"'${_.startCase(propertyName)}'"` : `@"${_.startCase(propertyName)}"`; case 'string': + case 'image': // TODO: replace once we implement image expressions return `@"'${_.startCase(propertyName)}'"`; case 'enum': return `@"'${_.last(_.keys(property.values))}'"`; @@ -208,6 +209,7 @@ global.mbglTestValue = function (property, layerType) { return '1.0'; case 'formatted': case 'string': + case 'image': // TODO: replace once we implement image expressions return `"${_.startCase(propertyName)}"`; case 'enum': { let type = camelize(originalPropertyName(property)); @@ -294,6 +296,7 @@ global.testHelperMessage = function (property, layerType, isFunction) { return 'testNumber' + fnSuffix; case 'formatted': case 'string': + case 'image': // TODO: replace once we implement image expressions return 'testString' + fnSuffix; case 'enum': let objCType = global.objCType(layerType, property.name); @@ -474,6 +477,7 @@ global.describeType = function (property) { return 'numeric'; case 'formatted': case 'string': + case 'image': // TODO: replace once we implement image expressions return 'string'; case 'enum': return '`MGL' + camelize(property.name) + '`'; @@ -522,6 +526,7 @@ global.describeValue = function (value, property, layerType) { return 'the float ' + '`' + formatNumber(value) + '`'; case 'formatted': case 'string': + case 'image': // TODO: replace once we implement image expressions if (value === '') { return 'the empty string'; } @@ -608,6 +613,7 @@ global.propertyType = function (property) { return 'NSNumber *'; case 'formatted': case 'string': + case 'image': // TODO: replace once we implement image expressions return 'NSString *'; case 'enum': return 'NSValue *'; @@ -640,6 +646,7 @@ global.isInterpolatable = function (property) { return type !== 'boolean' && type !== 'enum' && type !== 'string' && + type !== 'image' && type !== 'formatted'; }; @@ -653,6 +660,7 @@ global.valueTransformerArguments = function (property) { case 'formatted': return ['mbgl::style::expression::Formatted', objCType]; case 'string': + case 'image': // TODO: replace once we implement image expressions return ['std::string', objCType]; case 'enum': return [mbglType(property), 'NSValue *', mbglType(property), `MGL${camelize(property.name)}`]; @@ -692,6 +700,7 @@ global.mbglType = function(property) { case 'formatted': return 'mbgl::style::expression::Formatted'; case 'string': + case 'image': // TODO: replace once we implement image expressions return 'std::string'; case 'enum': { let type = camelize(originalPropertyName(property)); |