mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-23 04:46:55 +03:00
(radio_callback): cosmetics.
* [MSG_HOTKEY]: remove extra block. * [MSG_KEY]: do not fall through. Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
parent
aa6055b6aa
commit
d7ecbd51cf
@ -60,21 +60,20 @@ radio_callback (Widget * w, Widget * sender, widget_msg_t msg, int parm, void *d
|
|||||||
switch (msg)
|
switch (msg)
|
||||||
{
|
{
|
||||||
case MSG_HOTKEY:
|
case MSG_HOTKEY:
|
||||||
|
for (i = 0; i < r->count; i++)
|
||||||
{
|
{
|
||||||
for (i = 0; i < r->count; i++)
|
if (r->texts[i].hotkey != NULL)
|
||||||
{
|
{
|
||||||
if (r->texts[i].hotkey != NULL)
|
int c;
|
||||||
{
|
|
||||||
int c = g_ascii_tolower ((gchar) r->texts[i].hotkey[0]);
|
|
||||||
|
|
||||||
if (c != parm)
|
c = g_ascii_tolower ((gchar) r->texts[i].hotkey[0]);
|
||||||
continue;
|
if (c != parm)
|
||||||
r->pos = i;
|
continue;
|
||||||
|
r->pos = i;
|
||||||
|
|
||||||
/* Take action */
|
/* Take action */
|
||||||
send_message (w, sender, MSG_KEY, ' ', data);
|
send_message (w, sender, MSG_KEY, ' ', data);
|
||||||
return MSG_HANDLED;
|
return MSG_HANDLED;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return MSG_NOT_HANDLED;
|
return MSG_NOT_HANDLED;
|
||||||
@ -106,6 +105,8 @@ radio_callback (Widget * w, Widget * sender, widget_msg_t msg, int parm, void *d
|
|||||||
widget_redraw (w);
|
widget_redraw (w);
|
||||||
return MSG_HANDLED;
|
return MSG_HANDLED;
|
||||||
}
|
}
|
||||||
|
return MSG_NOT_HANDLED;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return MSG_NOT_HANDLED;
|
return MSG_NOT_HANDLED;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user