DSpCanUserSelectContext
You can use the DSpCanUserSelectContext function to determine whether there is a meaningful choice of contexts to present to the user with the DSpUserSelectContext function.
OSStatus DSpCanUserSelectContext ( DSpContextAttributesPtr inDesiredAttributes Boolean *outUserCanSelectContext );
- DSpContextAttributesPtr
- A pointer to a context attributes structure that specifies the required attributes.
- outUserCanSelectContext
- On exit, the value is
true
if there are multiple contexts that meet the specified attribute requirements;false
if there are not.- function result
- A result code.
DESCRIPTION
The DSpCanUserSelectContext function takes a pointer to a context attributes structure in the inDesiredAttributes parameter and returnstrue
in the outUserCanSelectContext parameter if there is more than one context that has the specified attributes. This function allows you to check before calling the DSpUserSelectContext function so as to avoid presenting the user with a selection dialog box when there is no choice of displays.