fix(sideMenu): enable menu w/ different historyId back view

This commit is contained in:
Adam Bradley
2014-12-03 23:28:00 -06:00
parent 74cc98039b
commit 6a1c53301c
3 changed files with 65 additions and 5 deletions

View File

@@ -368,7 +368,12 @@ function($scope, $attrs, $ionicSideMenuDelegate, $ionicPlatform, $ionicBody, $io
startX <= self.edgeThreshold ||
startX >= self.content.element.offsetWidth - self.edgeThreshold;
var menuEnabled = self.enableMenuWithBackViews() ? true : !$ionicHistory.backView();
var backView = $ionicHistory.backView();
var menuEnabled = enableMenuWithBackViews ? true : !backView;
if (!menuEnabled) {
var currentView = $ionicHistory.currentView() || {};
return backView.historyId !== currentView.historyId;
}
return ($scope.dragContent || self.isOpen()) &&
dragIsWithinBounds &&