[gnome-software/1364-implement-other-apps-by-author-section-in-app-details-page: 156/156] gs-shell: Let the 'Back' button go back in the Details page




commit 5a4260bdb6bd84d6b8490c8e5b7501d164567898
Author: Milan Crha <mcrha redhat com>
Date:   Fri May 6 10:49:24 2022 +0200

    gs-shell: Let the 'Back' button go back in the Details page
    
    The 'Back' button checks whether it can go back within the Details
    page and only if there was no previous app there, it goes back through
    its own back stack.

 src/gs-shell.c | 4 ++++
 1 file changed, 4 insertions(+)
---
diff --git a/src/gs-shell.c b/src/gs-shell.c
index db449a9b0..e49f276eb 100644
--- a/src/gs-shell.c
+++ b/src/gs-shell.c
@@ -789,6 +789,10 @@ gs_shell_go_back (GsShell *shell)
 {
        BackEntry *entry;
 
+       if (gs_shell_get_mode (shell) == GS_SHELL_MODE_DETAILS &&
+           gs_details_page_go_back (GS_DETAILS_PAGE (GS_DETAILS_PAGE (shell->pages[GS_SHELL_MODE_DETAILS]))))
+               return;
+
        /* nothing to do */
        if (g_queue_is_empty (shell->back_entry_stack)) {
                g_debug ("no back stack, showing overview");


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