Ticket #2608: mc hangs while switching to opened screen.

The bug was introduced in 6ad4b2466b.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
Andrew Borodin 2012-04-08 16:29:46 +04:00
parent c8c8c0da11
commit 08f2593ae9

View File

@ -1220,11 +1220,12 @@ init_dlg (Dlg_head * h)
dlg_read_history (h);
}
h->state = DLG_ACTIVE;
/* Select the first widget that takes focus */
while (h->current != NULL && !dlg_focus (h))
h->current = dlg_widget_next (h, h->current);
h->state = DLG_ACTIVE;
dlg_redraw (h);
h->ret_value = 0;