@@ -35,6 +35,20 @@ | |||
<string>getData:</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSSwitchCell</string> | |||
<key>default</key> | |||
<false/> | |||
<key>defaults</key> | |||
<string>sh.litten.nevvepreferences</string> | |||
<key>key</key> | |||
<string>screenshotSound</string> | |||
<key>label</key> | |||
<string>Screenshot Sound</string> | |||
<key>PostNotification</key> | |||
<string>sh.litten.nevvepreferences/ReloadPrefs</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSLinkListCell</string> | |||
@@ -181,7 +195,7 @@ | |||
<key>defaults</key> | |||
<string>sh.litten.nevvepreferences</string> | |||
<key>key</key> | |||
<string>typingSoundSwitch</string> | |||
<string>typingSound</string> | |||
<key>label</key> | |||
<string>Typing Sound</string> | |||
<key>PostNotification</key> | |||
@@ -233,6 +247,52 @@ | |||
<string>getData:</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSLinkListCell</string> | |||
<key>default</key> | |||
<string>None</string> | |||
<key>defaults</key> | |||
<string>sh.litten.nevvepreferences</string> | |||
<key>detail</key> | |||
<string>PSListItemsController</string> | |||
<key>key</key> | |||
<string>alertAppearSounds</string> | |||
<key>label</key> | |||
<string>Alert Appears</string> | |||
<key>set</key> | |||
<string>setAndPreview:forSpecifier:</string> | |||
<key>title</key> | |||
<string>Anywhere</string> | |||
<key>titlesDataSource</key> | |||
<string>getData:</string> | |||
<key>valuesDataSource</key> | |||
<string>getData:</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSLinkListCell</string> | |||
<key>default</key> | |||
<string>None</string> | |||
<key>defaults</key> | |||
<string>sh.litten.nevvepreferences</string> | |||
<key>detail</key> | |||
<string>PSListItemsController</string> | |||
<key>key</key> | |||
<string>alertDisappearSounds</string> | |||
<key>label</key> | |||
<string>Alert Disappears</string> | |||
<key>set</key> | |||
<string>setAndPreview:forSpecifier:</string> | |||
<key>title</key> | |||
<string>Anywhere</string> | |||
<key>titlesDataSource</key> | |||
<string>getData:</string> | |||
<key>valuesDataSource</key> | |||
<string>getData:</string> | |||
</dict> | |||
</array> | |||
<key>title</key> | |||
<string>Anywhere</string> |
@@ -24,7 +24,7 @@ | |||
<key>key</key> | |||
<string>unlockedSounds</string> | |||
<key>label</key> | |||
<string>Unlocked/NC</string> | |||
<string>Unlocked</string> | |||
<key>set</key> | |||
<string>setAndPreview:forSpecifier:</string> | |||
<key>title</key> |
@@ -13,6 +13,9 @@ BOOL dpkgInvalid = NO; | |||
// Option Switches | |||
BOOL enabled = YES; | |||
BOOL typingSoundSwitch = NO; | |||
BOOL screenshotSoundSwitch = NO; | |||
BOOL isUnlock; | |||
// Homescreen | |||
SystemSoundID killingAppSound; | |||
@@ -48,6 +51,8 @@ SystemSoundID respringSound; | |||
SystemSoundID touchingSound; | |||
SystemSoundID typingSound; | |||
SystemSoundID enteringHomescreenSound; | |||
SystemSoundID alertAppearSound; | |||
SystemSoundID alertDisappearSound; | |||
NSString *siriSoundsList; | |||
NSString *screenshotSoundsList; | |||
@@ -58,6 +63,8 @@ NSString *respringSoundsList; | |||
NSString *touchingSoundsList; | |||
NSString *typingSoundsList; | |||
NSString *enteringHomescreenSoundsList; | |||
NSString *alertAppearSoundsList; | |||
NSString *alertDisappearSoundsList; | |||
// Hardware Buttons | |||
SystemSoundID volumeSound; |
@@ -210,13 +210,15 @@ | |||
+ (void)playScreenshotSound { | |||
%orig; | |||
if (enabled) { | |||
if (enabled && screenshotSoundSwitch) { | |||
screenshotSound = 0; | |||
AudioServicesDisposeSystemSoundID(screenshotSound); | |||
AudioServicesCreateSystemSoundID((CFURLRef) CFBridgingRetain([NSURL fileURLWithPath:[NSString stringWithFormat:@"/Library/Nevve/%@",screenshotSoundsList]]),& screenshotSound); | |||
AudioServicesPlaySystemSound(screenshotSound); | |||
} else { | |||
%orig; | |||
} | |||
} | |||
@@ -489,12 +491,15 @@ | |||
- (void)_playLockSound { | |||
%orig; | |||
if (enabled) { | |||
if (enabled ) { | |||
lockedSound = 0; | |||
AudioServicesDisposeSystemSoundID(lockedSound); | |||
AudioServicesCreateSystemSoundID((CFURLRef) CFBridgingRetain([NSURL fileURLWithPath:[NSString stringWithFormat:@"/Library/Nevve/%@",lockedSoundsList]]),& lockedSound); | |||
AudioServicesPlaySystemSound(lockedSound); | |||
isUnlock = YES; | |||
} else { | |||
%orig; | |||
} | |||
@@ -558,11 +563,12 @@ | |||
- (void)viewWillDisappear:(BOOL)arg1 { | |||
%orig; | |||
if (enabled) { | |||
if (enabled && isUnlock) { | |||
unlockedSound = 0; | |||
AudioServicesDisposeSystemSoundID(unlockedSound); | |||
AudioServicesCreateSystemSoundID((CFURLRef) CFBridgingRetain([NSURL fileURLWithPath:[NSString stringWithFormat:@"/Library/Nevve/%@",unlockedSoundsList]]),& unlockedSound); | |||
AudioServicesPlaySystemSound(unlockedSound); | |||
isUnlock = NO; | |||
} | |||
@@ -650,6 +656,36 @@ | |||
%end | |||
%hook UIAlertController | |||
-(void)viewWillAppear:(BOOL)arg1 { | |||
%orig; | |||
if (enabled) { | |||
alertAppearSound = 0; | |||
AudioServicesDisposeSystemSoundID(alertAppearSound); | |||
AudioServicesCreateSystemSoundID((CFURLRef) CFBridgingRetain([NSURL fileURLWithPath:[NSString stringWithFormat:@"/Library/Nevve/%@",alertAppearSoundsList]]),& alertAppearSound); | |||
AudioServicesPlaySystemSound(alertAppearSound); | |||
} | |||
} | |||
-(void)viewWillDisappear:(BOOL)arg1 { | |||
%orig; | |||
if (enabled) { | |||
alertDisappearSound = 0; | |||
AudioServicesDisposeSystemSoundID(alertDisappearSound); | |||
AudioServicesCreateSystemSoundID((CFURLRef) CFBridgingRetain([NSURL fileURLWithPath:[NSString stringWithFormat:@"/Library/Nevve/%@",alertDisappearSoundsList]]),& alertDisappearSound); | |||
AudioServicesPlaySystemSound(alertDisappearSound); | |||
} | |||
} | |||
%end | |||
%end | |||
// This is an Alert if the Tweak is pirated (DRM) | |||
@@ -726,7 +762,8 @@ | |||
// Enabled Switch | |||
[pfs registerBool:&enabled default:YES forKey:@"Enabled"]; | |||
// Option Switches | |||
[pfs registerBool:&typingSoundSwitch default:NO forKey:@"typingSoundSwitch"]; | |||
[pfs registerBool:&typingSoundSwitch default:NO forKey:@"typingSound"]; | |||
[pfs registerBool:& screenshotSoundSwitch default:NO forKey:@"screenshotSound"]; | |||
// Homescreen | |||
[pfs registerObject:& killingAppSoundsList default:nil forKey:@"killingAppSounds"]; | |||
[pfs registerObject:& forceTouchSoundsList default:nil forKey:@"forceTouchSounds"]; | |||
@@ -748,6 +785,8 @@ | |||
[pfs registerObject:& touchingSoundsList default:nil forKey:@"touchingSounds"]; | |||
[pfs registerObject:& typingSoundsList default:nil forKey:@"typingSounds"]; | |||
[pfs registerObject:& enteringHomescreenSoundsList default:nil forKey:@"enteringHomescreenSounds"]; | |||
[pfs registerObject:& alertAppearSoundsList default:nil forKey:@"alertAppearSounds"]; | |||
[pfs registerObject:& alertDisappearSoundsList default:nil forKey:@"alertDisappearSounds"]; | |||
// Hardware Buttons | |||
[pfs registerObject:& volumeSoundsList default:nil forKey:@"volumeSounds"]; | |||
[pfs registerObject:& sleepButtonSoundsList default:nil forKey:@"sleepButtonSounds"]; |
@@ -1,7 +1,7 @@ | |||
Package: sh.litten.nevve | |||
Name: Nevve | |||
Depends: mobilesubstrate, preferenceloader, firmware (>= 11), ws.hbang.common (>= 1.14) | |||
Version: 1.0.4 | |||
Name: Nevve ❄️ | |||
Depends: mobilesubstrate, preferenceloader, firmware (>= 12), ws.hbang.common (>= 1.14) | |||
Version: 1.1.1 | |||
Architecture: iphoneos-arm | |||
Description: Sounds Falling Down To Your Device | |||
Maintainer: Litten <hello@litten.sh> |
@@ -16,6 +16,6 @@ echo " ******* " | |||
echo " *** " | |||
echo " * " | |||
echo "" | |||
echo "Thank Your For Installing Nevve 1.0.4 🤗" | |||
echo "Thank Your For Installing Nevve 1.1.1 🤗" | |||
echo "" | |||
echo "" |