summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorFarow <farow_spam@lavabit.com>2013-10-13 22:39:17 +0300
committerTingPing <tingping@tingping.se>2013-10-22 13:35:28 -0400
commitbb5d589c795918a3353d9d9537768d7dc2c1d8dd (patch)
tree513853973452274b6c2d8d76eba162c5128b2821
parent6d3c176ff83052f35c0eed2ffd7aa35bf69315fb (diff)
Open channel list window on /list
-rw-r--r--src/common/fe.h1
-rw-r--r--src/common/outbound.c2
-rw-r--r--src/fe-gtk/fe-gtk.c6
-rw-r--r--src/fe-text/fe-text.c5
4 files changed, 13 insertions, 1 deletions
diff --git a/src/common/fe.h b/src/common/fe.h
index 24fde989..a7287c4d 100644
--- a/src/common/fe.h
+++ b/src/common/fe.h
@@ -179,5 +179,6 @@ typedef enum
 void fe_tray_set_icon (feicon icon);
 void fe_tray_set_tooltip (const char *text);
 void fe_tray_set_balloon (const char *title, const char *text);
+void fe_open_chan_list (server *serv, char *filter, int do_refresh);
 
 #endif
diff --git a/src/common/outbound.c b/src/common/outbound.c
index 879d0337..0b37caf5 100644
--- a/src/common/outbound.c
+++ b/src/common/outbound.c
@@ -2477,7 +2477,7 @@ cmd_lastlog (struct session *sess, char *tbuf, char *word[], char *word_eol[])
 static int
 cmd_list (struct session *sess, char *tbuf, char *word[], char *word_eol[])
 {
-	sess->server->p_list_channels (sess->server, word_eol[2], 1);
+	fe_open_chan_list (sess->server, word_eol[2], TRUE);
 
 	return TRUE;
 }
diff --git a/src/fe-gtk/fe-gtk.c b/src/fe-gtk/fe-gtk.c
index af3173e1..3763cc3b 100644
--- a/src/fe-gtk/fe-gtk.c
+++ b/src/fe-gtk/fe-gtk.c
@@ -1091,3 +1091,9 @@ fe_get_file (const char *title, char *initial,
 	/* CANCEL: Call callback once with file=NULL. */
 	gtkutil_file_req (title, callback, userdata, initial, NULL, flags | FRF_FILTERISINITIAL);
 }
+
+void
+fe_open_chan_list (server *serv, char *filter, int do_refresh)
+{
+	chanlist_opengui (serv, do_refresh);
+}
diff --git a/src/fe-text/fe-text.c b/src/fe-text/fe-text.c
index b218e862..6f197916 100644
--- a/src/fe-text/fe-text.c
+++ b/src/fe-text/fe-text.c
@@ -908,3 +908,8 @@ void fe_tray_set_icon (feicon icon){}
 void fe_tray_set_tooltip (const char *text){}
 void fe_tray_set_balloon (const char *title, const char *text){}
 void fe_userlist_update (session *sess, struct User *user){}
+void
+fe_open_chan_list (server *serv, char *filter, int do_refresh)
+{
+	serv->p_list_channels (serv, filter, 1);
+}