mirror of
https://https.git.savannah.gnu.org/git/bash.git
synced 2026-08-06 02:02:42 +02:00
commit bash-20090827 snapshot
This commit is contained in:
@@ -2226,12 +2226,12 @@ rl_filename_completion_function (text, state)
|
||||
}
|
||||
|
||||
/* An initial implementation of a menu completion function a la tcsh. The
|
||||
first time (if the last readline command was not rl_menu_complete), we
|
||||
first time (if the last readline command was not rl_old_menu_complete), we
|
||||
generate the list of matches. This code is very similar to the code in
|
||||
rl_complete_internal -- there should be a way to combine the two. Then,
|
||||
for each item in the list of matches, we insert the match in an undoable
|
||||
fashion, with the appropriate character appended (this happens on the
|
||||
second and subsequent consecutive calls to rl_menu_complete). When we
|
||||
second and subsequent consecutive calls to rl_old_menu_complete). When we
|
||||
hit the end of the match list, we restore the original unmatched text,
|
||||
ring the bell, and reset the counter to zero. */
|
||||
int
|
||||
@@ -2251,7 +2251,7 @@ rl_old_menu_complete (count, invoking_key)
|
||||
|
||||
/* The first time through, we generate the list of matches and set things
|
||||
up to insert them. */
|
||||
if (rl_last_func != rl_menu_complete)
|
||||
if (rl_last_func != rl_old_menu_complete)
|
||||
{
|
||||
/* Clean up from previous call, if any. */
|
||||
FREE (orig_text);
|
||||
|
||||
@@ -111,6 +111,7 @@ static const FUNMAP default_funmap[] = {
|
||||
{ "non-incremental-reverse-search-history", rl_noninc_reverse_search },
|
||||
{ "non-incremental-forward-search-history-again", rl_noninc_forward_search_again },
|
||||
{ "non-incremental-reverse-search-history-again", rl_noninc_reverse_search_again },
|
||||
{ "old-menu-complete", rl_old_menu_complete },
|
||||
{ "overwrite-mode", rl_overwrite_mode },
|
||||
#ifdef __CYGWIN__
|
||||
{ "paste-from-clipboard", rl_paste_from_clipboard },
|
||||
|
||||
@@ -151,6 +151,7 @@ extern int rl_dump_variables PARAMS((int, int));
|
||||
extern int rl_complete PARAMS((int, int));
|
||||
extern int rl_possible_completions PARAMS((int, int));
|
||||
extern int rl_insert_completions PARAMS((int, int));
|
||||
extern int rl_old_menu_complete PARAMS((int, int));
|
||||
extern int rl_menu_complete PARAMS((int, int));
|
||||
extern int rl_backward_menu_complete PARAMS((int, int));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user