2012-07-27 [ticho] 3.8.1cvs20
authorAndrej Kacian <ticho@claws-mail.org>
Fri, 27 Jul 2012 17:51:33 +0000 (17:51 +0000)
committerAndrej Kacian <ticho@claws-mail.org>
Fri, 27 Jul 2012 17:51:33 +0000 (17:51 +0000)
* src/compose.c
Fixed "transient for" property for file attach dialog when
called from Attachments list popup menu. Simplified menu item
sensitivities setting code logic for this menu.

ChangeLog
PATCHSETS
configure.ac
src/compose.c

index 93f3c8a..0da45df 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2012-07-27 [ticho]     3.8.1cvs20
+
+       * src/compose.c
+               Fixed "transient for" property for file attach dialog when
+               called from Attachments list popup menu. Simplified menu item
+               sensitivities setting code logic for this menu.
+
 2012-07-25 [ticho]     3.8.1cvs19
 
        * manual/advanced.xml
index 35ed291..0fc422e 100644 (file)
--- a/PATCHSETS
+++ b/PATCHSETS
 ( cvs diff -u -r 1.12.2.60 -r 1.12.2.61 src/gtk/prefswindow.c;  ) > 3.8.1cvs17.patchset
 ( cvs diff -u -r 1.9.2.78 -r 1.9.2.79 src/gtk/gtkaspell.c;  ) > 3.8.1cvs18.patchset
 ( cvs diff -u -r 1.1.2.60 -r 1.1.2.61 manual/advanced.xml;  ) > 3.8.1cvs19.patchset
+( cvs diff -u -r 1.382.2.604 -r 1.382.2.605 src/compose.c;  ) > 3.8.1cvs20.patchset
index 7c7e025..e278e60 100644 (file)
@@ -12,7 +12,7 @@ MINOR_VERSION=8
 MICRO_VERSION=1
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=19
+EXTRA_VERSION=20
 EXTRA_RELEASE=
 EXTRA_GTK2_VERSION=
 
index e123975..7a23338 100644 (file)
@@ -9438,14 +9438,8 @@ static gboolean attach_button_pressed(GtkWidget *widget, GdkEventButton *event,
                attach_selection = gtk_tree_view_get_selection(GTK_TREE_VIEW(widget));
                attach_nr_selected = gtk_tree_selection_count_selected_rows(attach_selection);
                        
-               if (attach_nr_selected > 0)
-               {
-                       cm_menu_set_sensitive_full(compose->ui_manager, "Popup/Compose/Remove", TRUE);
-                       cm_menu_set_sensitive_full(compose->ui_manager, "Popup/Compose/Properties", TRUE);
-               } else {
-                       cm_menu_set_sensitive_full(compose->ui_manager, "Popup/Compose/Remove", FALSE);
-                       cm_menu_set_sensitive_full(compose->ui_manager, "Popup/Compose/Properties", FALSE);
-               }
+               cm_menu_set_sensitive_full(compose->ui_manager, "Popup/Compose/Remove", (attach_nr_selected > 0));
+               cm_menu_set_sensitive_full(compose->ui_manager, "Popup/Compose/Properties", (attach_nr_selected > 0));
                        
                gtk_menu_popup(GTK_MENU(compose->popupmenu), NULL, NULL,
                               NULL, NULL, event->button, event->time);
@@ -9851,6 +9845,10 @@ static void compose_attach_cb(GtkAction *action, gpointer data)
        if (compose->redirect_filename != NULL)
                return;
 
+       /* Set focus_window properly, in case we were called via popup menu,
+        * which unsets it (via focus_out_event callback on compose window). */
+       manage_window_focus_in(compose->window, NULL, NULL);
+
        file_list = filesel_select_multiple_files_open(_("Select file"));
 
        if (file_list) {