Logo Search packages:      
Sourcecode: pulseaudio version File versions

void pa_context_set_state_callback ( pa_context c,
pa_context_notify_cb_t  cb,
void *  userdata 
)

Set a callback function that is called whenever the context status changes

Definition at line 908 of file context.c.

References PA_CONTEXT_FAILED, and PA_CONTEXT_TERMINATED.

                                                                                             {
    pa_assert(c);
    pa_assert(PA_REFCNT_VALUE(c) >= 1);

    if (c->state == PA_CONTEXT_TERMINATED || c->state == PA_CONTEXT_FAILED)
        return;

    c->state_callback = cb;
    c->state_userdata = userdata;
}


Generated by  Doxygen 1.6.0   Back to index