summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/notebook.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/notebook.c b/src/notebook.c
index f7f06a0..b0854ee 100644
--- a/src/notebook.c
+++ b/src/notebook.c
@@ -172,14 +172,13 @@ tab_tree_row_activated_cb(GtkTreeView G_GNUC_UNUSED *tree_view,
GtkTreeModel *tree_model;
GtkTreeIter tree_iter;
gint position;
- gchar *title;
tree_model = gtk_tree_view_get_model(tree_view);
if (gtk_tree_model_get_iter(tree_model, &tree_iter, tree_path)) {
- gtk_tree_model_get(tree_model, &tree_iter,
- 0, &position, 1, &title, -1);
- g_print ("Row %d, \"%s\" activated\n", position, title);
- g_free(title);
+ gtk_tree_model_get(tree_model, &tree_iter, 0, &position, -1);
+ mq_notebook_set_current_page(notebook, position - 1);
+ } else {
+ g_assert_not_reached();
}
gtk_widget_hide(notebook->tab_tree_popover);