richedit: Update paragraph on saved cursor when inserting table start.

Dylan Smith dylan.ah.smith at gmail.com
Mon Aug 10 14:44:59 CDT 2009


Since the table row start is inserted after the rest of the table is
inserted, the cursor is saved, and temporarily moved to the start of the
row to insert the table row start paragraph.  Unfortunately the
paragraph in saved cursor becomes invalid during this insertion and
needs to be updated, so this code introduced a regression once
paragraphs started to be stored in cursors.
---
 dlls/riched20/table.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
-------------- next part --------------
diff --git a/dlls/riched20/table.c b/dlls/riched20/table.c
index 69f4851..0d2dab5 100644
--- a/dlls/riched20/table.c
+++ b/dlls/riched20/table.c
@@ -96,6 +96,7 @@ ME_DisplayItem* ME_InsertTableRowStartAtParagraph(ME_TextEditor *editor,
   editor->pCursors[0].nOffset = 0;
   editor->pCursors[1] = editor->pCursors[0];
   startRowPara = ME_InsertTableRowStartFromCursor(editor);
+  savedCursor.pPara = ME_GetParagraph(savedCursor.pRun);
   editor->pCursors[0] = savedCursor;
   editor->pCursors[1] = editor->pCursors[0];
 


More information about the wine-patches mailing list