aboutsummaryrefslogtreecommitdiffstats
path: root/embed/mozilla/mozilla-embed-single.cpp
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2005-01-30 23:20:36 +0800
committerChristian Persch <chpe@src.gnome.org>2005-01-30 23:20:36 +0800
commit8f01817138c1852b319898a5de3f4b9f244cdea5 (patch)
tree3473088e9fc4b6200a85e6714183e6f8482b2963 /embed/mozilla/mozilla-embed-single.cpp
parent58dba74abaf6313221c50629e546dc4492672486 (diff)
downloadgsoc2013-epiphany-8f01817138c1852b319898a5de3f4b9f244cdea5.tar
gsoc2013-epiphany-8f01817138c1852b319898a5de3f4b9f244cdea5.tar.gz
gsoc2013-epiphany-8f01817138c1852b319898a5de3f4b9f244cdea5.tar.bz2
gsoc2013-epiphany-8f01817138c1852b319898a5de3f4b9f244cdea5.tar.lz
gsoc2013-epiphany-8f01817138c1852b319898a5de3f4b9f244cdea5.tar.xz
gsoc2013-epiphany-8f01817138c1852b319898a5de3f4b9f244cdea5.tar.zst
gsoc2013-epiphany-8f01817138c1852b319898a5de3f4b9f244cdea5.zip
Move new-window signal to the embed single, and new window creation from
2005-01-30 Christian Persch <chpe@cvs.gnome.org> * doc/reference/tmpl/ephy-embed.sgml: * embed/ephy-embed-single.c: (ephy_embed_single_iface_init): * embed/ephy-embed-single.h: * embed/ephy-embed.c: (ephy_embed_base_init): * embed/ephy-embed.h: * embed/mozilla/mozilla-embed-single.cpp: * embed/mozilla/mozilla-embed.cpp: * embed/mozilla/mozilla-embed.h: * lib/ephy-marshal.list: * lib/ephy-prefs.h: * src/ephy-shell.c: (ephy_shell_new_window_cb), (impl_get_embed_single): * src/ephy-tab.c: (ephy_tab_new_window_cb): Move new-window signal to the embed single, and new window creation from EphyTab to EphyShell.
Diffstat (limited to 'embed/mozilla/mozilla-embed-single.cpp')
-rw-r--r--embed/mozilla/mozilla-embed-single.cpp27
1 files changed, 22 insertions, 5 deletions
diff --git a/embed/mozilla/mozilla-embed-single.cpp b/embed/mozilla/mozilla-embed-single.cpp
index f1ac51326..06e830319 100644
--- a/embed/mozilla/mozilla-embed-single.cpp
+++ b/embed/mozilla/mozilla-embed-single.cpp
@@ -312,14 +312,31 @@ mozilla_setup_colors (MozillaEmbedSingle *mes)
}
static void
-mozilla_embed_single_new_window_orphan_cb (GtkMozEmbedSingle *embed,
- GtkMozEmbed **retval,
+mozilla_embed_single_new_window_orphan_cb (GtkMozEmbedSingle *moz_single,
+ GtkMozEmbed **newEmbed,
guint chrome_mask,
- EphyEmbedSingle *shell)
+ EphyEmbedSingle *single)
{
- g_assert (chrome_mask & GTK_MOZ_EMBED_FLAG_OPENASCHROME);
+ GtkMozEmbedChromeFlags chrome = (GtkMozEmbedChromeFlags) chrome_mask;
+ EphyEmbed *new_embed = NULL;
+ EphyEmbedChrome mask;
- *retval = _mozilla_embed_new_xul_dialog ();
+ if (chrome_mask & GTK_MOZ_EMBED_FLAG_OPENASCHROME)
+ {
+ *newEmbed = _mozilla_embed_new_xul_dialog ();
+ return;
+ }
+
+ mask = _mozilla_embed_translate_chrome (chrome);
+
+ g_signal_emit_by_name (single, "new-window", NULL, mask,
+ &new_embed);
+
+ g_assert (new_embed != NULL);
+
+ gtk_moz_embed_set_chrome_mask (GTK_MOZ_EMBED (new_embed), chrome);
+
+ *newEmbed = GTK_MOZ_EMBED (new_embed);
}
static void