Add vibrate on zap

Changelog-Added: Vibrate when a zap is received
Closes: #768
This commit is contained in:
Swift
2023-03-09 13:36:42 -05:00
committed by William Casarin
parent d982bb886e
commit 73f7b69654
3 changed files with 36 additions and 6 deletions

View File

@@ -101,6 +101,12 @@ class UserSettingsStore: ObservableObject {
}
}
@Published var zap_vibration: Bool {
didSet {
UserDefaults.standard.set(zap_vibration, forKey: "zap_vibration")
}
}
@Published var translation_service: TranslationService {
didSet {
UserDefaults.standard.set(translation_service.rawValue, forKey: "translation_service")
@@ -178,6 +184,7 @@ class UserSettingsStore: ObservableObject {
show_wallet_selector = should_show_wallet_selector(pubkey)
left_handed = UserDefaults.standard.object(forKey: "left_handed") as? Bool ?? false
zap_vibration = UserDefaults.standard.object(forKey: "zap_vibration") as? Bool ?? false
disable_animation = should_disable_image_animation()
// Note from @tyiu: