diff options
Diffstat (limited to 'platform/darwin/src/MGLStyleLayer.mm.ejs')
-rw-r--r-- | platform/darwin/src/MGLStyleLayer.mm.ejs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/platform/darwin/src/MGLStyleLayer.mm.ejs b/platform/darwin/src/MGLStyleLayer.mm.ejs index c35d254caf..4e59c3c6cb 100644 --- a/platform/darwin/src/MGLStyleLayer.mm.ejs +++ b/platform/darwin/src/MGLStyleLayer.mm.ejs @@ -34,6 +34,18 @@ return self; } +<% if (type !== 'background' && type !== 'raster') { -%> +- (void)setPredicate:(NSPredicate *)predicate +{ + self.layer->setFilter(predicate.mgl_filter); +} + +- (NSPredicate *)predicate +{ + return [NSPredicate mgl_predicateWithFilter:self.layer->getFilter()]; +} + +<% } -%> <% if (layoutProperties.length) { -%> #pragma mark - Accessing the Layout Attributes |