commit cc77602066cffdc030ce6b7b71eaa78d0bcf737f
Author: Juergen Spitzmueller <sp...@lyx.org>
Date:   Fri May 24 14:19:18 2024 +0200

    InsetNote: pass on inset-modify lfuns addressed at other insets (#13068)
    
    (cherry picked from commit ae1ddcbda0615b742184f4263cd1ad550eb38c32)
---
 src/insets/InsetNote.cpp | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/insets/InsetNote.cpp b/src/insets/InsetNote.cpp
index b12b755fba..b0e2b5f0cc 100644
--- a/src/insets/InsetNote.cpp
+++ b/src/insets/InsetNote.cpp
@@ -141,6 +141,11 @@ void InsetNote::doDispatch(Cursor & cur, FuncRequest & cmd)
        switch (cmd.action()) {
 
        case LFUN_INSET_MODIFY: {
+               if (cmd.getArg(0) != "note") {
+                       // not for us; might be handled higher up
+                       cur.undispatched();
+                       return;
+               }
                // Do not do anything if converting to the same type of Note.
                // A quick break here is done instead of disabling the LFUN
                // because disabling the LFUN would lead to a greyed out
@@ -150,7 +155,7 @@ void InsetNote::doDispatch(Cursor & cur, FuncRequest & cmd)
                InsetNoteParams params;
                string2params(to_utf8(cmd.argument()), params);
                if (params_.type == params.type)
-                 break;
+                       break;
 
                cur.recordUndoInset(this);
                string2params(to_utf8(cmd.argument()), params_);
-- 
lyx-cvs mailing list
lyx-cvs@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-cvs

Reply via email to