Remove annoying airdrop and contacts from share menu.
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.

45 lines
1.2KB

  1. @interface UIActivityContentViewController
  2. - (void) updateContentWithPeopleProxies:(id)arg1 shareProxies:(id)arg2 actionProxies:(id)arg3 activitiesByUUID:(id)arg4 nearbyCountSlotID:(id)arg5 animated:(BOOL)arg6;
  3. @end
  4. @interface _UIActivityUserDefaultsViewController
  5. @property NSArray * favoritesProxies;
  6. @property NSArray * suggestionProxies;
  7. - (void) setFavoritesProxies:(NSArray*)arg1;
  8. - (void) setSuggestionProxies:(NSArray*)arg1;
  9. - (void) makeEditable:(NSArray*)arg1;
  10. @end
  11. @interface UserAP
  12. @property BOOL canEdit;
  13. @property BOOL canMove;
  14. @end
  15. %hook UIActivityContentViewController
  16. - (void) updateContentWithPeopleProxies:(NSArray*)arg1 shareProxies:(NSArray*)arg2 actionProxies:(NSArray*)arg3 activitiesByUUID:(NSMutableDictionary*)arg4 nearbyCountSlotID:(id)arg5 animated:(BOOL)arg6 {
  17. %orig([NSMutableArray new], arg2, arg3, arg4, arg5, arg6);
  18. }
  19. %end
  20. %hook _UIActivityUserDefaultsViewController
  21. - (void) setFavoritesProxies:(NSArray*)arg1 {
  22. %orig;
  23. [self makeEditable:self.favoritesProxies];
  24. }
  25. - (void) setSuggestionProxies:(NSArray*)arg1 {
  26. %orig;
  27. [self makeEditable:self.suggestionProxies];
  28. }
  29. %new
  30. - (void) makeEditable:(NSArray*)arg1 {
  31. for (UserAP * ap in arg1) {
  32. ap.canEdit = YES;
  33. ap.canMove = YES;
  34. }
  35. }
  36. %end