aboutsummaryrefslogtreecommitdiffstats
path: root/src/ephy-window.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ephy-window.c')
-rw-r--r--src/ephy-window.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/ephy-window.c b/src/ephy-window.c
index c0ec381fc..3c08bf238 100644
--- a/src/ephy-window.c
+++ b/src/ephy-window.c
@@ -2007,6 +2007,7 @@ tab_added_cb (EphyNotebook *notebook,
EphyTab *tab,
EphyWindow *window)
{
+ EphyExtension *manager;
EphyEmbed *embed;
g_return_if_fail (EPHY_IS_TAB (tab));
@@ -2023,6 +2024,10 @@ tab_added_cb (EphyNotebook *notebook,
g_signal_connect_after (embed, "ge-modal-alert",
G_CALLBACK (modal_alert_cb), window);
+
+ /* Let the extensions attach themselves to the tab */
+ manager = EPHY_EXTENSION (ephy_shell_get_extensions_manager (ephy_shell));
+ ephy_extension_attach_tab (manager, window, tab);
}
static void
@@ -2030,10 +2035,15 @@ tab_removed_cb (EphyNotebook *notebook,
EphyTab *tab,
EphyWindow *window)
{
+ EphyExtension *manager;
EphyEmbed *embed;
g_return_if_fail (EPHY_IS_TAB (tab));
+ /* Let the extensions remove themselves from the tab */
+ manager = EPHY_EXTENSION (ephy_shell_get_extensions_manager (ephy_shell));
+ ephy_extension_detach_tab (manager, window, tab);
+
g_signal_handlers_disconnect_by_func (G_OBJECT (tab),
G_CALLBACK (sync_tab_visibility),
window);