     }
     
     private func dismissedFrameInContainerView(containerView: UIView, direction: Direction) -> CGRect {
-        var frame = presentedFrameInContainerView(containerView, direction: direction)
+        var frame = presentedFrameInContainerView(containerView)
         switch direction {
         case .Left:
             frame.origin.x += containerView.frame.size.width

    
    // MARK: - Private functions
    
    private func presentedFrameInContainerView(containerView: UIView, direction: Direction) -> CGRect {
        // TODO: Use AutoLayout
        var frame = containerView.bounds
        frame.origin.x += leftInset

            options: UIViewAnimationOptions.CurveEaseInOut,
            animations: {
                fromViewController?.view.frame = self.dismissedFrameInContainerView(containerView, direction: self.direction)
                toViewController?.view.frame = self.presentedFrameInContainerView(containerView)
            }
            )
        { finished in
