Add sections for events

This commit is contained in:
Ben Ogle
2014-09-09 12:30:43 -07:00
parent 0f83fe54f9
commit e452b88fec
2 changed files with 16 additions and 0 deletions

View File

@@ -54,6 +54,10 @@ class Cursor extends Model
@emitter.dispose()
@needsAutoscroll = true
###
Section: Events
###
# Essential: Calls your `callback` when the cursor has been moved.
#
# * `callback` {Function}
@@ -91,6 +95,10 @@ class Cursor extends Model
Grim.deprecate("::on is no longer supported. Use the event subscription methods instead")
super
###
Section: Methods
###
destroy: ->
@marker.destroy()

View File

@@ -30,6 +30,10 @@ class Selection extends Model
@emitter.emit 'did-destroy'
@emitter.dispose()
###
Section: Events
###
# Extended: Calls your `callback` when the selection was moved.
#
# * `callback` {Function}
@@ -52,6 +56,10 @@ class Selection extends Model
super
###
Section: Methods
###
destroy: ->
@marker.destroy()