summaryrefslogtreecommitdiff
path: root/src/nautilus-view.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nautilus-view.c')
-rw-r--r--src/nautilus-view.c27
1 files changed, 9 insertions, 18 deletions
diff --git a/src/nautilus-view.c b/src/nautilus-view.c
index d1f1778c6..02a9c383e 100644
--- a/src/nautilus-view.c
+++ b/src/nautilus-view.c
@@ -6342,12 +6342,19 @@ nautilus_view_update_context_menus (NautilusView *view)
NAUTILUS_VIEW_CLASS (G_OBJECT_GET_CLASS (view))->update_context_menus (view);
}
-static void
-real_update_toolbar_menus (NautilusView *view)
+/* Convenience function to reset the menus owned by the but that are managed on
+ * the toolbar and update them with the current state.
+ * It will also update the actions state, which will also update children
+ * actions state if the children subclass nautilus_view_update_actions_state
+ */
+void
+nautilus_view_update_toolbar_menus (NautilusView *view)
{
NautilusToolbar *toolbar;
NautilusWindow *window;
+ g_assert (NAUTILUS_IS_VIEW (view));
+
window = nautilus_view_get_window (view);
toolbar = NAUTILUS_TOOLBAR (nautilus_window_get_toolbar (window));
nautilus_toolbar_reset_menus (toolbar);
@@ -6356,21 +6363,6 @@ real_update_toolbar_menus (NautilusView *view)
nautilus_view_update_actions_state (view);
}
-/* Convenience function to reset the menus owned by the but that are managed on
- * the toolbar and update them with the current state.
- * Children can subclass it and add items on the menu after chaining up to the
- * parent, so menus are already reseted.
- * It will also update the actions state, which will also update children
- * actions state if the children subclass nautilus_view_update_actions_state
- */
-void
-nautilus_view_update_toolbar_menus (NautilusView *view)
-{
- g_assert(NAUTILUS_IS_VIEW (view));
-
- NAUTILUS_VIEW_CLASS (G_OBJECT_GET_CLASS (view))->update_toolbar_menus (view);
-}
-
/**
* nautilus_view_pop_up_selection_context_menu
*
@@ -7378,7 +7370,6 @@ nautilus_view_class_init (NautilusViewClass *klass)
klass->get_window = nautilus_view_get_window;
klass->update_context_menus = real_update_context_menus;
klass->update_actions_state = real_update_actions_state;
- klass->update_toolbar_menus = real_update_toolbar_menus;
copied_files_atom = gdk_atom_intern ("x-special/gnome-copied-files", FALSE);