mirror of
https://github.com/irssi/irssi.git
synced 2026-08-11 04:43:34 +02:00
CTCP msgs/replies stops the "event privmsg" or "event notice" signals now
so you don't have to check for them anymore (unless you use signal_add_first()..). /WINDOW MOVE command had some bugs. CTCP reply to some channel didn't display the channel name. Several code cleanups. git-svn-id: http://svn.irssi.org/repos/irssi/trunk@327 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
919abb2c6f
commit
18f3c74d68
19 changed files with 231 additions and 229 deletions
|
|
@ -306,7 +306,7 @@ WINDOW_REC *window_find_item(WINDOW_REC *window, const char *name)
|
|||
return MODULE_DATA(item);
|
||||
}
|
||||
|
||||
int window_refnum_prev(int refnum)
|
||||
int window_refnum_prev(int refnum, int wrap)
|
||||
{
|
||||
GSList *tmp;
|
||||
int prev, max;
|
||||
|
|
@ -317,14 +317,14 @@ int window_refnum_prev(int refnum)
|
|||
|
||||
if (rec->refnum < refnum && (prev == -1 || rec->refnum > prev))
|
||||
prev = rec->refnum;
|
||||
if (max == -1 || rec->refnum > max)
|
||||
if (wrap && (max == -1 || rec->refnum > max))
|
||||
max = rec->refnum;
|
||||
}
|
||||
|
||||
return prev != -1 ? prev : max;
|
||||
}
|
||||
|
||||
int window_refnum_next(int refnum)
|
||||
int window_refnum_next(int refnum, int wrap)
|
||||
{
|
||||
GSList *tmp;
|
||||
int min, next;
|
||||
|
|
@ -335,7 +335,7 @@ int window_refnum_next(int refnum)
|
|||
|
||||
if (rec->refnum > refnum && (next == -1 || rec->refnum < next))
|
||||
next = rec->refnum;
|
||||
if (min == -1 || rec->refnum < min)
|
||||
if (wrap && (min == -1 || rec->refnum < min))
|
||||
min = rec->refnum;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue