@@ -5756,6 +5756,7 @@ ionic.controllers.NavController = ionic.controllers.ViewController.inherit({
5756
5756
* Toggle the left menu to open 100%
5757
5757
*/
5758
5758
toggleLeft : function ( ) {
5759
+ this . content . enableAnimation ( ) ;
5759
5760
var openAmount = this . getOpenAmount ( ) ;
5760
5761
if ( openAmount > 0 ) {
5761
5762
this . openPercentage ( 0 ) ;
@@ -5768,6 +5769,7 @@ ionic.controllers.NavController = ionic.controllers.ViewController.inherit({
5768
5769
* Toggle the right menu to open 100%
5769
5770
*/
5770
5771
toggleRight : function ( ) {
5772
+ this . content . enableAnimation ( ) ;
5771
5773
var openAmount = this . getOpenAmount ( ) ;
5772
5774
if ( openAmount < 0 ) {
5773
5775
this . openPercentage ( 0 ) ;
@@ -5837,6 +5839,8 @@ ionic.controllers.NavController = ionic.controllers.ViewController.inherit({
5837
5839
* negative value for right menu (only one menu will be visible at a time).
5838
5840
*/
5839
5841
openAmount : function ( amount ) {
5842
+ console . log ( 'OPEN AMOUNT' , amount ) ;
5843
+
5840
5844
var maxLeft = this . left && this . left . width || 0 ;
5841
5845
var maxRight = this . right && this . right . width || 0 ;
5842
5846
@@ -5878,6 +5882,7 @@ ionic.controllers.NavController = ionic.controllers.ViewController.inherit({
5878
5882
* @param {Event } e the gesture event to use for snapping
5879
5883
*/
5880
5884
snapToRest : function ( e ) {
5885
+ console . log ( 'SNAP TO REST' ) ;
5881
5886
// We want to animate at the end of this
5882
5887
this . content . enableAnimation ( ) ;
5883
5888
this . _isDragging = false ;
@@ -5936,7 +5941,9 @@ ionic.controllers.NavController = ionic.controllers.ViewController.inherit({
5936
5941
5937
5942
// End a drag with the given event
5938
5943
_endDrag : function ( e ) {
5939
- this . snapToRest ( e ) ;
5944
+ if ( this . _isDragging ) {
5945
+ this . snapToRest ( e ) ;
5946
+ }
5940
5947
this . _startX = null ;
5941
5948
this . _lastX = null ;
5942
5949
this . _offsetX = null ;
0 commit comments