diff options
author | Christian Persch <chpe@src.gnome.org> | 2008-06-13 01:21:16 +0800 |
---|---|---|
committer | Christian Persch <chpe@src.gnome.org> | 2008-06-13 01:21:16 +0800 |
commit | 66b802b53a6be466dd91bbb98ea3cca25440a55d (patch) | |
tree | 2f09504c884e68654e2f992c58e734e840d5dd1e /src/window-commands.c | |
parent | a397eafd27b12b528de6e6a13f16b86deb37f99c (diff) | |
download | gsoc2013-epiphany-66b802b53a6be466dd91bbb98ea3cca25440a55d.tar gsoc2013-epiphany-66b802b53a6be466dd91bbb98ea3cca25440a55d.tar.gz gsoc2013-epiphany-66b802b53a6be466dd91bbb98ea3cca25440a55d.tar.bz2 gsoc2013-epiphany-66b802b53a6be466dd91bbb98ea3cca25440a55d.tar.lz gsoc2013-epiphany-66b802b53a6be466dd91bbb98ea3cca25440a55d.tar.xz gsoc2013-epiphany-66b802b53a6be466dd91bbb98ea3cca25440a55d.tar.zst gsoc2013-epiphany-66b802b53a6be466dd91bbb98ea3cca25440a55d.zip |
Reimplement tabs detaching and tabs DND.
svn path=/trunk/; revision=8278
Diffstat (limited to 'src/window-commands.c')
-rw-r--r-- | src/window-commands.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/window-commands.c b/src/window-commands.c index e2f31f00f..d9e15d913 100644 --- a/src/window-commands.c +++ b/src/window-commands.c @@ -968,6 +968,30 @@ void window_cmd_tabs_move_right (GtkAction *action, } void +window_cmd_tabs_detach (GtkAction *action, + EphyWindow *window) +{ + EphyEmbed *embed; + GtkNotebook *notebook; + EphyWindow *new_window; + + notebook = GTK_NOTEBOOK (ephy_window_get_notebook (window)); + if (gtk_notebook_get_n_pages (notebook) <= 1) + return; + + embed = ephy_embed_container_get_active_child (EPHY_EMBED_CONTAINER (window)); + + g_object_ref_sink (embed); + gtk_notebook_remove_page (notebook, gtk_notebook_page_num (notebook, GTK_WIDGET (embed))); + + new_window = ephy_window_new (); + ephy_embed_container_add_child (EPHY_EMBED_CONTAINER (new_window), embed, 0, FALSE); + g_object_unref (embed); + + gtk_window_present (GTK_WINDOW (new_window)); +} + +void window_cmd_load_location (GtkAction *action, EphyWindow *window) { |