Added 32->16 mapping for SBM_GETRANGE/SBM_SETRANGE messages.

Added support for SBM_GETRANGE16 message in the scrollbar window
proc.
oldstable
Dmitry Timoshkov 2004-06-14 17:55:27 +00:00 committed by Alexandre Julliard
parent a9d5f0829a
commit 8f9d07f16b
2 changed files with 27 additions and 2 deletions

View File

@ -1378,8 +1378,12 @@ static LRESULT WINAPI ScrollBarWndProc( HWND hwnd, UINT message, WPARAM wParam,
return 0;
case SBM_GETRANGE16:
FIXME("don't know how to handle SBM_GETRANGE16 (wp=%04x,lp=%08lx)\n", wParam, lParam );
return 0;
{
INT min, max;
SCROLL_GetScrollRange(hwnd, SB_CTL, &min, &max);
return MAKELRESULT(min, max);
}
case SBM_GETRANGE:
return SCROLL_GetScrollRange(hwnd, SB_CTL, (LPINT)wParam, (LPINT)lParam);

View File

@ -1876,6 +1876,16 @@ INT WINPROC_MapMsg32ATo16( HWND hwnd, UINT msg32, WPARAM wParam32,
*pwparam16 = (WPARAM16)LOWORD(wParam32);
switch(msg32)
{
case SBM_SETRANGE:
*pmsg16 = SBM_SETRANGE16;
*plparam = MAKELPARAM(wParam32, *plparam);
*pwparam16 = 0;
return 0;
case SBM_GETRANGE:
*pmsg16 = SBM_GETRANGE16;
return 1;
case BM_GETCHECK:
case BM_SETCHECK:
case BM_GETSTATE:
@ -2385,6 +2395,11 @@ void WINPROC_UnmapMsg32ATo16( HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam,
{
switch(msg)
{
case SBM_GETRANGE:
*(LPINT)wParam = LOWORD(p16->lResult);
*(LPINT)lParam = HIWORD(p16->lResult);
break;
case LB_ADDFILE:
case LB_ADDSTRING:
case LB_DIR:
@ -2934,6 +2949,9 @@ LRESULT WINAPI __wine_call_wndproc_32A( HWND16 hwnd, UINT16 msg, WPARAM16 wParam
WPARAM wParam32;
HWND hwnd32 = WIN_Handle32( hwnd );
TRACE_(msg)("func %p (hwnd=%p,msg=%s,wp=%08x,lp=%08lx)\n",
func, hwnd32, SPY_GetMsgName(msg, hwnd32), wParam, lParam);
if (WINPROC_MapMsg16To32A( hwnd32, msg, wParam, &msg32, &wParam32, &lParam ) == -1)
return 0;
result = WINPROC_CallWndProc( func, hwnd32, msg32, wParam32, lParam );
@ -2952,6 +2970,9 @@ LRESULT WINAPI __wine_call_wndproc_32W( HWND16 hwnd, UINT16 msg, WPARAM16 wPara
WPARAM wParam32;
HWND hwnd32 = WIN_Handle32( hwnd );
TRACE_(msg)("func %p (hwnd=%p,msg=%s,wp=%08x,lp=%08lx)\n",
func, hwnd32, SPY_GetMsgName(msg, hwnd32), wParam, lParam);
if (WINPROC_MapMsg16To32W( hwnd32, msg, wParam, &msg32, &wParam32, &lParam ) == -1)
return 0;
result = WINPROC_CallWndProc( func, hwnd32, msg32, wParam32, lParam );