]> git.lyx.org Git - features.git/commitdiff
Fix another selection bug in InsetTabular
authorScott Kostyshak <skostysh@lyx.org>
Wed, 12 Dec 2012 08:44:17 +0000 (03:44 -0500)
committerScott Kostyshak <skostysh@lyx.org>
Wed, 12 Dec 2012 20:53:09 +0000 (15:53 -0500)
Fix #4981:
In tabular if a vertical selection is made with the keyboard (e.g.
LFUN_UP_SELECT), the selection is drawn if there are two cells selected.
Previously, the selection would be drawn only if there were more than
two selected.

(cherry picked from commit 5cc1adf7c7a348aae4f9471d7edb41c8570311d7)

src/insets/InsetTabular.cpp

index 6115f0a5b1c059806042a3cf599f7082e500c2aa..c740a2fcb805dcfe7e48932acf6f434490bc1071 100644 (file)
@@ -4118,6 +4118,7 @@ void InsetTabular::doDispatch(Cursor & cur, FuncRequest & cmd)
                        cur.pit() = cur.lastpit();
                        cur.pos() = cur.lastpos();
                        cur.setCurrentFont();
+                       cur.screenUpdateFlags(Update::Force | Update::FitCursor);
                        return;
                }
                cur.screenUpdateFlags(Update::Force | Update::FitCursor);
@@ -4156,6 +4157,7 @@ void InsetTabular::doDispatch(Cursor & cur, FuncRequest & cmd)
                        cur.pit() = 0;
                        cur.pos() = cur.lastpos();
                        cur.setCurrentFont();
+                       cur.screenUpdateFlags(Update::Force | Update::FitCursor);
                        return;
                }
                cur.screenUpdateFlags(Update::Force | Update::FitCursor);