UndoableVar
A class similar to Var
but with support for undo and redo.
Attributes
- Graph
- Supertypes
- trait Sink[A]trait SignalSource[A]trait Source[A]class Objecttrait Matchableclass Any
Members list
Value members
Concrete methods
Get the current state
Get the current state
Attributes
Turn on recording; updates now save previous state in undo history
Turn on recording; updates now save previous state in undo history
Attributes
Undo the last undo
Undo the last undo
Attributes
Manually save current state in undo history
Manually save current state in undo history
Attributes
Set the current state in an undo-aware manner
Set the current state in an undo-aware manner
Attributes
Coerce to the signal
Coerce to the signal
Attributes
Coerce to the writer
Coerce to the writer
Attributes
Undo the last update
Undo the last update
Attributes
Turn off recording; updates now do not save previous state
Turn off recording; updates now do not save previous state
Attributes
Similar to update
for Var
s, but undo-aware
Similar to update
for Var
s, but undo-aware
Attributes
Use the state monad to update the Var, and returns the result asynchronously after the Var is updated.
Use the state monad to update the Var, and returns the result asynchronously after the Var is updated.
Note: IO continues before the Transaction ends; is this bad? The reason we want to use a Transaction is so that we don't lose updates to the state in between reading it out and updating it, and we need to return after that Transaction fires asynchronously; this is the only way I know how to do that. If we see weird bugs around this then we can rethink how this works.
Attributes
Use a state monad to update the Var; doesn't return the result.
Use a state monad to update the Var; doesn't return the result.
Wraps in IO for convenience.
Attributes
Similar to updater
for Var
s, but undo-aware
Similar to updater
for Var
s, but undo-aware
Attributes
Concrete fields
A signal of the current value
A signal of the current value
Attributes
An observer that wraps UndoState.update to record (or not) updates
depending on whether recording
is set in the state
An observer that wraps UndoState.update to record (or not) updates
depending on whether recording
is set in the state