             return
         }
         
+        if SlideMenuOptions.slidingMode == SlideMenuOptions.SlidingMode.Standard {
+            var leftFrame: CGRect = leftContainerView.frame
+            if (leftFrame.origin.x != 0.0) {
+                leftFrame.origin.x = 0.0
+                leftContainerView.frame = leftFrame
+            }
+        }
+        
         switch panGesture.state {
             case UIGestureRecognizerState.Began:
+                if SlideMenuOptions.mainContainerViewAlwaysOnTop {
+                    if SlideMenuOptions.slidingMode == SlideMenuOptions.SlidingMode.Standard {
+                        LeftPanState.frameAtStartOfPan = mainContainerView.frame
+                    } else {
+                        LeftPanState.frameAtStartOfPan = leftContainerView.frame
+                    }
+                } else {
+                    LeftPanState.frameAtStartOfPan = leftContainerView.frame
+                }
                 
-                LeftPanState.frameAtStartOfPan = leftContainerView.frame
                 LeftPanState.startPointOfPan = panGesture.locationInView(view)
                 LeftPanState.wasOpenAtStartOfPan = isLeftOpen()
                 LeftPanState.wasHiddenAtStartOfPan = isLeftHidden()
                 
-                leftViewController?.beginAppearanceTransition(LeftPanState.wasHiddenAtStartOfPan, animated: true)
+                if SlideMenuOptions.mainContainerViewAlwaysOnTop && SlideMenuOptions.slidingMode == SlideMenuOptions.SlidingMode.Standard {
+                    mainViewController?.beginAppearanceTransition(LeftPanState.wasHiddenAtStartOfPan, animated: true)
+                } else {
+                    leftViewController?.beginAppearanceTransition(LeftPanState.wasHiddenAtStartOfPan, animated: true)
+                    mainViewController?.beginAppearanceTransition(LeftPanState.wasHiddenAtStartOfPan, animated: true)
+                }
+                
                 addShadowToView(leftContainerView)
+                addShadowToView(mainContainerView)
+
                 setOpenWindowLevel()
             case UIGestureRecognizerState.Changed:
                 
                 let translation: CGPoint = panGesture.translationInView(panGesture.view!)
-                leftContainerView.frame = applyLeftTranslation(translation, toFrame: LeftPanState.frameAtStartOfPan)
+                
+                if SlideMenuOptions.mainContainerViewAlwaysOnTop && SlideMenuOptions.slidingMode == SlideMenuOptions.SlidingMode.Standard {
+                    mainContainerView.frame = applyLeftTranslation(translation, toFrame: LeftPanState.frameAtStartOfPan)
+                } else {
+                    leftContainerView.frame = applyLeftTranslation(translation, toFrame: LeftPanState.frameAtStartOfPan)
+                    var mainViewFrame: CGRect = mainContainerView.frame
+                    mainViewFrame.origin.x = leftContainerView.frame.origin.x + leftContainerView.frame.size.width
+                    mainContainerView.frame = mainViewFrame
+                }
+                
                 applyLeftOpacity()
                 applyLeftContentViewScale()
             case UIGestureRecognizerState.Ended:

        var newOrigin: CGFloat = toFrame.origin.x
        newOrigin += translation.x
        
        let minOrigin: CGFloat = leftMinOrigin()
        let maxOrigin: CGFloat = 0.0
        var newFrame: CGRect = toFrame
        
        if newOrigin < minOrigin {

        var frame: CGRect = leftContainerView.frame;
        frame.origin.x = finalXOrigin
    
        var frameMainContent: CGRect = mainContainerView.frame
        frameMainContent.origin.x = 0.0
        
        if SlideMenuOptions.mainContainerViewAlwaysOnTop {
            if SlideMenuOptions.slidingMode == SlideMenuOptions.SlidingMode.Push {
                frame.origin.x = finalXOrigin;
            }
        } else {
            if SlideMenuOptions.slidingMode == SlideMenuOptions.SlidingMode.Standard {
                frame.origin.x = finalXOrigin
            } else if SlideMenuOptions.slidingMode == SlideMenuOptions.SlidingMode.Push {
                frame.origin.x = finalXOrigin
            }
        }

        var duration: NSTimeInterval = Double(SlideMenuOptions.animationDuration)
        if velocity != 0.0 {
            duration = Double(fabs(xOrigin - finalXOrigin) / velocity)
