diff options
author | Christian Persch <chpe@cvs.gnome.org> | 2004-08-09 01:48:30 +0800 |
---|---|---|
committer | Christian Persch <chpe@src.gnome.org> | 2004-08-09 01:48:30 +0800 |
commit | 859bd4706dba82e469d699aebd3f6336c0482c7a (patch) | |
tree | 748284de8cfa092c2c713e0d923be925ced3f167 /embed/mozilla/mozilla-embed.cpp | |
parent | 8f30d82289466a8983b48d1a269f2f6779711772 (diff) | |
download | gsoc2013-epiphany-859bd4706dba82e469d699aebd3f6336c0482c7a.tar gsoc2013-epiphany-859bd4706dba82e469d699aebd3f6336c0482c7a.tar.gz gsoc2013-epiphany-859bd4706dba82e469d699aebd3f6336c0482c7a.tar.bz2 gsoc2013-epiphany-859bd4706dba82e469d699aebd3f6336c0482c7a.tar.lz gsoc2013-epiphany-859bd4706dba82e469d699aebd3f6336c0482c7a.tar.xz gsoc2013-epiphany-859bd4706dba82e469d699aebd3f6336c0482c7a.tar.zst gsoc2013-epiphany-859bd4706dba82e469d699aebd3f6336c0482c7a.zip |
Allow XUL windows to open new windows.
2004-08-08 Christian Persch <chpe@cvs.gnome.org>
* embed/mozilla/mozilla-embed.cpp:
Allow XUL windows to open new windows.
Diffstat (limited to 'embed/mozilla/mozilla-embed.cpp')
-rw-r--r-- | embed/mozilla/mozilla-embed.cpp | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/embed/mozilla/mozilla-embed.cpp b/embed/mozilla/mozilla-embed.cpp index a07f54831..7d77f1e6c 100644 --- a/embed/mozilla/mozilla-embed.cpp +++ b/embed/mozilla/mozilla-embed.cpp @@ -1158,7 +1158,7 @@ ephy_embed_iface_init (EphyEmbedIface *iface) iface->has_modified_forms = impl_has_modified_forms; } -void +static void xul_visibility_cb (GtkWidget *embed, gboolean visibility, GtkWidget *window) { if (visibility) @@ -1171,12 +1171,23 @@ xul_visibility_cb (GtkWidget *embed, gboolean visibility, GtkWidget *window) } } -void +static void xul_size_to_cb (GtkWidget *embed, gint width, gint height, gpointer dummy) { gtk_widget_set_size_request (embed, width, height); } +static void +xul_new_window_cb (GtkMozEmbed *embed, + GtkMozEmbed **retval, + guint chrome_mask, + gpointer dummy) +{ + g_assert (chrome_mask & GTK_MOZ_EMBED_FLAG_OPENASCHROME); + + *retval = _mozilla_embed_new_xul_dialog (); +} + GtkMozEmbed * _mozilla_embed_new_xul_dialog (void) { @@ -1196,6 +1207,9 @@ _mozilla_embed_new_xul_dialog (void) g_signal_connect_object (embed, "size_to", G_CALLBACK (xul_size_to_cb), NULL, (GConnectFlags) 0); + g_signal_connect_object (embed, "new_window", + G_CALLBACK (xul_new_window_cb), + NULL, (GConnectFlags) 0); return GTK_MOZ_EMBED (embed); } |