25#ifndef _SO_LIST_SENSOR_
26#define _SO_LIST_SENSOR_
138 virtual void trigger();
141 virtual void dyingReference();
144 virtual void schedule() {};
147 virtual void unschedule() {};
155 void invokeDeleteCallback();
void SoSensorCB(void *data, SoSensor *sensor)
This typedef defines the calling sequence for all callbacks from sensors.
Maintains a list of pointers to instances of the SoBase classes.
Sensor class that can be attached to Open Inventor base lists.
@ SET
A previously existing item has been replaced.
@ REMOVE
An item has been deleted.
@ TOUCH
A touch() call has been done on list.
@ INSERT
An item has been inserted.
@ COPY
The list is resulting of a list copy.
@ APPEND
An item has been appended to the list.
@ UNSPECIFIED
Unspecified change.
@ TRUNCATE
The list has been cleared.
SoListSensor(SoSensorCB *func, void *data)
Constructor that takes standard callback function and data.
SoBaseList * getAttachedList() const
Returns the list that this sensor is sensing, or NULL if it is not attached to any list.
void detach()
Unschedules this sensor (if it is scheduled) and makes it ignore changes to the list.
SoListSensor()
Constructor.
ChangeType getTriggerType() const
Returns the type of change that occurred.
virtual ~SoListSensor()
Destructor.
int getTriggerIndex() const
Returns the index of the item that was added, removed, inserted, set, ...
void attach(SoBaseList *list)
Makes this sensor detect changes to the given list.
void setDeleteCallback(SoSensorCB *f, void *data=NULL)
Sets a callback that will be called when the object the sensor is sensing is deleted.
Abstract base class for Open Inventor sensors.