Browse Source

【转档】APP激活标准版序列码,再升级成高级版序列码,首页-转档仍然显示Upgrade按钮和说明文字(重启APP正常)

liujiajie 11 months ago
parent
commit
cef1af056d

+ 8 - 0
PDF Office/PDF Master/Class/Batch/WindowController/VC/KMBatchOperateConvertViewController.swift

@@ -339,6 +339,7 @@ class KMBatchOperateConvertViewController: KMBatchOperateBaseViewController,NSCo
         NotificationCenter.default.addObserver(self, selector: #selector(IAPProductRestoreFinishedNotification(notification:)), name: NSNotification.Name("KMIAPProductRestoreFinishedNotification"), object: nil)
 //        NotificationCenter.default.addObserver(self, selector: #selector(themeChanged(notification:)), name: NSNotification.Name("AppleInterfaceThemeChangedNotification"), object: nil)
         DistributedNotificationCenter.default().addObserver(self, selector: #selector(themeChanged(notification:)), name: NSNotification.Name("AppleInterfaceThemeChangedNotification"), object: nil)
+        NotificationCenter.default.addObserver(self, selector: #selector(deviceActivateStatusChanged(notification:)), name: NSNotification.Name("kDeviceActivateNotification"), object: nil)
     }
     
     
@@ -374,6 +375,13 @@ class KMBatchOperateConvertViewController: KMBatchOperateBaseViewController,NSCo
             self.collectionView.reloadData()
         }
     }
+    @objc func deviceActivateStatusChanged(notification: NSNotification) {
+        DispatchQueue.main.asyncAfter(deadline: .now() + 0.3) {
+            self.updateBottomView()
+            self.prepareData()
+            self.collectionView.reloadData()
+        }
+    }
     func updateViewColor() {
         self.view.wantsLayer = true
         if KMAppearance.isDarkMode() {