         } else {
             UIView.animateWithDuration(animationDuration, delay:0, usingSpringWithDamping:animationDamping, initialSpringVelocity:0, options:.CurveEaseInOut, animations: { () -> Void in
                     self.backgroundView.alpha = 1.0
-                    if self.displayCloseButton == true {
+                    if self.displayCloseButton {
                         self.closeButton.alpha = 1.0
                         self.closeButton.frame = self.closeButtonShowFrame
                     }
-                    if self.displayDeleteButton == true {
+                    if self.displayDeleteButton {
                         self.deleteButton.alpha = 1.0
                         self.deleteButton.frame = self.deleteButtonShowFrame
                     }
-                    if self.displayCustomCloseButton == true {
+                    if self.displayCustomCloseButton {
                         self.customCloseButton.alpha = 1.0
                         self.customCloseButton.frame = self.customCloseButtonShowFrame
                     }
-                    if self.displayCustomDeleteButton == true {
+                    if self.displayCustomDeleteButton {
                         self.customDeleteButton.alpha = 1.0
                         self.customDeleteButton.frame = self.customDeleteButtonShowFrame
                     }

                let alpha: CGFloat = hidden ? 0.0 : 1.0
                self.toolBar.alpha = alpha
                self.toolBar.frame = hidden ? self.frameForToolbarHideAtOrientation() : self.frameForToolbarAtOrientation()
                if self.displayCloseButton == true {
                    self.closeButton.alpha = alpha
                    self.closeButton.frame = hidden ? self.closeButtonHideFrame : self.closeButtonShowFrame
                }
                if self.displayDeleteButton == true {
                    self.deleteButton.alpha = alpha
                    self.deleteButton.frame = hidden ? self.deleteButtonHideFrame : self.deleteButtonShowFrame
                }
                if self.displayCustomCloseButton == true {
                    self.customCloseButton.alpha = alpha
                    self.customCloseButton.frame = hidden ? self.customCloseButtonHideFrame : self.customCloseButtonShowFrame
                }
                if self.displayCustomDeleteButton == true {
                    self.customDeleteButton.alpha = alpha
                    self.customDeleteButton.frame = hidden ? self.customDeleteButtonHideFrame : self.customDeleteButtonShowFrame
                }

        isPerformingLayout = false
    }
    
    override public func viewDidAppear(animated: Bool) {
        super.viewDidAppear(true)
        isViewActive = true
    }
    
    override public func prefersStatusBarHidden() -> Bool {
        if statusBarStyle == nil {
            return true
        }
