diff options
author | Marco Pesenti Gritti <marco@it.gnome.org> | 2003-04-28 01:09:58 +0800 |
---|---|---|
committer | Marco Pesenti Gritti <mpeseng@src.gnome.org> | 2003-04-28 01:09:58 +0800 |
commit | 4d94003629211bb7cb57189742b718201d2c27bd (patch) | |
tree | 693ae06447b471e76bf9baccaa91d7e7e7981fa8 /src/bookmarks/ephy-bookmarks-editor.c | |
parent | fbe3cc4fcb4bdfd7bd28443a0852a4b79ff920c6 (diff) | |
download | gsoc2013-epiphany-4d94003629211bb7cb57189742b718201d2c27bd.tar gsoc2013-epiphany-4d94003629211bb7cb57189742b718201d2c27bd.tar.gz gsoc2013-epiphany-4d94003629211bb7cb57189742b718201d2c27bd.tar.bz2 gsoc2013-epiphany-4d94003629211bb7cb57189742b718201d2c27bd.tar.lz gsoc2013-epiphany-4d94003629211bb7cb57189742b718201d2c27bd.tar.xz gsoc2013-epiphany-4d94003629211bb7cb57189742b718201d2c27bd.tar.zst gsoc2013-epiphany-4d94003629211bb7cb57189742b718201d2c27bd.zip |
Update sensitivity on selection changes. Thanks xan to find this one.
2003-04-27 Marco Pesenti Gritti <marco@it.gnome.org>
* src/bookmarks/ephy-bookmarks-editor.c:
(ephy_bookmarks_editor_update_menu), (view_selection_changed_cb),
(ephy_bookmarks_editor_construct):
Update sensitivity on selection changes. Thanks xan to find
this one.
* src/toolbar.c: (remove_action), (topic_remove_cb),
(bookmark_remove_cb):
Get back bookmarks/toolbar sync on bookmark removal.
Diffstat (limited to 'src/bookmarks/ephy-bookmarks-editor.c')
-rw-r--r-- | src/bookmarks/ephy-bookmarks-editor.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/bookmarks/ephy-bookmarks-editor.c b/src/bookmarks/ephy-bookmarks-editor.c index ffaa078c5..4fb95efc2 100644 --- a/src/bookmarks/ephy-bookmarks-editor.c +++ b/src/bookmarks/ephy-bookmarks-editor.c @@ -597,6 +597,8 @@ ephy_bookmarks_editor_update_menu (EphyBookmarksEditor *editor) GList *selected; GtkWidget *focus_widget; + LOG ("Update menu sensitivity") + bmk_focus = ephy_node_view_is_target (EPHY_NODE_VIEW (editor->priv->bm_view)); key_focus = ephy_node_view_is_target @@ -1037,6 +1039,12 @@ provide_favicon (EphyNode *node, GValue *value, gpointer user_data) } static void +view_selection_changed_cb (GtkWidget *view, EphyBookmarksEditor *editor) +{ + ephy_bookmarks_editor_update_menu (editor); +} + +static void ephy_bookmarks_editor_construct (EphyBookmarksEditor *editor) { GtkTreeSelection *selection; @@ -1125,6 +1133,10 @@ ephy_bookmarks_editor_construct (EphyBookmarksEditor *editor) n_topic_drag_dest_types); selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (key_view)); gtk_tree_selection_set_mode (selection, GTK_SELECTION_BROWSE); + g_signal_connect (G_OBJECT (selection), + "changed", + G_CALLBACK (view_selection_changed_cb), + editor); ephy_node_view_add_column (EPHY_NODE_VIEW (key_view), _("Topics"), G_TYPE_STRING, EPHY_NODE_KEYWORD_PROP_NAME, @@ -1203,6 +1215,11 @@ ephy_bookmarks_editor_construct (EphyBookmarksEditor *editor) "show_popup", G_CALLBACK (ephy_bookmarks_editor_show_popup_cb), editor); + selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (bm_view)); + g_signal_connect (G_OBJECT (selection), + "changed", + G_CALLBACK (view_selection_changed_cb), + editor); selected_id_str = eel_gconf_get_string (CONF_BOOKMARKS_SELECTED_NODE); selected_id = g_ascii_strtoull (selected_id_str, NULL, 10); |