angular.module('daily', ['dailiesFilters']).
  config(['$routeProvider', function($routeProvider) {
  $routeProvider.
  	  when('/home', {templateUrl: 'partials/home.html',   controller: HomeCtrl }).
  	  when('/answer', {templateUrl: 'partials/answer.html',   controller: AnswerCtrl }).
  	  when('/support', {templateUrl: 'partials/support.html',   controller: SupportCtrl }).
      when('/daily', {templateUrl: 'partials/daily.html',   controller: DailyCtrl }).
      when('/ok', {templateUrl: 'partials/ok.html',  controller: OkCtrl}).
      when('/bad', {templateUrl: 'partials/bad.html',  controller: OkCtrl}).
      when('/login', {templateUrl: 'partials/login.html',  controller: LoginCtrl}).
      when('/tutorial', {templateUrl: 'partials/tutorial.html', controller: TutorialCtrl}).
      otherwise({redirectTo: '/home' });
}])
.directive('stopEvent', function () {
  return {
    link: function (scope, element, attr) {
      element.bind(attr.stopEvent, function (e) {
          e.stopPropagation();
      });
    }
  };
});