mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-03-22 15:19:59 +07:00
[rd-editor] IJPL-185748 Frontend speculative undo/redo
GitOrigin-RevId: 58a5cc8f70827e79d080d236332de18022c26e6c
This commit is contained in:
committed by
intellij-monorepo-bot
parent
25f56bbecf
commit
e530e2a172
@@ -232,6 +232,7 @@ final class UndoClientState implements Disposable {
|
||||
|
||||
void flushCurrentCommand() {
|
||||
commandMerger.flushCurrentCommand(undoStacksHolder, nextCommandTimestamp());
|
||||
undoSpy.flushCommand(project);
|
||||
}
|
||||
|
||||
boolean isInsideCommand() {
|
||||
|
||||
@@ -31,12 +31,15 @@ interface UndoSpy {
|
||||
isTransparent: Boolean,
|
||||
)
|
||||
|
||||
fun flushCommand(project: Project?)
|
||||
|
||||
companion object {
|
||||
@JvmField
|
||||
val BLIND: UndoSpy = object : UndoSpy {
|
||||
override fun commandStarted(project: Project?, undoConfirmationPolicy: UndoConfirmationPolicy) = Unit
|
||||
override fun addUndoableAction(action: UndoableAction, type: UndoableActionType) = Unit
|
||||
override fun commandFinished(project: Project?, commandName: @Command String?, commandGroupId: Any?, isTransparent: Boolean) = Unit
|
||||
override fun commandStarted(project: Project?, undoConfirmationPolicy: UndoConfirmationPolicy) {}
|
||||
override fun addUndoableAction(action: UndoableAction, type: UndoableActionType) {}
|
||||
override fun commandFinished(project: Project?, commandName: @Command String?, commandGroupId: Any?, isTransparent: Boolean) {}
|
||||
override fun flushCommand(project: Project?) {}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user