From f0b7ef6f89f8c84c89c6eab45d110dc07adc9136 Mon Sep 17 00:00:00 2001 From: Max Lynch Date: Mon, 18 Nov 2013 10:14:24 -0600 Subject: [PATCH] Added scope events for tab bar --- js/ext/angular/src/directive/ionicTabBar.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/js/ext/angular/src/directive/ionicTabBar.js b/js/ext/angular/src/directive/ionicTabBar.js index a3f2954ebb..140b985837 100644 --- a/js/ext/angular/src/directive/ionicTabBar.js +++ b/js/ext/angular/src/directive/ionicTabBar.js @@ -90,6 +90,7 @@ angular.module('ionic.ui.tabs', ['ngAnimate']) $scope.$watch('isVisible', function(value) { if(childElement) { $animate.leave(childElement); + $scope.$broadcast('tab.hidden'); childElement = undefined; } if(childScope) { @@ -102,6 +103,8 @@ angular.module('ionic.ui.tabs', ['ngAnimate']) childElement = clone; childElement.addClass('view-full'); $animate.enter(clone, $element.parent(), $element); + + $scope.$broadcast('tab.shown'); }); } });