From 4f61ad954a70da25246b1a000d5d73f334de2dc9 Mon Sep 17 00:00:00 2001 From: Justin Spahr-Summers Date: Sun, 25 Nov 2012 23:38:48 -0800 Subject: [PATCH] Reapply layer properties whenever -setLayer: is invoked too --- Rebel/RBLView.m | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Rebel/RBLView.m b/Rebel/RBLView.m index f64dbc6..9ed3192 100644 --- a/Rebel/RBLView.m +++ b/Rebel/RBLView.m @@ -180,6 +180,11 @@ static IMP RBLViewDrawRectIMP; self.layer.opaque = self.opaque; } +- (void)setLayer:(CALayer *)layer { + [super setLayer:layer]; + [self applyLayerProperties]; +} + // 10.8+ only. - (void)updateLayer { NSAssert(self.contents != nil, @"%@ does not have contents, %s should not be invoked", self, __func__);