From d88f0bcbe8f9e12b3c9ee9f09c2a072e77a6984e Mon Sep 17 00:00:00 2001 From: Ilya Laktyushin Date: Sat, 9 Feb 2019 00:06:58 +0400 Subject: [PATCH] Fixed status bar vanishing after web view media playback --- Telegram-iOS/AppDelegate.swift | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Telegram-iOS/AppDelegate.swift b/Telegram-iOS/AppDelegate.swift index 28e31009ca..fba870de05 100644 --- a/Telegram-iOS/AppDelegate.swift +++ b/Telegram-iOS/AppDelegate.swift @@ -1065,6 +1065,12 @@ private final class SharedApplicationContext { BITHockeyManager.shared().start() BITHockeyManager.shared().authenticator.authenticateInstallation() } + + NotificationCenter.default.addObserver(forName: NSNotification.Name.UIWindowDidBecomeHidden, object: nil, queue: nil, using: { notification in + if UIApplication.shared.isStatusBarHidden { + UIApplication.shared.setStatusBarHidden(false, with: .none) + } + }) return true }