+2007-08-14 [ticho] 2.10.0cvs123
+
+ * src/messageview.c
+ * src/gtk/gtkutils.c
+ Changed return receipt account selector to GtkComboBox.
+ Fixed a runtime warning where GTK tried to parse
+ "name <email@address" as a Pango markup in an alertpanel label.
+
2007-08-14 [ticho] 2.10.0cvs122
* src/prefs_logging.c
( cvs diff -u -r 1.382.2.401 -r 1.382.2.402 src/compose.c; cvs diff -u -r 1.204.2.145 -r 1.204.2.146 src/prefs_common.c; cvs diff -u -r 1.103.2.91 -r 1.103.2.92 src/prefs_common.h; cvs diff -u -r 1.1.2.19 -r 1.1.2.20 src/prefs_receive.c; cvs diff -u -r 1.1.2.16 -r 1.1.2.17 src/prefs_send.c; cvs diff -u -r 1.17.2.39 -r 1.17.2.40 src/send_message.c; ) > 2.10.0cvs120.patchset
( cvs diff -u -r 1.25.2.20 -r 1.25.2.21 tools/Makefile.am; cvs diff -u -r 1.30.2.22 -r 1.30.2.23 tools/README; diff -u /dev/null tools/popfile-link.sh; ) > 2.10.0cvs121.patchset
( cvs diff -u -r 1.1.2.8 -r 1.1.2.9 src/prefs_logging.c; ) > 2.10.0cvs122.patchset
+( cvs diff -u -r 1.94.2.144 -r 1.94.2.145 src/messageview.c; cvs diff -u -r 1.5.2.64 -r 1.5.2.65 src/gtk/gtkutils.c; ) > 2.10.0cvs123.patchset
MICRO_VERSION=0
INTERFACE_AGE=0
BINARY_AGE=0
-EXTRA_VERSION=122
+EXTRA_VERSION=123
EXTRA_RELEASE=
EXTRA_GTK2_VERSION=
#include <stdarg.h>
#include <sys/stat.h>
+#include "combobox.h"
+
#if HAVE_LIBCOMPFACE
# include <compface.h>
#endif
}
GtkWidget *gtkut_account_menu_new(GList *ac_list,
- GCallback callback,
- gpointer data)
+ GCallback callback,
+ gpointer data)
{
GList *cur_ac;
- GtkWidget *menu;
+ GtkWidget *optmenu;
+ GtkListStore *menu;
+ GtkTreeIter iter;
+ PrefsAccount *account;
+ gchar *name;
g_return_val_if_fail(ac_list != NULL, NULL);
- menu = gtk_menu_new();
+ optmenu = gtkut_sc_combobox_create(NULL, FALSE);
+ menu = GTK_LIST_STORE(gtk_combo_box_get_model(GTK_COMBO_BOX(optmenu)));
for (cur_ac = ac_list; cur_ac != NULL; cur_ac = cur_ac->next) {
- gchar *name;
- GtkWidget *menuitem;
- PrefsAccount *account;
-
account = (PrefsAccount *) cur_ac->data;
if (account->name)
name = g_strdup_printf("%s: %s <%s>",
name = g_strdup_printf("%s: %s",
account->account_name,
account->address);
- MENUITEM_ADD(menu, menuitem, name, account->account_id);
+ COMBOBOX_ADD_ESCAPED(menu, name, account->account_id);
g_free(name);
- if (callback != NULL)
- g_signal_connect(G_OBJECT(menuitem), "activate",
- callback, data);
}
- return menu;
+ gtk_combo_box_set_active(GTK_COMBO_BOX(optmenu), 0);
+
+ if( callback != NULL )
+ g_signal_connect(G_OBJECT(optmenu), "changed", callback, data);
+
+ return optmenu;
}
void gtkut_set_widget_bgcolor_rgb(GtkWidget *widget, guint rgbvalue)
#include "uri_opener.h"
#include "inc.h"
#include "log.h"
+#include "combobox.h"
static GList *messageview_list = NULL;
if (ok != 0) {
AlertValue val;
gchar *message;
- message = g_strdup_printf(
+ message = g_markup_printf_escaped(
_("The notification address to which the return receipt is\n"
"to be sent does not correspond to the return path:\n"
"Notification address: %s\n"
static void select_account_cb(GtkWidget *w, gpointer data)
{
- *(gint*)data = GPOINTER_TO_INT(g_object_get_data(G_OBJECT(w), MENU_VAL_ID));
+ *(gint*)data = combobox_get_active_data(GTK_COMBO_BOX(w));
}
-
+
static PrefsAccount *select_account_from_list(GList *ac_list)
{
GtkWidget *optmenu;
- GtkWidget *menu;
gint account_id;
g_return_val_if_fail(ac_list != NULL, NULL);
g_return_val_if_fail(ac_list->data != NULL, NULL);
- optmenu = gtk_option_menu_new();
- menu = gtkut_account_menu_new(ac_list,
- G_CALLBACK(select_account_cb),
+ optmenu = gtkut_account_menu_new(ac_list,
+ G_CALLBACK(select_account_cb),
&account_id);
- if (!menu)
+ if (!optmenu)
return NULL;
- gtk_option_menu_set_menu(GTK_OPTION_MENU(optmenu), menu);
- gtk_option_menu_set_history(GTK_OPTION_MENU(optmenu), 0);
account_id = ((PrefsAccount *) ac_list->data)->account_id;
if (alertpanel_with_widget(
_("Return Receipt Notification"),