ghostty/macos/Sources/Helpers/VibrantLayer.m
Pete Schaffner 3b6bac0121 Make special blending mode class more generic
This allows us to specify what kind of context we'd like our vibrant
layer to exist in (light or dark).
2024-02-11 00:53:18 +01:00

28 lines
422 B
Objective-C

#import "VibrantLayer.h"
@interface VibrantLayer()
@property (nonatomic) VibrantLayerType type;
@end
@implementation VibrantLayer
- (id)initForAppearance:(VibrantLayerType)type {
self = [super init];
if (self) {
_type = type;
}
return self;
}
- (id)compositingFilter {
if (self.type == VibrantLayerTypeLight) {
return @"plusD";
} else {
return @"plusL";
}
}
@end