Commit fed00cb8 authored by Kanit Therdsteerasukdi's avatar Kanit Therdsteerasukdi Committed by Alexandre Julliard

comctl32: datetime: Return 1 in DTM_SETFORMAT when successful.

parent cecd205f
......@@ -279,7 +279,7 @@ DATETIME_SetFormatW (DATETIME_INFO *infoPtr, LPCWSTR lpszFormat)
DATETIME_UseFormat (infoPtr, lpszFormat);
InvalidateRect (infoPtr->hwndSelf, NULL, TRUE);
return infoPtr->nrFields;
return 1;
}
......
......@@ -190,14 +190,12 @@ static void test_dtm_set_format(HWND hWndDateTime)
{
LRESULT r;
todo_wine {
r = SendMessage(hWndDateTime, DTM_SETFORMAT, 0, (LPARAM)NULL);
expect(1, r);
r = SendMessage(hWndDateTime, DTM_SETFORMAT, 0, (LPARAM)NULL);
expect(1, r);
r = SendMessage(hWndDateTime, DTM_SETFORMAT, 0,
(LPARAM)"'Today is: 'hh':'m':'s dddd MMM dd', 'yyyy");
expect(1, r);
}
r = SendMessage(hWndDateTime, DTM_SETFORMAT, 0,
(LPARAM)"'Today is: 'hh':'m':'s dddd MMM dd', 'yyyy");
expect(1, r);
ok_sequence(sequences, DATETIME_SEQ_INDEX, test_dtm_set_format_seq, "test_dtm_set_format", FALSE);
flush_sequences(sequences, NUM_MSG_SEQUENCES);
......
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