-
-
Save jonathanpenn/3969536 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import "MPAppDelegate.h" | |
@interface MPAppDelegate() | |
@property (strong, nonatomic) UIView *wildView; | |
@property (strong, nonatomic) UIViewController *viewController; | |
@end | |
@implementation MPAppDelegate | |
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions | |
{ | |
self.wildView = [[UIView alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; | |
self.wildView.backgroundColor = [UIColor whiteColor]; | |
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; | |
self.viewController = [[UIViewController alloc] init]; | |
self.window.rootViewController = self.viewController; | |
[self.window makeKeyAndVisible]; | |
return YES; | |
} | |
- (void)applicationDidBecomeActive:(UIApplication *)application | |
{ | |
[NSTimer scheduledTimerWithTimeInterval:.1 target:self selector:@selector(toggleWildView) userInfo:nil repeats:YES]; | |
} | |
- (void)toggleWildView | |
{ | |
self.wildView.superview ? [self.wildView removeFromSuperview] : [self.window addSubview:self.wildView]; | |
} | |
@end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment