[LyX/master] Update correctly completion after undo
Jean-Marc Lasgouttes
lasgouttes at lyx.org
Thu Oct 14 14:19:00 UTC 2021
commit 06acb7f806f99cd418781f9d0645b213f8241062
Author: Jean-Marc Lasgouttes <lasgouttes at lyx.org>
Date: Thu Oct 14 16:39:33 2021 +0200
Update correctly completion after undo
This is take #2 after reverting e59aee458.
Request the completer to rebuild a completion after undo/redo.
Fixes #12383.
---
src/frontends/qt/GuiView.cpp | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/src/frontends/qt/GuiView.cpp b/src/frontends/qt/GuiView.cpp
index 767791f..9126d48 100644
--- a/src/frontends/qt/GuiView.cpp
+++ b/src/frontends/qt/GuiView.cpp
@@ -4067,8 +4067,10 @@ void GuiView::dispatchToBufferView(FuncRequest const & cmd, DispatchResult & dr)
// Let the current BufferView dispatch its own actions.
bv->dispatch(cmd, dr);
if (dr.dispatched()) {
- if (cmd.action() == LFUN_REDO || cmd.action() == LFUN_UNDO)
+ if (cmd.action() == LFUN_REDO || cmd.action() == LFUN_UNDO) {
+ updateCompletion(bv->cursor(), true, false);
updateDialog("document", "");
+ }
return;
}
More information about the lyx-cvs
mailing list