         menuView.addGestureRecognizer(rightSwipeGesture)
     }
     
+    // MARK: - Page controller
+    
+    private func moveToMenuPage(page: Int, animated: Bool) {
+        currentPage = page
+        currentViewController = pagingViewControllers[page]
+        
+        delegate?.willMoveToMenuPage?(currentPage)
+        
+        menuView.moveToMenu(page: currentPage, animated: animated)
+        
+        let duration = animated ? options.animationDuration : 0
+        UIView.animateWithDuration(duration, animations: { [unowned self] () -> Void in
+            self.scrollView.contentOffset.x = self.scrollView.frame.width * CGFloat(page)
+            }) { (finished: Bool) -> Void in
+                if finished {
+                    self.delegate?.didMoveToMenuPage?(self.currentPage)
+                }
+        }
+    }
+    
+    // MARK: - Page calculator
+    
     private func currentPagingViewPage() -> Int {
         let pageWidth = self.scrollView.frame.width
         
         return Int(floor((self.scrollView.contentOffset.x - pageWidth / 2) / pageWidth)) + 1
     }
     
-    private func targetIndex(#tappedIndex: Int) -> Int {
+    private func targetPage(#tappedPage: Int) -> Int {
         switch options.menuDisplayMode {
         case .FlexibleItemWidth(_, let scrollingMode):
             switch scrollingMode {
             case .PagingEnabled:
-                return tappedIndex < currentPage ? currentPage-1 : currentPage+1
+                return tappedPage < currentPage ? currentPage-1 : currentPage+1
             default:
-                return tappedIndex
+                return tappedPage
             }
         case .FixedItemWidth(_, _, let scrollingMode):
             switch scrollingMode {
             case .PagingEnabled:
-                return tappedIndex < currentPage ? currentPage-1 : currentPage+1
+                return tappedPage < currentPage ? currentPage-1 : currentPage+1
             default:
-                return tappedIndex
+                return tappedPage
             }
         case .SegmentedControl:
-            return tappedIndex
+            return tappedPage
         }
     }
     

        return titles
    }
    
    private func addSwipeGestureHandlersIfNeeded() {
        switch options.menuDisplayMode {
        case .FlexibleItemWidth(_, let scrollingMode):


import UIKit

@objc public protocol PagingMenuControllerDelegate: class {
    optional func willMoveToMenuPage(page: Int)
    optional func didMoveToMenuPage(page: Int)
}

public class PagingMenuController: UIViewController, UIScrollViewDelegate {
    
    public weak var delegate: PagingMenuControllerDelegate?
    private var options: PagingMenuOptions!
    private var menuView: MenuView!
    private var scrollView: UIScrollView!
