forked from martanne/vis
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
view: add infrastructure for delayed cursor destruction
At least one cursor (referred to as primary or main cursor) has always to exist. In the sam command language implementation we might want to dispose a cursor even if it is the primary one before later commands will create different ones (e.g. `:x/pattern/ { i/>>>/ a/<<</ }`). This commit introduces view_cursors_dispose_force. If called on the last remaining cursor, its selection is cleared and it is marked for destruction as soon as a new cursor is created. view_cursor_disposed returns the cursor marked for deletion (if any) and clears the descruction flag.
- Loading branch information
Showing
2 changed files
with
30 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters