API Reference | developer.brewmp.com API Reference | developer.brewmp.com

Developer

API Reference

ITAPI_MAKEVOICECALL()

Brew Release
Brew MP 1.0.2
See Also
AEECLSID AEEEvent Error Codes Events ITAPI ITAPI_MakeVoiceCall
Description
This method is called to place a voice call. The number dialed is specified in the digits string. No call is placed if the input string is empty or NULL. Only the following digits are allowed: 0-9, #, * and + if it is first character. All other digits are ignored. If a voice call is in progress EALREADY is returned. If a data call is in progress the data call is ended and the voice call is placed.
This function enforces the privacy policies established by the carrier. This may include intermediate prompts to the user using dialogs.
Typically, when this function is invoked, a dialog is displayed to the user requesting whether it is OK to place a call. When the user clicks "YES", the call is placed.
The event flow to the application when this function is invoked: 1. A dialog is displayed to the user. 2. When that dialog is dismissed, the event EVT_DIALOG_END is sent to the application. 3. At this point, the application must re-draw the screen. 4. If user accepted to place the call, the event EVT_APP_SUSPEND is sent to the application. 5. When the call finishes, the event EVT_APP_RESUME is sent to the application. 6. The application must re-draw the screen.
Params
pITAPI
[]:
Pointer to the ITAPI interface object.
pszNumber
[]:
Pointer to the number to dial.
clsReturn
[]:
ClassID of the applet to be run when the call is completed.
Interface
Prototype
  •  int ITAPI_MakeVoiceCall(ITAPI * pITAPI, const char * pszNumber, AEECLSID clsReturn);
    
Return
  • AEE_SUCCESS : the call is in progress. AEE_EBADPARM : the number is invalid. AEE_EALREADY : there is a voice call already in progress.
Side Effect
  • Depending on the device integration, a dialer application may take over the display. If that happens, the top-visible applet will be suspended.
Comments
If clsReturn is 0, the current application will be resumed. If the class ID passed in clsReturn is not an application then it will be ignored and the current application will be resumed. If the class ID passed in clsReturn is invalid, this API will not return an error. When ITAPI_MakeVoiceCall() is invoked, a privacy dialog will prompt for placing a voice call. After the privacy dialog is selected by the user, EVT_DIALOG_END is sent to the application with dwParam indicating the response. The dwParam has 1 for a "Yes" response and 2 for "No" response from the user. Device manufacturers can choose to not display the dialog at all in which case not EVT_DIALOG_XXX events will be sent to the app for originating a voice call.