 		AVAudioSession.sharedInstance().addObserver(self, forKeyPath: "outputVolume", options: [.old, .new], context: nil)
 		
 		// Observe when application enters and resumes from background
-		NotificationCenter.default.addObserver(self, selector: #selector(UIApplicationDelegate.applicationWillResignActive(_:)), name: NSNotification.Name.UIApplicationWillResignActive, object: nil)
-		NotificationCenter.default.addObserver(self, selector: #selector(UIApplicationDelegate.applicationDidBecomeActive(_:)), name: NSNotification.Name.UIApplicationDidBecomeActive, object: nil)
+		NotificationCenter.default.addObserver(self, selector: #selector(VolumeBar.applicationWillResignActive(notification:)), name: NSNotification.Name.UIApplicationWillResignActive, object: nil)
+		NotificationCenter.default.addObserver(self, selector: #selector(VolumeBar.applicationDidBecomeActive(notification:)), name: NSNotification.Name.UIApplicationDidBecomeActive, object: nil)
 		
 		// Observe device rotation
 		NotificationCenter.default.addObserver(self, selector: #selector(VolumeBar.updateHeight), name: NSNotification.Name.UIDeviceOrientationDidChange, object: nil)

	}
	
	/// Returns the `statusBarStyle` property of the `VolumeBar`.
	private override var preferredStatusBarStyle: UIStatusBarStyle {
		guard let bar = volumeBar else { return .default }
		return bar.statusBarStyle
	}
	
	/// Returns the `statusBarHidden` property of the `VolumeBar`.
	private override var prefersStatusBarHidden: Bool {
		guard let bar = volumeBar else { return false }
		return bar.statusBarActuallyHidden
	}

	/// Observe changes in volume.
	///
	/// This method is called when the user presses either of the volume buttons.
	public override func observeValue(forKeyPath keyPath: String?, of object: Any?, change: [NSKeyValueChangeKey: Any]?, context: UnsafeMutableRawPointer?) {
		// Exit early if the object isn't an `AVAudioSession`.
		guard object is AVAudioSession else { return }
		
		show()
	}
	
	/// Observe when the application background state changes.
	public func applicationWillResignActive(notification: Notification) {
