Hide the youtuber overlay background on iOS
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
979B

  1. //
  2. // Implementation file, shows all methods, classes, property's, and ivars implemented in code
  3. //
  4. //Linking the header file.
  5. //It is possible to put all the headers in here,
  6. //but that will get real messy real soon on a bigger tweak.
  7. #import "Tweak.h"
  8. %hook YTMainAppVideoPlayerOverlayView //The class I am hooking.
  9. -(void)setControlsOverlayVisible:(BOOL)arg1 { //The method I am hooking.
  10. //Obtaining the background from property's.
  11. //You could leave this method out but it helps with readability
  12. //because the original header is in another file.
  13. //The reason I'm doing this every single time and not only
  14. //one per view initialization is because I noticed that
  15. //youtube resets this value sometimes so this is just in case.
  16. UIView * background = (UIView *) [self backgroundView];
  17. [background setAlpha:(CGFloat)0]; //Calling the method to set the alpha to 0
  18. %orig(arg1); //Invoking the original setControlsOverlayVisible method with the original value
  19. }
  20. %end