# HG changeset patch # User Gabriel Schulhof # Date 1179527470 0 # Node ID 14d10dc7c482769cb0cb72715153d36a2414da6b # Parent 77f8b8adb2565237c9d81190d477d04874ac935d# Parent 9c8172ddc72dfc2d632a050586939182e90920d7 propagate from branch 'im.pidgin.pidgin' (head faebb5b94eeb15c49559aa2b3c3ce87c9a38a763) to branch 'org.maemo.garage.pidgin.pidgin.aop_menu' (head 64262e31f65dd1e8c63341053dc1b4545fb4a5fc) diff -r 77f8b8adb256 -r 14d10dc7c482 ChangeLog --- a/ChangeLog Thu May 17 07:28:53 2007 +0000 +++ b/ChangeLog Fri May 18 22:31:10 2007 +0000 @@ -29,8 +29,9 @@ formatting in tags too * File transfer progress for transfers on MSN is now correctly displayed * You can set/change alias of buddies/chats by double-clicking on the - conversation tabs. (Ma Xuan) + conversation tabs (Ma Xuan) * Fix IRC connection bug with dircproxy (xjoe) + * Ctrl+[shift]+tab focuses the next most active tab (William Thompson) Finch: * Userlist in chat windows, which can be turned on or off using @@ -43,6 +44,7 @@ * Work around an ncurses bug which appears when half of a multi-cell character is covered by an upper-level window * New plugins are shown in bold text in the plugin dialog + * Nicer HTML screendumps version 2.0.0 (5/3/2007): * The project has new names - libpurple for the core, Pidgin for the diff -r 77f8b8adb256 -r 14d10dc7c482 finch/libgnt/gntwm.c --- a/finch/libgnt/gntwm.c Thu May 17 07:28:53 2007 +0000 +++ b/finch/libgnt/gntwm.c Fri May 18 22:31:10 2007 +0000 @@ -628,14 +628,40 @@ int x, y; chtype old = 0, now = 0; FILE *file = fopen("dump.html", "w"); + struct { + char ascii; + char *unicode; + } unis[] = { + {'q', "─"}, + {'t', "├"}, + {'u', "┤"}, + {'x', "│"}, + {'-', "↑"}, + {'.', "↓"}, + {'l', "┌"}, + {'k', "┐"}, + {'m', "└"}, + {'j', "┘"}, + {'a', "▒"}, + {'\0', NULL} + }; + fprintf(file, "\n \n\n\n"); fprintf(file, "
");
 	for (y = 0; y < getmaxy(stdscr); y++) {
 		for (x = 0; x < getmaxx(stdscr); x++) {
-			char ch;
+			char ch[2] = {0, 0}, *print;
+#ifdef NO_WIDECHAR
 			now = mvwinch(curscr, y, x);
-			ch = now & A_CHARTEXT;
-			now ^= ch;
+			ch[0] = now & A_CHARTEXT;
+			now ^= ch[0];
+#else
+			cchar_t wch;
+			char unicode[12];
+			mvwin_wch(curscr, y, x, &wch);
+			now = wch.attr;
+			ch[0] = (char)(wch.chars[0] & 0xff);
+#endif
 
 #define CHECK(attr, start, end) \
 			do \
@@ -688,48 +714,39 @@
 				fprintf(file, "",
 						bg.r, bg.g, bg.b, fg.r, fg.g, fg.b);
 			}
+			print = ch;
+#ifndef NO_WIDECHAR
+			if (wch.chars[0] > 255) {
+				snprintf(unicode, sizeof(unicode), "&#x%x;", wch.chars[0]);
+				print = unicode;
+			}
+#endif
 			if (now & A_ALTCHARSET)
 			{
-				switch (ch)
-				{
-					case 'q':
-						ch = '-'; break;
-					case 't':
-					case 'u':
-					case 'x':
-						ch = '|'; break;
-					case 'v':
-					case 'w':
-					case 'l':
-					case 'm':
-					case 'k':
-					case 'j':
-					case 'n':
-						ch = '+'; break;
-					case '-':
-						ch = '^'; break;
-					case '.':
-						ch = 'v'; break;
-					case 'a':
-						ch = '#'; break;
-					default:
-						ch = ' '; break;
+				int u;
+				for (u = 0; unis[u].ascii; u++) {
+					if (ch[0] == unis[u].ascii) {
+						print = unis[u].unicode;
+						break;
+					}
 				}
+				if (!unis[u].ascii)
+					print = " ";
 			}
-			if (ch == '&')
+			if (ch[0] == '&')
 				fprintf(file, "&");
-			else if (ch == '<')
+			else if (ch[0] == '<')
 				fprintf(file, "<");
-			else if (ch == '>')
+			else if (ch[0] == '>')
 				fprintf(file, ">");
 			else
-				fprintf(file, "%c", ch);
+				fprintf(file, "%s", print);
 			old = now;
 		}
 		fprintf(file, "\n");
 		old = 0;
 	}
-	fprintf(file, "
"); + fprintf(file, "\n"); fclose(file); return TRUE; } diff -r 77f8b8adb256 -r 14d10dc7c482 finch/plugins/gntgf.c --- a/finch/plugins/gntgf.c Thu May 17 07:28:53 2007 +0000 +++ b/finch/plugins/gntgf.c Fri May 18 22:31:10 2007 +0000 @@ -56,7 +56,8 @@ #include #include -#include +#include "gntplugin.h" +#include "gntconv.h" typedef struct { @@ -154,7 +155,7 @@ #endif static void -notify(const char *fmt, ...) +notify(PurpleConversation *conv, const char *fmt, ...) { GntWidget *window; GntToast *toast; @@ -164,6 +165,13 @@ if (purple_prefs_get_bool(PREFS_BEEP)) beep(); + + if (conv != NULL) { + FinchConv *fc = conv->ui_data; + if (gnt_widget_has_focus(fc->window)) + return; + } + #ifdef HAVE_X11 if (purple_prefs_get_bool(PREFS_URGENT)) urgent(); @@ -220,14 +228,14 @@ buddy_signed_on(PurpleBuddy *buddy, gpointer null) { if (purple_prefs_get_bool(PREFS_EVENT_SIGNONF)) - notify(_("%s just signed on"), purple_buddy_get_alias(buddy)); + notify(NULL, _("%s just signed on"), purple_buddy_get_alias(buddy)); } static void buddy_signed_off(PurpleBuddy *buddy, gpointer null) { if (purple_prefs_get_bool(PREFS_EVENT_SIGNONF)) - notify(_("%s just signed off"), purple_buddy_get_alias(buddy)); + notify(NULL, _("%s just signed off"), purple_buddy_get_alias(buddy)); } static void @@ -235,7 +243,7 @@ PurpleConversation *conv, PurpleMessageFlags flags, gpointer null) { if (purple_prefs_get_bool(PREFS_EVENT_IM_MSG)) - notify(_("%s sent you a message"), sender); + notify(conv, _("%s sent you a message"), sender); } static void @@ -254,9 +262,9 @@ if (purple_prefs_get_bool(PREFS_EVENT_CHAT_NICK) && (purple_utf8_has_word(msg, nick))) - notify(_("%s said your nick in %s"), sender, purple_conversation_get_name(conv)); + notify(conv, _("%s said your nick in %s"), sender, purple_conversation_get_name(conv)); else if (purple_prefs_get_bool(PREFS_EVENT_CHAT_MSG)) - notify(_("%s sent a message in %s"), sender, purple_conversation_get_name(conv)); + notify(conv, _("%s sent a message in %s"), sender, purple_conversation_get_name(conv)); } static gboolean diff -r 77f8b8adb256 -r 14d10dc7c482 libpurple/protocols/msn/msn.c --- a/libpurple/protocols/msn/msn.c Thu May 17 07:28:53 2007 +0000 +++ b/libpurple/protocols/msn/msn.c Fri May 18 22:31:10 2007 +0000 @@ -619,7 +619,7 @@ account = purple_connection_get_account(gc); user = msn_normalize(account, purple_account_get_username(account)); - if (strstr(user, "@hotmail.com") != NULL) + if (strstr(user, "@hotmail.") != NULL) { m = g_list_append(m, NULL); act = purple_plugin_action_new(_("Open Hotmail Inbox"), diff -r 77f8b8adb256 -r 14d10dc7c482 libpurple/protocols/msn/notification.c --- a/libpurple/protocols/msn/notification.c Thu May 17 07:28:53 2007 +0000 +++ b/libpurple/protocols/msn/notification.c Fri May 18 22:31:10 2007 +0000 @@ -982,7 +982,8 @@ } else { - fputs("\n" + fputs("\n" + "\n" "\n" "