From 1ef0c8c45f040c1d7af3f7289194fec587ad6d15 Mon Sep 17 00:00:00 2001 From: James Booth Date: Sun, 2 Jun 2013 03:02:32 +0100 Subject: Added 'any' to /who command --- src/command/command.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/command/command.c b/src/command/command.c index 41413320..8c281e7c 100644 --- a/src/command/command.c +++ b/src/command/command.c @@ -955,6 +955,7 @@ cmd_init(void) autocomplete_add(who_ac, strdup("offline")); autocomplete_add(who_ac, strdup("available")); autocomplete_add(who_ac, strdup("unavailable")); + autocomplete_add(who_ac, strdup("any")); cmd_history_init(); } @@ -1770,7 +1771,8 @@ _cmd_who(gchar **args, struct cmd_help_t help) && (strcmp(presence, "away") != 0) && (strcmp(presence, "chat") != 0) && (strcmp(presence, "xa") != 0) - && (strcmp(presence, "dnd") != 0)) { + && (strcmp(presence, "dnd") != 0) + && (strcmp(presence, "any") != 0)) { cons_show("Usage: %s", help.usage); // valid arg @@ -1780,7 +1782,7 @@ _cmd_who(gchar **args, struct cmd_help_t help) GList *list = muc_get_roster(room); // no arg, show all contacts - if (presence == NULL) { + if ((presence == NULL) || (g_strcmp0(presence, "any") == 0)) { ui_room_roster(room, list, NULL); // available @@ -1860,7 +1862,7 @@ _cmd_who(gchar **args, struct cmd_help_t help) GSList *list = roster_get_contacts(); // no arg, show all contacts - if (presence == NULL) { + if ((presence == NULL) || (g_strcmp0(presence, "any") == 0)) { cons_show("All contacts:"); cons_show_contacts(list); -- cgit 1.4.1-2-gfad0 tter
path: root/bin/toot.py
blob: a8d0b08652320c2270082dcaad79dcb74b03652a (plain) (tree)
1
2
3
4
5