flutter_undo

Last updated:

0 purchases

flutter_undo Image
flutter_undo Images
Add to Cart

Description:

flutter undo

Flutter Undo #
This package provides a mechanism to interact with UndoManager on iOS.
Getting Started #
The easiest way to use the plugin is to wrap a text editing widget in the UndoableTextElement widget:
UndoableTextElement(
controller: controller,
focusNode: focusNode,
child: TextField(controller: controller, focusNode: focusNode),
);
copied to clipboard
For more control, you can interact with the UndoManager directly:
// Register a command
UndoManager.instance.registerCommand(
UndoCommand(
undo: (identifier) {
widget.controller.value = lastValue;
},
redo: (identifier) {
widget.controller.value = currentValue;
},
),
);
copied to clipboard
// Clear the undo stack
UndoManager.instance.reset();
copied to clipboard

License:

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.