Przeglądaj źródła

iOS: Passcode setting off on cancel (closes #18137)

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
Soomin Lee 8 lat temu
rodzic
commit
7b6d638440
1 zmienionych plików z 3 dodań i 0 usunięć
  1. 3 0
      Sources/VLCSettingsController.m

+ 3 - 0
Sources/VLCSettingsController.m

@@ -94,6 +94,9 @@
 - (void)PAPasscodeViewControllerDidCancel:(PAPasscodeViewController *)controller
 {
     [[VLCKeychainCoordinator defaultCoordinator] setPasscode:nil];
+
+    //Set manually the value to NO to disable the UISwitch.
+    [[NSUserDefaults standardUserDefaults] setBool:NO forKey:kVLCSettingPasscodeOnKey];
     [self didChangePasscodeStatus:NO];
 
     [controller dismissViewControllerAnimated:YES completion:nil];