         isPerformingLayout = false
     }
     
-    override open func viewDidAppear(_ animated: Bool) {
+    override public func viewDidAppear(animated: Bool) {
         super.viewDidAppear(true)
         isViewActive = true
-
-    }
-    
-    override open var prefersStatusBarHidden: Bool {
-        get {
-            return !SKPhotoBrowserOptions.displayStatusbar
-        }
     }
     
     // MARK: - Notification
-    open func handleSKPhotoLoadingDidEndNotification(_ notification: Notification) {
+    public func handleSKPhotoLoadingDidEndNotification(notification: NSNotification) {
         guard let photo = notification.object as? SKPhotoProtocol else {
             return
         }
         
-        DispatchQueue.main.async(execute: {
-            guard let page = self.pagingScrollView.pageDisplayingAtPhoto(photo), let photo = page.photo else {
+        dispatch_async(dispatch_get_main_queue(), {
+            guard let page = self.pagingScrollView.pageDisplayingAtPhoto(photo), photo = page.photo else {
                 return
             }
             

    
    func configureCloseButton() {
        closeButton = SKCloseButton(frame: .zero)
        closeButton.addTarget(self, action: #selector(closeButtonPressed(_:)), for: .touchUpInside)
        closeButton.isHidden = !SKPhotoBrowserOptions.displayCloseButton
        view.addSubview(closeButton)
    }
    
    func configureDeleteButton() {
        deleteButton = SKDeleteButton(frame: .zero)
        deleteButton.addTarget(self, action: #selector(deleteButtonPressed(_:)), for: .touchUpInside)
        deleteButton.isHidden = !SKPhotoBrowserOptions.displayDeleteButton
        view.addSubview(deleteButton)
    }
    

            closeButton.alpha = 1
            closeButton.frame = closeButton.showFrame
        }
        if showDeleteButton {
            deleteButton.alpha = 1
            deleteButton.frame = deleteButton.showFrame
        }
    }
    
    func pageDisplayedAtIndex(index: Int) -> SKZoomingScrollView? {
        return pagingScrollView.pageDisplayedAtIndex(index)
    }
    
    func getImageFromView(sender: UIView) -> UIImage {
        UIGraphicsBeginImageContextWithOptions(sender.frame.size, true, 0.0)
        sender.layer.renderInContext(UIGraphicsGetCurrentContext()!)
        let result = UIGraphicsGetImageFromCurrentImageContext()
        UIGraphicsEndImageContext()
        return result!
