Commit f6b3376e authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

comctl32/tests: Remove practically unused parameters from test functions.

parent 31057e4b
...@@ -63,6 +63,7 @@ ...@@ -63,6 +63,7 @@
static HFONT hFont; static HFONT hFont;
static DRAWITEMSTRUCT g_drawitem; static DRAWITEMSTRUCT g_drawitem;
static HWND parent_wnd;
static struct msg_sequence *sequences[NUM_MSG_SEQUENCES]; static struct msg_sequence *sequences[NUM_MSG_SEQUENCES];
...@@ -643,8 +644,23 @@ static void test_tab(INT nMinTabWidth) ...@@ -643,8 +644,23 @@ static void test_tab(INT nMinTabWidth)
DeleteObject(hFont); DeleteObject(hFont);
} }
static void test_curfocus(HWND parent_wnd, INT nTabs) static void test_width(void)
{ {
trace ("Testing with default MinWidth\n");
test_tab(-1);
trace ("Testing with MinWidth set to -3\n");
test_tab(-3);
trace ("Testing with MinWidth set to 24\n");
test_tab(24);
trace ("Testing with MinWidth set to 54\n");
test_tab(54);
trace ("Testing with MinWidth set to 94\n");
test_tab(94);
}
static void test_curfocus(void)
{
const INT nTabs = 5;
INT focusIndex; INT focusIndex;
HWND hTab; HWND hTab;
...@@ -676,8 +692,9 @@ static void test_curfocus(HWND parent_wnd, INT nTabs) ...@@ -676,8 +692,9 @@ static void test_curfocus(HWND parent_wnd, INT nTabs)
DestroyWindow(hTab); DestroyWindow(hTab);
} }
static void test_cursel(HWND parent_wnd, INT nTabs) static void test_cursel(void)
{ {
const INT nTabs = 5;
INT selectionIndex; INT selectionIndex;
INT focusIndex; INT focusIndex;
TCITEM tcItem; TCITEM tcItem;
...@@ -728,8 +745,9 @@ static void test_cursel(HWND parent_wnd, INT nTabs) ...@@ -728,8 +745,9 @@ static void test_cursel(HWND parent_wnd, INT nTabs)
DestroyWindow(hTab); DestroyWindow(hTab);
} }
static void test_extendedstyle(HWND parent_wnd, INT nTabs) static void test_extendedstyle(void)
{ {
const INT nTabs = 5;
DWORD prevExtendedStyle; DWORD prevExtendedStyle;
DWORD extendedStyle; DWORD extendedStyle;
HWND hTab; HWND hTab;
...@@ -762,8 +780,9 @@ static void test_extendedstyle(HWND parent_wnd, INT nTabs) ...@@ -762,8 +780,9 @@ static void test_extendedstyle(HWND parent_wnd, INT nTabs)
DestroyWindow(hTab); DestroyWindow(hTab);
} }
static void test_unicodeformat(HWND parent_wnd, INT nTabs) static void test_unicodeformat(void)
{ {
const INT nTabs = 5;
INT unicodeFormat; INT unicodeFormat;
HWND hTab; HWND hTab;
...@@ -793,9 +812,10 @@ static void test_unicodeformat(HWND parent_wnd, INT nTabs) ...@@ -793,9 +812,10 @@ static void test_unicodeformat(HWND parent_wnd, INT nTabs)
DestroyWindow(hTab); DestroyWindow(hTab);
} }
static void test_getset_item(HWND parent_wnd, INT nTabs) static void test_getset_item(void)
{ {
char szText[32] = "New Label"; char szText[32] = "New Label";
const INT nTabs = 5;
TCITEM tcItem; TCITEM tcItem;
LPARAM lparam; LPARAM lparam;
DWORD ret; DWORD ret;
...@@ -935,10 +955,11 @@ static void test_getset_item(HWND parent_wnd, INT nTabs) ...@@ -935,10 +955,11 @@ static void test_getset_item(HWND parent_wnd, INT nTabs)
DestroyWindow(hTab); DestroyWindow(hTab);
} }
static void test_getset_tooltips(HWND parent_wnd, INT nTabs) static void test_getset_tooltips(void)
{ {
HWND hTab, toolTip;
char toolTipText[32] = "ToolTip Text Test"; char toolTipText[32] = "ToolTip Text Test";
const INT nTabs = 5;
HWND hTab, toolTip;
hTab = createFilledTabControl(parent_wnd, TCS_FIXEDWIDTH, TCIF_TEXT|TCIF_IMAGE, nTabs); hTab = createFilledTabControl(parent_wnd, TCS_FIXEDWIDTH, TCIF_TEXT|TCIF_IMAGE, nTabs);
ok(hTab != NULL, "Failed to create tab control\n"); ok(hTab != NULL, "Failed to create tab control\n");
...@@ -958,8 +979,9 @@ static void test_getset_tooltips(HWND parent_wnd, INT nTabs) ...@@ -958,8 +979,9 @@ static void test_getset_tooltips(HWND parent_wnd, INT nTabs)
DestroyWindow(hTab); DestroyWindow(hTab);
} }
static void test_misc(HWND parent_wnd, INT nTabs) static void test_misc(void)
{ {
const INT nTabs = 5;
HWND hTab; HWND hTab;
RECT rTab; RECT rTab;
INT nTabsRetrieved; INT nTabsRetrieved;
...@@ -1019,7 +1041,7 @@ static void test_misc(HWND parent_wnd, INT nTabs) ...@@ -1019,7 +1041,7 @@ static void test_misc(HWND parent_wnd, INT nTabs)
DestroyWindow(hTab); DestroyWindow(hTab);
} }
static void test_adjustrect(HWND parent_wnd) static void test_adjustrect(void)
{ {
HWND hTab; HWND hTab;
INT r; INT r;
...@@ -1036,7 +1058,7 @@ static void test_adjustrect(HWND parent_wnd) ...@@ -1036,7 +1058,7 @@ static void test_adjustrect(HWND parent_wnd)
expect(-1, r); expect(-1, r);
} }
static void test_insert_focus(HWND parent_wnd) static void test_insert_focus(void)
{ {
HWND hTab; HWND hTab;
INT nTabsRetrieved; INT nTabsRetrieved;
...@@ -1102,7 +1124,7 @@ static void test_insert_focus(HWND parent_wnd) ...@@ -1102,7 +1124,7 @@ static void test_insert_focus(HWND parent_wnd)
DestroyWindow(hTab); DestroyWindow(hTab);
} }
static void test_delete_focus(HWND parent_wnd) static void test_delete_focus(void)
{ {
HWND hTab; HWND hTab;
INT nTabsRetrieved; INT nTabsRetrieved;
...@@ -1214,7 +1236,7 @@ static void test_removeimage(void) ...@@ -1214,7 +1236,7 @@ static void test_removeimage(void)
DestroyIcon(hicon); DestroyIcon(hicon);
} }
static void test_delete_selection(HWND parent_wnd) static void test_delete_selection(void)
{ {
HWND hTab; HWND hTab;
DWORD ret; DWORD ret;
...@@ -1236,7 +1258,7 @@ static void test_delete_selection(HWND parent_wnd) ...@@ -1236,7 +1258,7 @@ static void test_delete_selection(HWND parent_wnd)
DestroyWindow(hTab); DestroyWindow(hTab);
} }
static void test_TCM_SETITEMEXTRA(HWND parent_wnd) static void test_TCM_SETITEMEXTRA(void)
{ {
HWND hTab; HWND hTab;
DWORD ret; DWORD ret;
...@@ -1273,7 +1295,7 @@ static void test_TCM_SETITEMEXTRA(HWND parent_wnd) ...@@ -1273,7 +1295,7 @@ static void test_TCM_SETITEMEXTRA(HWND parent_wnd)
DestroyWindow(hTab); DestroyWindow(hTab);
} }
static void test_TCS_OWNERDRAWFIXED(HWND parent_wnd) static void test_TCS_OWNERDRAWFIXED(void)
{ {
LPARAM lparam, lparam2; LPARAM lparam, lparam2;
TCITEMA item; TCITEMA item;
...@@ -1370,7 +1392,6 @@ static void test_TCS_OWNERDRAWFIXED(HWND parent_wnd) ...@@ -1370,7 +1392,6 @@ static void test_TCS_OWNERDRAWFIXED(HWND parent_wnd)
START_TEST(tab) START_TEST(tab)
{ {
HWND parent_wnd;
LOGFONTA logfont; LOGFONTA logfont;
lstrcpyA(logfont.lfFaceName, "Arial"); lstrcpyA(logfont.lfFaceName, "Arial");
...@@ -1382,38 +1403,29 @@ START_TEST(tab) ...@@ -1382,38 +1403,29 @@ START_TEST(tab)
InitCommonControls(); InitCommonControls();
trace ("Testing with default MinWidth\n"); test_width();
test_tab(-1);
trace ("Testing with MinWidth set to -3\n");
test_tab(-3);
trace ("Testing with MinWidth set to 24\n");
test_tab(24);
trace ("Testing with MinWidth set to 54\n");
test_tab(54);
trace ("Testing with MinWidth set to 94\n");
test_tab(94);
init_msg_sequences(sequences, NUM_MSG_SEQUENCES); init_msg_sequences(sequences, NUM_MSG_SEQUENCES);
parent_wnd = createParentWindow(); parent_wnd = createParentWindow();
ok(parent_wnd != NULL, "Failed to create parent window!\n"); ok(parent_wnd != NULL, "Failed to create parent window!\n");
test_curfocus(parent_wnd, 5); test_curfocus();
test_cursel(parent_wnd, 5); test_cursel();
test_extendedstyle(parent_wnd, 5); test_extendedstyle();
test_unicodeformat(parent_wnd, 5); test_unicodeformat();
test_getset_item(parent_wnd, 5); test_getset_item();
test_getset_tooltips(parent_wnd, 5); test_getset_tooltips();
test_misc(parent_wnd, 5); test_misc();
test_adjustrect(parent_wnd); test_adjustrect();
test_insert_focus(parent_wnd); test_insert_focus();
test_delete_focus(parent_wnd); test_delete_focus();
test_delete_selection(parent_wnd); test_delete_selection();
test_removeimage(); test_removeimage();
test_TCM_SETITEMEXTRA(parent_wnd); test_TCM_SETITEMEXTRA();
test_TCS_OWNERDRAWFIXED(parent_wnd); test_TCS_OWNERDRAWFIXED();
DestroyWindow(parent_wnd); DestroyWindow(parent_wnd);
} }
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