Jump to content

WM BUTTON1DBLCLK: Difference between revisions

From EDM2
Created page with "This message occurs when the operator presses button 1 of the pointing device twice within a specified time. ==Syntax== <PRE> param1 POINTS ptspointerpos; Pointer position.: param2 USHORT fsHitTestres; Hit-test result.: USHORT fsflags; Keyboard control codes.: </PRE> ==Parameters== ;ptspointerpos (POINTS) - Input : Pointer position. The pointer position is in window coordinates relative to the bottom-left corner of the..."
 
 
Line 57: Line 57:
;in Multiline Entry Fields
;in Multiline Entry Fields
The default window procedure takes no action on this message, other than to set rc to FALSE.  
The default window procedure takes no action on this message, other than to set rc to FALSE.  
==Related Messages==
* [[WM_BUTTON1DBLCLK (in Frame Controls)]]
* [[WM_BUTTON1DBLCLK (in Multiline Entry Fields)]]


[[Category:Messages]]
[[Category:Messages]]

Latest revision as of 22:12, 13 April 2025

This message occurs when the operator presses button 1 of the pointing device twice within a specified time.

Syntax

param1
    POINTS    ptspointerpos;  /* Pointer position. */

param2
    USHORT    fsHitTestres;   /* Hit-test result. */
    USHORT    fsflags;        /* Keyboard control codes. */

Parameters

ptspointerpos (POINTS) - Input
Pointer position. The pointer position is in window coordinates relative to the bottom-left corner of the window.
fsHitTestres (USHORT) - Input
Hit-test result. fsHitTestres provides the hit-test result. It contains the value returned from the hit-test process, which determines the window to be associated with this message. For details of the possible values, see WM_HITTEST.
fsflags (USHORT) - Input
Keyboard control codes. In addition to the control codes described with the WM_CHAR message, the following keyboard control codes are valid:
KC_NONE
Indicates that no key is pressed.

Returns

rc (BOOL) - returns
Processed indicator.
TRUE
Message processed
FALSE
Message ignored.

Remarks

This message is posted to the application queue associated with the window that is to receive the pointer-button information.

A double-click is recognized if all of the following are true:

  • Two clicks are of the same button.
  • No intervening pointing device button is pressed.
  • The two clicks occur within the double-click time interval as defined by the SV_DBLCLKTIME system value.
  • The two clicks occur within a small spatial distance. This is defined by the rectangle, the length of whose sides parallel to the x- and y-axes are respectively, the SV_CXDBLCLICK and SV_CYDBLCLICK system values. The first click is assumed to be at the center of this rectangle.

The keyboard control codes specified by flags reflects the keyboard state at the time the mouse message was initiated. This may or may not reflect the current keyboard state.

in Multiline Entry Fields

This message indicates that mouse button 1 has clicked twice within the system double-click time.

Mouse Event Action
Double-Click If the click point is in the middle of a non-white-space character, the token (word) surrounding the clicked-on character, and any trailing spaces, are selected. If the click point is in a space character, the previous word (along with the trailing spaces including the clicked-on space) is selected. If there is no preceding word (either because the spaces are at the beginning of the text or immediately follow a line-break character) the run of spaces is selected. If the click point is on a tab or line-break character, that character is selected.
Shift-Double-Click Double-clicking while the Shift key is pressed leaves the anchor point alone, and moves the cursor point to the beginning or end of the clicked-on token. If the click point is before the anchor point in the text, the cursor point is moved to the beginning of the surrounding word, otherwise, the cursor point is moved to the end of the surrounding word. When shift-double-clicking, the selection is extended to include the token that was double-clicked on.
Margin Mouse Event All mouse events in a margin cause the MLE to send a MLN_MARGIN notification to the owner window of the MLE. This message has, as its parameters, the original mouse message. The owner can process the notification or not. If the owner does not process the message, the event is treated as if it occurred on the closest point in the text.

Default Processing

The default window procedure sends the message to the owner window if it exists, otherwise it takes no action on this message, other than to set rc to FALSE.

in Frame Controls

If the frame is minimized, the frame control window procedure causes the frame window to return to its previous state. Otherwise, the message is handled like a WM_BUTTON1DOWN message.

in Multiline Entry Fields

The default window procedure takes no action on this message, other than to set rc to FALSE.