diff options
author | Benjamin Franzke <benjaminfranzke@googlemail.com> | 2010-11-04 13:39:33 +0100 |
---|---|---|
committer | Benjamin Franzke <benjaminfranzke@googlemail.com> | 2010-11-04 13:39:33 +0100 |
commit | 3d25681eb65376f35a051196dfd316c6fcbc7fa9 (patch) | |
tree | ad44a6507d36626d77e96047dd1c4e3207e31313 /src/interface.c | |
parent | 2c6e80e1741707fec58bb3e5c114079a9d7ccaa5 (diff) | |
download | pa-sink-ctl-3d25681eb65376f35a051196dfd316c6fcbc7fa9.tar.gz pa-sink-ctl-3d25681eb65376f35a051196dfd316c6fcbc7fa9.tar.bz2 pa-sink-ctl-3d25681eb65376f35a051196dfd316c6fcbc7fa9.zip |
get_input: only handle inputs, when context is ready
Diffstat (limited to 'src/interface.c')
-rw-r--r-- | src/interface.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/interface.c b/src/interface.c index a4a03cb..15a8fbb 100644 --- a/src/interface.c +++ b/src/interface.c @@ -16,6 +16,7 @@ #define H_MSG_BOX 3 extern pa_context* context; +extern gboolean context_ready; static WINDOW *menu_win; static WINDOW *msg_win; @@ -167,6 +168,9 @@ gboolean get_input(gpointer data) gint c; gboolean volume_increment = TRUE; + if (!context_ready) + return FALSE; + c = wgetch(menu_win); switch (c) { case 'k': |