title: Disable swipe to view sidemenu when using tabs
body: <p>I'm writing a small ionic app and have an issue. I'm using a sidemenu and also tabs. I have an ionic slide-box in one of my views, when I wipe this slidebox from left to right the side menu slides out. I've read through various related topics on the ionic forum but none have worked.</p>
  
  <p>I've tried adding <code>drag-content="false"</code> to various tags and also added <code>$ionicSideMenuDelegate.canDragContent(false);</code> to my controller.</p>
  
  <p>Neither worked. I think it's because I'm using a sidemenu, with tabs and views in the tabs. Heres my code:</p>
  
  <p>index.html</p>
  
  <pre><code>    &lt;ion-side-menus&gt;
  
      &lt;!-- Header bar --&gt;
      &lt;ion-side-menu-content ng-controller="NavCtrl" drag-content="false"&gt;
          &lt;ion-nav-bar class="bar-positive"&gt;
              &lt;ion-nav-back-button class="button-icon ion-ios7-arrow-back"&gt;
              &lt;/ion-nav-back-button&gt;
          &lt;/ion-nav-bar&gt;
  
          &lt;!-- Page content --&gt;
          &lt;ion-nav-view drag-content="false" animation="slide-left-right"&gt;&lt;/ion-nav-view&gt;
      &lt;/ion-side-menu-content&gt; 
  
      &lt;!-- Side menu --&gt;
      &lt;ion-side-menu side="left" class="side-menu"&gt;
          &lt;ion-header-bar class="bar bar-header bar-dark"&gt;
              &lt;h1 class="title"&gt;Menu&lt;/h1&gt;
          &lt;/ion-header-bar&gt;
          &lt;ion-content has-header="true"&gt;
  
              &lt;div ng-if="authData.twitter" class="logged-in-user item item-avatar"&gt;
                  &lt;img ng-src="{{authData.twitter.cachedUserProfile.profile_image_url}}"/&gt;
                  &lt;h2&gt;Hello, {{authData.twitter.displayName}}&lt;/h2&gt;
                  &lt;p&gt;Logged in via Twitter&lt;/p&gt;
              &lt;/div&gt;
  
              &lt;div ng-if="authData.facebook" class="logged-in-user item item-avatar"&gt;
                  &lt;img ng-src="{{authData.facebook.cachedUserProfile.picture.data.url}}"/&gt;
                  &lt;h2&gt;Hello, {{authData.facebook.displayName}}&lt;/h2&gt;
                  &lt;p&gt;Logged in via Facebook&lt;/p&gt;
              &lt;/div&gt;
  
              &lt;ul class="list"&gt;
                  &lt;li&gt;
                      &lt;a class="item item-icon-left" menu-close nav-clear href="#/venue"&gt;
                          &lt;i class="icon ion-ios7-location"&gt;&lt;/i&gt;Venue
                      &lt;/a&gt;
                  &lt;/li&gt;
                  &lt;li&gt;
                      &lt;a class="item item-icon-left" menu-close nav-clear href="#/lunch"&gt;
                          &lt;i class="icon ion-pizza"&gt;&lt;/i&gt;Lunch
                      &lt;/a&gt;
                  &lt;/li&gt;
                  &lt;li&gt;
                      &lt;a class="item item-icon-left" menu-close nav-clear href="#/wifi"&gt;
                          &lt;i class="icon ion-wifi"&gt;&lt;/i&gt;Wifi
                      &lt;/a&gt;
                  &lt;/li&gt;
              &lt;/ul&gt;
          &lt;/ion-content&gt;
          &lt;ion-footer-bar class="bar bar-dark"&gt;
              &lt;button class="button button-icon icon ion-log-out menu-close nav-clear" ng-controller="LoginCtrl" ng-click="logout()"&gt; Logout&lt;/button&gt;
          &lt;/ion-footer-bar&gt;
      &lt;/ion-side-menu&gt;  
  
    &lt;/ion-side-menus&gt;
  </code></pre>
  
  <p>and my view:</p>
  
  <pre><code>&lt;ion-view title="Agenda"&gt;
  &lt;ion-content drag-content="false"&gt;
      &lt;ion-slide-box on-slide-changed="slideHasChanged($index)"&gt;
          &lt;ion-slide&gt;
              &lt;div class="header-card header-card--image"&gt;
                  &lt;div class="overlay"&gt;
                      &lt;div class="item item-text-wrap"&gt;
                          &lt;h3 class="header-card__heading"&gt;Happening now&lt;/h3&gt;
                          &lt;img ng-src="img/me.jpeg" class="header-card__avatar"/&gt;
                          &lt;h2 class="header-card__heading"&gt;some guy&lt;/h2&gt;
                          &lt;p class="header-card__text"&gt;Some title&lt;/p&gt;
                      &lt;/div&gt;
                  &lt;/div&gt;
              &lt;/div&gt;
          &lt;/ion-slide&gt;
          &lt;ion-slide&gt;
              &lt;div class="header-card header-card--image"&gt;
                  &lt;div class="overlay"&gt;
                      &lt;div class="item item-text-wrap"&gt;
                          &lt;h3 class="header-card__heading"&gt;Coming Next&lt;/h3&gt;
                          &lt;img ng-src="img/me.jpeg" class="header-card__avatar"/&gt;
                          &lt;h2 class="header-card__heading"&gt;Some guy&lt;/h2&gt;
                          &lt;p class="header-card__text"&gt;Slowly taking over the world&lt;/p&gt;
                      &lt;/div&gt;
                  &lt;/div&gt;
              &lt;/div&gt;
          &lt;/ion-slide&gt;
      &lt;/ion-slide-box&gt;
      &lt;ion-list&gt;
          &lt;ion-item ng-repeat="(id,agendaItem) in agendaItems" type="item-text-wrap" href="#/tab/agendaItem/{{agendaItem.$id}}" class="item item-avatar item-with-grid"&gt;
              &lt;img ng-src="{{agendaItem.image}}"&gt;
              &lt;p&gt;{{agendaItem.startTime}} &lt;i ng-if="agendaItem.hasNotificationSet == true" class="icon-left ion-ios7-bell"&gt;&lt;/i&gt;&lt;/p&gt;
              &lt;h2&gt;{{agendaItem.title}}&lt;/h2&gt;
              &lt;p&gt;{{agendaItem.speaker}}&lt;/p&gt;
              &lt;ion-option-button ng-class="agendaItem.hasNotificationSet ? 'button-balanced icon ion-ios7-bell' : 'button-positive icon ion-ios7-bell-outline'" ng-controller="NotificationCtrl" ng-click="add(agendaItem)"&gt;&lt;/ion-option-button&gt;
  
              &lt;!--&lt;ion-option-button ng-click="getNotificationIds()"&gt;&lt;/ion-option-button&gt;--&gt;
          &lt;/ion-item&gt;
      &lt;/ion-list&gt;
  &lt;/ion-content&gt;
  </code></pre>
  
  <p></p>
  
  <p>and my controller:</p>
  
  <pre><code>.controller('AgendaCtrl', function($scope, AgendaFactory, $ionicSideMenuDelegate, $rootScope, $ionicPopup, $timeout, $cordovaLocalNotification, NotificationFactory) {
  
      $ionicSideMenuDelegate.canDragContent(false); // doesn't seem to work
  
      var agendaItems = AgendaFactory.getAgenda();
  
      // Loop through agenda itens and check which have notifications set
      agendaItems.$loaded().then(function(array) {
          angular.forEach(array, function(value, key) {
  
          if (NotificationFactory.isNotificationScheduled(value.notificationId) == true) {
                  value.hasNotificationSet = true;
          } else {
                  value.hasNotificationSet = false;
          }
  
      });
  
      $scope.getNotificationIds = function () {
          $cordovaLocalNotification.getScheduledIds().then(function (scheduledIds) {
            console.log(scheduledIds);
          });
        };
  
          $scope.agendaItems = agendaItems;
      });
  
      $scope.firstTimeLogin = $rootScope.firstTimeLogin;
  
  })
  </code></pre>