From 901662a6351991deb99da995e78c32960f206209 Mon Sep 17 00:00:00 2001 From: iAdam1n Date: Thu, 2 Jul 2015 15:28:47 +0100 Subject: [PATCH] Initial release. --- Makefile | 12 ++++++++++++ MusicRotate.plist | 1 + Tweak.xm | 42 ++++++++++++++++++++++++++++++++++++++++++ control | 10 ++++++++++ 4 files changed, 65 insertions(+) create mode 100644 Makefile create mode 100644 MusicRotate.plist create mode 100644 Tweak.xm create mode 100644 control diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..23e3cac --- /dev/null +++ b/Makefile @@ -0,0 +1,12 @@ +include theos/makefiles/common.mk +export SDKVERSION = 8.4 +ARCHS = armv7 arm64 + +TWEAK_NAME = MusicRotate +TWEAKNAME_FRAMEWORKS = UIKit +MusicRotate_FILES = Tweak.xm + +include $(THEOS_MAKE_PATH)/tweak.mk + +after-install:: + install.exec "killall -9 SpringBoard" diff --git a/MusicRotate.plist b/MusicRotate.plist new file mode 100644 index 0000000..e5c60ee --- /dev/null +++ b/MusicRotate.plist @@ -0,0 +1 @@ +{ Filter = { Bundles = ( "com.apple.UIKit" ); }; } diff --git a/Tweak.xm b/Tweak.xm new file mode 100644 index 0000000..ee08a15 --- /dev/null +++ b/Tweak.xm @@ -0,0 +1,42 @@ +#import +#import +#import + +%hook UIWindow +-(bool)isInterfaceAutorotationDisabled { + return FALSE; +} +-(bool)_shouldAutorotateToInterfaceOrientation:(long long)arg1 checkForDismissal:(bool)arg2 isRotationDisabled:(bool*)arg3 { + return TRUE; +} +%end + +%hook UIInputWindowController +-(bool)setInterfaceAutorotationDisabled { + return FALSE; +} +%end + +%hook UIMovieScrubber +-(bool)setRotationDisabled { + return FALSE; +} +%end + +%hook UIViewController +-(bool)_isInterfaceAutorotationDisabled { + return FALSE; +} +%end + +%hook UIApplication +-(bool)_rotationDisabledDuringTouch { + return FALSE; +} +-(bool)_setRotationDisabledDuringTouch { + return FALSE; +} +-(bool)_isAutorotationDisabledForAppWindows { + return FALSE; +} +%end \ No newline at end of file diff --git a/control b/control new file mode 100644 index 0000000..04dc049 --- /dev/null +++ b/control @@ -0,0 +1,10 @@ +Package: com.iadam1n.musicrotate +Name: MusicRotate +Pre-Depends: firmware (>=8.4) +Depends: mobilesubstrate +Version: 1.0 +Architecture: iphoneos-arm +Description: Enable rotation in Music app on iOS 8.4+. +Maintainer: iAdam1n +Author: iAdam1n +Section: Tweaks