Commit 90284629 authored by Victor Ananjevsky's avatar Victor Ananjevsky

fix setting active tab in notebook dialog

parent 8957347f
...@@ -70,11 +70,6 @@ notebook_create_widget (GtkWidget * dlg) ...@@ -70,11 +70,6 @@ notebook_create_widget (GtkWidget * dlg)
gtk_container_child_set( GTK_CONTAINER (w), a, "tab-expand", options.notebook_data.expand, NULL); gtk_container_child_set( GTK_CONTAINER (w), a, "tab-expand", options.notebook_data.expand, NULL);
} }
/* set active tab */
if (options.notebook_data.active <= 0)
options.notebook_data.active = 1;
gtk_notebook_set_current_page (GTK_NOTEBOOK (w), options.notebook_data.active - 1);
return w; return w;
} }
...@@ -98,6 +93,10 @@ notebook_swallow_childs (void) ...@@ -98,6 +93,10 @@ notebook_swallow_childs (void)
if (tabs[i].pid != -1) if (tabs[i].pid != -1)
gtk_socket_add_id (GTK_SOCKET (s), tabs[i].xid); gtk_socket_add_id (GTK_SOCKET (s), tabs[i].xid);
} }
/* set active tab */
if (options.notebook_data.active > 0)
gtk_notebook_set_current_page (GTK_NOTEBOOK (notebook), options.notebook_data.active - 1);
} }
void void
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment