|
|
|
|
|
VolumePhysicalButton (Function) In french: VolumeBoutonPhysique Identifies or modifies the sound source associated with the physical buttons used to set the volume of the device. Remark: This function can be used in the emulator. // Modify the sound source associated with the buttons used to set the volume // in a window containing a multimedia control: VolumePhysicalButton(MyWindow, volumeMusic)
Syntax
Retrieving the sound source associated with the physical buttons used to set the volume (for a window) Hide the details
<Result> = VolumePhysicalButton([<Window name>])
<Result>: Integer Sound source associated with the buttons used to set the volume: | | volumeAlarm | Volume of the alarme. | volumeCall | Volume of calls. | volumeDefault | Volume of default source. This source depends on the phone configuration. | volumeMusic | Volume used when playing an audio or video file. | volumeNotification | Volume of the sound emitted during a new notification. | volumeRing | Volume of phone ring. | volumeSystem | Volume of system sounds. |
<Window name>: Optional character string Name or alias of the window to be used. If this parameter is not specified or if it corresponds to an empty string (""), the current window will be used.
Modifying the sound source associated with the physical buttons used to set the volume (for a window) Hide the details
<Result> = VolumePhysicalButton(<Window name> , <Source>)
<Result>: Boolean - True if the modification was performed. This modification is taken into account for the specified window and it is not applied anymore when this window is closed.
- False otherwise. If an error occurs, the ErrorOccurred variable is set to True. To get the details of the error, use ErrorInfo.
<Window name>: Character string - Name or alias of the window to be used.
- Empty string ("") to handle the current window.
<Source>: Integer constant Sound source that must be assigned to the buttons used to set the volume: | | volumeAlarm | Volume of the alarme. | volumeCall | Volume of calls. | volumeDefault | Restore the default source, configured on the phone. | volumeMusic | Volume used when playing an audio or video file. | volumeNotification | Volume of the sound emitted during a new notification. | volumeRing | Volume of phone ring. | volumeSystem | Volume of system sounds. |
Remarks - In some cases, the buttons used to set the volume can act on a sound source other than the one assigned by VolumePhysicalButton (if a call is in progress for example).
- To modify the setting of the volume for a sound source, use VolumeModify.
- To find out the value of the current setting for the volume of a sound source, use VolumeGet.
Component: wd300android.jar
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|