fix bug 3170, 'QuickSearch fights with View/Hide read threads menu option'
authorPaul <paul@claws-mail.org>
Tue, 3 Jun 2014 16:56:15 +0000 (17:56 +0100)
committerPaul <paul@claws-mail.org>
Tue, 3 Jun 2014 16:56:15 +0000 (17:56 +0100)
src/mainwindow.c

index 7b71254dbe45c019e8fe2f09222f5246e7f29257..62b380a40767341b0b654c12579d805823700fe0 100644 (file)
@@ -3316,10 +3316,14 @@ do { \
 
        if (mainwin->summaryview->folder_item && !mainwin->summaryview->folder_item->threaded)
                cm_toggle_menu_set_active_full(mainwin->ui_manager, "Menu/View/HideReadThreads", FALSE);
 
        if (mainwin->summaryview->folder_item && !mainwin->summaryview->folder_item->threaded)
                cm_toggle_menu_set_active_full(mainwin->ui_manager, "Menu/View/HideReadThreads", FALSE);
-       if (mainwin->summaryview->folder_item && mainwin->summaryview->folder_item->hide_read_msgs)
+       if ((mainwin->summaryview->folder_item && mainwin->summaryview->folder_item->hide_read_msgs) ||
+           quicksearch_has_sat_predicate(mainwin->summaryview->quicksearch))
                cm_menu_set_sensitive_full(mainwin->ui_manager, "Menu/View/HideReadThreads", FALSE);
                cm_menu_set_sensitive_full(mainwin->ui_manager, "Menu/View/HideReadThreads", FALSE);
-       if (mainwin->summaryview->folder_item && mainwin->summaryview->folder_item->hide_read_threads)
+       if ((mainwin->summaryview->folder_item && mainwin->summaryview->folder_item->hide_read_threads) ||
+           quicksearch_has_sat_predicate(mainwin->summaryview->quicksearch))
                cm_menu_set_sensitive_full(mainwin->ui_manager, "Menu/View/HideReadMessages", FALSE);
                cm_menu_set_sensitive_full(mainwin->ui_manager, "Menu/View/HideReadMessages", FALSE);
+       if (quicksearch_has_sat_predicate(mainwin->summaryview->quicksearch))
+               cm_menu_set_sensitive_full(mainwin->ui_manager, "Menu/View/HideDelMessages", FALSE);
 
        cm_menu_set_sensitive_full(mainwin->ui_manager, "Menu/View/Goto/PrevHistory",
                messageview_nav_has_prev(mainwin->messageview));
 
        cm_menu_set_sensitive_full(mainwin->ui_manager, "Menu/View/Goto/PrevHistory",
                messageview_nav_has_prev(mainwin->messageview));