[evolution-patches] Fix for bug #256899
- From: "chaya n" <chaya kutty gmail com>
- To: evolution-patches gnome org
- Subject: [evolution-patches] Fix for bug #256899
- Date: Tue, 4 Apr 2006 21:56:38 +0530
Patch to get rid of the Enable/Disable redundant button
Index: em-account-prefs.c
===================================================================
RCS file: /cvs/gnome/evolution/mail/em-account-prefs.c,v
retrieving revision 1.26
diff -u -r1.26 em-account-prefs.c
--- em-account-prefs.c 10 Feb 2006 22:28:01 -0000 1.26
+++ em-account-prefs.c 4 Apr 2006 15:48:55 -0000
@@ -313,28 +313,28 @@
mail_config_write ();
}
-static void
-account_able_clicked (GtkButton *button, gpointer user_data)
-{
- EMAccountPrefs *prefs = user_data;
- GtkTreeSelection *selection;
- EAccount *account;
- GtkTreeModel *model;
- GtkTreeIter iter;
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- selection = gtk_tree_view_get_selection (prefs->table);
- if (gtk_tree_selection_get_selected (selection, &model, &iter)) {
- gtk_tree_model_get (model, &iter, 3, &account, -1);
- account->enabled = !account->enabled;
- gtk_list_store_set ((GtkListStore *) model, &iter, 0, account->enabled, -1);
-
- gtk_button_set_label (prefs->mail_able, account->enabled ? _("Disable") : _("Enable"));
- /* let the rest of the application know it changed */
- e_account_list_change (mail_config_get_accounts(), account);
- account_able_changed (account);
- }
-}
static void
account_able_toggled (GtkCellRendererToggle *renderer, char *arg1, gpointer user_data)
@@ -372,8 +372,8 @@
account_able_changed (account);
gtk_list_store_set ((GtkListStore *) model, &iter, 0, account->enabled, -1);
- if (gtk_tree_selection_iter_is_selected (selection, &iter))
- gtk_button_set_label (prefs->mail_able, account->enabled ? _("Disable") : _("Enable"));
+
+
/* let the rest of the application know it changed */
}
@@ -405,10 +405,10 @@
if (state) {
gtk_tree_model_get (model, &iter, 3, &account, -1);
url = e_account_get_string (account, E_ACCOUNT_SOURCE_URL);
- if (account->source && account->enabled)
- gtk_button_set_label (prefs->mail_able, _("Disable"));
- else
- gtk_button_set_label (prefs->mail_able, _("Enable"));
+
+
+
+
} else {
gtk_widget_grab_focus (GTK_WIDGET (prefs->mail_add));
}
@@ -593,8 +593,8 @@
prefs->mail_default = GTK_BUTTON (glade_xml_get_widget (gui, "cmdAccountDefault"));
g_signal_connect (prefs->mail_default, "clicked", G_CALLBACK (account_default_clicked), prefs);
- prefs->mail_able = GTK_BUTTON (glade_xml_get_widget (gui, "cmdAccountAble"));
- g_signal_connect (prefs->mail_able, "clicked", G_CALLBACK (account_able_clicked), prefs);
+
+
g_signal_connect (gtk_tree_view_get_selection (prefs->table),
"changed", G_CALLBACK (account_cursor_change), prefs);
@@ -611,6 +611,6 @@
new = (EMAccountPrefs *) g_object_new (em_account_prefs_get_type (), NULL);
em_account_prefs_construct (new);
new->shell = shell;
-
+
return (GtkWidget *) new;
}
Index: mail-config.glade
===================================================================
RCS file: /cvs/gnome/evolution/mail/mail-config.glade,v
retrieving revision 1.169
diff -u -r1.169 mail-config.glade
--- mail-config.glade 11 Feb 2006 22:30:36 -0000 1.169
+++ mail-config.glade 4 Apr 2006 15:50:42 -0000
@@ -4514,20 +4514,20 @@
</widget>
</child>
- <child>
- <widget class="GtkButton" id="cmdAccountAble">
- <property name="width_request">89</property>
- <property name="height_request">36</property>
- <property name="visible">True</property>
- <property name="sensitive">False</property>
- <property name="can_default">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">E_nable</property>
- <property name="use_underline">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- <property name="focus_on_click">True</property>
- </widget>
- </child>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
</widget>
<packing>
<property name="padding">0</property>
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution/mail/ChangeLog,v
retrieving revision 1.3818.2.3
diff -u -p -r1.3818.2.3 ChangeLog
--- ChangeLog 22 Mar 2006 12:00:05 -0000 1.3818.2.3
+++ ChangeLog 4 Apr 2006 15:54:33 -0000
@@ -1,3 +1,10 @@
+2006-04-04 Chaya N <chaya kutty gmail com>
+
+ *em-account-prefs.c: Remove account_able_clicked() and other signals connected to Enable button
+ *mail-config.glade: Remove gtk_button (Enable/Disable)
+ Fixes bug #256899
+
+
2006-03-22 Patrick Ohly <patrick ohly intel com>
* em-utils.c (em_utils_selection_set_urilist):
@@ -974,7 +981,7 @@ t2006-02-20 Parthasarathi Susarla <spar
2005-08-18 Not Zed <NotZed Ximian com>
* em-format-html-display.c (efhd_message_add_bar): dont add
- attachment bar if it is disabled.
+>> attachment bar if it is disabled.
(efhd_attachment_button): dont add attachments if there is no bar.
* em-format.c (emf_inlinepgp_signed, emf_inlinepgp_encrypted): fix
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]