about summary refs log tree commit diff stats
path: root/src/xmpp
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2013-06-02 17:51:38 +0100
committerJames Booth <boothj5@gmail.com>2013-06-02 17:51:38 +0100
commitf72e7d89b842d696730021226e540237b7c14a60 (patch)
tree08f616ae8d65b15b68513514572cd2f408961f88 /src/xmpp
parentf455f9ab90db3cd8a05e36c2ea018851806cb5c8 (diff)
downloadprofani-tty-f72e7d89b842d696730021226e540237b7c14a60.tar.gz
Changed autocomplete for /group and /who
Diffstat (limited to 'src/xmpp')
-rw-r--r--src/xmpp/roster.c6
-rw-r--r--src/xmpp/xmpp.h1
2 files changed, 7 insertions, 0 deletions
diff --git a/src/xmpp/roster.c b/src/xmpp/roster.c
index 2126efd8..c6039ed2 100644
--- a/src/xmpp/roster.c
+++ b/src/xmpp/roster.c
@@ -421,6 +421,12 @@ roster_find_resource(char *search_str)
 }
 
 char *
+roster_find_group(char *search_str)
+{
+    return autocomplete_complete(groups_ac, search_str);
+}
+
+char *
 roster_barejid_from_name(const char * const name)
 {
     return g_hash_table_lookup(name_to_barejid, name);
diff --git a/src/xmpp/xmpp.h b/src/xmpp/xmpp.h
index 7d077237..50518dba 100644
--- a/src/xmpp/xmpp.h
+++ b/src/xmpp/xmpp.h
@@ -139,6 +139,7 @@ GSList * roster_get_contacts(void);
 char * roster_find_contact(char *search_str);
 char * roster_find_jid(char *search_str);
 char * roster_find_resource(char *search_str);
+char * roster_find_group(char *search_str);
 gboolean roster_add(const char * const barejid, const char * const name,
     GSList *groups, const char * const subscription, gboolean pending_out,
     gboolean from_initial);