38 hScroll =
CreateWindowA(
"SCROLLBAR",
"",
WS_CHILD |
WS_VISIBLE, 0, 0, 120, 100,
hWnd, (
HMENU)100,
GetModuleHandleA(0), 0 );
64 ok(
hMainWnd !=
NULL,
"Failed to create parent window. Tests aborted.\n");
95 ok(
ret,
"The scrollbar should be disabled.\n" );
99 ok(
ret,
"The scrollbar should be enabled.\n" );
104 ok(
ret,
"The scrollbar LTUP button should be disabled.\n" );
107 ok(
ret,
"The scrollbar should be enabled.\n" );
111 ok(
ret,
"The scrollbar RTDN button should be disabled.\n" );
114 ok(
ret,
"The scrollbar should be enabled.\n" );
119 ok( !
ret,
"EnableScrollBar should fail.\n" );
149 ok( !
ret,
"The position should not be set.\n" );
152 ok( !
ret,
"The position should be equal to zero\n");
155 ok(
ret,
"The range should be set.\n" );
158 ok( !
ret ,
"The position should not be set.\n" );
161 ok(
ret == 30,
"The position should be set!!!\n");
167 ok(
ret == 30,
"The position should be set.\n" );
170 ok(
ret == 30,
"The position should not be equal to zero\n");
173 ok(
ret,
"The range should be set.\n" );
176 ok(
ret == 30,
"The position should be set.\n" );
179 ok(
ret == 30,
"The position should not be equal to zero\n");
183 ok( !
ret,
"The position should not be set.\n" );
188 ok( !
ret,
"The position should be equal to zero\n");
203 ok(
ret,
"The ShowScrollBar() should not failed.\n" );
207 ok(
ret,
"The ShowScrollBar() should not failed.\n" );
211 ok( !
ret,
"The ShowScrollBar() should failed.\n" );
214 ok(
ret,
"The ShowScrollBar() should not fail.\n" );
229 if (!pGetScrollBarInfo)
231 win_skip(
"GetScrollBarInfo is not available\n");
241 ok(
ret,
"The GetScrollBarInfo() call should not fail.\n" );
243 ok(
ret,
"The GetWindowRect() call should not fail.\n" );
245 "unexpected rgstate(0x%x)\n", sbi.
rgstate[0]);
255 ok(
ret,
"The GetScrollBarInfo() call should not fail.\n" );
257 ok(
ret,
"The GetWindowRect() call should not fail.\n" );
263 ok(
ret,
"The GetScrollBarInfo() call should not fail.\n" );
269 ok(
ret,
"The GetScrollBarInfo() call should not fail.\n" );
271 ok(
ret,
"The GetWindowRect() call should not fail.\n" );
277 ok(
ret,
"The GetScrollBarInfo() call should not fail.\n" );
295 0, 0, 10, 10, 0, 0, 0,
NULL);
300 broken( !
ret) ,
"GetScrollRange failed.\n");
304 "Scroll bar range is %d,%d. Expected 0,0. Style %08x\n",
min,
max,
style);
308 "Scroll bar range is %d,%d. Expected 0,100. Style %08x\n",
min,
max,
style);
311 broken( !
ret) ,
"GetScrollRange failed.\n");
315 "Scroll bar range is %d,%d. Expected 0,0. Style %08x\n",
min,
max,
style);
319 "Scroll bar range is %d,%d. Expected 0,100. Style %08x\n",
min,
max,
style);
324 ok( !
ret,
"GetScrollInfo succeeded unexpectedly. Style is %08x\n",
style);
328 "GetScrollInfo failed unexpectedly. Style is %08x\n",
style);
333 ok( !
ret,
"GetScrollInfo succeeded unexpectedly. Style is %08x\n",
style);
337 "GetScrollInfo failed unexpectedly. Style is %08x\n",
style);
341 ok(
ret,
"SetScrollRange failed.\n");
344 ok(
ret,
"GetScrollRange failed.\n");
347 "Scroll bar range is %d,%d. Expected 0,100. Style %08x\n",
min,
max,
style);
351 ok(
ret,
"GetScrollInfo failed unexpectedly. Style is %08x\n",
style);
354 ok(
ret,
"GetScrollInfo failed unexpectedly. Style is %08x\n",
style);
363 "unexpected style change %08x/%08x\n", winstyle,
style);
366 "unexpected style change %08x/%08x\n", winstyle,
style);
372 0, 0, 10, 10, 0, 0, 0,
NULL);
377 ok(
ret,
"SetScrollRange failed.\n");
380 ok(
ret,
"GetScrollRange failed.\n");
383 "Scroll bar range is %d,%d. Expected 0,100. Style %08x\n",
min,
max,
style);
387 ok(
ret,
"GetScrollInfo failed unexpectedly. Style is %08x\n",
style);
390 ok(
ret,
"GetScrollInfo failed unexpectedly. Style is %08x\n",
style);
399 "unexpected style change %08x/%08x\n", winstyle,
style);
402 "unexpected style change %08x/%08x\n", winstyle,
style);
408 0, 0, 10, 10, 0, 0, 0,
NULL);
416 ok(
ret,
"SetScrollInfo failed. Style is %08x\n",
style);
419 ok(
ret,
"GetScrollRange failed.\n");
422 "Scroll bar range is %d,%d. Expected 0,100. Style %08x\n",
min,
max,
style);
426 ok(
ret,
"GetScrollInfo failed unexpectedly. Style is %08x\n",
style);
429 ok(
ret,
"GetScrollInfo failed unexpectedly. Style is %08x\n",
style);
432 ok( !
ret,
"Vertical window scroll bar was not enabled\n");
434 ok( !
ret,
"Horizontal window scroll bar was not enabled\n");
442 0, 0, 10, 10, 0, 0, 0,
NULL);
446 ok( !
ret,
"GetScrollInfo succeeded unexpectedly. Style is %08x\n",
style);
452 ok( !
ret,
"GetScrollInfo succeeded unexpectedly. Style is %08x\n",
style);
471 horz.
cbSize =
sizeof horz;
473 horz.
nMin = 0xdeadbeaf;
474 horz.
nMax = 0xbaadc0de;
479 if(
cs->lpCreateParams)
484 ok(h_ret && v_ret,
"GetScrollInfo() should return NON-zero "
485 "but got h_ret=%d v_ret=%d\n", h_ret, v_ret);
487 "unexpected init values(SB_VERT): min=%d max=%d\n",
490 "unexpected init values(SB_HORZ): min=%d max=%d\n",
495 ok(!h_ret && !v_ret,
"GetScrollInfo() should return zeru, "
496 "but got h_ret=%d v_ret=%d\n", h_ret, v_ret);
497 ok(vert.
nMin == 0xdeadbeaf && vert.
nMax == 0xbaadc0de,
498 "unexpected initialization(SB_VERT): min=%d max=%d\n",
500 ok(horz.
nMin == 0xdeadbeaf && horz.
nMax == 0xbaadc0de,
501 "unexpected initialization(SB_HORZ): min=%d max=%d\n",
507 ok(!h_ret && !v_ret,
"GetScrollInfo() should return zeru, "
508 "but got h_ret=%d v_ret=%d\n", h_ret, v_ret);
509 ok(horz.
nMin == 0xdeadbeaf && horz.
nMax == 0xbaadc0de &&
510 vert.
nMin == 0xdeadbeaf && vert.
nMax == 0xbaadc0de,
511 "unexpected initialization\n");
528 memset( &wc, 0,
sizeof wc );
558 ok(
ret,
"scroll bar disabled\n");
563 ok(!
ret,
"scroll bar enabled\n");
565 memset(&si, 0,
sizeof(si));
572 memset(&si, 0,
sizeof(si));
575 ok(!
ret,
"scroll bar enabled\n");
583 ok(!
ret,
"scroll bar enabled\n");
599 ok(
ret,
"scroll bar disabled\n");
614 if (
msg == SBM_SETSCROLLINFO)
633 memset(&wc, 0,
sizeof(wc));
649 ok(!
res,
"SetScrollPos returned %lu\n",
res);
653 ok(
res == 2,
"SetScrollPos returned %lu\n",
res);
659 memset(&scroll_info, 0xcc,
sizeof(scroll_info));
660 scroll_info.
cbSize =
sizeof(scroll_info);
662 ok(
res == 1,
"SBM_GETSCROLLBARINFO returned %lu\n",
res);
671 memset(&scroll_info, 0xcc,
sizeof(scroll_info));
672 scroll_info.
cbSize =
sizeof(scroll_info);
674 ok(!
res,
"SBM_GETSCROLLBARINFO returned %lu\n",
res);
688 memset(&scroll_info, 0xcc,
sizeof(scroll_info));
689 scroll_info.
cbSize =
sizeof(scroll_info);
691 ok(!
res,
"SBM_GETSCROLLBARINFO returned %lu\n",
res);
695 ok(
res == 0,
"SetScrollPos returned %lu\n",
res);
static const char * wine_dbgstr_rect(const RECT *prc)
#define ERROR_INVALID_PARAMETER
#define GetProcAddress(x, y)
HMODULE WINAPI DECLSPEC_HOTPATCH GetModuleHandleA(LPCSTR lpModuleName)
HINSTANCE WINAPI DECLSPEC_HOTPATCH LoadLibraryA(LPCSTR lpLibFileName)
GLdouble GLdouble GLdouble r
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
static const char cls_name[]
static const CLSID *static CLSID *static const GUID VARIANT VARIANT *static IServiceProvider DWORD *static HMENU
#define WS_OVERLAPPEDWINDOW
static IsThemeActiveT pIsThemeActive
DWORD WINAPI GetLastError(void)
HGDIOBJ WINAPI GetStockObject(_In_ int)
BOOL WINAPI IsWindow(_In_opt_ HWND)
HWND WINAPI CreateWindowExA(_In_ DWORD dwExStyle, _In_opt_ LPCSTR lpClassName, _In_opt_ LPCSTR lpWindowName, _In_ DWORD dwStyle, _In_ int X, _In_ int Y, _In_ int nWidth, _In_ int nHeight, _In_opt_ HWND hWndParent, _In_opt_ HMENU hMenu, _In_opt_ HINSTANCE hInstance, _In_opt_ LPVOID lpParam)
BOOL WINAPI ShowWindow(_In_ HWND, _In_ int)
BOOL WINAPI ReleaseCapture(void)
BOOL WINAPI UnregisterClassA(_In_ LPCSTR, HINSTANCE)
LONG WINAPI GetWindowLongA(_In_ HWND, _In_ int)
LRESULT WINAPI DefWindowProcA(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
struct tagSCROLLINFO SCROLLINFO
#define CreateWindowA(a, b, c, d, e, f, g, h, i, j, k)
BOOL WINAPI GetWindowRect(_In_ HWND, _Out_ LPRECT)
__analysis_noreturn void WINAPI PostQuitMessage(_In_ int)
HBRUSH WINAPI GetSysColorBrush(_In_ int)
LONG WINAPI SetWindowLongW(_In_ HWND, _In_ int, _In_ LONG)
LRESULT WINAPI SendMessageA(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI GetClassInfoExA(_In_opt_ HINSTANCE, _In_ LPCSTR, _Out_ LPWNDCLASSEXA)
struct tagSCROLLBARINFO * LPSCROLLBARINFO
int WINAPI SetScrollPos(_In_ HWND, _In_ int, _In_ int, _In_ BOOL)
BOOL WINAPI GetScrollRange(_In_ HWND, _In_ int, _Out_ LPINT, _Out_ LPINT)
ATOM WINAPI RegisterClassA(_In_ CONST WNDCLASSA *)
ATOM WINAPI RegisterClassExA(_In_ CONST WNDCLASSEXA *)
BOOL WINAPI SetScrollRange(_In_ HWND, _In_ int, _In_ int, _In_ int, _In_ BOOL)
#define SIF_DISABLENOSCROLL
#define STATE_SYSTEM_INVISIBLE
BOOL WINAPI EnableWindow(_In_ HWND, _In_ BOOL)
#define STATE_SYSTEM_OFFSCREEN
BOOL WINAPI IsWindowEnabled(_In_ HWND)
BOOL WINAPI OffsetRect(_Inout_ LPRECT, _In_ int, _In_ int)
int WINAPI SetScrollInfo(_In_ HWND, _In_ int, _In_ LPCSCROLLINFO, _In_ BOOL)
BOOL WINAPI ShowScrollBar(_In_ HWND, _In_ int, _In_ BOOL)
int WINAPI GetScrollPos(_In_ HWND, _In_ int)
LRESULT(CALLBACK * WNDPROC)(HWND, UINT, WPARAM, LPARAM)
BOOL WINAPI GetScrollInfo(_In_ HWND, _In_ int, _Inout_ LPSCROLLINFO)
BOOL WINAPI IsWindowVisible(_In_ HWND)
BOOL WINAPI DestroyWindow(_In_ HWND)
BOOL WINAPI EnableScrollBar(_In_ HWND, _In_ UINT, _In_ UINT)
BOOL WINAPI EqualRect(_In_ LPCRECT, _In_ LPCRECT)
BOOL WINAPI MoveWindow(_In_ HWND, _In_ int, _In_ int, _In_ int, _In_ int, _In_ BOOL)
LRESULT WINAPI CallWindowProcA(_In_ WNDPROC, _In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
HCURSOR WINAPI LoadCursorA(_In_opt_ HINSTANCE, _In_ LPCSTR)