Sfoglia il codice sorgente

display(iOS): fixed crash when switching displays

osy 2 anni fa
parent
commit
cc06ff098e

+ 0 - 2
Platform/iOS/Display/VMDisplayViewController.h

@@ -27,8 +27,6 @@
 @property (nonatomic) BOOL hasAutoSave;
 @property (nonatomic, readwrite) BOOL prefersStatusBarHidden;
 
-@property (nonatomic, strong) NSMutableArray<NSObject *> *notifications;
-
 - (void)showKeyboard;
 - (void)hideKeyboard;
 

+ 0 - 8
Platform/iOS/Display/VMDisplayViewController.swift

@@ -47,14 +47,6 @@ public extension VMDisplayViewController {
         navigationController?.setNavigationBarHidden(true, animated: animated)
     }
     
-    override func viewWillDisappear(_ animated: Bool) {
-        super.viewWillDisappear(animated)
-        for notification in notifications {
-            NotificationCenter.default.removeObserver(notification)
-        }
-        notifications.removeAllObjects()
-    }
-    
     override func viewDidAppear(_ animated: Bool) {
         super.viewDidAppear(animated)
         if runInBackground {