## Display Device Driver Reference for OS/2

[prev][next][parent][TOC]

### Remarks

Action routines can perform whatever computation and decision-making is necessary to modify the DSPINSTL data chain for eventual execution. Typically, action routines modify a key field within a data element, or they can add or subtract data-chain elements.

Generally, action routines should not change external system values, such as OS2.INI entries, because there is no guarantee that the user will not end the installation process after the action routine returns. Therefore, it is recommended that the persistent state setting be performed by the commands in DSP files rather than by action routines.

An action routine communicates with the DSPINSTL utility program by setting the data-chain element key values. If an action routine sets several alternative key values in different chain elements, an equivalent set of DSP files (at least one for each alternative key value) must be provided in the eventual source directories or diskettes.

Note: The other DSPINSTL action routines have identical calling sequences and return codes. For that reason, the details of the procedure call interface for Default_Secondary(), Selected_Primary(), and Selected_ Secondary() are not included here.

Three service routines are provided to manipulate the data element chain. The following data structure characterizes a DSPINSTL data element:

    struct dspinstl_chain_element
    {
     ULONG rev_num;        /* DSPINSTL data chain element revision number    */

     PDSPINSTL_CHAIN next; /* Pointer to next DSPINSTL data chain element    */

     PSZ key;              /* Pointer to keyword string associated with this */
                           /*   chain element                                */

     PSZ general_prompt;   /* Pointer to the prompt string to be written in  */
                           /*   the Specify Source Directory panel when this */
                           /*   chain element is interpreted.  A NULL value  */
                           /*   indicates that the previous source directory */
                           /*   should be used again and that this panel     */
                           /*   should be bypassed for this chain element.   */

     PSZ diskette_prompt;  /* Pointer to the prompt string to be written in  */
                           /*   the Insert Diskette prompt panel             */

     PSZ volume_label;     /* Pointer to the (optional) diskette volume      */
                           /*   label string that is used to verify the      */
                           /*   correct identity of a DSP diskette           */

     PSZ resolution_string;/* Optional string that indicates a display driver*/
                           /*   resolution.  The string can be passed to     */
                           /*   Select_Display_Resolutions or left NULL      */
    };

Note: Typically, the various strings found in DSPINSTL data elements are initialized from string values found in DSPINSTL configuration file entries .