diff options
Diffstat (limited to 'platform/darwin/src/MGLStyleValue_Private.h')
-rw-r--r-- | platform/darwin/src/MGLStyleValue_Private.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/platform/darwin/src/MGLStyleValue_Private.h b/platform/darwin/src/MGLStyleValue_Private.h index 82ce232c6b..07dbd31238 100644 --- a/platform/darwin/src/MGLStyleValue_Private.h +++ b/platform/darwin/src/MGLStyleValue_Private.h @@ -217,6 +217,11 @@ private: // Private utilities for converting from mgl to mbgl values mbglValue = rawValue.mgl_color; } + // Image + void getMBGLValue(NSString *rawValue, mbgl::style::expression::Image &mbglValue) { + mbglValue = mbgl::style::expression::Image(rawValue.UTF8String); + } + // Array void getMBGLValue(ObjCType rawValue, std::vector<MBGLElement> &mbglValue) { mbglValue.reserve(rawValue.count); @@ -295,6 +300,11 @@ private: // Private utilities for converting from mbgl to mgl values return [MGLColor mgl_colorWithColor:mbglStopValue]; } + // Image + static NSString *toMGLRawStyleValue(const mbgl::style::expression::Image &mbglImageValue) { + return @(mbglImageValue.id().c_str()); + } + // Array static NSArray<NSExpression*> *toMGLRawStyleValue(const std::vector<MBGLElement> &mbglStopValue) { NSMutableArray *array = [NSMutableArray arrayWithCapacity:mbglStopValue.size()]; |