28#define expect(expected, got) ok(got == expected, "Expected %d, got %d\n", expected, got)
29#define NUM_MSG_SEQUENCE 2
30#define PARENT_SEQ_INDEX 0
31#define TRACKBAR_SEQ_INDEX 1
53 { WM_NOTIFYFORMAT,
sent},
75 { WM_NOTIFYFORMAT,
sent},
385 static LONG defwndproc_counter = 0;
408 defwndproc_counter++;
410 defwndproc_counter--;
435 return CreateWindowA(
"Trackbar test parent class",
"Trackbar test parent window",
442 static LONG defwndproc_counter = 0;
453 defwndproc_counter++;
455 defwndproc_counter--;
470 if (!hWndTrack)
return NULL;
491 HWND hWndLeftBuddy, hWndTrackbar;
493 HWND hWndCurrentBuddy;
497 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
501 hWndLeftBuddy =
CreateWindowA(
STATUSCLASSNAMEA,
NULL, 0, 0, 0, 300, 20,
NULL,
NULL,
NULL,
NULL);
502 ok(hWndLeftBuddy !=
NULL,
"Expected non NULL value\n");
504 if (hWndLeftBuddy !=
NULL){
507 ok(rTest == hWndCurrentBuddy,
"Expected hWndCurrentBuddy\n");
509 ok(rTest == hWndLeftBuddy,
"Expected hWndLeftBuddy\n");
511 skip (
"left buddy control not present?\n");
513 hWndRightBuddy =
CreateWindowA(
STATUSCLASSNAMEA,
NULL, 0, 0, 0, 300, 20,
NULL,
NULL,
NULL,
NULL);
515 ok(hWndRightBuddy !=
NULL,
"expected non NULL value\n");
518 if (hWndRightBuddy !=
NULL){
521 ok(rTest == hWndCurrentBuddy,
"Expected hWndCurrentBuddy\n");
523 ok(rTest == hWndRightBuddy,
"Expected hWndRightbuddy\n");
525 skip(
"Right buddy control not present?\n");
528 if (hWndLeftBuddy !=
NULL){
530 ok(rTest == hWndLeftBuddy,
"Expected hWndLeftBuddy\n");
533 if (hWndRightBuddy !=
NULL){
535 ok(rTest == hWndRightBuddy,
"Expected hWndRightBuddy\n");
551 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
578 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
581 ok(
r == 20,
"Unexpected page size %d.\n",
r);
586 ok(
r == 13,
"Unexpected page size %d.\n",
r);
591 ok(
r == 11,
"Unexpected page size %d.\n",
r);
596 ok(
r == 8,
"Unexpected page size %d.\n",
r);
599 ok(
r == 8,
"Unexpected page size %d.\n",
r);
604 ok(
r == 10,
"Unexpected page size %d.\n",
r);
609 ok(
r == 10,
"Unexpected page size %d.\n",
r);
614 ok(
r == 10,
"Unexpected page size %d.\n",
r);
617 ok(
r == 10,
"Unexpected page size %d.\n",
r);
620 ok(
r == 7,
"Unexpected page size %d.\n",
r);
625 ok(
r == 19,
"Unexpected page size %d.\n",
r);
630 ok(hWndTrackbar !=
NULL,
"Failed to create trackbar window.\n");
674 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
704 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
718 ok(
r == 25,
"got %d\n",
r);
725 ok(
r == 30,
"got %d\n",
r);
732 ok(
r == 100,
"got %d\n",
r);
746 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
810 ok(
r == 0,
"got %d\n",
r);
817 ok(
r == 0,
"got %d\n",
r);
825 ok(
r == 0,
"got %d\n",
r);
838 ok(
r == 25,
"Unexpected position %d\n",
r);
846 ok(
r == 20,
"Unexpected position %d\n",
r);
854 ok(
r == 70,
"Unexpected position %d\n",
r);
865 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
937 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
979 ok(
r2 ==
r,
"Unexpected thumb length %d.\n",
r);
990 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
1005 ok(
r ==
FALSE,
"Expected FALSE, got %d\n",
r);
1007 ok(
r ==
TRUE,
"Expected TRUE, got %d\n",
r);
1009 ok(
r ==
TRUE,
"Expected TRUE, got %d\n",
r);
1012 ok(
r ==
FALSE,
"Expected FALSE, got %d\n",
r);
1056 for (
i = 0;
i < 2;
i++)
1063 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
1071 ok(
EqualRect(&
rect, &rect1),
"Unexpected thumb rectangle %s, previous %s\n",
1077 ok(
EqualRect(&
rect, &rect1),
"Unexpected thumb rectangle %s, previous %s\n",
1083 ok(
EqualRect(&
rect, &rect1),
"Unexpected thumb rectangle %s, previous %s\n",
1089 ok(!
EqualRect(&
rect, &rect1),
"Unexpected thumb rectangle %s, previous %s\n",
1106 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
1112 ok(numtics == 6,
"Expected 6, got %d\n", numtics);
1132 ok(
r > 0,
"Expected r > 0, got %d\n",
r);
1134 ok(
r > 0,
"Expected r > 0, got %d\n",
r);
1144 HWND hWndTooltip, hWndTrackbar;
1149 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
1168 ok(hWndTooltip !=
NULL,
"Expected non NULL value\n");
1169 if (hWndTooltip !=
NULL){
1172 ok(rTest == hWndTooltip,
"Expected hWndToolTip, got\n");
1175 ok(rTest ==
NULL,
"Expected NULL\n");
1178 ok(rTest == hWndTooltip,
"Expected hWndTooltip, got\n");
1180 skip(
"tool tip control not present?\n");
1184 ok(rTest == hWndTooltip,
"Expected hWndTooltip\n");
1199 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
1205 ok(
r ==
FALSE,
"Expected FALSE, got %d\n",
r);
1207 ok(
r ==
TRUE,
"Expected TRUE, got %d\n",
r);
1211 ok(
r ==
FALSE,
"Expected FALSE, got %d\n",
r);
1225 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
1352 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
1361 ok(hWndTrackbar !=
NULL,
"Expected non NULL value\n");
1380 skip(
"parent window not present\n");
static const char * wine_dbgstr_rect(const RECT *prc)
static void init_msg_sequences(struct msg_sequence **seq, int n)
static void flush_sequences(struct msg_sequence **seq, int n)
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 void test_page_size(void)
static struct msg_sequence * sequences[NUM_MSG_SEQUENCE]
static void test_position(void)
static HWND create_parent_window(void)
static const struct message parent_buddy_window_test_seq[]
static void test_trackbar_buddy(void)
static BOOL register_parent_wnd_class(void)
static void test_ignore_selection(void)
static const struct message parent_tic_settings_test_seq[]
static void test_create(void)
static HWND create_trackbar2(DWORD style, HWND parent)
static const struct message selection_test_seq[]
static const struct message tic_settings_test_seq[]
static void test_tic_settings(void)
static void test_tool_tips(void)
static const struct message page_size_test_seq[]
static void test_initial_state(void)
#define TRACKBAR_SEQ_INDEX
static LRESULT WINAPI parent_wnd_proc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
static const struct message parent_selection_test_seq[]
static const struct message parent_thumb_length_test_seq[]
static const struct message range_test_seq[]
static void test_TBS_AUTOTICKS(void)
static void test_range(void)
static HWND create_trackbar(DWORD style, HWND parent)
#define expect(expected, got)
static const struct message tic_placement_test_seq[]
static const struct message parent_new_window_test_seq[]
static const struct message line_size_test_seq[]
static const struct message position_test_seq[]
static LRESULT WINAPI trackbar_no_wmpaint_proc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
static const struct message parent_position_test_seq[]
static void test_thumb_length(void)
static const struct message thumb_length_test_seq[]
static LRESULT WINAPI trackbar_subclass_proc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
static const struct message unicode_test_seq[]
static void test_selection(void)
static const struct message parent_range_test_seq[]
static void test_tic_placement(void)
static const struct message buddy_window_test_seq[]
static void test_line_size(void)
static const struct message ignore_selection_test_seq[]
static const struct message tool_tips_test_seq[]
static const struct message parent_create_trackbar_wnd_seq[]
static const DWORD defaultstyle
static const struct message empty_seq[]
static void test_unicode(void)
#define PBT_APMRESUMESTANDBY
#define PBT_APMRESUMECRITICAL
#define TBS_ENABLESELRANGE
#define TBM_GETUNICODEFORMAT
#define TBM_SETUNICODEFORMAT
#define TBM_SETTHUMBLENGTH
#define TBM_GETTHUMBLENGTH
static BOOL load_v6_module(ULONG_PTR *pcookie, HANDLE *hCtx)
static void unload_v6_module(ULONG_PTR cookie, HANDLE hCtx)
HGDIOBJ WINAPI GetStockObject(_In_ int)
#define WM_QUERYNEWPALETTE
#define SetWindowLongPtrA
#define WM_CTLCOLORSTATIC
BOOL WINAPI RedrawWindow(_In_opt_ HWND, _In_opt_ LPCRECT, _In_opt_ HRGN, _In_ UINT)
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)
LRESULT WINAPI DefWindowProcA(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
#define WM_WINDOWPOSCHANGING
#define CreateWindowA(a, b, c, d, e, f, g, h, i, j, k)
LRESULT WINAPI SendMessageA(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
#define GetWindowLongPtrA
HWND WINAPI GetDesktopWindow(void)
#define WM_IME_SETCONTEXT
BOOL WINAPI GetClientRect(_In_ HWND, _Out_ LPRECT)
ATOM WINAPI RegisterClassA(_In_ CONST WNDCLASSA *)
BOOL WINAPI SetRectEmpty(_Out_ LPRECT)
LRESULT(CALLBACK * WNDPROC)(HWND, UINT, WPARAM, LPARAM)
BOOL WINAPI DestroyWindow(_In_ HWND)
BOOL WINAPI EqualRect(_In_ LPCRECT, _In_ LPCRECT)
LRESULT WINAPI CallWindowProcA(_In_ WNDPROC, _In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
HCURSOR WINAPI LoadCursorA(_In_opt_ HINSTANCE, _In_ LPCSTR)