diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/ephy-window.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/src/ephy-window.c b/src/ephy-window.c index cdb4b6281..d9f241fa1 100644 --- a/src/ephy-window.c +++ b/src/ephy-window.c @@ -1389,7 +1389,6 @@ show_embed_popup (EphyWindow *window, EphyTab *tab, EphyEmbedEvent *event) gboolean framed, has_background, can_open_in_new; GtkWidget *widget; EphyEmbedEventType type; - gboolean showing_edit_actions = FALSE; /* Do not show the menu in print preview mode */ if (window->priv->mode == EPHY_WINDOW_MODE_PRINT_PREVIEW) @@ -1414,8 +1413,8 @@ show_embed_popup (EphyWindow *window, EphyTab *tab, EphyEmbedEvent *event) } else if (context & EMBED_CONTEXT_LINK) { - showing_edit_actions = TRUE; popup = "/EphyLinkPopup"; + update_edit_actions_sensitivity (window, TRUE); } else if (context & EMBED_CONTEXT_IMAGE) { @@ -1423,14 +1422,14 @@ show_embed_popup (EphyWindow *window, EphyTab *tab, EphyEmbedEvent *event) } else if (context & EMBED_CONTEXT_INPUT) { - showing_edit_actions = TRUE; popup = "/EphyInputPopup"; + update_edit_actions_sensitivity (window, FALSE); } else { - showing_edit_actions = TRUE; popup = framed ? "/EphyFramedDocumentPopup" : "/EphyDocumentPopup"; + update_edit_actions_sensitivity (window, TRUE); } widget = gtk_ui_manager_get_widget (GTK_UI_MANAGER (window->ui_merge), @@ -1446,11 +1445,6 @@ show_embed_popup (EphyWindow *window, EphyTab *tab, EphyEmbedEvent *event) action = gtk_action_group_get_action (action_group, "OpenLinkInNewTab"); g_object_set (action, "sensitive", can_open_in_new, FALSE); - if (showing_edit_actions) - { - update_edit_actions_sensitivity (window, TRUE); - } - g_object_set_data_full (G_OBJECT (window), "context_event", g_object_ref (event), (GDestroyNotify)g_object_unref); |