diff options
author | ailin-nemui <ailin-nemui@users.noreply.github.com> | 2017-10-06 14:58:47 +0200 |
---|---|---|
committer | ailin-nemui <ailin-nemui@users.noreply.github.com> | 2017-10-06 14:58:47 +0200 |
commit | 1fd285dccfd43b740e88f7f4e168132387d39843 (patch) | |
tree | d267684a711264dde49a9480963cfac61027368b /src/perl | |
parent | 92dbb1895b84bc9412bea62ce11473daf4dd2618 (diff) | |
download | irssi-1fd285dccfd43b740e88f7f4e168132387d39843.zip |
refactor history to use history_entries list
this allows access to the global history even when a using /window history
named or /set window_history on, and you want to recall something from one
of the other windows' histories.
usage (default): ctrl+up/down
Diffstat (limited to 'src/perl')
-rw-r--r-- | src/perl/ui/Window.xs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/perl/ui/Window.xs b/src/perl/ui/Window.xs index 8c994cc2..b8d68ad8 100644 --- a/src/perl/ui/Window.xs +++ b/src/perl/ui/Window.xs @@ -252,8 +252,9 @@ PREINIT: GList *tmp; PPCODE: rec = command_history_current(window); - for (tmp = rec->list; tmp != NULL; tmp = tmp->next) - XPUSHs(sv_2mortal(new_pv(tmp->data))); + for (tmp = command_history_list_first(rec); tmp != NULL; tmp = command_history_list_next(rec, tmp)) + XPUSHs(sv_2mortal(new_pv(((HISTORY_ENTRY_REC *)tmp->data)->text))); + #******************************* MODULE = Irssi::UI::Window PACKAGE = Irssi::Windowitem PREFIX = window_item_ |