audio_manager_peek_event()

Check for the next change event without blocking.

Synopsis:

#include <audio/audio_manager_event.h>
 
int audio_manager_peek_event(audio_manager_event_context_t *context, int fd, audio_manager_event_type_t *event_type, void **event_params)

Since:

BlackBerry 10.0.0

Arguments:

context

The context returned by audio_manager_get_event_context().

fd

The file descriptor returned by audio_manager_get_event_fd().

event_type

The type of the event triggered.

event_params

The parameters of the event triggered. The caller is responsible for casting the pointer to the proper change event structure.

Library:

libaudio_manager (For the qcc command, use the -l audio_manager option to link against this library)

Description:

Use audio_manager_peek_event() to determine whether an event has occurred. If an event is found, it returns the event. This function allows you to check for and retrieve an event without blocking. You can call audio_manager_dispatch_event() to clear the event that is returned.

Returns:

EOK upon success, a negative errno upon failure. The errno values are available in the errno.h file.