summaryrefslogtreecommitdiffstats
path: root/src/notebook.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/notebook.c')
-rw-r--r--src/notebook.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/notebook.c b/src/notebook.c
index 61502e7..675e6bb 100644
--- a/src/notebook.c
+++ b/src/notebook.c
@@ -24,11 +24,23 @@
#include <glib.h>
#include <gtk/gtk.h>
+#include "tab-label.h"
+#include "tab-page.h"
+#include "tree.h"
#include "window.h"
+#define MQ_TAB_TREE(obj) (MqTabTree *) (obj)
+
+typedef struct {
+ MqTree parent_instance;
+ MqTabLabel *label;
+ MqTabPage *page;
+} MqTabTree;
+
struct _MqNotebook {
GtkNotebook parent_instance;
MqWindow *window;
+ MqTabTree *tree;
};
enum {
@@ -104,6 +116,9 @@ mq_notebook_class_init(MqNotebookClass *klass)
static void
mq_notebook_init(MqNotebook *notebook)
{
+ notebook->tree = MQ_TAB_TREE(mq_tree_insert_root_allocated(
+ MQ_TREE(g_new0(MqTabTree, 1)), NULL));
+
gtk_notebook_set_show_border(GTK_NOTEBOOK(notebook), FALSE);
gtk_notebook_set_scrollable(GTK_NOTEBOOK(notebook), TRUE);
gtk_notebook_set_group_name(GTK_NOTEBOOK(notebook), "mq-tabs");