Commit d5478118 authored by Eric Pouech's avatar Eric Pouech Committed by Alexandre Julliard

richedit: Don't force repaint while the redraw flag is off.

parent f43570cb
......@@ -2660,7 +2660,8 @@ static LRESULT RichEditWndProc_common(HWND hWnd, UINT msg, WPARAM wParam,
ME_SendRequestResize(editor, TRUE);
return 0;
case WM_SETREDRAW:
editor->bRedraw = wParam;
if ((editor->bRedraw = wParam))
ME_RewrapRepaint(editor);
return 0;
case WM_SIZE:
{
......
......@@ -109,7 +109,8 @@ void ME_UpdateRepaint(ME_TextEditor *editor)
{
/* Should be called whenever the contents of the control have changed */
ME_Cursor *pCursor;
if (!editor->bRedraw) return;
if (ME_WrapMarkedParagraphs(editor))
ME_UpdateScrollBar(editor);
......@@ -135,10 +136,12 @@ ME_RewrapRepaint(ME_TextEditor *editor)
* looks, but not content. Like resizing. */
ME_MarkAllForWrapping(editor);
ME_WrapMarkedParagraphs(editor);
ME_UpdateScrollBar(editor);
ME_Repaint(editor);
if (editor->bRedraw)
{
ME_WrapMarkedParagraphs(editor);
ME_UpdateScrollBar(editor);
ME_Repaint(editor);
}
}
int ME_twips2pointsX(ME_Context *c, int x)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment