Commit f85985ab authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

win32u: Move WM_NCCREATE scroll handling from user32.

parent 4de61c46
......@@ -93,22 +93,6 @@ LRESULT WINAPI DefWindowProcA( HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam
switch(msg)
{
case WM_NCCREATE:
if (lParam)
{
CREATESTRUCTA *cs = (CREATESTRUCTA *)lParam;
result = NtUserMessageCall( hwnd, msg, wParam, lParam, 0, NtUserDefWindowProc, TRUE );
if(cs->style & (WS_HSCROLL | WS_VSCROLL))
{
SCROLLINFO si = {sizeof si, SIF_ALL, 0, 100, 0, 0, 0};
NtUserSetScrollInfo( hwnd, SB_HORZ, &si, FALSE );
NtUserSetScrollInfo( hwnd, SB_VERT, &si, FALSE );
}
}
break;
case WM_SYSCOMMAND:
result = NC_HandleSysCommand( hwnd, wParam, lParam );
break;
......@@ -220,22 +204,6 @@ LRESULT WINAPI DefWindowProcW(
switch(msg)
{
case WM_NCCREATE:
if (lParam)
{
CREATESTRUCTW *cs = (CREATESTRUCTW *)lParam;
result = NtUserMessageCall( hwnd, msg, wParam, lParam, 0, NtUserDefWindowProc, FALSE );
if(cs->style & (WS_HSCROLL | WS_VSCROLL))
{
SCROLLINFO si = {sizeof si, SIF_ALL, 0, 100, 0, 0, 0};
NtUserSetScrollInfo( hwnd, SB_HORZ, &si, FALSE );
NtUserSetScrollInfo( hwnd, SB_VERT, &si, FALSE );
}
}
break;
case WM_SYSCOMMAND:
result = NC_HandleSysCommand( hwnd, wParam, lParam );
break;
......
......@@ -2369,6 +2369,14 @@ LRESULT default_window_proc( HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam,
{
CREATESTRUCTW *cs = (CREATESTRUCTW *)lparam;
set_window_text( hwnd, cs->lpszName, ansi );
if (cs->style & (WS_HSCROLL | WS_VSCROLL))
{
SCROLLINFO si = { .cbSize = sizeof(si), .fMask = SIF_ALL, .nMax = 100 };
NtUserSetScrollInfo( hwnd, SB_HORZ, &si, FALSE );
NtUserSetScrollInfo( hwnd, SB_VERT, &si, FALSE );
}
result = 1;
}
break;
......
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