Permalink
Browse files

modified for compatibility with ISX on lockscreen :-)

  • Loading branch information...
1 parent e6bd147 commit fff193bad3ce45f776e3f1433ffaea122e78f5f5 @moeseth committed Feb 1, 2012
Showing with 11 additions and 0 deletions.
  1. +11 −0 Tweak.x
View
11 Tweak.x
@@ -16,6 +16,14 @@
- (void)positionSlidingViewAtY:(CGFloat)y;
@end
+static BOOL isOnLockScreen()
+{
+ SBAwayController *awayController = [objc_getClass("SBAwayController") sharedAwayController];
+ if (!awayController)
+ return NO;
+ else [awayController isLocked];
+}
+
%hook SBBulletinListView
static UIView *activeView;
@@ -27,6 +35,9 @@ static UIView *activeView;
- (id)initWithFrame:(CGRect)frame delegate:(id)delegate
{
+ if (isOnLockScreen())
+ return %orig;
+
if ((self = %orig)) {
IOSurfaceRef surface = [UIWindow createScreenIOSurface];
UIImageOrientation imageOrientation;

0 comments on commit fff193b

Please sign in to comment.