A message hook is useful for intercepting or spying on messages
sent to message handlers which were either not created by the
consumer, or when subclassing the handler is not feasible.
If messageHook returns false, no other message hooks will be
invoked and the message will not be delivered to the handler.
If all installed message hooks return true, the message will
be delivered to the handler for processing.
An object which intercepts messages sent to a message handler.
Notes
A message hook is useful for intercepting or spying on messages sent to message handlers which were either not created by the consumer, or when subclassing the handler is not feasible.
If
messageHook
returnsfalse
, no other message hooks will be invoked and the message will not be delivered to the handler.If all installed message hooks return
true
, the message will be delivered to the handler for processing.See also: MessageLoop.installMessageHook and MessageLoop.removeMessageHook