summaryrefslogtreecommitdiff
path: root/src/interface.c
diff options
context:
space:
mode:
authorBenjamin Franzke <benjaminfranzke@googlemail.com>2011-12-19 11:21:05 +0100
committerBenjamin Franzke <benjaminfranzke@googlemail.com>2011-12-19 11:21:48 +0100
commit8214988ef3d74945b440895615eca06df4cae61c (patch)
tree65291ea45dca3a28af08f6dc24023145ff4a275c /src/interface.c
parentef40d1a710228fbef322414c1400dfa922d082f5 (diff)
downloadpa-sink-ctl-8214988ef3d74945b440895615eca06df4cae61c.tar.gz
pa-sink-ctl-8214988ef3d74945b440895615eca06df4cae61c.tar.bz2
pa-sink-ctl-8214988ef3d74945b440895615eca06df4cae61c.zip
command: Put main ctl length logic into interface.c
Diffstat (limited to 'src/interface.c')
-rw-r--r--src/interface.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/interface.c b/src/interface.c
index d4b65e7..8c39e06 100644
--- a/src/interface.c
+++ b/src/interface.c
@@ -190,6 +190,14 @@ interface_redraw(struct interface *ifc)
wrefresh(ifc->menu_win);
}
+int
+interface_get_main_ctl_length(struct interface *ifc)
+{
+ struct context *ctx = container_of(ifc, struct context, interface);
+
+ return g_list_length(ctx->sink_list) + g_list_length(ctx->source_list);
+}
+
static gboolean
interface_get_input(GIOChannel *source, GIOCondition condition, gpointer data)
{