aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCharles Kerr <charles.kerr@canonical.com>2016-01-13 14:35:12 -0600
committerCharles Kerr <charles.kerr@canonical.com>2016-01-13 14:35:12 -0600
commit9b72c7f662440844bf59521e124f59bcbddec4a5 (patch)
tree068221198bc1ca78180ac7106d2303cbc4e3079e
parent42d1bd46eecd552dfb907eaa782dd36718893fd4 (diff)
downloadayatana-indicator-sound-9b72c7f662440844bf59521e124f59bcbddec4a5.tar.gz
ayatana-indicator-sound-9b72c7f662440844bf59521e124f59bcbddec4a5.tar.bz2
ayatana-indicator-sound-9b72c7f662440844bf59521e124f59bcbddec4a5.zip
in tests' PulseAudio mock, add pa_context_get_sink_input_info_list() implementation
-rw-r--r--tests/pa-mock.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/pa-mock.cpp b/tests/pa-mock.cpp
index 5dd5c9b..7e7b70c 100644
--- a/tests/pa-mock.cpp
+++ b/tests/pa-mock.cpp
@@ -351,6 +351,25 @@ pa_context_set_source_volume_by_name (pa_context *c, const char * name, const pa
return dummy_operation();
}
+pa_operation*
+pa_context_get_sink_input_info_list(pa_context *c, pa_sink_input_info_cb_t cb, void *userdata)
+{
+ reinterpret_cast<PAMockContext*>(c)->idleOnce(
+ [c, cb, userdata]() {
+
+ pa_sink_input_info sink_input;
+ sink_input.name = "default-sink-input";
+ sink_input.proplist = nullptr;
+ sink_input.has_volume = false;
+
+ if (cb != nullptr)
+ cb(c, &sink_input, true, userdata);
+ });
+
+ return dummy_operation();
+}
+
+
/* *******************************
* subscribe.h
* *******************************/