     private func invalidDismissTimer() {
         dismissTimer?.invalidate()
         dismissTimer = nil
-    }
-
-    /**
-    Get the current top viewController.
-    
-    - returns: current top viewController instance or nil.
-    */
-    private func getTopViewController() -> UIViewController? {
-        var topController: UIViewController? = UIApplication.sharedApplication().keyWindow?.rootViewController
-        while topController?.presentedViewController != nil {
-            topController = topController?.presentedViewController
-        }
-        return topController
     }
 
     /**

        seperateView.hidden = actionButton.hidden
        actionButtonWidthConstraint?.constant = actionButton.hidden ? 0 : (secondActionButton.hidden ? TTGSnackbar.snackbarActionButtonMaxWidth : TTGSnackbar.snackbarActionButtonMinWidth)
        secondActionButtonWidthConstraint?.constant = secondActionButton.hidden ? 0 : (actionButton.hidden ? TTGSnackbar.snackbarActionButtonMaxWidth : TTGSnackbar.snackbarActionButtonMinWidth)
        
        self.layoutIfNeeded()

        // Find current stop viewcontroller
        if let topController = getTopViewController() {
            let superView: UIView = topController.view
            superView.addSubview(self)

            // Snackbar height constraint


            // Show 
            showWithAnimation()
        } else {
            fatalError("TTGSnackbar needs a keyWindows to display.")
        }
    }

