ACAPI_​Install_​PanelHandler

Installs the create/destroy handlers for the registered custom settings panel.

    GSErrCode  ACAPI_Install_PanelHandler (
        Int32                    refCon,
        APIPanelCreateProc*      handlerCreateProc,
        APIPanelDestroyProc*     handlerDestroyProc
    );

 

Parameters

refCon
[in] Panel reference number
handlerCreateProc
[in] Callback function, called when the panel is created.
handlerDestroyProc
[in] Callback function, called when the panel is destroyed.

 

Return Values

APIERR_REFUSEDPAR
There is no panel registered with refcon by the add-on.
NoError
The function has completed with success.

For other common API errors see the API Errors document.

 

Remarks

This function installs the callback functions for handling create/delete events of the dialog panel registered by ACAPI_Register_SettingsPanel, ACAPI_Register_InfoBoxPanel or ACAPI_Register_AttributePanel.

The ACAPI_Install_PanelHandler function should be called from Initialize.

The ‘create’ handler is called when the panel is created. The handler must create the tabpage and the observer. The ‘destroy’ handler is called when the panel is destroyed. The handler must destroy the tabpage and the observer.

For more details refer to the general description of Custom Panels in Settings Dialogs.

 

Example

Refer to the Panel_Test example project of the API Development Kit.

 

Requirements

Version: API 4.1 or later
Header: ACAPinc.h

 

See Also

APIPanelCreateProc
APIPanelDestroyProc
ACAPI_Register_SettingsPanel
ACAPI_Register_InfoBoxPanel
ACAPI_Register_AttributePanel
Custom Panels in Settings Dialogs
API Functions