         sourceController source: UIViewController
         ) -> UIViewControllerAnimatedTransitioning?
     {
-        return SideMenuAnimationController()
+        let sideMenuAnimationController = SideMenuAnimationController()
+        sideMenuAnimationController.duration = presentDuration
+        return sideMenuAnimationController
     }
     
     func animationControllerForDismissedController(dismissed: UIViewController) -> UIViewControllerAnimatedTransitioning? {
-        return SideMenuDismissAnimationController()
+        let sideMenuDismissAnimationController = SideMenuDismissAnimationController()
+        sideMenuDismissAnimationController.duration = dismissDuration
+        return sideMenuDismissAnimationController
     }
     
 }
 
 class SideMenuAnimationController: NSObject, UIViewControllerAnimatedTransitioning {
     
-    let duration = 0.5
+    var duration: NSTimeInterval = 0.5
     let peekWidth: CGFloat = 44.0
 
     func transitionDuration(transitionContext: UIViewControllerContextTransitioning?) -> NSTimeInterval {


class SideMenuTransitioningController: NSObject, UIViewControllerTransitioningDelegate {
    
    // MARK: - UIViewControllerTransitioningDelegate
    
    func animationControllerForPresentedController(


class SideMenuDismissAnimationController: NSObject, UIViewControllerAnimatedTransitioning {
    
    var duration: NSTimeInterval = 0.5

    func transitionDuration(transitionContext: UIViewControllerContextTransitioning?) -> NSTimeInterval {
        return duration
