summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2019-09-25 23:31:56 +0300
committerMikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com>2019-09-26 11:57:39 +0300
commite78c31c4b53326f260a4274018b5cb98fac0dbb6 (patch)
treec81f74500b9a1d5a618ee2b12b54324ceaeec175 /include
parentb5862c212769ee1372e4005dd1b96d49b72171e3 (diff)
downloadqtlocation-mapboxgl-e78c31c4b53326f260a4274018b5cb98fac0dbb6.tar.gz
[core] LayerProperty -> StyleProperty
Diffstat (limited to 'include')
-rw-r--r--include/mbgl/style/conversion_impl.hpp20
-rw-r--r--include/mbgl/style/layer.hpp8
-rw-r--r--include/mbgl/style/layers/background_layer.hpp2
-rw-r--r--include/mbgl/style/layers/circle_layer.hpp2
-rw-r--r--include/mbgl/style/layers/custom_layer.hpp2
-rw-r--r--include/mbgl/style/layers/fill_extrusion_layer.hpp2
-rw-r--r--include/mbgl/style/layers/fill_layer.hpp2
-rw-r--r--include/mbgl/style/layers/heatmap_layer.hpp2
-rw-r--r--include/mbgl/style/layers/hillshade_layer.hpp2
-rw-r--r--include/mbgl/style/layers/layer.hpp.ejs2
-rw-r--r--include/mbgl/style/layers/line_layer.hpp2
-rw-r--r--include/mbgl/style/layers/raster_layer.hpp2
-rw-r--r--include/mbgl/style/layers/symbol_layer.hpp2
13 files changed, 25 insertions, 25 deletions
diff --git a/include/mbgl/style/conversion_impl.hpp b/include/mbgl/style/conversion_impl.hpp
index 866eff9eb5..ebeeee1c79 100644
--- a/include/mbgl/style/conversion_impl.hpp
+++ b/include/mbgl/style/conversion_impl.hpp
@@ -349,22 +349,22 @@ Value makeValue(T&& arg) {
}
template <typename T>
-LayerProperty makeLayerProperty(const PropertyValue<T>& value) {
- return value.match([](const Undefined&) -> LayerProperty { return {}; },
- [](const T& t) -> LayerProperty {
- return {makeValue(t), LayerProperty::Kind::Constant};
+StyleProperty makeStyleProperty(const PropertyValue<T>& value) {
+ return value.match([](const Undefined&) -> StyleProperty { return {}; },
+ [](const T& t) -> StyleProperty {
+ return {makeValue(t), StyleProperty::Kind::Constant};
},
- [](const PropertyExpression<T>& fn) -> LayerProperty {
- return {fn.getExpression().serialize(), LayerProperty::Kind::Expression};
+ [](const PropertyExpression<T>& fn) -> StyleProperty {
+ return {fn.getExpression().serialize(), StyleProperty::Kind::Expression};
});
}
-inline LayerProperty makeLayerProperty(const TransitionOptions& value) {
- return {makeValue(value), LayerProperty::Kind::Transition};
+inline StyleProperty makeStyleProperty(const TransitionOptions& value) {
+ return {makeValue(value), StyleProperty::Kind::Transition};
}
-inline LayerProperty makeLayerProperty(const ColorRampPropertyValue& value) {
- return {makeValue(value), LayerProperty::Kind::Expression};
+inline StyleProperty makeStyleProperty(const ColorRampPropertyValue& value) {
+ return {makeValue(value), StyleProperty::Kind::Expression};
}
} // namespace conversion
diff --git a/include/mbgl/style/layer.hpp b/include/mbgl/style/layer.hpp
index 646bad898c..11fd429be9 100644
--- a/include/mbgl/style/layer.hpp
+++ b/include/mbgl/style/layer.hpp
@@ -66,10 +66,10 @@ struct LayerTypeInfo {
const enum class TileKind : uint8_t { Geometry, Raster, RasterDEM, NotRequired } tileKind;
};
-struct LayerProperty {
+struct StyleProperty {
enum class Kind : uint8_t { Undefined, Constant, Expression, Transition };
- LayerProperty(Value value_, Kind kind_) : value(std::move(value_)), kind(kind_) {}
- LayerProperty() = default;
+ StyleProperty(Value value_, Kind kind_) : value(std::move(value_)), kind(kind_) {}
+ StyleProperty() = default;
const Value value;
const Kind kind = Kind::Undefined;
};
@@ -123,7 +123,7 @@ public:
const conversion::Convertible& value) = 0;
optional<conversion::Error> setVisibility(const conversion::Convertible& value);
- virtual LayerProperty getPaintProperty(const std::string&) const = 0;
+ virtual StyleProperty getPaintProperty(const std::string&) const = 0;
// Private implementation
// TODO : We should not have public mutable data members.
diff --git a/include/mbgl/style/layers/background_layer.hpp b/include/mbgl/style/layers/background_layer.hpp
index 8caade26b0..ad40e49660 100644
--- a/include/mbgl/style/layers/background_layer.hpp
+++ b/include/mbgl/style/layers/background_layer.hpp
@@ -24,7 +24,7 @@ public:
optional<conversion::Error> setLayoutProperty(const std::string& name, const conversion::Convertible& value) final;
optional<conversion::Error> setPaintProperty(const std::string& name, const conversion::Convertible& value) final;
- LayerProperty getPaintProperty(const std::string& name) const final;
+ StyleProperty getPaintProperty(const std::string& name) const final;
// Paint properties
diff --git a/include/mbgl/style/layers/circle_layer.hpp b/include/mbgl/style/layers/circle_layer.hpp
index be4fe5cee4..f0bd18a825 100644
--- a/include/mbgl/style/layers/circle_layer.hpp
+++ b/include/mbgl/style/layers/circle_layer.hpp
@@ -24,7 +24,7 @@ public:
optional<conversion::Error> setLayoutProperty(const std::string& name, const conversion::Convertible& value) final;
optional<conversion::Error> setPaintProperty(const std::string& name, const conversion::Convertible& value) final;
- LayerProperty getPaintProperty(const std::string& name) const final;
+ StyleProperty getPaintProperty(const std::string& name) const final;
// Paint properties
diff --git a/include/mbgl/style/layers/custom_layer.hpp b/include/mbgl/style/layers/custom_layer.hpp
index 9ae68c4fff..ad27226505 100644
--- a/include/mbgl/style/layers/custom_layer.hpp
+++ b/include/mbgl/style/layers/custom_layer.hpp
@@ -71,7 +71,7 @@ public:
// Dynamic properties
optional<conversion::Error> setLayoutProperty(const std::string& name, const conversion::Convertible& value) final;
optional<conversion::Error> setPaintProperty(const std::string& name, const conversion::Convertible& value) final;
- LayerProperty getPaintProperty(const std::string&) const final;
+ StyleProperty getPaintProperty(const std::string&) const final;
// Private implementation
class Impl;
diff --git a/include/mbgl/style/layers/fill_extrusion_layer.hpp b/include/mbgl/style/layers/fill_extrusion_layer.hpp
index 63ccf369d4..f2a5284fb9 100644
--- a/include/mbgl/style/layers/fill_extrusion_layer.hpp
+++ b/include/mbgl/style/layers/fill_extrusion_layer.hpp
@@ -24,7 +24,7 @@ public:
optional<conversion::Error> setLayoutProperty(const std::string& name, const conversion::Convertible& value) final;
optional<conversion::Error> setPaintProperty(const std::string& name, const conversion::Convertible& value) final;
- LayerProperty getPaintProperty(const std::string& name) const final;
+ StyleProperty getPaintProperty(const std::string& name) const final;
// Paint properties
diff --git a/include/mbgl/style/layers/fill_layer.hpp b/include/mbgl/style/layers/fill_layer.hpp
index acf60cec0d..0f4ce02aea 100644
--- a/include/mbgl/style/layers/fill_layer.hpp
+++ b/include/mbgl/style/layers/fill_layer.hpp
@@ -24,7 +24,7 @@ public:
optional<conversion::Error> setLayoutProperty(const std::string& name, const conversion::Convertible& value) final;
optional<conversion::Error> setPaintProperty(const std::string& name, const conversion::Convertible& value) final;
- LayerProperty getPaintProperty(const std::string& name) const final;
+ StyleProperty getPaintProperty(const std::string& name) const final;
// Paint properties
diff --git a/include/mbgl/style/layers/heatmap_layer.hpp b/include/mbgl/style/layers/heatmap_layer.hpp
index 7eb7bb8edd..233ed32e36 100644
--- a/include/mbgl/style/layers/heatmap_layer.hpp
+++ b/include/mbgl/style/layers/heatmap_layer.hpp
@@ -25,7 +25,7 @@ public:
optional<conversion::Error> setLayoutProperty(const std::string& name, const conversion::Convertible& value) final;
optional<conversion::Error> setPaintProperty(const std::string& name, const conversion::Convertible& value) final;
- LayerProperty getPaintProperty(const std::string& name) const final;
+ StyleProperty getPaintProperty(const std::string& name) const final;
// Paint properties
diff --git a/include/mbgl/style/layers/hillshade_layer.hpp b/include/mbgl/style/layers/hillshade_layer.hpp
index 7c8f6fa573..aaed4597dc 100644
--- a/include/mbgl/style/layers/hillshade_layer.hpp
+++ b/include/mbgl/style/layers/hillshade_layer.hpp
@@ -24,7 +24,7 @@ public:
optional<conversion::Error> setLayoutProperty(const std::string& name, const conversion::Convertible& value) final;
optional<conversion::Error> setPaintProperty(const std::string& name, const conversion::Convertible& value) final;
- LayerProperty getPaintProperty(const std::string& name) const final;
+ StyleProperty getPaintProperty(const std::string& name) const final;
// Paint properties
diff --git a/include/mbgl/style/layers/layer.hpp.ejs b/include/mbgl/style/layers/layer.hpp.ejs
index f678adeda7..20dcb86abd 100644
--- a/include/mbgl/style/layers/layer.hpp.ejs
+++ b/include/mbgl/style/layers/layer.hpp.ejs
@@ -40,7 +40,7 @@ public:
optional<conversion::Error> setLayoutProperty(const std::string& name, const conversion::Convertible& value) final;
optional<conversion::Error> setPaintProperty(const std::string& name, const conversion::Convertible& value) final;
- LayerProperty getPaintProperty(const std::string& name) const final;
+ StyleProperty getPaintProperty(const std::string& name) const final;
<% if (layoutProperties.length) { -%>
// Layout properties
diff --git a/include/mbgl/style/layers/line_layer.hpp b/include/mbgl/style/layers/line_layer.hpp
index a1c69e9475..410b518f7b 100644
--- a/include/mbgl/style/layers/line_layer.hpp
+++ b/include/mbgl/style/layers/line_layer.hpp
@@ -27,7 +27,7 @@ public:
optional<conversion::Error> setLayoutProperty(const std::string& name, const conversion::Convertible& value) final;
optional<conversion::Error> setPaintProperty(const std::string& name, const conversion::Convertible& value) final;
- LayerProperty getPaintProperty(const std::string& name) const final;
+ StyleProperty getPaintProperty(const std::string& name) const final;
// Layout properties
diff --git a/include/mbgl/style/layers/raster_layer.hpp b/include/mbgl/style/layers/raster_layer.hpp
index e516e1a0fc..91dab175ec 100644
--- a/include/mbgl/style/layers/raster_layer.hpp
+++ b/include/mbgl/style/layers/raster_layer.hpp
@@ -24,7 +24,7 @@ public:
optional<conversion::Error> setLayoutProperty(const std::string& name, const conversion::Convertible& value) final;
optional<conversion::Error> setPaintProperty(const std::string& name, const conversion::Convertible& value) final;
- LayerProperty getPaintProperty(const std::string& name) const final;
+ StyleProperty getPaintProperty(const std::string& name) const final;
// Paint properties
diff --git a/include/mbgl/style/layers/symbol_layer.hpp b/include/mbgl/style/layers/symbol_layer.hpp
index 578d7d1701..0c128f84a6 100644
--- a/include/mbgl/style/layers/symbol_layer.hpp
+++ b/include/mbgl/style/layers/symbol_layer.hpp
@@ -26,7 +26,7 @@ public:
optional<conversion::Error> setLayoutProperty(const std::string& name, const conversion::Convertible& value) final;
optional<conversion::Error> setPaintProperty(const std::string& name, const conversion::Convertible& value) final;
- LayerProperty getPaintProperty(const std::string& name) const final;
+ StyleProperty getPaintProperty(const std::string& name) const final;
// Layout properties