summaryrefslogtreecommitdiffstats
path: root/src/pulsecore/sink-input.h
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2008-10-21 18:24:45 +0200
committerLennart Poettering <lennart@poettering.net>2008-10-21 18:24:45 +0200
commit358824b330e20b9e6472fdefc4613e03b20c9abb (patch)
treeb852559702e728644ab18727e0e7a99b379a1244 /src/pulsecore/sink-input.h
parent309bc71f07bdb00ecf050d7a4b1734accafcb95f (diff)
add new virtual function may_move_to to sink inputs/source outputs to allow modules to forbid certain connections
Diffstat (limited to 'src/pulsecore/sink-input.h')
-rw-r--r--src/pulsecore/sink-input.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/pulsecore/sink-input.h b/src/pulsecore/sink-input.h
index ed95fe4b..97668c52 100644
--- a/src/pulsecore/sink-input.h
+++ b/src/pulsecore/sink-input.h
@@ -156,10 +156,15 @@ struct pa_sink_input {
returns */
pa_usec_t (*get_latency) (pa_sink_input *i); /* may be NULL */
- /* If non_NULL this function is called from thread context if the
+ /* If non-NULL this function is called from thread context if the
* state changes. The old state is found in thread_info.state. */
void (*state_change) (pa_sink_input *i, pa_sink_input_state_t state); /* may be NULL */
+ /* If non-NULL this function is called before this sink input is
+ * move to a sink and if it returns FALSE the move will not
+ * be allowed */
+ pa_bool_t (*may_move_to) (pa_sink_input *i, pa_sink *s); /* may be NULL */
+
struct {
pa_sink_input_state_t state;
pa_atomic_t drained;
@@ -292,6 +297,7 @@ pa_bool_t pa_sink_input_get_mute(pa_sink_input *i);
pa_resample_method_t pa_sink_input_get_resample_method(pa_sink_input *i);
int pa_sink_input_move_to(pa_sink_input *i, pa_sink *dest);
+pa_bool_t pa_sink_input_may_move_to(pa_sink_input *i, pa_sink *dest);
pa_sink_input_state_t pa_sink_input_get_state(pa_sink_input *i);