aboutsummaryrefslogtreecommitdiffstats
path: root/src/ephy-window.c
diff options
context:
space:
mode:
authorAdam Hooper <adamh@src.gnome.org>2004-12-18 02:03:35 +0800
committerAdam Hooper <adamh@src.gnome.org>2004-12-18 02:03:35 +0800
commit9bf71295e9a4e5cdfe9dc4380343616c49b161c6 (patch)
tree6b3aa6ef7d872a5cdc84da940b240e723b93c800 /src/ephy-window.c
parentc5b4d13e2e64dd3e28de75b17f6a436f339d5dc2 (diff)
downloadgsoc2013-epiphany-9bf71295e9a4e5cdfe9dc4380343616c49b161c6.tar
gsoc2013-epiphany-9bf71295e9a4e5cdfe9dc4380343616c49b161c6.tar.gz
gsoc2013-epiphany-9bf71295e9a4e5cdfe9dc4380343616c49b161c6.tar.bz2
gsoc2013-epiphany-9bf71295e9a4e5cdfe9dc4380343616c49b161c6.tar.lz
gsoc2013-epiphany-9bf71295e9a4e5cdfe9dc4380343616c49b161c6.tar.xz
gsoc2013-epiphany-9bf71295e9a4e5cdfe9dc4380343616c49b161c6.tar.zst
gsoc2013-epiphany-9bf71295e9a4e5cdfe9dc4380343616c49b161c6.zip
Add attach_tab and detach_tab functions to extension interface (bug
#153732). Thanks to Crispin for almost all of the code.
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);