]> git.lyx.org Git - features.git/commitdiff
Properly resolve tracked changes when pasting multiple tabular cells
authorJuergen Spitzmueller <spitz@lyx.org>
Sat, 21 Mar 2020 14:54:37 +0000 (15:54 +0100)
committerJuergen Spitzmueller <spitz@lyx.org>
Sat, 21 Mar 2020 14:54:37 +0000 (15:54 +0100)
Fixes #11791

src/insets/InsetTabular.cpp

index e1ee36d676fe3d0d30c4ea21867d4ede44ef1127..dc8be284b2955f496545febcdf1979e51986e08d 100644 (file)
@@ -7131,9 +7131,12 @@ bool InsetTabular::pasteClipboard(Cursor & cur)
                        // FIXME?: why do we need to do this explicitly? (EL)
                        tabular.cellInset(r2, c2)->setBuffer(tabular.buffer());
 
-                       // FIXME: change tracking (MG)
-                       inset->setChange(Change(buffer().params().track_changes ?
+                       if (!lyxrc.ct_markup_copied) {
+                               // do not paste deleted text
+                               inset->acceptChanges();
+                               inset->setChange(Change(buffer().params().track_changes ?
                                                Change::INSERTED : Change::UNCHANGED));
+                       }
                        cur.pos() = 0;
                        cur.pit() = 0;
                }