Version 1.0.3

Added a12 compatability.

Fixed a bug where AVLock's button was overlapping.
This commit is contained in:
2019-06-22 15:35:41 +03:00
committed by GitHub
父節點 713095850c
當前提交 d0fd47ccba
共有 3 個文件被更改,包括 30 次插入18 次删除

查看文件

@ -1,5 +1,5 @@
ARCHS = armv7 arm64
ARCHS = armv7 arm64 arm64e
export TARGET = iphone:clang:11.2:7.0
include $(THEOS)/makefiles/common.mk
TWEAK_NAME = AVLock

查看文件

@ -21,7 +21,8 @@
@end
//#import <AudioToolbox/AudioToolbox.h>
//#import <AudioToolbox/AudioServices.h>
extern "C" CFNotificationCenterRef CFNotificationCenterGetDistributedCenter(void);
@ -96,13 +97,24 @@ CFNotificationCenterAddObserver(CFNotificationCenterGetDarwinNotifyCenter(),
}
%end
double delayInSeconds = 0.13;
%hook AVPlaybackControlsVisibilityControllerItem
-(BOOL)wantsAnimatedTransitionToHidden:(BOOL)arg1 alpha:(double)arg2{
if(!arg1){
delayInSeconds = 0.0;
[[NSNotificationCenter defaultCenter] postNotificationName:UIDeviceOrientationDidChangeNotification object:nil];
//AudioServicesPlaySystemSound(1103);
delayInSeconds = 0.13;
}
return %orig;
}
%end
%hook AVTransportControlsView
int test = 30;
// iOS 12
-(AVTransportControlsView *)initWithFrame:(CGRect)frame styleSheet:(id)arg2 captureView:(id)arg3{
AVTransportControlsView *origself = %orig(frame,arg2,arg3);
@ -178,7 +190,7 @@ int test = 30;
%new
-(void)deviceOrientationDidChange{
double delayInSeconds = 0.13;
dispatch_time_t popTime = dispatch_time(DISPATCH_TIME_NOW, delayInSeconds * NSEC_PER_SEC);
dispatch_after(popTime, dispatch_get_main_queue(), ^(void){

Binary file not shown.