Commit 250855bf authored by Dylan Smith's avatar Dylan Smith Committed by Alexandre Julliard

wordpad: Fix failing GetDlgItem that forced screen repaint.

The rebar is the parent of the ruler, not the top level window, so GetDlgItem was returning NULL when the window is resized. As a result the screen was being invalidated and repainted instead of the ruler.
parent 6e5a22c7
......@@ -2546,7 +2546,7 @@ static LRESULT OnSize( HWND hWnd, WPARAM wParam, LPARAM lParam )
HWND hwndEditor = preview_isactive() ? GetDlgItem(hWnd, IDC_PREVIEW) : GetDlgItem(hWnd, IDC_EDITOR);
HWND hwndStatusBar = GetDlgItem(hWnd, IDC_STATUSBAR);
HWND hwndReBar = GetDlgItem(hWnd, IDC_REBAR);
HWND hRulerWnd = GetDlgItem(hWnd, IDC_RULER);
HWND hRulerWnd = GetDlgItem(hwndReBar, IDC_RULER);
int rebarHeight = 0;
if (hwndStatusBar)
......
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