| MATLAB® | ![]() |
lh = event.proplistener(Hobj,Properties,'PropEvent',@CallbackFunction)
lh = event.proplistener(Hobj,Properties,'PropEvent',@CallbackFunction) creates a property listener object for one or more properties on the specified object.
Hobj — handle of object whose property or properties are to be listened to. If Hobj is an array, the listener responds to the named event on all objects in the array.
Properties — a object array or cell array of meta.property object handles representing the properties to be listened to.
PropEvent — must be one of the strings: PresSet, PostSet, PreGet, PostGet
@CallbackFunction — function handle to the callback function that executes when the event occurs.
The event.proplistener class defines property event listener objects. It is a subclass of the event.listener class and adds one property to those defined by event.listener:
Object — Cell array of objects whose property events are being listened to.
You can call the event.proplistener constructor instead of calling addlistener to create a property listener. However, when you do not use addlistener, the listener's lifecycle is not tied to the object(s) being listened to.
See Listening for Changes to Property Values.
See Obtaining Information About Classes with Meta-Classes for more information on using meta.property objects.
![]() | event.listener | eventlisteners | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |