Fix of DLG_ACTION handling in diff viewer.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Этот коммит содержится в:
родитель
9ae7a28bf8
Коммит
3e35200517
@ -422,6 +422,6 @@ PageUp = pgup
|
||||
Home = home
|
||||
End = end
|
||||
Help = f1
|
||||
Quit = f10; q; shift-q; ctrl-g; esc
|
||||
Quit = f10; q; shift-q; esc
|
||||
Shell = ctrl-o
|
||||
SelectCodepage = alt-e
|
||||
|
@ -425,6 +425,6 @@ PageUp = pgup
|
||||
Home = home
|
||||
End = end
|
||||
Help = f1
|
||||
Quit = f10; q; shift-q; ctrl-g; esc
|
||||
Quit = f10; q; shift-q; esc
|
||||
Shell = ctrl-o
|
||||
SelectCodepage = alt-e
|
||||
|
@ -3132,6 +3132,9 @@ dview_execute_cmd (WDiff * dview, unsigned long command)
|
||||
repaint_screen ();
|
||||
break;
|
||||
#endif
|
||||
case CK_Cancel:
|
||||
/* don't close diffviewer due to SIGINT */
|
||||
break;
|
||||
default:
|
||||
res = MSG_NOT_HANDLED;
|
||||
}
|
||||
@ -3234,8 +3237,19 @@ dview_dialog_callback (Dlg_head * h, Widget * sender, dlg_msg_t msg, int parm, v
|
||||
return MSG_HANDLED;
|
||||
|
||||
case DLG_ACTION:
|
||||
/* command from buttonbar */
|
||||
return send_message ((Widget *) dview, WIDGET_COMMAND, parm);
|
||||
/* shortcut */
|
||||
if (sender == NULL)
|
||||
return dview_execute_cmd (NULL, parm);
|
||||
/* message from buttonbar */
|
||||
if (sender == (Widget *) find_buttonbar (h))
|
||||
{
|
||||
if (data != NULL)
|
||||
return send_message ((Widget *) data, WIDGET_COMMAND, parm);
|
||||
|
||||
dview = (WDiff *) find_widget_type (h, dview_callback);
|
||||
return dview_execute_cmd (dview, parm);
|
||||
}
|
||||
return MSG_NOT_HANDLED;
|
||||
|
||||
case DLG_VALIDATE:
|
||||
dview = (WDiff *) find_widget_type (h, dview_callback);
|
||||
|
@ -527,7 +527,7 @@ static const global_keymap_ini_t default_diff_keymap[] = {
|
||||
{"Home", "home"},
|
||||
{"End", "end"},
|
||||
{"Help", "f1"},
|
||||
{"Quit", "f10; q; shift-q; ctrl-g; esc"},
|
||||
{"Quit", "f10; q; shift-q; esc"},
|
||||
#ifdef HAVE_CHARSET
|
||||
{"SelectCodepage", "alt-e"},
|
||||
#endif
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user