mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-08 10:51:03 +00:00
* text.C (erase): when deleting a text inset in change-tracking
mode, make the cursor jump over it; avoid crash in setCursorIntern by using the right LyXText. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16001 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
59f15f2d94
commit
7c1b006288
@ -1657,7 +1657,7 @@ bool LyXText::erase(LCursor & cur)
|
||||
// FIXME: change tracking (MG)
|
||||
par.eraseChar(cur.pos(), cur.buffer().params().trackChanges);
|
||||
if (par.isDeleted(cur.pos()))
|
||||
cur.forwardPos();
|
||||
cur.forwardPosNoDescend();
|
||||
needsUpdate = true;
|
||||
} else if (cur.pit() != cur.lastpit()) {
|
||||
if (cur.buffer().params().trackChanges
|
||||
@ -1687,7 +1687,7 @@ bool LyXText::erase(LCursor & cur)
|
||||
cur.updateFlags(Update::Force);
|
||||
// Make sure the cursor is correct. Is this really needed?
|
||||
// No, not really... at least not here!
|
||||
setCursorIntern(cur, cur.pit(), cur.pos());
|
||||
cur.text()->setCursorIntern(cur, cur.pit(), cur.pos());
|
||||
}
|
||||
|
||||
return needsUpdate;
|
||||
|
Loading…
Reference in New Issue
Block a user