2012-02-19 107 views

回答

0

我在另一个线程中写了一个答案,这个线程显然是一些人非常喜欢的;看看它here

不过,@ EvilPenguin的回答是完全正确的,我只是在这里和那里解释一些事情,但它最终会将您重定向到同一个地方。

0
#import <SpringBoard/SpringBoard.h> // for SBScreenFlash 
%hook SBAwayLockBar 
-(void)unlock // the method you’re hooking 
{ 
%orig; 
[[%c(SBScreenFlash) sharedInstance] flash]; 
} 
%end 

如果你使用Slider解锁你的设备,它会截屏你的屏幕。它不是一个好的调整,但它只是你所要求的。

#import <SpringBoard/SpringBoard.h> // for SBScreenFlash 
    %hook SBAwayLockBar 
    -(void)unlock // the method you’re hooking 
    { 
    %orig; 
    UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Hello World!" message:@"my first Tweak" delegate:nil cancelButtonTitle:@"Cool" otherButtonTitles:nil]; 
[alert show]; 
[alert release]; 
    } 
    %end 

这会提示alertview给你打个招呼世界;) 玩得开心