mirror of
https://github.com/irssi/irssi.git
synced 2026-08-10 20:33:46 +02:00
reorder history add and fixes
This commit is contained in:
parent
4659cea65a
commit
ad842ea8a6
3 changed files with 9 additions and 20 deletions
|
|
@ -456,22 +456,21 @@ static void key_send_line(void)
|
|||
add_history = *str != '\0';
|
||||
history = command_history_current(active_win);
|
||||
|
||||
if (redir != NULL && redir->flags & ENTRY_REDIRECT_FLAG_HIDDEN)
|
||||
add_history = 0;
|
||||
|
||||
if (add_history && history != NULL) {
|
||||
command_history_add(history, str);
|
||||
}
|
||||
|
||||
if (redir == NULL) {
|
||||
signal_emit("send command", 3, str,
|
||||
active_win->active_server,
|
||||
active_win->active);
|
||||
} else {
|
||||
if (redir->flags & ENTRY_REDIRECT_FLAG_HIDDEN)
|
||||
add_history = 0;
|
||||
handle_entry_redirect(str);
|
||||
}
|
||||
|
||||
if (add_history) {
|
||||
history = command_history_find(history);
|
||||
if (history != NULL)
|
||||
command_history_add(history, str);
|
||||
}
|
||||
|
||||
if (active_entry != NULL)
|
||||
gui_entry_set_text(active_entry, "");
|
||||
command_history_clear_pos(active_win);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue