Using Photoshop Standard Callback Suites

These callbacks are accessed through callback suite pointers that are hard coded into the parameter block structures; these suites were defined in Photoshop 4.0 and earlier.

In this case, the suite pointer allows access to multiple callback functions. They are given the name of "Standard Suites".

See Photoshop Standard Callback Suites for a list of the standard callback suites available in Photoshop.

The suites are described by a pointer to a record containing:

  • a 2 byte version number for the suite,
  • a 2 byte count of the number of routines in the suite,
  • a series of function pointers for the callback routines.

Before calling a callback defined in the suite, the plug-in needs to check the following conditions:

  1. The suite pointer must not be NULL.
  2. The suite version number must match the version number the plug-in wishes to use. (Adobe does not expect to change suite version numbers often.)
  3. The number of routines defined in the suite must be great enough to include the routine of interest.
  4. The pointer for the routine of interest must not be NULL. If these conditions are not met, your plug-in module should put up an error dialog to alert the user and return a positive result code.