Solved

NM_RCLICK vs. WM_RBUTTONDOWN

Posted on 1998-05-13
1
716 Views
Last Modified: 2013-11-20
Is there any advantage to handling one message over the other.  I felt that the NM_* messages were more suitable for common controls, but I am not sure.  Is there a technical advantage of one over the other?  I am aware that some of the message handlers provide different additional data (points vs. NMHDR struct), but again I want to know if I get more bang for my buck (speed, performance, etc.) with one over the other.  Thanks.

PS: Although I may be guessing, I feel that handling NM_* messages is slower, but I have not benchmarked this.
0
Comment
Question by:falkland
1 Comment
 
LVL 2

Accepted Solution

by:
jstolan earned 100 total points
ID: 1310345
The purpose of the WM_NOTIFY messages such as NM_RCLICK is for a control to notify it's parent that a user has clicked on the control.  If the parent is a dialog, for example, it never sees a WM_RBUTTONDOWN message because the event occurred in the child window (the control).

Conversely, if the user clicks on the dialog, the dialog gets the WM_RBUTTONDOWN message but not the NM_RCLICK message.

So you see, the meaning of these messages are quite different, and they should be handled differently.  They are not interchangeable.
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

Introduction: Displaying information on the statusbar.   Continuing from the third article about sudoku.   Open the project in visual studio. Status bar – let’s display the timestamp there.  We need to get the timestamp from the document s…
Introduction: The undo support, implementing a stack. Continuing from the eigth article about sudoku.   We need a mechanism to keep track of the digits entered so as to implement an undo mechanism.  This should be a ‘Last In First Out’ collec…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now