Usage Notes

To be notified of PS updates using this class, the application must perform the following steps:

  1. Define a class derived from ECLPSNotify.
  2. Implement the NotifyEvent method of the ECLPSNotify-derived class.
  3. Optionally implement other member functions of ECLPSNotify.
  4. Create an instance of the derived class.
  5. Register the instance with the ECLPS::RegisterPSEvent() method.

After registration is complete, updates to the presentation space will cause the NotifyEvent() method of the ECLPSNotify-derived class to be called.

Note that multiple PS updates which occur in a short period of time may be aggregated into a single event notification.

An application can choose to provide its own constructor and destructor for the derived class. This can be useful if the application needs to store some instance-specific data in the class and pass that information as a parameter on the constructor.

If an error is detected during event registration, the NotifyError() member function is called with an ECLErr object. Events may or may not continue to be generated after an error. When event generation terminates (due to an error or some other reason) the NotifyStop() member function is called. The default implementation of NotifyError() will present a message box to the user showing the text of the error messages retrieved from the ECLErr object.

When event notification stops for any reason (error or a call the ECLPS::UnregisterPSEvent) the NotifyStop() member function is called. The default implementation of NotifyStop() does nothing.