Commit 0dcb8786 authored by Randall Leeds's avatar Randall Leeds

a simple, tiny reduction in code verbosity

parent 73302aed
...@@ -114,8 +114,7 @@ class Hypothesis extends Annotator ...@@ -114,8 +114,7 @@ class Hypothesis extends Annotator
scope: "#{scope}:provider" scope: "#{scope}:provider"
onReady: => onReady: =>
console.log "Provider functions are ready for #{origin}" console.log "Provider functions are ready for #{origin}"
if source is @element.injector().get('$window').parent if source is $window.parent then @host = channel
@host = channel
entities = [] entities = []
channel = this._setupXDM options channel = this._setupXDM options
...@@ -278,10 +277,9 @@ class Hypothesis extends Annotator ...@@ -278,10 +277,9 @@ class Hypothesis extends Annotator
_setupDocumentEvents: -> _setupDocumentEvents: ->
document.addEventListener 'dragover', (event) => document.addEventListener 'dragover', (event) =>
for p in @providers @host?.notify
p.channel.notify method: 'dragFrame'
method: 'dragFrame' params: event.screenX
params: event.screenX
# Override things not used in the angular version. # Override things not used in the angular version.
_setupDynamicStyle: -> this _setupDynamicStyle: -> this
......
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