summaryrefslogtreecommitdiff
path: root/src/nautilus-window-menus.c
diff options
context:
space:
mode:
authorJohn Sullivan <sullivan@src.gnome.org>2000-10-06 23:30:11 +0000
committerJohn Sullivan <sullivan@src.gnome.org>2000-10-06 23:30:11 +0000
commitd5b404333015793b86af8ef2289ac5c8997629fd (patch)
treeebcbbadb061a8c2a0fcb79d513bd4d5ee4419583 /src/nautilus-window-menus.c
parentb79ac3db4177ebe92a76fbb3d787da8e40ec5339 (diff)
downloadnautilus-d5b404333015793b86af8ef2289ac5c8997629fd.tar.gz
Finished bug 3496 (labels in menu items never change)
Finished bug 3495 (menu item sensitivity never changes) I think I have fixed all outstanding code that was setting the sensitivity and label text of menu items, except for cut/copy/paste (which is commented out) and undo, which has its own bug report. If you run across any others, please write up new bugs. * src/file-manager/fm-directory-view.c: (insert_bonobo_menu_item), (insert_bonobo_menu_subtree): Removed unnecessary (and #ifdeffed-out) calls to bonobo_ui_handler_set_sensitivity. (fm_directory_view_real_merge_menus): Removed unnecessary call to fm_directory_view_update_menus. * src/file-manager/fm-icon-view.c: Updated menu path #defines that I needed to use later. (update_layout_menus): Move set_sensitive calls out of #ifdef, and modernize them. (insert_bonobo_menu_item) removed unnecessary (and #ifdeffed-out) call to bonobo_ui_handler_set_sensitivity (fm_icon_view_merge_menus): Took out code that's been modernized elsewhere; (update_one_menu_item), (fm_icon_view_update_menus): removed #ifdefs, and modernized. * src/file-manager/fm-search-list-view.c: (update_reveal_item): New helper function (real_merge_menus): #ifdefs removed (real_update_menus): Now calls helper function, #ifdefs removed * src/file-manager/nautilus-search-list-view-ui.xml: Couldn't resist improving a menu title * src/nautilus-window-manage-views.c: (load_content_view): modernize code setting initial zoom menu items sensitivity. * src/nautilus-window-menus.c: (append_bookmark_to_menu), (create_menu_item_from_node), (nautilus_window_initialize_bookmarks_menu): Added more parameter checking because I saw an unreproducible parameter-failure crash a few levels deep.
Diffstat (limited to 'src/nautilus-window-menus.c')
-rw-r--r--src/nautilus-window-menus.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/nautilus-window-menus.c b/src/nautilus-window-menus.c
index c26a8bb99..55667aaad 100644
--- a/src/nautilus-window-menus.c
+++ b/src/nautilus-window-menus.c
@@ -865,6 +865,9 @@ append_bookmark_to_menu (NautilusWindow *window,
#endif
char *raw_name, *display_name, *truncated_name;
+ g_assert (NAUTILUS_IS_WINDOW (window));
+ g_assert (NAUTILUS_IS_BOOKMARK (bookmark));
+
pixbuf = nautilus_bookmark_get_pixbuf (bookmark, NAUTILUS_ICON_SIZE_FOR_MENUS);
/* Set up pixmap type based on result of function. If we fail, set pixmap type to none */
@@ -966,6 +969,8 @@ create_menu_item_from_node (NautilusWindow *window,
char *index_as_string;
char *item_path;
char *sub_item_path;
+
+ g_assert (NAUTILUS_IS_WINDOW (window));
index_as_string = g_strdup_printf ("item_%d", index);
#ifdef UIH
@@ -1242,6 +1247,8 @@ nautilus_window_disable_keyboard_navigation_for_menus (NautilusWindow *window)
static void
nautilus_window_initialize_bookmarks_menu (NautilusWindow *window)
{
+ g_assert (NAUTILUS_IS_WINDOW (window));
+
/* Construct the initial set of bookmarks. */
refresh_bookmarks_menu (window);