richedit: Scroll cursor into view even with redraw turned off.
diff --git a/dlls/riched20/paint.c b/dlls/riched20/paint.c
index 2955594..2202967 100644
--- a/dlls/riched20/paint.c
+++ b/dlls/riched20/paint.c
@@ -159,7 +159,6 @@
   BOOL wrappedParagraphs;
 
   wrappedParagraphs = ME_WrapMarkedParagraphs(editor);
-  if (!editor->bRedraw) return;
   if (wrappedParagraphs)
     ME_UpdateScrollBar(editor);
   
@@ -174,7 +173,8 @@
     ME_SendOldNotify(editor, EN_CHANGE);
     editor->nEventMask |= ENM_CHANGE;
   }
-  ME_Repaint(editor);
+  if (editor->bRedraw)
+    ME_Repaint(editor);
   ME_SendSelChange(editor);
 }
 
@@ -185,10 +185,10 @@
    * looks, but not content. Like resizing. */
   
   ME_MarkAllForWrapping(editor);
+  ME_WrapMarkedParagraphs(editor);
+  ME_UpdateScrollBar(editor);
   if (editor->bRedraw)
   {
-    ME_WrapMarkedParagraphs(editor);
-    ME_UpdateScrollBar(editor);
     ME_Repaint(editor);
   }
 }
@@ -1093,6 +1093,7 @@
                             || (winStyle & ES_DISABLENOSCROLL);
   if (bScrollBarIsVisible != bScrollBarWillBeVisible)
   {
+    /* FIXME: ShowScrollBar will redraw the scrollbar when editor->bRedraw is FALSE */
     ShowScrollBar(hWnd, SB_VERT, bScrollBarWillBeVisible);
   }
   ME_UpdateScrollBar(editor);
@@ -1126,6 +1127,7 @@
 
   if (bScrollBarWasVisible != bScrollBarWillBeVisible)
   {
+    /* FIXME: ShowScrollBar will redraw the scrollbar when editor->bRedraw is FALSE */
     ShowScrollBar(hWnd, SB_VERT, bScrollBarWillBeVisible);
     ME_MarkAllForWrapping(editor);
     ME_WrapMarkedParagraphs(editor);
@@ -1144,13 +1146,14 @@
     editor->vert_si.nPage = si.nPage;
     if (bScrollBarWillBeVisible)
     {
-      SetScrollInfo(hWnd, SB_VERT, &si, TRUE);
+      SetScrollInfo(hWnd, SB_VERT, &si, editor->bRedraw);
     }
     else
     {
       if (bScrollBarWasVisible && !(si.fMask & SIF_DISABLENOSCROLL))
       {
-        SetScrollInfo(hWnd, SB_VERT, &si, TRUE);
+        SetScrollInfo(hWnd, SB_VERT, &si, editor->bRedraw);
+        /* FIXME: ShowScrollBar will redraw the scrollbar when editor->bRedraw is FALSE */
         ShowScrollBar(hWnd, SB_VERT, FALSE);
         ME_ScrollAbs(editor, 0);
       }
diff --git a/dlls/riched20/tests/editor.c b/dlls/riched20/tests/editor.c
index 3f98f30..18deadd 100644
--- a/dlls/riched20/tests/editor.c
+++ b/dlls/riched20/tests/editor.c
@@ -5189,7 +5189,7 @@
     SendMessage(eventMaskEditHwnd, WM_SETREDRAW, FALSE, 0);
     queriedEventMask = 0;  /* initialize to something other than we expect */
     SendMessage(eventMaskEditHwnd, EM_REPLACESEL, 0, (LPARAM) text);
-    todo_wine ok(queriedEventMask == (eventMask & ~ENM_CHANGE),
+    ok(queriedEventMask == (eventMask & ~ENM_CHANGE),
             "wrong event mask (0x%x) during WM_COMMAND\n", queriedEventMask);
     SendMessage(eventMaskEditHwnd, WM_SETREDRAW, TRUE, 0);
 
@@ -5568,7 +5568,7 @@
     ok(lines == 1, "Line wasn't expected to wrap (lines=%d).\n", lines);
     MoveWindow(hwnd, 0, 0, 200, 80, FALSE);
     lines = SendMessage(hwnd, EM_GETLINECOUNT, 0, 0);
-    todo_wine ok(lines > 1, "Line was expected to wrap (lines=%d).\n", lines);
+    ok(lines > 1, "Line was expected to wrap (lines=%d).\n", lines);
 
     SendMessage(hwnd, WM_SETREDRAW, TRUE, 0);
     DestroyWindow(hwnd);
@@ -5588,15 +5588,9 @@
         ok(lines == 8, "%d lines instead of 8\n", lines);
         ret = SendMessage(hwnd, EM_GETSCROLLPOS, 0, (LPARAM)&pt);
         ok(ret == 1, "EM_GETSCROLLPOS returned %d instead of 1\n", ret);
-        if (!redraw)
-            todo_wine ok(pt.y != 0, "Didn't scroll down after replacing text.\n");
-        else
-            ok(pt.y != 0, "Didn't scroll down after replacing text.\n");
+        ok(pt.y != 0, "Didn't scroll down after replacing text.\n");
         ret = GetWindowLong(hwnd, GWL_STYLE);
-        if (!redraw)
-            todo_wine ok(ret & WS_VSCROLL, "Scrollbar was not shown yet (style=%x).\n", (UINT)ret);
-        else
-            ok(ret & WS_VSCROLL, "Scrollbar was not shown yet (style=%x).\n", (UINT)ret);
+        ok(ret & WS_VSCROLL, "Scrollbar was not shown yet (style=%x).\n", (UINT)ret);
 
         SendMessage(hwnd, WM_SETTEXT, 0, (LPARAM)NULL);
         lines = SendMessage(hwnd, EM_GETLINECOUNT, 0, 0);