]> git.lyx.org Git - lyx.git/blobdiff - src/text2.C
fix two crashes related to dEPM. Some crashes remain
[lyx.git] / src / text2.C
index 1bc7544ed77f9b0d11520ead4a191276805c126e..81171bbd20d969123da105e4595775ddbbac5fc7 100644 (file)
@@ -1056,6 +1056,7 @@ bool LyXText::cursorUp(LCursor & cur)
                int const y = bv_funcs::getPos(cur, cur.boundary()).y_;
                LCursor old = cur;
                editXY(cur, x, y - par.rows()[row].ascent() - 1);
+               cur.clearSelection();
 
                // This happens when you move out of an inset.
                // And to give the DEPM the possibility of doing
@@ -1101,6 +1102,7 @@ bool LyXText::cursorDown(LCursor & cur)
                int const y = bv_funcs::getPos(cur, cur.boundary()).y_;
                LCursor old = cur;
                editXY(cur, x, y + par.rows()[row].descent() + 1);
+               cur.clearSelection();
 
                // This happens when you move out of an inset.
                // And to give the DEPM the possibility of doing