mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-23 17:06:16 -04:00
Merge pull request #2724 from xavidotron/develop
Add a aceSelectionChanged hook to allow plugins to react when the cursor moves
This commit is contained in:
commit
c337a0585c
2 changed files with 16 additions and 0 deletions
|
@ -339,3 +339,14 @@ Things in context:
|
|||
|
||||
This hook is provided to allow author highlight style to be modified.
|
||||
Registered hooks should return 1 if the plugin handles highlighting. If no plugin returns 1, the core will use the default background-based highlighting.
|
||||
|
||||
## aceSelectionChanged
|
||||
Called from: src/static/js/ace2_inner.js
|
||||
|
||||
Things in context:
|
||||
|
||||
1. rep - information about where the user's cursor is
|
||||
2. documentAttributeManager - information about attributes in the document
|
||||
|
||||
This hook allows a plugin to react to a cursor or selection change,
|
||||
perhaps to update a UI element based on the style at the cursor location.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue