summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Franzke <benjaminfranzke@googlemail.com>2011-12-19 11:22:25 +0100
committerBenjamin Franzke <benjaminfranzke@googlemail.com>2011-12-19 11:22:25 +0100
commit3edb3bcabb1c4cb7fbae5b33a26486ef4ef789f8 (patch)
tree7ad903d997beb19a850b04e7d5937162e6e35048
parent8214988ef3d74945b440895615eca06df4cae61c (diff)
downloadpa-sink-ctl-3edb3bcabb1c4cb7fbae5b33a26486ef4ef789f8.tar.gz
pa-sink-ctl-3edb3bcabb1c4cb7fbae5b33a26486ef4ef789f8.tar.bz2
pa-sink-ctl-3edb3bcabb1c4cb7fbae5b33a26486ef4ef789f8.zip
command: Check current ctl in down-command
-rw-r--r--src/command.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/command.c b/src/command.c
index f16e0b0..3b399dc 100644
--- a/src/command.c
+++ b/src/command.c
@@ -59,6 +59,12 @@ down(struct context *ctx, int key)
return;
ctl = interface_get_current_ctl(&ctx->interface, &parent);
+ if (ctl == NULL) {
+ ifc->chooser_child = SELECTED_MAIN_CTL;
+ ctl = interface_get_current_ctl(&ctx->interface, &parent);
+ if (ctl == NULL)
+ return;
+ }
if (parent)
ctl = parent;