]> git.saurik.com Git - winterboard.git/commitdiff
Make SMS labels and timestamps transparent.
authorJay Freeman (saurik) <saurik@saurik.com>
Fri, 21 Oct 2011 01:10:01 +0000 (01:10 +0000)
committerJay Freeman (saurik) <saurik@saurik.com>
Fri, 21 Oct 2011 01:10:01 +0000 (01:10 +0000)
Library.mm

index f81c3ecdcb00a64afe30091c5a185e595ebc449f..1b4a595aa59067afde9db36b854872639b44b6ec 100644 (file)
@@ -1319,6 +1319,7 @@ MSHook(void, SBStatusBarTimeView$drawRect$, SBStatusBarTimeView *self, SEL sel,
 @interface UIView (WinterBoard)
 - (bool) wb$isWBImageView;
 - (void) wb$logHierarchy;
+- (void) wb$setBackgroundColor:(UIColor *)color;
 @end
 
 @implementation UIView (WinterBoard)
@@ -1331,6 +1332,12 @@ MSHook(void, SBStatusBarTimeView$drawRect$, SBStatusBarTimeView *self, SEL sel,
     WBLogHierarchy(self);
 }
 
+- (void) wb$setBackgroundColor:(UIColor *)color {
+    [self setBackgroundColor:color];
+    for (UIView *child in [self subviews])
+        [child wb$setBackgroundColor:color];
+}
+
 @end
 
 @interface WBImageView : UIImageView {
@@ -1539,12 +1546,13 @@ MSInstanceMessageHook1(void, CKMessageCell, addBalloonView, CKBalloonView *, bal
 
 MSInstanceMessageHook1(void, CKTranscriptCell, setBackgroundColor, UIColor *, color) {
     MSOldCall([UIColor clearColor]);
+    [[self contentView] wb$setBackgroundColor:[UIColor clearColor]];
 }
 
 MSInstanceMessageHook2(id, CKTranscriptCell, initWithStyle,reuseIdentifier, int, style, NSString *, reuse) {
     if ((self = MSOldCall(style, reuse)) != nil) {
         [self setBackgroundColor:[UIColor clearColor]];
-        [[self contentView] setBackgroundColor:[UIColor clearColor]];
+        [[self contentView] wb$setBackgroundColor:[UIColor clearColor]];
     } return self;
 }