Advertisement
princetechn0

Untitled

Feb 23rd, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. #import <control.h>
  2.  
  3. %hook SBLockHardwareButtonActions
  4.  
  5.  
  6. -(void)performTriplePressActions {
  7.  
  8. static BOOL on = NO;
  9.  
  10. if (on == NO) {
  11. [[NSClassFromString(@"SBUIFlashlightController")
  12. sharedInstance] turnFlashlightOn];
  13. on = YES;
  14. } else {
  15. [[NSClassFromString(@"SBUIFlashlightController")
  16. sharedInstance] turnFlashlightOff];
  17. on = NO;
  18.  
  19. }
  20.  
  21.  
  22.  
  23. }
  24.  
  25.  
  26.  
  27.  
  28. %end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement