From 190275beff4541a0415fea000ab1499e59438c4b Mon Sep 17 00:00:00 2001 From: Luis Grassi Date: Tue, 19 Jun 2018 14:54:32 +0200 Subject: [PATCH] fixed window level --- PasscodeLock/PasscodeLockPresenter.swift | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/PasscodeLock/PasscodeLockPresenter.swift b/PasscodeLock/PasscodeLockPresenter.swift index abf53718..5ecbd8e3 100644 --- a/PasscodeLock/PasscodeLockPresenter.swift +++ b/PasscodeLock/PasscodeLockPresenter.swift @@ -70,7 +70,6 @@ open class PasscodeLockPresenter { public init(mainWindow window: UIWindow?, configuration: PasscodeLockConfigurationType, viewController: PasscodeLockViewController) { mainWindow = window - mainWindow?.windowLevel = 1 passcodeConfiguration = configuration passcodeLockVC = viewController } @@ -89,10 +88,9 @@ open class PasscodeLockPresenter { isPasscodePresented = true - passcodeLockWindow.windowLevel = 2 + passcodeLockWindow.windowLevel = UIWindowLevelStatusBar passcodeLockWindow.isHidden = false - mainWindow?.windowLevel = 1 mainWindow?.endEditing(true) let passcodeLockVC = PasscodeLockViewController(state: .enterPasscode, configuration: (config ?? passcodeConfiguration), stringsToShow: stringsToShow, tintColor: tintColor, font: font) @@ -114,7 +112,6 @@ open class PasscodeLockPresenter { open func dismissPasscodeLock(animated: Bool = true) { isPasscodePresented = false - mainWindow?.windowLevel = 1 mainWindow?.makeKeyAndVisible() if animated {