[nautilus/wip/gbsneto/actionbar: 518/522] files-view: add ::stop-loading action



commit 213ce36a698e09b82c9c904ed82325dae1f510a6
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date:   Mon Mar 28 18:23:30 2016 -0300

    files-view: add ::stop-loading action
    
    This action will be consumed by the actionbar, to simplify
    the development of the stop button.

 src/nautilus-files-view.c |   12 +++++++++++-
 1 files changed, 11 insertions(+), 1 deletions(-)
---
diff --git a/src/nautilus-files-view.c b/src/nautilus-files-view.c
index 1d0c12d..2a4dbba 100644
--- a/src/nautilus-files-view.c
+++ b/src/nautilus-files-view.c
@@ -6645,6 +6645,14 @@ action_detect_media (GSimpleAction *action,
     nautilus_file_list_free (selection);
 }
 
+static void
+action_stop_loading (GSimpleAction *action,
+                     GVariant      *state,
+                     gpointer       user_data)
+{
+    nautilus_files_view_stop_loading (user_data);
+}
+
 const GActionEntry view_entries[] =
 {
     /* Toolbar menu */
@@ -6706,7 +6714,9 @@ const GActionEntry view_entries[] =
     { "invert-selection", action_invert_selection },
     { "open-file-and-close-window", action_open_file_and_close_window },
     /* Warning dialog for the change of the shorcut to move to trash */
-    { "show-move-to-trash-shortcut-changed-dialog", action_show_move_to_trash_shortcut_changed_dialog }
+    { "show-move-to-trash-shortcut-changed-dialog", action_show_move_to_trash_shortcut_changed_dialog },
+    /* Helper */
+    { "stop-loading", action_stop_loading }
 };
 
 static gboolean


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