comparison mcabber/src/commands.c @ 960:90ff94f0fbbb

Auto-whois shouldn't enable chat mode
author Mikael Berthe <mikael@lilotux.net>
date Mon, 11 Sep 2006 19:14:59 +0200
parents 30b799632653
children 303408ef5e5d 056364952b0d
comparison
equal deleted inserted replaced
959:8bf36cef8aa6 960:90ff94f0fbbb
1869 } 1869 }
1870 1870
1871 jb_room_unlock(buddy_getjid(bud)); 1871 jb_room_unlock(buddy_getjid(bud));
1872 } 1872 }
1873 1873
1874 void room_whois(gpointer bud, char *arg) 1874 // room_whois(..)
1875 // If interactive is TRUE, chatmode can be enabled.
1876 void room_whois(gpointer bud, char *arg, guint interactive)
1875 { 1877 {
1876 char **paramlst; 1878 char **paramlst;
1877 gchar *nick, *buffer; 1879 gchar *nick, *buffer;
1878 const char *jid, *realjid; 1880 const char *jid, *realjid;
1879 const char *rst_msg; 1881 const char *rst_msg;
1895 return; 1897 return;
1896 } 1898 }
1897 1899
1898 nick = to_utf8(nick); 1900 nick = to_utf8(nick);
1899 1901
1900 // Enter chat mode 1902 if (interactive) {
1901 scr_set_chatmode(TRUE); 1903 // Enter chat mode
1902 scr_ShowBuddyWindow(); 1904 scr_set_chatmode(TRUE);
1905 scr_ShowBuddyWindow();
1906 }
1903 1907
1904 jid = buddy_getjid(bud); 1908 jid = buddy_getjid(bud);
1905 rstatus = buddy_getstatus(bud, nick); 1909 rstatus = buddy_getstatus(bud, nick);
1906 1910
1907 if (rstatus == offline) { 1911 if (rstatus == offline) {
2028 } else if (!strcasecmp(subcmd, "topic")) { 2032 } else if (!strcasecmp(subcmd, "topic")) {
2029 if ((arg = check_room_subcommand(arg, FALSE, bud)) != NULL) 2033 if ((arg = check_room_subcommand(arg, FALSE, bud)) != NULL)
2030 room_topic(bud, arg); 2034 room_topic(bud, arg);
2031 } else if (!strcasecmp(subcmd, "whois")) { 2035 } else if (!strcasecmp(subcmd, "whois")) {
2032 if ((arg = check_room_subcommand(arg, TRUE, bud)) != NULL) 2036 if ((arg = check_room_subcommand(arg, TRUE, bud)) != NULL)
2033 room_whois(bud, arg); 2037 room_whois(bud, arg, TRUE);
2034 } else { 2038 } else {
2035 scr_LogPrint(LPRINT_NORMAL, "Unrecognized parameter!"); 2039 scr_LogPrint(LPRINT_NORMAL, "Unrecognized parameter!");
2036 } 2040 }
2037 2041
2038 free_arg_lst(paramlst); 2042 free_arg_lst(paramlst);