[Xfce4-commits] [apps/xfce4-terminal] 01/01: Tab became active if unclosed to the left of the current tab
noreply at xfce.org
noreply at xfce.org
Wed May 2 21:13:50 CEST 2018
This is an automated email from the git hooks/post-receive script.
f 2 4 0 4 p u s h e d a c o m m i t t o b r a n c h m a s t e r
in repository apps/xfce4-terminal.
commit d8540c4c8b31ae68b687b35f882943821dd3e4ae
Author: Igor <f2404 at yandex.ru>
Date: Wed May 2 12:15:04 2018 -0400
Tab became active if unclosed to the left of the current tab
---
terminal/terminal-window.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/terminal/terminal-window.c b/terminal/terminal-window.c
index f57ad0d..9ed0a81 100644
--- a/terminal/terminal-window.c
+++ b/terminal/terminal-window.c
@@ -1655,7 +1655,7 @@ terminal_window_action_undo_close_tab (GtkAction *action,
{
TerminalScreen *terminal;
TerminalWindowTabInfo *tab_info;
- gint current = gtk_notebook_get_current_page (GTK_NOTEBOOK (window->priv->notebook));
+ GtkWidget *current = GTK_WIDGET (window->priv->active);
terminal = TERMINAL_SCREEN (g_object_new (TERMINAL_TYPE_SCREEN, NULL));
terminal_window_add (window, terminal);
@@ -1673,7 +1673,10 @@ terminal_window_action_undo_close_tab (GtkAction *action,
/* restore tab focus if the unclosed one wasn't active when it was closed */
if (!tab_info->was_active)
- gtk_notebook_set_current_page (GTK_NOTEBOOK (window->priv->notebook), current);
+ {
+ gint page_num = gtk_notebook_page_num (GTK_NOTEBOOK (window->priv->notebook), current);
+ gtk_notebook_set_current_page (GTK_NOTEBOOK (window->priv->notebook), page_num);
+ }
/* free info */
terminal_window_tab_info_free (tab_info);
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Xfce4-commits
mailing list