From 3edb3bcabb1c4cb7fbae5b33a26486ef4ef789f8 Mon Sep 17 00:00:00 2001 From: Benjamin Franzke Date: Mon, 19 Dec 2011 11:22:25 +0100 Subject: command: Check current ctl in down-command --- src/command.c | 6 ++++++ 1 file changed, 6 insertions(+) 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; -- cgit