Commit c85f1c88 authored by Randall Leeds's avatar Randall Leeds

Merge pull request #2070 from hypothesis/1979-clear-selected-annotations

AppController listens to 'beforeAnnotationCreated'
parents a76f7683 29b98048
......@@ -20,13 +20,15 @@ class AnnotationUIController
class AppController
this.$inject = [
'$controller', '$document', '$location', '$route', '$scope', '$window',
'$controller', '$document', '$location', '$rootScope', '$route', '$scope',
'$window',
'auth', 'drafts', 'identity',
'permissions', 'streamer', 'annotationUI',
'annotationMapper', 'threading'
]
constructor: (
$controller, $document, $location, $route, $scope, $window,
$controller, $document, $location, $rootScope, $route, $scope,
$window,
auth, drafts, identity,
permissions, streamer, annotationUI,
annotationMapper, threading
......@@ -103,6 +105,9 @@ class AppController
# Reload the view.
$route.reload()
$rootScope.$on 'beforeAnnotationCreated', ->
$scope.clearSelection()
$scope.login = ->
$scope.dialog.visible = true
identity.request {oncancel}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment