You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
looking into trustworthy Programming Windows 3.1 book , I found this:
If you want your window procedure to receive double-click mouse messages, you
must include the identifier CS-DBLCLKS when initializing the window style in the window
class structure before calling Register Class:
If you do not include CS_DBLCLKS in the window style and the user clicks the left mouse
button twice in quick succession, your window procedure receives these messages:
WM_LBUTTONDOWN, WM_LBUTTONUP, WM_LBUTTONDOWN, and WM-LBUT-
TONUP. (The window procedure might also receive other messages between these button
messages.) If you want to implement your own double-click logic, you can use the Win¬
dows function GetMessageTime to obtain the relative times of the WM-LBUTTONDOWN
messages. This function is discussed in more detail in Chapter 5.
If you include CS_DBLCLKS in your window class, the window procedure receives
these messages for a double-click: WM-LBUTTONDOWN, WM-LBUTTONUP, WM-
_LBUTTONDBLCLK, and WM_LBUTTONUP. The WM-LBUTTONDBLCLK message sim¬
ply replaces the second WM-LBUTTONDOWN message.
...this is nice and reasonable solution of double-click processing
instead of direct detection, it may just check if there is a handler for a double click
The text was updated successfully, but these errors were encountered:
From discord Pavel said
looking into trustworthy Programming Windows 3.1 book , I found this:
If you want your window procedure to receive double-click mouse messages, you
must include the identifier CS-DBLCLKS when initializing the window style in the window
class structure before calling Register Class:
wndcl ass. style = CS_H REDRAW ! CS.VREDRAW ! CS_DBLCLKS ;
If you do not include CS_DBLCLKS in the window style and the user clicks the left mouse
button twice in quick succession, your window procedure receives these messages:
WM_LBUTTONDOWN, WM_LBUTTONUP, WM_LBUTTONDOWN, and WM-LBUT-
TONUP. (The window procedure might also receive other messages between these button
messages.) If you want to implement your own double-click logic, you can use the Win¬
dows function GetMessageTime to obtain the relative times of the WM-LBUTTONDOWN
messages. This function is discussed in more detail in Chapter 5.
If you include CS_DBLCLKS in your window class, the window procedure receives
these messages for a double-click: WM-LBUTTONDOWN, WM-LBUTTONUP, WM-
_LBUTTONDBLCLK, and WM_LBUTTONUP. The WM-LBUTTONDBLCLK message sim¬
ply replaces the second WM-LBUTTONDOWN message.
...this is nice and reasonable solution of double-click processing
instead of direct detection, it may just check if there is a handler for a double click
The text was updated successfully, but these errors were encountered: