?
Solved

NM_RCLICK vs. WM_RBUTTONDOWN

Posted on 1998-05-13
1
Medium Priority
?
770 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 2

Accepted Solution

by:
jstolan earned 200 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

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

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…
In this post we will learn different types of Android Layout and some basics of an Android App.
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.
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
Suggested Courses

719 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