Skip to content

Commit 912099c

Browse files
authored
Merge pull request Kureev#119 from getreup/master
makes blurview and vibrancyview cliptobounds
2 parents 49c01e5 + 6d47336 commit 912099c

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

ios/BlurView.m

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ - (void)setBlurType:(NSString *)blurType
1212
if (_visualEffectView) {
1313
[_visualEffectView removeFromSuperview];
1414
}
15-
15+
16+
self.clipsToBounds = true;
1617
if ([blurType isEqual: @"xlight"]) {
1718
blurEffect = [BlurAmount effectWithStyle:UIBlurEffectStyleExtraLight];
1819
} else if ([blurType isEqual: @"light"]) {
@@ -22,7 +23,7 @@ - (void)setBlurType:(NSString *)blurType
2223
} else {
2324
blurEffect = [BlurAmount effectWithStyle:UIBlurEffectStyleDark];
2425
}
25-
26+
2627
dispatch_async(dispatch_get_main_queue(), ^{
2728
_visualEffectView = [[UIVisualEffectView alloc] initWithEffect:blurEffect];
2829
_visualEffectView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;

ios/VibrancyView.m

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ - (void)setBlurType:(NSString *)blurType {
2424

2525
UIBlurEffect *blurEffect;
2626

27+
self.clipsToBounds = true;
2728
if ([blurType isEqual: @"xlight"]) {
2829
blurEffect = [UIBlurEffect effectWithStyle:UIBlurEffectStyleExtraLight];
2930
} else if ([blurType isEqual: @"light"]) {

0 commit comments

Comments
 (0)