[haiku-3rdparty-dev] Re: Capturing the "NTCH" message
- From: Stephan Assmus <superstippi@xxxxxx>
- To: haiku-3rdparty-dev@xxxxxxxxxxxxx
- Date: Mon, 30 Nov 2009 19:31:35 +0100
Hi,
On 2009-11-30 at 09:50:46 [+0100], Yashasvi A.C. <yashasviac@xxxxxxxxx>
wrote:
> I have been able to capture the "NTCH" messages whenever the state of a
> specific control changes. For example, when I click the "CheckBox1"
> control, the NTCH message is intercepted. The order goes like _MUP, ChCl
> (my customized command message for the control) and then NTCH.
>
> When I spoke to my supervisor, he told me that the NTCH message was the
> notification message. I looked at the information in it and it consists
> of 6 attributes:
> when, source, be:value, be:sender, be:observe_orig_what,
> be:observe_change_what.
> We believe this may be the message we were looking for when need to look
> at a control changing its state.
Correct.
> The thing is I would like to see whether any of these attributes contain
> the value "CheckBox1" which I can use for my analysis. I suspect the
> "CheckBox1" string might be in the sender or source attributes. How do I
> look at these attributes though? Source is of a B_POINTER_TYPE (void* i
> think) and sender is BMessenger. I cant just do a toString() style of
> code to these attributes and view their values, isnt it?
You should definitely read the chapters on messaging in the BeBook. For
your convenience:
<file:///boot/system/documentation/bebook/TheApplicationKit_Messaging.html>
<http://www.haiku-os.org/legacy-docs/bebook/TheApplicationKit_Messaging.html>
Otherwise one doesn't know where to start to answer these questions, and it
would mostly be a duplication of the BeBook anyway, until one reaches more
specific problems that you have.
Best regards,
-Stephan
Other related posts: