pidgin: 55577fa6: correctly use some text marked by N_(), ...

khc at pidgin.im khc at pidgin.im
Mon Apr 27 00:55:45 EDT 2009


-----------------------------------------------------------------
Revision: 55577fa653435bea0213ccd380f914790714f8a1
Ancestor: 7281ad5ba8e68debd285e06dafebd991e980f3da
Author: khc at pidgin.im
Date: 2009-04-27T04:52:41
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/55577fa653435bea0213ccd380f914790714f8a1

Modified files:
        libpurple/protocols/qq/buddy_info.c
        libpurple/protocols/qq/qq.c

ChangeLog: 

correctly use some text marked by N_(), and mark one more string as
translatable


-------------- next part --------------
============================================================
--- libpurple/protocols/qq/buddy_info.c	997ca090088d2790f7dcc9a16829b1961ee3bb82
+++ libpurple/protocols/qq/buddy_info.c	a684715078b8936574cf2345cedd5a341c09c5cc
@@ -191,7 +191,7 @@ static void info_display_only(PurpleConn
 		}
 		switch (field_infos[index].type) {
 			case QQ_FIELD_BOOL:
-				purple_notify_user_info_add_pair(user_info, field_infos[index].text,
+				purple_notify_user_info_add_pair(user_info, _(field_infos[index].text),
 					strtol(segments[index], NULL, 10) ? _("True") : _("False"));
 				break;
 			case QQ_FIELD_CHOICE:
@@ -200,7 +200,7 @@ static void info_display_only(PurpleConn
 					choice_num = 0;
 				}
 
-				purple_notify_user_info_add_pair(user_info, field_infos[index].text, field_infos[index].choice[choice_num]);
+				purple_notify_user_info_add_pair(user_info, _(field_infos[index].text), field_infos[index].choice[choice_num]);
 				break;
 			case QQ_FIELD_LABEL:
 			case QQ_FIELD_STRING:
@@ -208,7 +208,7 @@ static void info_display_only(PurpleConn
 			default:
 				if (strlen(segments[index]) != 0) {
 					utf8_value = qq_to_utf8(segments[index], QQ_CHARSET_DEFAULT);
-					purple_notify_user_info_add_pair(user_info, field_infos[index].text, utf8_value);
+					purple_notify_user_info_add_pair(user_info, _(field_infos[index].text), utf8_value);
 					g_free(utf8_value);
 				}
 				break;
@@ -348,18 +348,18 @@ static void field_request_new(PurpleRequ
 			utf8_value = qq_to_utf8(segments[index], QQ_CHARSET_DEFAULT);
 			if (field_infos[index].type == QQ_FIELD_STRING) {
 				field = purple_request_field_string_new(
-						field_infos[index].id, field_infos[index].text, utf8_value, FALSE);
+					field_infos[index].id, _(field_infos[index].text), utf8_value, FALSE);
 			} else {
 				field = purple_request_field_string_new(
-						field_infos[index].id, field_infos[index].text, utf8_value, TRUE);
+					field_infos[index].id, _(field_infos[index].text), utf8_value, TRUE);
 			}
 			purple_request_field_group_add_field(group, field);
 			g_free(utf8_value);
 			break;
 		case QQ_FIELD_BOOL:
 			field = purple_request_field_bool_new(
-					field_infos[index].id, field_infos[index].text,
-					strtol(segments[index], NULL, 10) ? TRUE : FALSE);
+				field_infos[index].id, _(field_infos[index].text),
+				strtol(segments[index], NULL, 10) ? TRUE : FALSE);
 			purple_request_field_group_add_field(group, field);
 			break;
 		case QQ_FIELD_CHOICE:
@@ -374,7 +374,7 @@ static void field_request_new(PurpleRequ
 				}
 			}
 			field = purple_request_field_choice_new(
-					field_infos[index].id, field_infos[index].text, choice_num);
+				field_infos[index].id, _(field_infos[index].text), choice_num);
 			for (i = 0; i < field_infos[index].choice_size; i++) {
 				purple_request_field_choice_add(field, field_infos[index].choice[i]);
 			}
============================================================
--- libpurple/protocols/qq/qq.c	c1fb3f4130a814d92965d668f4002abe1b0eeaca
+++ libpurple/protocols/qq/qq.c	7daf00307244c92419d466406f670a867f4440e0
@@ -674,8 +674,8 @@ static void action_about_openq(PurplePlu
 	g_string_append(info, "wd<br>\n");
 	g_string_append(info, "x6719620<br>\n");
 	g_string_append(info, "netelk<br>\n");
-	g_string_append(info, "and more, please let me know... thank you!<br>\n");
-	g_string_append(info, "<br>\n");
+	g_string_append(info, _("and more, please let me know... thank you!))"));
+	g_string_append(info, "<br>\n<br>\n");
 	g_string_append(info, _("<p><i>And, all the boys in the backroom...</i><br>\n"));
 	g_string_append(info, _("<i>Feel free to join us!</i> :)"));
 	g_string_append(info, "</body></html>");


More information about the Commits mailing list