* main.c (copy_prog_name): Make static.
(midnight_callback): Handle both Alt-Enter and Ctrl-Enter before the widgets, because the input widget interprets them now. (default_map): Remove Alt-Enter, it's handled elsewhere.
Этот коммит содержится в:
родитель
7f3a386062
Коммит
befd79dfbc
@ -1,5 +1,10 @@
|
||||
2002-12-25 Pavel Roskin <proski@gnu.org>
|
||||
|
||||
* main.c (copy_prog_name): Make static.
|
||||
(midnight_callback): Handle both Alt-Enter and Ctrl-Enter before
|
||||
the widgets, because the input widget interprets them now.
|
||||
(default_map): Remove Alt-Enter, it's handled elsewhere.
|
||||
|
||||
* key.c (correct_key_code): Convert Shift-Tab and Ctrl-Tab to
|
||||
Back Tab (used in dialogs to jump to the previous widget).
|
||||
|
||||
|
17
src/main.c
17
src/main.c
@ -1319,9 +1319,8 @@ copy_other_readlink (void)
|
||||
copy_readlink (opanel);
|
||||
}
|
||||
|
||||
/* Inserts the selected file name into the input line */
|
||||
/* Exported so that the command modules uses it */
|
||||
void
|
||||
/* Insert the selected file name into the input line */
|
||||
static void
|
||||
copy_prog_name (void)
|
||||
{
|
||||
char *tmp;
|
||||
@ -1469,8 +1468,6 @@ static const key_map default_map[] = {
|
||||
{KEY_F (20), (key_callback) quiet_quit_cmd},
|
||||
|
||||
/* Copy useful information to the command line */
|
||||
{ALT ('\n'), copy_prog_name},
|
||||
{ALT ('\r'), copy_prog_name},
|
||||
{ALT ('a'), copy_current_pathname},
|
||||
{ALT ('A'), copy_other_pathname},
|
||||
|
||||
@ -1741,14 +1738,14 @@ midnight_callback (struct Dlg_head *h, int id, int msg)
|
||||
if (id == '\t')
|
||||
free_completions (cmdline);
|
||||
|
||||
/* Ctrl-Enter */
|
||||
if (id == ('\n' | KEY_M_CTRL)) {
|
||||
copy_prog_name ();
|
||||
if (id == '\n' && cmdline->buffer[0]) {
|
||||
send_message ((Widget *) cmdline, WIDGET_KEY, id);
|
||||
return MSG_HANDLED;
|
||||
}
|
||||
|
||||
if (id == '\n' && cmdline->buffer[0]) {
|
||||
send_message ((Widget *) cmdline, WIDGET_KEY, id);
|
||||
/* Ctrl-Enter and Alt-Enter */
|
||||
if ((id & ~(KEY_M_CTRL | KEY_M_ALT)) == '\n') {
|
||||
copy_prog_name ();
|
||||
return MSG_HANDLED;
|
||||
}
|
||||
|
||||
|
@ -126,7 +126,6 @@ void change_panel (void);
|
||||
void init_sigchld (void); /* For subshell.c */
|
||||
int load_prompt (int fd, void *unused);
|
||||
void save_cwds_stat (void);
|
||||
void copy_prog_name (void);
|
||||
int quiet_quit_cmd (void); /* For cmd.c and command.c */
|
||||
|
||||
void untouch_bar (void);
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user