summaryrefslogtreecommitdiffstats
path: root/audio/a2dp.c
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2007-08-28 09:54:21 +0000
committerJohan Hedberg <johan.hedberg@nokia.com>2007-08-28 09:54:21 +0000
commite2827b35575bab20a99a170805a0a59a32fb2c48 (patch)
treeedb190807b7b969177647edd311e83187cedf5bb /audio/a2dp.c
parentb72f1302fa22e420431356a61a80f5f045f75c97 (diff)
Make SBC Audio Source count configurable and the default value 1
Diffstat (limited to 'audio/a2dp.c')
-rw-r--r--audio/a2dp.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/audio/a2dp.c b/audio/a2dp.c
index d3cedefc..fad9bd25 100644
--- a/audio/a2dp.c
+++ b/audio/a2dp.c
@@ -656,21 +656,21 @@ add:
return sep;
}
-int a2dp_init(DBusConnection *conn, gboolean enable_sink, gboolean enable_source)
+int a2dp_init(DBusConnection *conn, int sources, int sinks)
{
- if (!enable_sink && !enable_source)
+ int i;
+
+ if (!sources && !sinks)
return 0;
connection = dbus_connection_ref(conn);
avdtp_init();
- if (enable_sink) {
- a2dp_add_sep(conn, AVDTP_SEP_TYPE_SOURCE);
+ for (i = 0; i < sources; i++)
a2dp_add_sep(conn, AVDTP_SEP_TYPE_SOURCE);
- }
- if (enable_source)
+ for (i = 0; i < sinks; i++)
a2dp_add_sep(conn, AVDTP_SEP_TYPE_SINK);
return 0;