summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorAndrej Mihajlov <and@mullvad.net>2021-10-11 12:49:00 +0200
committerAndrej Mihajlov <and@mullvad.net>2021-11-03 13:30:51 +0100
commitb1de55c65369025a87ecc89c5121e9b41bd9fb09 (patch)
treeb2a924b74ae0a1c57c1cedbfb6fb8cbab8ec6986
parent0bb2c7ef8005bfba08b6343d102f52523ba502f1 (diff)
downloadmullvadvpn-b1de55c65369025a87ecc89c5121e9b41bd9fb09.tar.xz
mullvadvpn-b1de55c65369025a87ecc89c5121e9b41bd9fb09.zip
Preferences: disable swipe to dismiss when editing
-rw-r--r--ios/MullvadVPN/PreferencesViewController.swift7
1 files changed, 7 insertions, 0 deletions
diff --git a/ios/MullvadVPN/PreferencesViewController.swift b/ios/MullvadVPN/PreferencesViewController.swift
index d0130bd9a8..56204c995a 100644
--- a/ios/MullvadVPN/PreferencesViewController.swift
+++ b/ios/MullvadVPN/PreferencesViewController.swift
@@ -47,6 +47,13 @@ class PreferencesViewController: UITableViewController, PreferencesDataSourceDel
override func setEditing(_ editing: Bool, animated: Bool) {
dataSource.setEditing(editing, animated: animated)
+ if #available(iOS 13.0, *) {
+ // Disable swipe to dismiss when editing
+ isModalInPresentation = editing
+ } else {
+ // no-op
+ }
+
super.setEditing(editing, animated: animated)
}