redoAction method

void redoAction()

Redo the previously undone editing action.

This function allows the user to redo an editing action that was previously undone using the undoAction function. It increases the edit position, and the image is decoded to reflect the next state.

Implementation

void redoAction() {
  if (stateManager.position < stateHistory.length - 1) {
    setState(() {
      layerInteractionManager.selectedLayerId = '';
      _checkInteractiveViewer();
      stateManager.position++;
      decodeImage();
    });
    mainEditorCallbacks?.handleRedo();
  }
}