Dylan Smith : richedit: Missing condition for inserting newline before table.

Alexandre Julliard julliard at winehq.org
Fri Jan 9 09:52:10 CST 2009


Module: wine
Branch: master
Commit: 1f6b8c7fd9f599513e2d34c1fd716b61e4e4e1ba
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=1f6b8c7fd9f599513e2d34c1fd716b61e4e4e1ba

Author: Dylan Smith <dylan.ah.smith at gmail.com>
Date:   Thu Jan  8 09:14:10 2009 -0500

richedit: Missing condition for inserting newline before table.

This case occurs when the cursor is at the start of the table, the
table is at the start of the text, and there is no selection.

---

 dlls/riched20/editor.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/dlls/riched20/editor.c b/dlls/riched20/editor.c
index 5bfc0aa..563e12e 100644
--- a/dlls/riched20/editor.c
+++ b/dlls/riched20/editor.c
@@ -2319,7 +2319,8 @@ static LRESULT ME_Char(ME_TextEditor *editor, WPARAM charCode,
       else if (para == ME_GetParagraph(editor->pCursors[1].pRun) &&
                cursor.nOffset + cursor.pRun->member.run.nCharOfs == 0 &&
                para->member.para.prev_para->member.para.nFlags & MEPF_ROWSTART &&
-               !para->member.para.prev_para->member.para.nCharOfs)
+               !para->member.para.prev_para->member.para.nCharOfs &&
+               wstr == '\r')
       {
         /* Insert a newline before the table. */
         WCHAR endl = '\r';




More information about the wine-cvs mailing list