mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-09 18:31:04 +00:00
fix bug 2155: crash when undoing dEPM
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10707 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
a95bd65e3e
commit
86d8a57443
@ -1,3 +1,8 @@
|
||||
2006-01-04 Jean-Marc Lasgouttes <lasgouttes@lyx.org>
|
||||
|
||||
* text2.C (deleteEmptyParagraphMechanism): since we delete a
|
||||
paragraph, recordUndo should span two paragraphs (bug 2155).
|
||||
|
||||
2006-01-01 Martin Vermeer <martin.vermeer@hut.fi>
|
||||
|
||||
* rowpainter.C (paintPar): always repaint the row with the
|
||||
|
@ -1234,7 +1234,8 @@ bool LyXText::deleteEmptyParagraphMechanism(LCursor & cur, LCursor & old)
|
||||
|
||||
if (oldpar.empty() || (oldpar.size() == 1 && oldpar.isLineSeparator(0))) {
|
||||
// Delete old par.
|
||||
recordUndo(old, Undo::ATOMIC, old.pit());
|
||||
recordUndo(old, Undo::ATOMIC,
|
||||
old.pit(), min(old.pit() + 1, old.lastpit()));
|
||||
ParagraphList & plist = old.text()->paragraphs();
|
||||
plist.erase(plist.begin() + old.pit());
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user