[geary/mjog/misc-fixes] Don't select wrong Inbox



commit 2590e0090e46c55a388be12d52ac7554c4f1eee4
Author: Michael Gratton <mike vee net>
Date:   Wed Dec 4 09:44:38 2019 +0800

    Don't select wrong Inbox
    
    Fixes the inboxes branch inbox being selected when the account branch
    inbox was clicked.

 src/client/application/application-main-window.vala | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/src/client/application/application-main-window.vala 
b/src/client/application/application-main-window.vala
index 812e3961..24b54256 100644
--- a/src/client/application/application-main-window.vala
+++ b/src/client/application/application-main-window.vala
@@ -669,9 +669,11 @@ public class Application.MainWindow :
             // selection changed callback. That will check to
             // ensure that we're not setting it again.
             if (to_select != null) {
-                // Prefer the inboxes branch if it exists
-                if (to_select.special_folder_type != INBOX ||
-                    !this.folder_list.select_inbox(to_select.account)) {
+                // Prefer the inboxes branch if it is a thing, but
+                // only for non-interactive calls
+                if (is_interactive ||
+                    (to_select.special_folder_type != INBOX ||
+                     !this.folder_list.select_inbox(to_select.account))) {
                     this.folder_list.select_folder(to_select);
                 }
             } else {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]