Fix this crash:

new doc
type:  foo bar
put cursor after foo: foo| bar
enter space: foo | bar
click somewhere else -> CRASH

The problem is that the paragraph breaking needs to be redone after the empty space is deleted.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16295 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Abdelrazak Younes 2006-12-15 23:17:10 +00:00
parent 5b5585e723
commit 4d96e200f0

View File

@ -1321,6 +1321,8 @@ bool LyXText::deleteEmptyParagraphMechanism(LCursor & cur, LCursor & old)
&& oldpar.isLineSeparator(old.pos() - 1)
&& !oldpar.isDeleted(old.pos() - 1)) {
oldpar.eraseChar(old.pos() - 1, false); // do not track changes in DEPM
// rebreak it and update the CoordCache.
redoParagraph(cur.bv(), old.pit());
#ifdef WITH_WARNINGS
#warning This will not work anymore when we have multiple views of the same buffer
// In this case, we will have to correct also the cursors held by