A function you must write to release resources allocated to the plugin
typedef void ResPluginDestroyF_t (ResPluginHandle_t handle )
This function is exported in the ResPluginCommon_t structure.
This function is called by PhAB to destroy an instance of the resource editor and free the resources allocated.
If the plugin is a frugal editor, then the plugin's widgets have already been destroyed at this point.
If the plugin is a full editor, then it is the plugin's responsibility to destroy its widgets and window, perhaps by calling PtDestroyWidget() with the topmost widget as an argument.
This example destroy function is from the complete plugin example at the end of this chapter.
static void plugin_full_destroy( ResPluginHandle_t handle ) { PluginFullInstance_t *instance = ( PluginFullInstance_t * ) handle; instance->exp->destroy( instance->convenience_handle ); free( instance ); }
QNX Neutrino
ResPluginCommon_t, ResPluginFrugalCreateF_t, ResPluginFullCreateF_t, Resource datatypes.