/* midori-notebook.c generated by valac 0.38.8, the Vala compiler
 * generated from midori-notebook.vala, do not modify */

/*
 Copyright (C) 2013 Christian Dywan <christian@twotoasts.de>

 This library is free software; you can redistribute it and/or
 modify it under the terms of the GNU Lesser General Public
 License as published by the Free Software Foundation; either
 version 2.1 of the License, or (at your option) any later version.

 See the file COPYING for the full license text.
*/

#include <glib.h>
#include <glib-object.h>
#include <gtk/gtk.h>
#include <gio/gio.h>
#include <float.h>
#include <math.h>
#include <stdlib.h>
#include <string.h>
#include <pango/pango.h>
#include <gdk/gdk.h>
#include <glib/gi18n-lib.h>
#include "webkit/webkit.h"


#define MIDORI_TYPE_TALLY (midori_tally_get_type ())
#define MIDORI_TALLY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), MIDORI_TYPE_TALLY, MidoriTally))
#define MIDORI_TALLY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), MIDORI_TYPE_TALLY, MidoriTallyClass))
#define MIDORI_IS_TALLY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), MIDORI_TYPE_TALLY))
#define MIDORI_IS_TALLY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), MIDORI_TYPE_TALLY))
#define MIDORI_TALLY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), MIDORI_TYPE_TALLY, MidoriTallyClass))

typedef struct _MidoriTally MidoriTally;
typedef struct _MidoriTallyClass MidoriTallyClass;
typedef struct _MidoriTallyPrivate MidoriTallyPrivate;

#define MIDORI_TYPE_TAB (midori_tab_get_type ())
#define MIDORI_TAB(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), MIDORI_TYPE_TAB, MidoriTab))
#define MIDORI_TAB_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), MIDORI_TYPE_TAB, MidoriTabClass))
#define MIDORI_IS_TAB(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), MIDORI_TYPE_TAB))
#define MIDORI_IS_TAB_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), MIDORI_TYPE_TAB))
#define MIDORI_TAB_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), MIDORI_TYPE_TAB, MidoriTabClass))

typedef struct _MidoriTab MidoriTab;
typedef struct _MidoriTabClass MidoriTabClass;
enum  {
	MIDORI_TALLY_0_PROPERTY,
	MIDORI_TALLY_TAB_PROPERTY,
	MIDORI_TALLY_CLOSE_BUTTON_LEFT_PROPERTY,
	MIDORI_TALLY_CLOSE_BUTTON_VISIBLE_PROPERTY,
	MIDORI_TALLY_NUM_PROPERTIES
};
static GParamSpec* midori_tally_properties[MIDORI_TALLY_NUM_PROPERTIES];
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _g_free0(var) (var = (g_free (var), NULL))

#define MIDORI_TYPE_NOTEBOOK (midori_notebook_get_type ())
#define MIDORI_NOTEBOOK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), MIDORI_TYPE_NOTEBOOK, MidoriNotebook))
#define MIDORI_NOTEBOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), MIDORI_TYPE_NOTEBOOK, MidoriNotebookClass))
#define MIDORI_IS_NOTEBOOK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), MIDORI_TYPE_NOTEBOOK))
#define MIDORI_IS_NOTEBOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), MIDORI_TYPE_NOTEBOOK))
#define MIDORI_NOTEBOOK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), MIDORI_TYPE_NOTEBOOK, MidoriNotebookClass))

typedef struct _MidoriNotebook MidoriNotebook;
typedef struct _MidoriNotebookClass MidoriNotebookClass;
typedef struct _MidoriNotebookPrivate MidoriNotebookPrivate;
enum  {
	MIDORI_NOTEBOOK_0_PROPERTY,
	MIDORI_NOTEBOOK_COUNT_PROPERTY,
	MIDORI_NOTEBOOK_INDEX_PROPERTY,
	MIDORI_NOTEBOOK_TAB_PROPERTY,
	MIDORI_NOTEBOOK_CLOSE_BUTTONS_LEFT_PROPERTY,
	MIDORI_NOTEBOOK_CLOSE_BUTTONS_VISIBLE_PROPERTY,
	MIDORI_NOTEBOOK_LABELS_VISIBLE_PROPERTY,
	MIDORI_NOTEBOOK_NUM_PROPERTIES
};
static GParamSpec* midori_notebook_properties[MIDORI_NOTEBOOK_NUM_PROPERTIES];

#define MIDORI_TYPE_CONTEXT_ACTION (midori_context_action_get_type ())
#define MIDORI_CONTEXT_ACTION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), MIDORI_TYPE_CONTEXT_ACTION, MidoriContextAction))
#define MIDORI_CONTEXT_ACTION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), MIDORI_TYPE_CONTEXT_ACTION, MidoriContextActionClass))
#define MIDORI_IS_CONTEXT_ACTION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), MIDORI_TYPE_CONTEXT_ACTION))
#define MIDORI_IS_CONTEXT_ACTION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), MIDORI_TYPE_CONTEXT_ACTION))
#define MIDORI_CONTEXT_ACTION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), MIDORI_TYPE_CONTEXT_ACTION, MidoriContextActionClass))

typedef struct _MidoriContextAction MidoriContextAction;
typedef struct _MidoriContextActionClass MidoriContextActionClass;
typedef struct _Block5Data Block5Data;
#define _g_list_free0(var) ((var == NULL) ? NULL : (var = (g_list_free (var), NULL)))
typedef struct _Block6Data Block6Data;
enum  {
	MIDORI_NOTEBOOK_TAB_CONTEXT_MENU_SIGNAL,
	MIDORI_NOTEBOOK_CONTEXT_MENU_SIGNAL,
	MIDORI_NOTEBOOK_TAB_SWITCHED_SIGNAL,
	MIDORI_NOTEBOOK_TAB_MOVED_SIGNAL,
	MIDORI_NOTEBOOK_TAB_DETACHED_SIGNAL,
	MIDORI_NOTEBOOK_NEW_TAB_SIGNAL,
	MIDORI_NOTEBOOK_NUM_SIGNALS
};
static guint midori_notebook_signals[MIDORI_NOTEBOOK_NUM_SIGNALS] = {0};

struct _MidoriTally {
	GtkEventBox parent_instance;
	MidoriTallyPrivate * priv;
	GtkLabel* label;
	GtkImage* icon;
};

struct _MidoriTallyClass {
	GtkEventBoxClass parent_class;
};

struct _MidoriTallyPrivate {
	MidoriTab* _tab;
	GtkSpinner* spinner;
	GtkHBox* box;
	GtkAlignment* align;
	GtkButton* close;
	gboolean _close_button_left;
	gboolean _close_button_visible;
};

struct _MidoriNotebook {
	GtkEventBox parent_instance;
	MidoriNotebookPrivate * priv;
	GtkNotebook* notebook;
};

struct _MidoriNotebookClass {
	GtkEventBoxClass parent_class;
};

struct _MidoriNotebookPrivate {
	gint last_tab_size;
	guint _count;
	gint _index;
	MidoriTab* _tab;
	MidoriTab* _previous;
	gboolean _close_buttons_left;
	gboolean _close_buttons_visible;
	gboolean _labels_visible;
};

struct _Block5Data {
	int _ref_count_;
	MidoriNotebook* self;
	MidoriTab* tab;
};

struct _Block6Data {
	int _ref_count_;
	MidoriNotebook* self;
	MidoriTab* tab;
};


static gpointer midori_tally_parent_class = NULL;
static gpointer midori_notebook_parent_class = NULL;

GType midori_tally_get_type (void) G_GNUC_CONST;
GType midori_tab_get_type (void) G_GNUC_CONST;
#define MIDORI_TALLY_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), MIDORI_TYPE_TALLY, MidoriTallyPrivate))
MidoriTally* midori_tally_new (MidoriTab* tab);
MidoriTally* midori_tally_construct (GType object_type, MidoriTab* tab);
void midori_tally_set_tab (MidoriTally* self, MidoriTab* value);
static void midori_tally_close_style_set (MidoriTally* self, GtkStyle* previous_style);
static void _midori_tally_close_style_set_gtk_widget_style_set (GtkWidget* _sender, GtkStyle* previous_style, gpointer self);
static void midori_tally_close_clicked (MidoriTally* self);
static void _midori_tally_close_clicked_gtk_button_clicked (GtkButton* _sender, gpointer self);
static void midori_tally_uri_changed (MidoriTally* self, GParamSpec* pspec);
static void _midori_tally_uri_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void midori_tally_title_changed (MidoriTally* self, GParamSpec* pspec);
static void _midori_tally_title_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void midori_tally_icon_changed (MidoriTally* self, GParamSpec* pspec);
static void _midori_tally_icon_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void midori_tally_minimized_changed (MidoriTally* self, GParamSpec* pspec);
static void _midori_tally_minimized_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void midori_tally_progress_changed (MidoriTally* self, GParamSpec* pspec);
static void _midori_tally_progress_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void midori_tally_colors_changed (MidoriTally* self);
static void _midori_tally_colors_changed_midori_tab_colors_changed (MidoriTab* _sender, gpointer self);
static void midori_tally_update_label (MidoriTally* self);
gboolean midori_tab_get_minimized (MidoriTab* self);
gdouble midori_tab_get_progress (MidoriTab* self);
static void midori_tally_update_color (MidoriTally* self);
static void midori_tally_close_button_left_changed (MidoriTally* self, GParamSpec* pspec);
static void _midori_tally_close_button_left_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void midori_tally_close_button_visible_changed (MidoriTally* self, GParamSpec* pspec);
static void _midori_tally_close_button_visible_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
MidoriTab* midori_tally_get_tab (MidoriTally* self);
const gchar* midori_tab_get_uri (MidoriTab* self);
gchar* midori_tab_get_display_title (const gchar* title, const gchar* uri);
PangoEllipsizeMode midori_tab_get_display_ellipsize (const gchar* title, const gchar* uri);
GdkColor* midori_tab_get_fg_color (MidoriTab* self);
GdkColor* midori_tab_get_bg_color (MidoriTab* self);
gboolean midori_tally_get_close_button_left (MidoriTally* self);
gboolean midori_tally_get_close_button_visible (MidoriTally* self);
void midori_tally_set_close_button_left (MidoriTally* self, gboolean value);
void midori_tally_set_close_button_visible (MidoriTally* self, gboolean value);
static void midori_tally_finalize (GObject * obj);
static void _vala_midori_tally_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec);
static void _vala_midori_tally_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec);
GType midori_notebook_get_type (void) G_GNUC_CONST;
#define MIDORI_NOTEBOOK_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), MIDORI_TYPE_NOTEBOOK, MidoriNotebookPrivate))
static void midori_notebook_size_allocated (MidoriNotebook* self, GdkRectangle* allocation);
static void _midori_notebook_size_allocated_gtk_widget_size_allocate (GtkWidget* _sender, GdkRectangle* allocation, gpointer self);
static void midori_notebook_page_switched (MidoriNotebook* self, GtkNotebookPage* new_tab, guint new_index);
static void _midori_notebook_page_switched_gtk_notebook_switch_page (GtkNotebook* _sender, GtkNotebookPage* page, guint page_num, gpointer self);
static void midori_notebook_page_moved (MidoriNotebook* self, GtkWidget* moving_tab, guint new_index);
static void _midori_notebook_page_moved_gtk_notebook_page_reordered (GtkNotebook* _sender, GtkWidget* p0, guint p1, gpointer self);
static GtkNotebook* midori_notebook_window_created (MidoriNotebook* self, GtkWidget* tab, gint x, gint y);
static GtkNotebook* _midori_notebook_window_created_gtk_notebook_create_window (GtkNotebook* _sender, GtkWidget* page, gint x, gint y, gpointer self);
#define MIDORI_NOTEBOOK_style_fixup "\n" \
"            style \"midori-close-button-style\"\n" \
"            {\n" \
"            GtkWidget::focus-padding = 0\n" \
"            GtkWidget::focus-line-width = 0\n" \
"            xthickness = 0\n" \
"            ythickness = 0\n" \
"            }\n" \
"            widget \"*.midori-close-button\" style \"midori-close-butt" \
"on-style\"\n" \
"            "
GtkWidget* midori_notebook_new (void);
GtkWidget* midori_notebook_construct (GType object_type);
static void midori_notebook_index_changed (MidoriNotebook* self, GParamSpec* pspec);
static void _midori_notebook_index_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void midori_notebook_tab_changed (MidoriNotebook* self, GParamSpec* pspec);
static void _midori_notebook_tab_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void midori_notebook_labels_visible_changed (MidoriNotebook* self, GParamSpec* pspec);
static void _midori_notebook_labels_visible_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void midori_notebook_close_buttons_visible_changed (MidoriNotebook* self, GParamSpec* pspec);
static void _midori_notebook_close_buttons_visible_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void midori_notebook_close_buttons_left_changed (MidoriNotebook* self, GParamSpec* pspec);
static void _midori_notebook_close_buttons_left_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void __lambda14_ (MidoriNotebook* self);
static void ___lambda14__gtk_button_clicked (GtkButton* _sender, gpointer self);
static void midori_notebook_take_incoming_uris (MidoriNotebook* self, GtkWidget* widget);
static gboolean midori_notebook_button_pressed (MidoriNotebook* self, GdkEventButton* event);
static gboolean _midori_notebook_button_pressed_gtk_widget_button_press_event (GtkWidget* _sender, GdkEventButton* event, gpointer self);
static gboolean midori_notebook_uri_dropped (MidoriNotebook* self, GtkWidget* widget, GdkDragContext* context, gint x, gint y, guint timestamp);
static gboolean _midori_notebook_uri_dropped_gtk_widget_drag_drop (GtkWidget* _sender, GdkDragContext* context, gint x, gint y, guint time_, gpointer self);
static void midori_notebook_uri_received (MidoriNotebook* self, GtkWidget* widget, GdkDragContext* context, gint x, gint y, GtkSelectionData* data, guint ttype, guint timestamp);
static void _midori_notebook_uri_received_gtk_widget_drag_data_received (GtkWidget* _sender, GdkDragContext* context, gint x, gint y, GtkSelectionData* selection_data, guint info, guint time_, gpointer self);
MidoriTab* midori_notebook_get_tab (MidoriNotebook* self);
WebKitWebView* midori_tab_get_web_view (MidoriTab* self);
GType midori_context_action_get_type (void) G_GNUC_CONST;
MidoriContextAction* midori_notebook_get_context_action (MidoriNotebook* self);
MidoriContextAction* midori_context_action_new (const gchar* name, const gchar* label, const gchar* tooltip, const gchar* stock_id);
MidoriContextAction* midori_context_action_construct (GType object_type, const gchar* name, const gchar* label, const gchar* tooltip, const gchar* stock_id);
static Block5Data* block5_data_ref (Block5Data* _data5_);
static void block5_data_unref (void * _userdata_);
MidoriContextAction* midori_context_action_new_escaped (const gchar* name, const gchar* label, const gchar* tooltip, const gchar* stock_id);
MidoriContextAction* midori_context_action_construct_escaped (GType object_type, const gchar* name, const gchar* label, const gchar* tooltip, const gchar* stock_id);
static void ____lambda15_ (Block5Data* _data5_);
static void _____lambda15__gtk_action_activate (GtkAction* _sender, gpointer self);
void midori_context_action_add (MidoriContextAction* self, GtkAction* action);
GtkMenu* midori_context_action_create_menu (MidoriContextAction* self, GtkMenu* default_menu, gboolean accels);
void midori_notebook_insert (MidoriNotebook* self, MidoriTab* tab, gint index);
gboolean midori_notebook_get_close_buttons_left (MidoriNotebook* self);
gboolean midori_notebook_get_close_buttons_visible (MidoriNotebook* self);
static gboolean midori_notebook_tab_button_pressed (MidoriNotebook* self, GtkWidget* label, GdkEventButton* event);
static gboolean _midori_notebook_tab_button_pressed_gtk_widget_button_press_event (GtkWidget* _sender, GdkEventButton* event, gpointer self);
static void midori_notebook_tab_removed (MidoriNotebook* self);
static void _midori_notebook_tab_removed_gtk_object_destroy (GtkObject* _sender, gpointer self);
static void midori_notebook_tab_minimized (MidoriNotebook* self, GParamSpec* pspec);
static void _midori_notebook_tab_minimized_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
guint midori_notebook_get_count (MidoriNotebook* self);
static void midori_notebook_set_count (MidoriNotebook* self, guint value);
static void midori_notebook_relayout (MidoriNotebook* self);
static void midori_notebook_resize (MidoriNotebook* self, gint new_size);
MidoriContextAction* midori_notebook_get_tab_context_action (MidoriNotebook* self, MidoriTab* tab);
static Block6Data* block6_data_ref (Block6Data* _data6_);
static void block6_data_unref (void * _userdata_);
static void __lambda16_ (Block6Data* _data6_);
static void ___lambda16__gtk_action_activate (GtkAction* _sender, gpointer self);
static void __lambda17_ (Block6Data* _data6_);
void midori_tab_set_minimized (MidoriTab* self, gboolean value);
static void ___lambda17__gtk_action_activate (GtkAction* _sender, gpointer self);
static void __lambda18_ (Block6Data* _data6_);
static void ___lambda18__gtk_action_activate (GtkAction* _sender, gpointer self);
static void __lambda19_ (Block6Data* _data6_);
static void ___lambda19__gtk_action_activate (GtkAction* _sender, gpointer self);
static void __lambda20_ (Block6Data* _data6_);
static void ___lambda20__gtk_action_activate (GtkAction* _sender, gpointer self);
void midori_notebook_move (MidoriNotebook* self, MidoriTab* tab, gint index);
static gboolean midori_notebook_real_expose_event (GtkWidget* base, GdkEventExpose* event);
static void midori_notebook_real_forall_internal (GtkContainer* base, gboolean include_internal, GtkCallback callback, void* callback_target);
void midori_notebook_remove (MidoriNotebook* self, MidoriTab* tab);
MidoriTab* midori_notebook_get_nth_tab (MidoriNotebook* self, gint index);
gint midori_notebook_get_tab_index (MidoriNotebook* self, MidoriTab* tab);
gint midori_notebook_get_index (MidoriNotebook* self);
gboolean midori_notebook_get_labels_visible (MidoriNotebook* self);
static MidoriTab* midori_notebook_get_previous (MidoriNotebook* self);
static void midori_notebook_set_previous (MidoriNotebook* self, MidoriTab* value);
void midori_notebook_set_index (MidoriNotebook* self, gint value);
void midori_notebook_set_tab (MidoriNotebook* self, MidoriTab* value);
void midori_notebook_set_close_buttons_left (MidoriNotebook* self, gboolean value);
void midori_notebook_set_close_buttons_visible (MidoriNotebook* self, gboolean value);
void midori_notebook_set_labels_visible (MidoriNotebook* self, gboolean value);
static void g_cclosure_user_marshal_VOID__OBJECT_OBJECT (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data);
static void g_cclosure_user_marshal_VOID__OBJECT_UINT (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data);
static void g_cclosure_user_marshal_VOID__OBJECT_INT_INT (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data);
static void midori_notebook_finalize (GObject * obj);
static void _vala_midori_notebook_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec);
static void _vala_midori_notebook_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec);
static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func);
static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func);
static gint _vala_array_length (gpointer array);


static void _midori_tally_close_style_set_gtk_widget_style_set (GtkWidget* _sender, GtkStyle* previous_style, gpointer self) {
#line 47 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_close_style_set ((MidoriTally*) self, previous_style);
#line 309 "midori-notebook.c"
}


static void _midori_tally_close_clicked_gtk_button_clicked (GtkButton* _sender, gpointer self) {
#line 54 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_close_clicked ((MidoriTally*) self);
#line 316 "midori-notebook.c"
}


static void _midori_tally_uri_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 59 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_uri_changed ((MidoriTally*) self, pspec);
#line 323 "midori-notebook.c"
}


static void _midori_tally_title_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 60 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_title_changed ((MidoriTally*) self, pspec);
#line 330 "midori-notebook.c"
}


static void _midori_tally_icon_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 61 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_icon_changed ((MidoriTally*) self, pspec);
#line 337 "midori-notebook.c"
}


static void _midori_tally_minimized_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 62 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_minimized_changed ((MidoriTally*) self, pspec);
#line 344 "midori-notebook.c"
}


static void _midori_tally_progress_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 63 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_progress_changed ((MidoriTally*) self, pspec);
#line 351 "midori-notebook.c"
}


static void _midori_tally_colors_changed_midori_tab_colors_changed (MidoriTab* _sender, gpointer self) {
#line 64 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_colors_changed ((MidoriTally*) self);
#line 358 "midori-notebook.c"
}


static void _midori_tally_close_button_left_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 71 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_close_button_left_changed ((MidoriTally*) self, pspec);
#line 365 "midori-notebook.c"
}


static void _midori_tally_close_button_visible_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 73 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_close_button_visible_changed ((MidoriTally*) self, pspec);
#line 372 "midori-notebook.c"
}


MidoriTally* midori_tally_construct (GType object_type, MidoriTab* tab) {
	MidoriTally * self = NULL;
	MidoriTab* _tmp0_;
	GtkHBox* _tmp1_;
	GtkHBox* _tmp2_;
	GtkSpinner* _tmp3_;
	GtkSpinner* _tmp4_;
	gint icon_size = 0;
	GtkSettings* _tmp5_;
	gint _tmp6_ = 0;
	GtkSpinner* _tmp7_;
	gint _tmp8_;
	gint _tmp9_;
	GtkHBox* _tmp10_;
	GtkSpinner* _tmp11_;
	GtkLabel* _tmp12_;
	GtkLabel* _tmp13_;
	GtkLabel* _tmp14_;
	GtkHBox* _tmp15_;
	GtkLabel* _tmp16_;
	GtkButton* _tmp17_;
	GtkButton* _tmp18_;
	GtkButton* _tmp19_;
	GtkButton* _tmp20_;
	GtkButton* _tmp21_;
	GThemedIcon* _tmp22_;
	GThemedIcon* _tmp23_;
	GtkImage* _tmp24_;
	GtkButton* _tmp25_;
	GtkImage* _tmp26_;
	GtkAlignment* _tmp27_;
	GtkAlignment* _tmp28_;
	GtkButton* _tmp29_;
	GtkHBox* _tmp30_;
	GtkAlignment* _tmp31_;
	GtkButton* _tmp32_;
	GThemedIcon* _tmp33_;
	GThemedIcon* _tmp34_;
	GtkImage* _tmp35_;
	GtkHBox* _tmp36_;
	GtkImage* _tmp37_;
	GtkHBox* _tmp38_;
	MidoriTab* _tmp39_;
	MidoriTab* _tmp40_;
	MidoriTab* _tmp41_;
	MidoriTab* _tmp42_;
	MidoriTab* _tmp43_;
	MidoriTab* _tmp44_;
	GtkLabel* _tmp45_;
	MidoriTab* _tmp46_;
	gboolean _tmp47_;
	gboolean _tmp48_;
	GtkSpinner* _tmp49_;
	MidoriTab* _tmp50_;
	gdouble _tmp51_;
	gdouble _tmp52_;
	GtkImage* _tmp53_;
	GtkSpinner* _tmp54_;
	gboolean _tmp55_;
	gboolean _tmp56_;
#line 25 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (tab != NULL, NULL);
#line 25 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = (MidoriTally*) g_object_new (object_type, NULL);
#line 26 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = tab;
#line 26 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_set_tab (self, _tmp0_);
#line 27 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = (GtkHBox*) gtk_hbox_new (FALSE, 1);
#line 27 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref_sink (_tmp1_);
#line 27 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->box);
#line 27 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->box = _tmp1_;
#line 28 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = self->priv->box;
#line 28 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_container_add ((GtkContainer*) self, (GtkWidget*) _tmp2_);
#line 30 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = (GtkSpinner*) gtk_spinner_new ();
#line 30 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref_sink (_tmp3_);
#line 30 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->spinner);
#line 30 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->spinner = _tmp3_;
#line 31 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = self->priv->spinner;
#line 31 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_set (_tmp4_, "active", TRUE, NULL);
#line 33 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	icon_size = 16;
#line 34 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp5_ = gtk_widget_get_settings ((GtkWidget*) self);
#line 34 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_icon_size_lookup_for_settings (_tmp5_, GTK_ICON_SIZE_MENU, &_tmp6_, NULL);
#line 34 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	icon_size = _tmp6_;
#line 36 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = self->priv->spinner;
#line 36 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp8_ = icon_size;
#line 36 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp9_ = icon_size;
#line 36 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_size_request ((GtkWidget*) _tmp7_, _tmp8_, _tmp9_);
#line 37 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp10_ = self->priv->box;
#line 37 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp11_ = self->priv->spinner;
#line 37 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_box_pack_start ((GtkBox*) _tmp10_, (GtkWidget*) _tmp11_, FALSE, FALSE, (guint) 0);
#line 38 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp12_ = (GtkLabel*) gtk_label_new (NULL);
#line 38 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref_sink (_tmp12_);
#line 38 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->label);
#line 38 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->label = _tmp12_;
#line 39 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp13_ = self->label;
#line 39 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_misc_set_alignment ((GtkMisc*) _tmp13_, 0.5f, 0.5f);
#line 40 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp14_ = self->label;
#line 40 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_misc_set_padding ((GtkMisc*) _tmp14_, 0, 0);
#line 41 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp15_ = self->priv->box;
#line 41 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp16_ = self->label;
#line 41 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_box_pack_start ((GtkBox*) _tmp15_, (GtkWidget*) _tmp16_, TRUE, TRUE, (guint) 0);
#line 42 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp17_ = (GtkButton*) gtk_button_new ();
#line 42 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref_sink (_tmp17_);
#line 42 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->close);
#line 42 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->close = _tmp17_;
#line 43 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp18_ = self->priv->close;
#line 43 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_button_set_relief (_tmp18_, GTK_RELIEF_NONE);
#line 44 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp19_ = self->priv->close;
#line 44 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_button_set_focus_on_click (_tmp19_, FALSE);
#line 46 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp20_ = self->priv->close;
#line 46 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_name ((GtkWidget*) _tmp20_, "midori-close-button");
#line 47 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp21_ = self->priv->close;
#line 47 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GtkWidget*) _tmp21_, "style-set", (GCallback) _midori_tally_close_style_set_gtk_widget_style_set, self, 0);
#line 49 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp22_ = (GThemedIcon*) g_themed_icon_new_with_default_fallbacks ("window-close-symbolic");
#line 49 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp23_ = _tmp22_;
#line 49 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp24_ = (GtkImage*) gtk_image_new_from_gicon ((GIcon*) _tmp23_, GTK_ICON_SIZE_MENU);
#line 49 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref_sink (_tmp24_);
#line 49 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->icon);
#line 49 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->icon = _tmp24_;
#line 49 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (_tmp23_);
#line 50 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp25_ = self->priv->close;
#line 50 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp26_ = self->icon;
#line 50 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_container_add ((GtkContainer*) _tmp25_, (GtkWidget*) _tmp26_);
#line 51 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp27_ = (GtkAlignment*) gtk_alignment_new (1.0f, 0.5f, 0.0f, 0.0f);
#line 51 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref_sink (_tmp27_);
#line 51 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->align);
#line 51 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->align = _tmp27_;
#line 52 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp28_ = self->priv->align;
#line 52 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp29_ = self->priv->close;
#line 52 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_container_add ((GtkContainer*) _tmp28_, (GtkWidget*) _tmp29_);
#line 53 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp30_ = self->priv->box;
#line 53 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp31_ = self->priv->align;
#line 53 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_box_pack_start ((GtkBox*) _tmp30_, (GtkWidget*) _tmp31_, FALSE, FALSE, (guint) 0);
#line 54 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp32_ = self->priv->close;
#line 54 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object (_tmp32_, "clicked", (GCallback) _midori_tally_close_clicked_gtk_button_clicked, self, 0);
#line 55 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp33_ = (GThemedIcon*) g_themed_icon_new_with_default_fallbacks ("text-html-symbolic");
#line 55 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp34_ = _tmp33_;
#line 55 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp35_ = (GtkImage*) gtk_image_new_from_gicon ((GIcon*) _tmp34_, GTK_ICON_SIZE_MENU);
#line 55 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref_sink (_tmp35_);
#line 55 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->icon);
#line 55 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->icon = _tmp35_;
#line 55 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (_tmp34_);
#line 56 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp36_ = self->priv->box;
#line 56 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp37_ = self->icon;
#line 56 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_box_pack_start ((GtkBox*) _tmp36_, (GtkWidget*) _tmp37_, FALSE, FALSE, (guint) 0);
#line 57 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp38_ = self->priv->box;
#line 57 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_show_all ((GtkWidget*) _tmp38_);
#line 59 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp39_ = tab;
#line 59 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) _tmp39_, "notify::uri", (GCallback) _midori_tally_uri_changed_g_object_notify, self, 0);
#line 60 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp40_ = tab;
#line 60 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) _tmp40_, "notify::title", (GCallback) _midori_tally_title_changed_g_object_notify, self, 0);
#line 61 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp41_ = tab;
#line 61 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) _tmp41_, "notify::icon", (GCallback) _midori_tally_icon_changed_g_object_notify, self, 0);
#line 62 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp42_ = tab;
#line 62 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) _tmp42_, "notify::minimized", (GCallback) _midori_tally_minimized_changed_g_object_notify, self, 0);
#line 63 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp43_ = tab;
#line 63 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) _tmp43_, "notify::progress", (GCallback) _midori_tally_progress_changed_g_object_notify, self, 0);
#line 64 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp44_ = tab;
#line 64 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object (_tmp44_, "colors-changed", (GCallback) _midori_tally_colors_changed_midori_tab_colors_changed, self, 0);
#line 65 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_update_label (self);
#line 66 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp45_ = self->label;
#line 66 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp46_ = tab;
#line 66 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp47_ = midori_tab_get_minimized (_tmp46_);
#line 66 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp48_ = _tmp47_;
#line 66 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_visible ((GtkWidget*) _tmp45_, !_tmp48_);
#line 67 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp49_ = self->priv->spinner;
#line 67 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp50_ = tab;
#line 67 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp51_ = midori_tab_get_progress (_tmp50_);
#line 67 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp52_ = _tmp51_;
#line 67 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_visible ((GtkWidget*) _tmp49_, _tmp52_ > 0.0);
#line 68 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp53_ = self->icon;
#line 68 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp54_ = self->priv->spinner;
#line 68 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp55_ = gtk_widget_get_visible ((GtkWidget*) _tmp54_);
#line 68 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp56_ = _tmp55_;
#line 68 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_visible ((GtkWidget*) _tmp53_, !_tmp56_);
#line 69 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_update_color (self);
#line 71 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) self, "notify::close-button-left", (GCallback) _midori_tally_close_button_left_changed_g_object_notify, self, 0);
#line 72 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_notify ((GObject*) self, "close-button-left");
#line 73 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) self, "notify::close-button-visible", (GCallback) _midori_tally_close_button_visible_changed_g_object_notify, self, 0);
#line 74 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_notify ((GObject*) self, "close-button-visible");
#line 25 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return self;
#line 672 "midori-notebook.c"
}


MidoriTally* midori_tally_new (MidoriTab* tab) {
#line 25 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return midori_tally_construct (MIDORI_TYPE_TALLY, tab);
#line 679 "midori-notebook.c"
}


static void midori_tally_close_style_set (MidoriTally* self, GtkStyle* previous_style) {
	GtkRequisition size = {0};
	GtkButton* _tmp0_;
	GtkWidget* _tmp1_;
	GtkRequisition _tmp2_ = {0};
	GtkButton* _tmp3_;
	GtkRequisition _tmp4_;
	gint _tmp5_;
	GtkRequisition _tmp6_;
	gint _tmp7_;
#line 78 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 80 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->close;
#line 80 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = ((GtkBin*) _tmp0_)->child;
#line 80 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_size_request (_tmp1_, &_tmp2_);
#line 80 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	size = _tmp2_;
#line 81 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = self->priv->close;
#line 81 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = size;
#line 81 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp5_ = _tmp4_.width;
#line 81 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp6_ = size;
#line 81 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = _tmp6_.height;
#line 81 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_size_request ((GtkWidget*) _tmp3_, _tmp5_, _tmp7_);
#line 715 "midori-notebook.c"
}


static void midori_tally_close_clicked (MidoriTally* self) {
	MidoriTab* _tmp0_;
#line 85 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 86 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_tab;
#line 86 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_object_destroy ((GtkObject*) _tmp0_);
#line 727 "midori-notebook.c"
}


static void midori_tally_uri_changed (MidoriTally* self, GParamSpec* pspec) {
	GtkLabel* _tmp0_;
	MidoriTab* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
#line 89 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 89 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 90 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->label;
#line 90 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->priv->_tab;
#line 90 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = midori_tab_get_uri (_tmp1_);
#line 90 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = _tmp2_;
#line 90 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_label_set_label (_tmp0_, _tmp3_);
#line 750 "midori-notebook.c"
}


static void midori_tally_title_changed (MidoriTally* self, GParamSpec* pspec) {
#line 93 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 93 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 94 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_update_label (self);
#line 761 "midori-notebook.c"
}


static void midori_tally_update_label (MidoriTally* self) {
	gchar* title = NULL;
	MidoriTab* _tmp0_;
	GtkLabel* _tmp1_;
	MidoriTab* _tmp2_;
	const gchar* _tmp3_;
	const gchar* _tmp4_;
	gchar* _tmp5_;
	gchar* _tmp6_;
	GtkLabel* _tmp7_;
	GtkLabel* _tmp8_;
	const gchar* _tmp9_;
	const gchar* _tmp10_;
	MidoriTab* _tmp11_;
	const gchar* _tmp12_;
	const gchar* _tmp13_;
	PangoEllipsizeMode _tmp14_;
	GtkLabel* _tmp15_;
	const gchar* _tmp16_;
	const gchar* _tmp17_;
#line 97 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 99 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_tab;
#line 99 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_get ((GObject*) _tmp0_, "title", &title, NULL);
#line 100 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->label;
#line 100 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = self->priv->_tab;
#line 100 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = midori_tab_get_uri (_tmp2_);
#line 100 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = _tmp3_;
#line 100 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp5_ = midori_tab_get_display_title (title, _tmp4_);
#line 100 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp6_ = _tmp5_;
#line 100 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_label_set_label (_tmp1_, _tmp6_);
#line 100 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_free0 (_tmp6_);
#line 102 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = self->label;
#line 102 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp8_ = self->label;
#line 102 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp9_ = gtk_label_get_label (_tmp8_);
#line 102 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp10_ = _tmp9_;
#line 102 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp11_ = self->priv->_tab;
#line 102 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp12_ = midori_tab_get_uri (_tmp11_);
#line 102 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp13_ = _tmp12_;
#line 102 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp14_ = midori_tab_get_display_ellipsize (_tmp10_, _tmp13_);
#line 102 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_label_set_ellipsize (_tmp7_, _tmp14_);
#line 103 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp15_ = self->label;
#line 103 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp16_ = gtk_label_get_label (_tmp15_);
#line 103 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp17_ = _tmp16_;
#line 103 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_tooltip_text ((GtkWidget*) self, _tmp17_);
#line 97 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_free0 (title);
#line 835 "midori-notebook.c"
}


static void midori_tally_icon_changed (MidoriTally* self, GParamSpec* pspec) {
	GIcon* icon = NULL;
	MidoriTab* _tmp0_;
	GtkImage* _tmp1_;
#line 106 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 106 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 108 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_tab;
#line 108 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_get ((GObject*) _tmp0_, "icon", &icon, NULL);
#line 109 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->icon;
#line 109 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_image_set_from_gicon (_tmp1_, icon, GTK_ICON_SIZE_MENU);
#line 106 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (icon);
#line 857 "midori-notebook.c"
}


static void midori_tally_colors_changed (MidoriTally* self) {
#line 112 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 113 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_update_color (self);
#line 866 "midori-notebook.c"
}


static void midori_tally_update_color (MidoriTally* self) {
	gboolean _tmp0_ = FALSE;
	MidoriTab* _tmp1_;
	GdkColor* _tmp2_;
	GdkColor* _tmp3_;
	GtkLabel* _tmp7_;
	MidoriTab* _tmp8_;
	GdkColor* _tmp9_;
	GdkColor* _tmp10_;
	GtkLabel* _tmp11_;
	MidoriTab* _tmp12_;
	GdkColor* _tmp13_;
	GdkColor* _tmp14_;
	MidoriTab* _tmp15_;
	GdkColor* _tmp16_;
	GdkColor* _tmp17_;
	MidoriTab* _tmp18_;
	GdkColor* _tmp19_;
	GdkColor* _tmp20_;
#line 116 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->priv->_tab;
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = midori_tab_get_fg_color (_tmp1_);
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = _tmp2_;
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp3_ != NULL) {
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = TRUE;
#line 901 "midori-notebook.c"
	} else {
		MidoriTab* _tmp4_;
		GdkColor* _tmp5_;
		GdkColor* _tmp6_;
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp4_ = self->priv->_tab;
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp5_ = midori_tab_get_bg_color (_tmp4_);
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp6_ = _tmp5_;
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = _tmp6_ != NULL;
#line 914 "midori-notebook.c"
	}
#line 117 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_event_box_set_visible_window ((GtkEventBox*) self, _tmp0_);
#line 118 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = self->label;
#line 118 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp8_ = self->priv->_tab;
#line 118 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp9_ = midori_tab_get_fg_color (_tmp8_);
#line 118 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp10_ = _tmp9_;
#line 118 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_modify_fg ((GtkWidget*) _tmp7_, GTK_STATE_NORMAL, _tmp10_);
#line 119 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp11_ = self->label;
#line 119 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp12_ = self->priv->_tab;
#line 119 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp13_ = midori_tab_get_fg_color (_tmp12_);
#line 119 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp14_ = _tmp13_;
#line 119 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_modify_fg ((GtkWidget*) _tmp11_, GTK_STATE_ACTIVE, _tmp14_);
#line 120 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp15_ = self->priv->_tab;
#line 120 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp16_ = midori_tab_get_bg_color (_tmp15_);
#line 120 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp17_ = _tmp16_;
#line 120 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_modify_bg ((GtkWidget*) self, GTK_STATE_NORMAL, _tmp17_);
#line 121 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp18_ = self->priv->_tab;
#line 121 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp19_ = midori_tab_get_bg_color (_tmp18_);
#line 121 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp20_ = _tmp19_;
#line 121 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_modify_bg ((GtkWidget*) self, GTK_STATE_ACTIVE, _tmp20_);
#line 954 "midori-notebook.c"
}


static void midori_tally_close_button_left_changed (MidoriTally* self, GParamSpec* pspec) {
	gboolean _tmp0_;
#line 124 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 124 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 125 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_close_button_left;
#line 125 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp0_) {
#line 968 "midori-notebook.c"
		GtkHBox* _tmp1_;
		GtkAlignment* _tmp2_;
		GtkHBox* _tmp3_;
		GtkLabel* _tmp4_;
		GtkHBox* _tmp5_;
		GtkImage* _tmp6_;
		GtkHBox* _tmp7_;
		GtkSpinner* _tmp8_;
#line 126 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp1_ = self->priv->box;
#line 126 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp2_ = self->priv->align;
#line 126 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		gtk_box_reorder_child ((GtkBox*) _tmp1_, (GtkWidget*) _tmp2_, 0);
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp3_ = self->priv->box;
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp4_ = self->label;
#line 127 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		gtk_box_reorder_child ((GtkBox*) _tmp3_, (GtkWidget*) _tmp4_, 1);
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp5_ = self->priv->box;
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp6_ = self->icon;
#line 128 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		gtk_box_reorder_child ((GtkBox*) _tmp5_, (GtkWidget*) _tmp6_, 2);
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp7_ = self->priv->box;
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp8_ = self->priv->spinner;
#line 129 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		gtk_box_reorder_child ((GtkBox*) _tmp7_, (GtkWidget*) _tmp8_, 3);
#line 1001 "midori-notebook.c"
	} else {
		GtkHBox* _tmp9_;
		GtkSpinner* _tmp10_;
		GtkHBox* _tmp11_;
		GtkImage* _tmp12_;
		GtkHBox* _tmp13_;
		GtkLabel* _tmp14_;
		GtkHBox* _tmp15_;
		GtkAlignment* _tmp16_;
#line 131 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp9_ = self->priv->box;
#line 131 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp10_ = self->priv->spinner;
#line 131 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		gtk_box_reorder_child ((GtkBox*) _tmp9_, (GtkWidget*) _tmp10_, 0);
#line 132 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp11_ = self->priv->box;
#line 132 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp12_ = self->icon;
#line 132 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		gtk_box_reorder_child ((GtkBox*) _tmp11_, (GtkWidget*) _tmp12_, 1);
#line 133 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp13_ = self->priv->box;
#line 133 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp14_ = self->label;
#line 133 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		gtk_box_reorder_child ((GtkBox*) _tmp13_, (GtkWidget*) _tmp14_, 2);
#line 134 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp15_ = self->priv->box;
#line 134 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp16_ = self->priv->align;
#line 134 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		gtk_box_reorder_child ((GtkBox*) _tmp15_, (GtkWidget*) _tmp16_, 3);
#line 1035 "midori-notebook.c"
	}
}


static void midori_tally_close_button_visible_changed (MidoriTally* self, GParamSpec* pspec) {
	gboolean _tmp0_ = FALSE;
	MidoriTab* _tmp1_;
	gboolean _tmp2_;
	gboolean _tmp3_;
	GtkAlignment* _tmp5_;
#line 138 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 138 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 139 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->priv->_tab;
#line 139 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = midori_tab_get_minimized (_tmp1_);
#line 139 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = _tmp2_;
#line 139 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (!_tmp3_) {
#line 1058 "midori-notebook.c"
		gboolean _tmp4_;
#line 139 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp4_ = self->priv->_close_button_visible;
#line 139 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = _tmp4_;
#line 1064 "midori-notebook.c"
	} else {
#line 139 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = FALSE;
#line 1068 "midori-notebook.c"
	}
#line 139 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp5_ = self->priv->align;
#line 139 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_visible ((GtkWidget*) _tmp5_, _tmp0_);
#line 1074 "midori-notebook.c"
}


static void midori_tally_minimized_changed (MidoriTally* self, GParamSpec* pspec) {
	GtkLabel* _tmp0_;
	MidoriTab* _tmp1_;
	gboolean _tmp2_;
	gboolean _tmp3_;
#line 142 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 142 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->label;
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->priv->_tab;
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = midori_tab_get_minimized (_tmp1_);
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = _tmp2_;
#line 143 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_visible ((GtkWidget*) _tmp0_, !_tmp3_);
#line 144 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_notify ((GObject*) self, "close-button-visible");
#line 1099 "midori-notebook.c"
}


static void midori_tally_progress_changed (MidoriTally* self, GParamSpec* pspec) {
	GtkSpinner* _tmp0_;
	MidoriTab* _tmp1_;
	gdouble _tmp2_;
	gdouble _tmp3_;
	GtkImage* _tmp4_;
	GtkSpinner* _tmp5_;
	gboolean _tmp6_;
	gboolean _tmp7_;
#line 147 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 147 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 148 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->spinner;
#line 148 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->priv->_tab;
#line 148 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = midori_tab_get_progress (_tmp1_);
#line 148 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = _tmp2_;
#line 148 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_visible ((GtkWidget*) _tmp0_, _tmp3_ > 0.0);
#line 149 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = self->icon;
#line 149 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp5_ = self->priv->spinner;
#line 149 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp6_ = gtk_widget_get_visible ((GtkWidget*) _tmp5_);
#line 149 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = _tmp6_;
#line 149 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_visible ((GtkWidget*) _tmp4_, !_tmp7_);
#line 1136 "midori-notebook.c"
}


MidoriTab* midori_tally_get_tab (MidoriTally* self) {
	MidoriTab* result;
	MidoriTab* _tmp0_;
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_tab;
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp0_;
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 1151 "midori-notebook.c"
}


static gpointer _g_object_ref0 (gpointer self) {
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return self ? g_object_ref (self) : NULL;
#line 1158 "midori-notebook.c"
}


void midori_tally_set_tab (MidoriTally* self, MidoriTab* value) {
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (midori_tally_get_tab (self) != value) {
#line 1167 "midori-notebook.c"
		MidoriTab* _tmp0_;
		MidoriTab* _tmp1_;
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = value;
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp1_ = _g_object_ref0 (_tmp0_);
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_object_unref0 (self->priv->_tab);
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		self->priv->_tab = _tmp1_;
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_object_notify_by_pspec ((GObject *) self, midori_tally_properties[MIDORI_TALLY_TAB_PROPERTY]);
#line 1180 "midori-notebook.c"
	}
}


gboolean midori_tally_get_close_button_left (MidoriTally* self) {
	gboolean result;
	gboolean _tmp0_;
#line 22 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 22 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_close_button_left;
#line 22 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp0_;
#line 22 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 1196 "midori-notebook.c"
}


void midori_tally_set_close_button_left (MidoriTally* self, gboolean value) {
#line 22 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 22 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (midori_tally_get_close_button_left (self) != value) {
#line 1205 "midori-notebook.c"
		gboolean _tmp0_;
#line 22 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = value;
#line 22 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		self->priv->_close_button_left = _tmp0_;
#line 22 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_object_notify_by_pspec ((GObject *) self, midori_tally_properties[MIDORI_TALLY_CLOSE_BUTTON_LEFT_PROPERTY]);
#line 1213 "midori-notebook.c"
	}
}


gboolean midori_tally_get_close_button_visible (MidoriTally* self) {
	gboolean result;
	gboolean _tmp0_;
#line 23 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 23 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_close_button_visible;
#line 23 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp0_;
#line 23 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 1229 "midori-notebook.c"
}


void midori_tally_set_close_button_visible (MidoriTally* self, gboolean value) {
#line 23 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 23 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (midori_tally_get_close_button_visible (self) != value) {
#line 1238 "midori-notebook.c"
		gboolean _tmp0_;
#line 23 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = value;
#line 23 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		self->priv->_close_button_visible = _tmp0_;
#line 23 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_object_notify_by_pspec ((GObject *) self, midori_tally_properties[MIDORI_TALLY_CLOSE_BUTTON_VISIBLE_PROPERTY]);
#line 1246 "midori-notebook.c"
	}
}


static void midori_tally_class_init (MidoriTallyClass * klass) {
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_parent_class = g_type_class_peek_parent (klass);
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_type_class_add_private (klass, sizeof (MidoriTallyPrivate));
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	G_OBJECT_CLASS (klass)->get_property = _vala_midori_tally_get_property;
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	G_OBJECT_CLASS (klass)->set_property = _vala_midori_tally_set_property;
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	G_OBJECT_CLASS (klass)->finalize = midori_tally_finalize;
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), MIDORI_TALLY_TAB_PROPERTY, midori_tally_properties[MIDORI_TALLY_TAB_PROPERTY] = g_param_spec_object ("tab", "tab", "tab", MIDORI_TYPE_TAB, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), MIDORI_TALLY_CLOSE_BUTTON_LEFT_PROPERTY, midori_tally_properties[MIDORI_TALLY_CLOSE_BUTTON_LEFT_PROPERTY] = g_param_spec_boolean ("close-button-left", "close-button-left", "close-button-left", FALSE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), MIDORI_TALLY_CLOSE_BUTTON_VISIBLE_PROPERTY, midori_tally_properties[MIDORI_TALLY_CLOSE_BUTTON_VISIBLE_PROPERTY] = g_param_spec_boolean ("close-button-visible", "close-button-visible", "close-button-visible", FALSE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 1268 "midori-notebook.c"
}


static void midori_tally_instance_init (MidoriTally * self) {
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv = MIDORI_TALLY_GET_PRIVATE (self);
#line 22 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->_close_button_left = FALSE;
#line 23 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->_close_button_visible = FALSE;
#line 1279 "midori-notebook.c"
}


static void midori_tally_finalize (GObject * obj) {
	MidoriTally * self;
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, MIDORI_TYPE_TALLY, MidoriTally);
#line 14 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->_tab);
#line 15 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->spinner);
#line 16 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->label);
#line 17 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->box);
#line 18 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->icon);
#line 19 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->align);
#line 20 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->close);
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	G_OBJECT_CLASS (midori_tally_parent_class)->finalize (obj);
#line 1303 "midori-notebook.c"
}


GType midori_tally_get_type (void) {
	static volatile gsize midori_tally_type_id__volatile = 0;
	if (g_once_init_enter (&midori_tally_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (MidoriTallyClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) midori_tally_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (MidoriTally), 0, (GInstanceInitFunc) midori_tally_instance_init, NULL };
		GType midori_tally_type_id;
		midori_tally_type_id = g_type_register_static (GTK_TYPE_EVENT_BOX, "MidoriTally", &g_define_type_info, 0);
		g_once_init_leave (&midori_tally_type_id__volatile, midori_tally_type_id);
	}
	return midori_tally_type_id__volatile;
}


static void _vala_midori_tally_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) {
	MidoriTally * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, MIDORI_TYPE_TALLY, MidoriTally);
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	switch (property_id) {
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_TALLY_TAB_PROPERTY:
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_value_set_object (value, midori_tally_get_tab (self));
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_TALLY_CLOSE_BUTTON_LEFT_PROPERTY:
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_value_set_boolean (value, midori_tally_get_close_button_left (self));
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_TALLY_CLOSE_BUTTON_VISIBLE_PROPERTY:
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_value_set_boolean (value, midori_tally_get_close_button_visible (self));
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 1342 "midori-notebook.c"
		default:
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 1348 "midori-notebook.c"
	}
}


static void _vala_midori_tally_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec) {
	MidoriTally * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, MIDORI_TYPE_TALLY, MidoriTally);
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	switch (property_id) {
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_TALLY_TAB_PROPERTY:
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		midori_tally_set_tab (self, g_value_get_object (value));
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_TALLY_CLOSE_BUTTON_LEFT_PROPERTY:
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		midori_tally_set_close_button_left (self, g_value_get_boolean (value));
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_TALLY_CLOSE_BUTTON_VISIBLE_PROPERTY:
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		midori_tally_set_close_button_visible (self, g_value_get_boolean (value));
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 1376 "midori-notebook.c"
		default:
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
#line 13 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 1382 "midori-notebook.c"
	}
}


static void _midori_notebook_size_allocated_gtk_widget_size_allocate (GtkWidget* _sender, GdkRectangle* allocation, gpointer self) {
#line 274 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_size_allocated ((MidoriNotebook*) self, allocation);
#line 1390 "midori-notebook.c"
}


static void _midori_notebook_page_switched_gtk_notebook_switch_page (GtkNotebook* _sender, GtkNotebookPage* page, guint page_num, gpointer self) {
#line 275 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_page_switched ((MidoriNotebook*) self, page, page_num);
#line 1397 "midori-notebook.c"
}


static void _midori_notebook_page_moved_gtk_notebook_page_reordered (GtkNotebook* _sender, GtkWidget* p0, guint p1, gpointer self) {
#line 276 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_page_moved ((MidoriNotebook*) self, p0, p1);
#line 1404 "midori-notebook.c"
}


static GtkNotebook* _midori_notebook_window_created_gtk_notebook_create_window (GtkNotebook* _sender, GtkWidget* page, gint x, gint y, gpointer self) {
	GtkNotebook* result;
	result = midori_notebook_window_created ((MidoriNotebook*) self, page, x, y);
#line 277 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 1413 "midori-notebook.c"
}


static void _midori_notebook_index_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 220 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_index_changed ((MidoriNotebook*) self, pspec);
#line 1420 "midori-notebook.c"
}


static void _midori_notebook_tab_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 221 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_tab_changed ((MidoriNotebook*) self, pspec);
#line 1427 "midori-notebook.c"
}


static void _midori_notebook_labels_visible_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 222 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_labels_visible_changed ((MidoriNotebook*) self, pspec);
#line 1434 "midori-notebook.c"
}


static void _midori_notebook_close_buttons_visible_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 223 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_close_buttons_visible_changed ((MidoriNotebook*) self, pspec);
#line 1441 "midori-notebook.c"
}


static void _midori_notebook_close_buttons_left_changed_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 224 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_close_buttons_left_changed ((MidoriNotebook*) self, pspec);
#line 1448 "midori-notebook.c"
}


static void __lambda14_ (MidoriNotebook* self) {
#line 238 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_emit (self, midori_notebook_signals[MIDORI_NOTEBOOK_NEW_TAB_SIGNAL], 0);
#line 1455 "midori-notebook.c"
}


static void ___lambda14__gtk_button_clicked (GtkButton* _sender, gpointer self) {
#line 237 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	__lambda14_ ((MidoriNotebook*) self);
#line 1462 "midori-notebook.c"
}


static gboolean _midori_notebook_button_pressed_gtk_widget_button_press_event (GtkWidget* _sender, GdkEventButton* event, gpointer self) {
	gboolean result;
	result = midori_notebook_button_pressed ((MidoriNotebook*) self, event);
#line 242 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 1471 "midori-notebook.c"
}


GtkWidget* midori_notebook_construct (GType object_type) {
	MidoriNotebook * self = NULL;
	GtkNotebook* _tmp0_;
	GtkNotebook* _tmp1_;
	GtkNotebook* _tmp2_;
	GtkNotebook* _tmp3_;
	GtkNotebook* _tmp4_;
	GtkNotebook* _tmp5_;
	GtkRcStyle* rcstyle = NULL;
	GtkRcStyle* _tmp6_;
	GtkNotebook* _tmp7_;
	GtkNotebook* _tmp8_;
	GtkNotebook* _tmp9_;
	GtkNotebook* _tmp10_;
	GtkNotebook* _tmp11_;
	GtkButton* add = NULL;
	GtkButton* _tmp12_;
	GThemedIcon* _tmp13_;
	GThemedIcon* _tmp14_;
	GtkImage* _tmp15_;
	GtkImage* _tmp16_;
	GtkNotebook* _tmp17_;
#line 203 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = (MidoriNotebook*) g_object_new (object_type, NULL);
#line 204 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_event_box_set_visible_window ((GtkEventBox*) self, FALSE);
#line 205 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = (GtkNotebook*) gtk_notebook_new ();
#line 205 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref_sink (_tmp0_);
#line 205 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->notebook);
#line 205 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->notebook = _tmp0_;
#line 206 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->notebook;
#line 206 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = self->notebook;
#line 206 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_notebook_set_scrollable (_tmp2_, TRUE);
#line 206 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_visible ((GtkWidget*) _tmp1_, TRUE);
#line 207 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = self->notebook;
#line 207 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_notebook_set_show_border (_tmp3_, FALSE);
#line 208 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = self->notebook;
#line 208 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_set ((GObject*) _tmp4_, "group-name", PACKAGE_NAME, NULL);
#line 209 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp5_ = self->notebook;
#line 209 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_container_add ((GtkContainer*) self, (GtkWidget*) _tmp5_);
#line 215 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp6_ = gtk_rc_style_new ();
#line 215 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	rcstyle = _tmp6_;
#line 216 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	rcstyle->xthickness = 0;
#line 217 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = self->notebook;
#line 217 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_modify_style ((GtkWidget*) _tmp7_, rcstyle);
#line 218 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_rc_parse_string (MIDORI_NOTEBOOK_style_fixup);
#line 220 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) self, "notify::index", (GCallback) _midori_notebook_index_changed_g_object_notify, self, 0);
#line 221 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) self, "notify::tab", (GCallback) _midori_notebook_tab_changed_g_object_notify, self, 0);
#line 222 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) self, "notify::labels-visible", (GCallback) _midori_notebook_labels_visible_changed_g_object_notify, self, 0);
#line 223 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) self, "notify::close-buttons-visible", (GCallback) _midori_notebook_close_buttons_visible_changed_g_object_notify, self, 0);
#line 224 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) self, "notify::close-buttons-left", (GCallback) _midori_notebook_close_buttons_left_changed_g_object_notify, self, 0);
#line 226 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp8_ = self->notebook;
#line 226 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GtkWidget*) _tmp8_, "size-allocate", (GCallback) _midori_notebook_size_allocated_gtk_widget_size_allocate, self, 0);
#line 227 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp9_ = self->notebook;
#line 227 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object (_tmp9_, "switch-page", (GCallback) _midori_notebook_page_switched_gtk_notebook_switch_page, self, 0);
#line 228 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp10_ = self->notebook;
#line 228 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object (_tmp10_, "page-reordered", (GCallback) _midori_notebook_page_moved_gtk_notebook_page_reordered, self, 0);
#line 229 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp11_ = self->notebook;
#line 229 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object (_tmp11_, "create-window", (GCallback) _midori_notebook_window_created_gtk_notebook_create_window, self, 0);
#line 231 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp12_ = (GtkButton*) gtk_button_new ();
#line 231 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref_sink (_tmp12_);
#line 231 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	add = _tmp12_;
#line 232 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_tooltip_text ((GtkWidget*) add, _ ("Open a new tab"));
#line 233 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_button_set_relief (add, GTK_RELIEF_NONE);
#line 234 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp13_ = (GThemedIcon*) g_themed_icon_new_with_default_fallbacks ("tab-new-symbolic");
#line 234 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp14_ = _tmp13_;
#line 234 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp15_ = (GtkImage*) gtk_image_new_from_gicon ((GIcon*) _tmp14_, GTK_ICON_SIZE_MENU);
#line 234 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref_sink (_tmp15_);
#line 234 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp16_ = _tmp15_;
#line 234 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_container_add ((GtkContainer*) add, (GtkWidget*) _tmp16_);
#line 234 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (_tmp16_);
#line 234 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (_tmp14_);
#line 235 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_show_all ((GtkWidget*) add);
#line 236 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp17_ = self->notebook;
#line 236 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_notebook_set_action_widget (_tmp17_, (GtkWidget*) add, GTK_PACK_START);
#line 237 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object (add, "clicked", (GCallback) ___lambda14__gtk_button_clicked, self, 0);
#line 240 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_take_incoming_uris (self, (GtkWidget*) add);
#line 242 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GtkWidget*) self, "button-press-event", (GCallback) _midori_notebook_button_pressed_gtk_widget_button_press_event, self, 0);
#line 203 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (add);
#line 203 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (rcstyle);
#line 203 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return (GtkWidget*) self;
#line 1611 "midori-notebook.c"
}


GtkWidget* midori_notebook_new (void) {
#line 203 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return midori_notebook_construct (MIDORI_TYPE_NOTEBOOK);
#line 1618 "midori-notebook.c"
}


static gboolean _midori_notebook_uri_dropped_gtk_widget_drag_drop (GtkWidget* _sender, GdkDragContext* context, gint x, gint y, guint time_, gpointer self) {
	gboolean result;
	result = midori_notebook_uri_dropped ((MidoriNotebook*) self, _sender, context, x, y, time_);
#line 249 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 1627 "midori-notebook.c"
}


static void _midori_notebook_uri_received_gtk_widget_drag_data_received (GtkWidget* _sender, GdkDragContext* context, gint x, gint y, GtkSelectionData* selection_data, guint info, guint time_, gpointer self) {
#line 250 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_uri_received ((MidoriNotebook*) self, _sender, context, x, y, selection_data, info, time_);
#line 1634 "midori-notebook.c"
}


static void midori_notebook_take_incoming_uris (MidoriNotebook* self, GtkWidget* widget) {
	GtkWidget* _tmp0_;
	GtkWidget* _tmp1_;
	GtkWidget* _tmp2_;
	GtkWidget* _tmp3_;
	GtkWidget* _tmp4_;
#line 245 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 245 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (widget != NULL);
#line 246 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = widget;
#line 246 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_drag_dest_set (_tmp0_, GTK_DEST_DEFAULT_ALL, (GtkTargetEntry*) NULL, -1, GDK_ACTION_COPY);
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = widget;
#line 247 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_drag_dest_add_text_targets (_tmp1_);
#line 248 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = widget;
#line 248 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_drag_dest_add_uri_targets (_tmp2_);
#line 249 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = widget;
#line 249 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object (_tmp3_, "drag-drop", (GCallback) _midori_notebook_uri_dropped_gtk_widget_drag_drop, self, 0);
#line 250 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = widget;
#line 250 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object (_tmp4_, "drag-data-received", (GCallback) _midori_notebook_uri_received_gtk_widget_drag_data_received, self, 0);
#line 1668 "midori-notebook.c"
}


static gboolean midori_notebook_uri_dropped (MidoriNotebook* self, GtkWidget* widget, GdkDragContext* context, gint x, gint y, guint timestamp) {
	gboolean result = FALSE;
	GdkDragContext* _tmp0_;
	guint _tmp1_;
#line 253 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 253 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (widget != NULL, FALSE);
#line 253 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (context != NULL, FALSE);
#line 254 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = context;
#line 254 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = timestamp;
#line 254 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_drag_finish (_tmp0_, FALSE, FALSE, (guint32) _tmp1_);
#line 255 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = TRUE;
#line 255 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 1692 "midori-notebook.c"
}


static void midori_notebook_uri_received (MidoriNotebook* self, GtkWidget* widget, GdkDragContext* context, gint x, gint y, GtkSelectionData* data, guint ttype, guint timestamp) {
	gchar** uri = NULL;
	GtkSelectionData* _tmp0_;
	gchar** _tmp1_;
	gchar** _tmp2_;
	gint uri_length1;
	gint _uri_size_;
	gchar* _tmp3_ = NULL;
	gchar** _tmp4_;
	gint _tmp4__length1;
	gchar* drag_uri = NULL;
	gchar* _tmp10_;
	MidoriTab* drag_tab = NULL;
	GtkWidget* _tmp11_;
	MidoriTab* _tmp18_;
	WebKitWebView* _tmp19_;
	WebKitWebView* _tmp20_;
	const gchar* _tmp21_;
#line 258 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 258 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (widget != NULL);
#line 258 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (context != NULL);
#line 258 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (data != NULL);
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = data;
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = _tmp1_ = gtk_selection_data_get_uris (_tmp0_);
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	uri = _tmp2_;
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	uri_length1 = _vala_array_length (_tmp1_);
#line 259 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_uri_size_ = uri_length1;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = uri;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4__length1 = uri_length1;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp4_ != NULL) {
#line 1738 "midori-notebook.c"
		gchar** _tmp5_;
		gint _tmp5__length1;
		const gchar* _tmp6_;
		gchar* _tmp7_;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp5_ = uri;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp5__length1 = uri_length1;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp6_ = _tmp5_[0];
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp7_ = g_strdup (_tmp6_);
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_free0 (_tmp3_);
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp3_ = _tmp7_;
#line 1755 "midori-notebook.c"
	} else {
		GtkSelectionData* _tmp8_;
		gchar* _tmp9_;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp8_ = data;
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp9_ = gtk_selection_data_get_text (_tmp8_);
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_free0 (_tmp3_);
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp3_ = _tmp9_;
#line 1767 "midori-notebook.c"
	}
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp10_ = g_strdup (_tmp3_);
#line 260 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	drag_uri = _tmp10_;
#line 262 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp11_ = widget;
#line 262 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (G_TYPE_CHECK_INSTANCE_TYPE (_tmp11_, MIDORI_TYPE_TALLY)) {
#line 1777 "midori-notebook.c"
		GtkWidget* _tmp12_;
		MidoriTab* _tmp13_;
		MidoriTab* _tmp14_;
		MidoriTab* _tmp15_;
#line 263 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp12_ = widget;
#line 263 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp13_ = midori_tally_get_tab (G_TYPE_CHECK_INSTANCE_TYPE (_tmp12_, MIDORI_TYPE_TALLY) ? ((MidoriTally*) _tmp12_) : NULL);
#line 263 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp14_ = _tmp13_;
#line 263 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp15_ = _g_object_ref0 (_tmp14_);
#line 263 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_object_unref0 (drag_tab);
#line 263 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		drag_tab = _tmp15_;
#line 1794 "midori-notebook.c"
	} else {
		MidoriTab* _tmp16_;
		MidoriTab* _tmp17_;
#line 265 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_signal_emit (self, midori_notebook_signals[MIDORI_NOTEBOOK_NEW_TAB_SIGNAL], 0);
#line 267 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp16_ = self->priv->_tab;
#line 267 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp17_ = _g_object_ref0 (_tmp16_);
#line 267 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_object_unref0 (drag_tab);
#line 267 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		drag_tab = _tmp17_;
#line 1808 "midori-notebook.c"
	}
#line 269 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp18_ = drag_tab;
#line 269 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp19_ = midori_tab_get_web_view (_tmp18_);
#line 269 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp20_ = _tmp19_;
#line 269 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp21_ = drag_uri;
#line 269 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	webkit_web_view_load_uri (_tmp20_, _tmp21_);
#line 258 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (drag_tab);
#line 258 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_free0 (drag_uri);
#line 258 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_free0 (_tmp3_);
#line 258 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	uri = (_vala_array_free (uri, uri_length1, (GDestroyNotify) g_free), NULL);
#line 1828 "midori-notebook.c"
}


static Block5Data* block5_data_ref (Block5Data* _data5_) {
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_atomic_int_inc (&_data5_->_ref_count_);
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return _data5_;
#line 1837 "midori-notebook.c"
}


static void block5_data_unref (void * _userdata_) {
	Block5Data* _data5_;
	_data5_ = (Block5Data*) _userdata_;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (g_atomic_int_dec_and_test (&_data5_->_ref_count_)) {
#line 1846 "midori-notebook.c"
		MidoriNotebook* self;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		self = _data5_->self;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_object_unref0 (_data5_->tab);
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_object_unref0 (self);
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_slice_free (Block5Data, _data5_);
#line 1856 "midori-notebook.c"
	}
}


static void ____lambda15_ (Block5Data* _data5_) {
	MidoriNotebook* self;
	GtkNotebook* _tmp0_;
	GtkNotebook* _tmp1_;
	MidoriTab* _tmp2_;
	gint _tmp3_;
#line 289 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = _data5_->self;
#line 290 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 290 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->notebook;
#line 290 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = _data5_->tab;
#line 290 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = gtk_notebook_page_num (_tmp1_, (GtkWidget*) _tmp2_);
#line 290 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_notebook_set_current_page (_tmp0_, _tmp3_);
#line 1879 "midori-notebook.c"
}


static void _____lambda15__gtk_action_activate (GtkAction* _sender, gpointer self) {
#line 289 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	____lambda15_ (self);
#line 1886 "midori-notebook.c"
}


MidoriContextAction* midori_notebook_get_context_action (MidoriNotebook* self) {
	MidoriContextAction* result = NULL;
	MidoriContextAction* menu = NULL;
	MidoriContextAction* _tmp0_;
	guint counter = 0U;
	GtkNotebook* _tmp1_;
	GList* _tmp2_;
	MidoriContextAction* _tmp28_;
#line 281 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 282 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = midori_context_action_new ("NotebookContextMenu", NULL, NULL, NULL);
#line 282 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	menu = _tmp0_;
#line 283 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	counter = (guint) 0;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->notebook;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = gtk_container_get_children ((GtkContainer*) _tmp1_);
#line 1910 "midori-notebook.c"
	{
		GList* child_collection = NULL;
		GList* child_it = NULL;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		child_collection = _tmp2_;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		for (child_it = child_collection; child_it != NULL; child_it = child_it->next) {
#line 1918 "midori-notebook.c"
			GtkWidget* child = NULL;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			child = (GtkWidget*) child_it->data;
#line 1922 "midori-notebook.c"
			{
				Block5Data* _data5_;
				GtkWidget* _tmp3_;
				MidoriTab* _tmp4_;
				MidoriTally* tally = NULL;
				GtkNotebook* _tmp5_;
				MidoriTab* _tmp6_;
				GtkWidget* _tmp7_;
				MidoriTally* _tmp8_;
				MidoriContextAction* action = NULL;
				guint _tmp9_;
				gchar* _tmp10_;
				gchar* _tmp11_;
				MidoriTally* _tmp12_;
				GtkLabel* _tmp13_;
				const gchar* _tmp14_;
				const gchar* _tmp15_;
				MidoriContextAction* _tmp16_;
				MidoriContextAction* _tmp17_;
				MidoriContextAction* _tmp18_;
				MidoriTally* _tmp19_;
				GtkImage* _tmp20_;
				GIcon* _tmp21_;
				GIcon* _tmp22_;
				GIcon* _tmp23_;
				MidoriContextAction* _tmp24_;
				MidoriContextAction* _tmp25_;
				MidoriContextAction* _tmp26_;
				guint _tmp27_;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_data5_ = g_slice_new0 (Block5Data);
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_data5_->_ref_count_ = 1;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_data5_->self = g_object_ref (self);
#line 285 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp3_ = child;
#line 285 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp4_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp3_, MIDORI_TYPE_TAB) ? ((MidoriTab*) _tmp3_) : NULL);
#line 285 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_data5_->tab = _tmp4_;
#line 286 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp5_ = self->notebook;
#line 286 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp6_ = _data5_->tab;
#line 286 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp7_ = gtk_notebook_get_tab_label (_tmp5_, (GtkWidget*) _tmp6_);
#line 286 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp8_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp7_, MIDORI_TYPE_TALLY) ? ((MidoriTally*) _tmp7_) : NULL);
#line 286 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				tally = _tmp8_;
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp9_ = counter;
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp10_ = g_strdup_printf ("Tab%u", _tmp9_);
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp11_ = _tmp10_;
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp12_ = tally;
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp13_ = _tmp12_->label;
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp14_ = gtk_label_get_label (_tmp13_);
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp15_ = _tmp14_;
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp16_ = midori_context_action_new_escaped (_tmp11_, _tmp15_, NULL, NULL);
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp17_ = _tmp16_;
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_g_free0 (_tmp11_);
#line 287 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				action = _tmp17_;
#line 288 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp18_ = action;
#line 288 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp19_ = tally;
#line 288 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp20_ = _tmp19_->icon;
#line 288 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				g_object_get (_tmp20_, "gicon", &_tmp21_, NULL);
#line 288 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp22_ = _tmp21_;
#line 288 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp23_ = _tmp22_;
#line 288 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				gtk_action_set_gicon ((GtkAction*) _tmp18_, _tmp23_);
#line 288 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_g_object_unref0 (_tmp23_);
#line 289 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp24_ = action;
#line 289 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				g_signal_connect_data ((GtkAction*) _tmp24_, "activate", (GCallback) _____lambda15__gtk_action_activate, block5_data_ref (_data5_), (GClosureNotify) block5_data_unref, 0);
#line 292 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp25_ = menu;
#line 292 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp26_ = action;
#line 292 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				midori_context_action_add (_tmp25_, (GtkAction*) _tmp26_);
#line 293 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp27_ = counter;
#line 293 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				counter = _tmp27_ + 1;
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_g_object_unref0 (action);
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_g_object_unref0 (tally);
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				block5_data_unref (_data5_);
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_data5_ = NULL;
#line 2034 "midori-notebook.c"
			}
		}
#line 284 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_list_free0 (child_collection);
#line 2039 "midori-notebook.c"
	}
#line 295 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp28_ = menu;
#line 295 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_emit (self, midori_notebook_signals[MIDORI_NOTEBOOK_CONTEXT_MENU_SIGNAL], 0, _tmp28_);
#line 296 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = menu;
#line 296 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 2049 "midori-notebook.c"
}


static gboolean midori_notebook_button_pressed (MidoriNotebook* self, GdkEventButton* event) {
	gboolean result = FALSE;
	GtkNotebook* _tmp0_;
	GList* _tmp1_;
	gboolean _tmp25_ = FALSE;
	gboolean _tmp26_ = FALSE;
	GdkEventButton _tmp27_;
	GdkEventType _tmp28_;
#line 299 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 299 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (event != NULL, FALSE);
#line 301 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 301 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = gtk_container_get_children ((GtkContainer*) _tmp0_);
#line 2069 "midori-notebook.c"
	{
		GList* child_collection = NULL;
		GList* child_it = NULL;
#line 301 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		child_collection = _tmp1_;
#line 301 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		for (child_it = child_collection; child_it != NULL; child_it = child_it->next) {
#line 2077 "midori-notebook.c"
			GtkWidget* child = NULL;
#line 301 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			child = (GtkWidget*) child_it->data;
#line 2081 "midori-notebook.c"
			{
				MidoriTally* tally = NULL;
				GtkNotebook* _tmp2_;
				MidoriTab* _tmp3_;
				GtkWidget* _tmp4_;
				MidoriTally* _tmp5_;
				GtkAllocation size = {0};
				MidoriTally* _tmp6_;
				GtkAllocation _tmp7_ = {0};
				gboolean _tmp8_ = FALSE;
				gboolean _tmp9_ = FALSE;
				MidoriTally* _tmp10_;
				gboolean _tmp11_;
#line 302 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp2_ = self->notebook;
#line 302 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp3_ = self->priv->_tab;
#line 302 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp4_ = gtk_notebook_get_tab_label (_tmp2_, (GtkWidget*) _tmp3_);
#line 302 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp5_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp4_, MIDORI_TYPE_TALLY) ? ((MidoriTally*) _tmp4_) : NULL);
#line 302 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				tally = _tmp5_;
#line 304 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp6_ = tally;
#line 304 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				gtk_widget_get_allocation ((GtkWidget*) _tmp6_, &_tmp7_);
#line 304 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				size = _tmp7_;
#line 305 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp10_ = tally;
#line 305 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp11_ = gtk_widget_get_mapped ((GtkWidget*) _tmp10_);
#line 305 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				if (_tmp11_) {
#line 2117 "midori-notebook.c"
					GdkEventButton _tmp12_;
					gdouble _tmp13_;
					GtkAllocation _tmp14_;
					gint _tmp15_;
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp12_ = *event;
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp13_ = _tmp12_.x_root;
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp14_ = size;
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp15_ = _tmp14_.x;
#line 306 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp9_ = _tmp13_ >= ((gdouble) _tmp15_);
#line 2132 "midori-notebook.c"
				} else {
#line 305 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp9_ = FALSE;
#line 2136 "midori-notebook.c"
				}
#line 305 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				if (_tmp9_) {
#line 2140 "midori-notebook.c"
					GdkEventButton _tmp16_;
					gdouble _tmp17_;
					GtkAllocation _tmp18_;
					gint _tmp19_;
					GtkAllocation _tmp20_;
					gint _tmp21_;
#line 307 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp16_ = *event;
#line 307 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp17_ = _tmp16_.x_root;
#line 307 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp18_ = size;
#line 307 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp19_ = _tmp18_.x;
#line 307 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp20_ = size;
#line 307 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp21_ = _tmp20_.width;
#line 307 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp8_ = _tmp17_ <= ((gdouble) (_tmp19_ + _tmp21_));
#line 2161 "midori-notebook.c"
				} else {
#line 305 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp8_ = FALSE;
#line 2165 "midori-notebook.c"
				}
#line 305 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				if (_tmp8_) {
#line 2169 "midori-notebook.c"
					MidoriTally* _tmp22_;
					GdkEventButton _tmp23_;
					gboolean _tmp24_ = FALSE;
#line 308 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp22_ = tally;
#line 308 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp23_ = *event;
#line 308 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					g_signal_emit_by_name ((GtkWidget*) _tmp22_, "button-press-event", &_tmp23_, &_tmp24_);
#line 309 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					result = TRUE;
#line 309 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_g_object_unref0 (tally);
#line 309 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_g_list_free0 (child_collection);
#line 309 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					return result;
#line 2187 "midori-notebook.c"
				}
#line 301 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_g_object_unref0 (tally);
#line 2191 "midori-notebook.c"
			}
		}
#line 301 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_list_free0 (child_collection);
#line 2196 "midori-notebook.c"
	}
#line 313 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp27_ = *event;
#line 313 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp28_ = _tmp27_.type;
#line 313 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp28_ == GDK_2BUTTON_PRESS) {
#line 2204 "midori-notebook.c"
		GdkEventButton _tmp29_;
		guint _tmp30_;
#line 313 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp29_ = *event;
#line 313 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp30_ = _tmp29_.button;
#line 313 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp26_ = _tmp30_ == ((guint) 1);
#line 2213 "midori-notebook.c"
	} else {
#line 313 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp26_ = FALSE;
#line 2217 "midori-notebook.c"
	}
#line 313 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp26_) {
#line 313 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp25_ = TRUE;
#line 2223 "midori-notebook.c"
	} else {
		GdkEventButton _tmp31_;
		guint _tmp32_;
#line 314 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp31_ = *event;
#line 314 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp32_ = _tmp31_.button;
#line 314 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp25_ = _tmp32_ == ((guint) 2);
#line 2233 "midori-notebook.c"
	}
#line 313 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp25_) {
#line 315 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_signal_emit (self, midori_notebook_signals[MIDORI_NOTEBOOK_NEW_TAB_SIGNAL], 0);
#line 316 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		result = TRUE;
#line 316 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		return result;
#line 2243 "midori-notebook.c"
	} else {
		GdkEventButton _tmp33_;
		guint _tmp34_;
#line 318 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp33_ = *event;
#line 318 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp34_ = _tmp33_.button;
#line 318 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		if (_tmp34_ == ((guint) 3)) {
#line 2253 "midori-notebook.c"
			MidoriContextAction* menu = NULL;
			MidoriContextAction* _tmp35_;
			GtkMenu* popup = NULL;
			MidoriContextAction* _tmp36_;
			GtkMenu* _tmp37_;
			GtkMenu* _tmp38_;
			GtkMenu* _tmp39_;
			GtkMenu* _tmp40_;
			GdkEventButton _tmp41_;
			guint _tmp42_;
			GdkEventButton _tmp43_;
			guint32 _tmp44_;
#line 319 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp35_ = midori_notebook_get_context_action (self);
#line 319 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			menu = _tmp35_;
#line 320 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp36_ = menu;
#line 320 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp37_ = midori_context_action_create_menu (_tmp36_, NULL, FALSE);
#line 320 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			popup = _tmp37_;
#line 321 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp38_ = popup;
#line 321 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			gtk_widget_show ((GtkWidget*) _tmp38_);
#line 322 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp39_ = popup;
#line 322 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			gtk_menu_attach_to_widget (_tmp39_, (GtkWidget*) self, NULL);
#line 323 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp40_ = popup;
#line 323 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp41_ = *event;
#line 323 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp42_ = _tmp41_.button;
#line 323 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp43_ = *event;
#line 323 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp44_ = _tmp43_.time;
#line 323 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			gtk_menu_popup (_tmp40_, NULL, NULL, NULL, NULL, _tmp42_, _tmp44_);
#line 324 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			result = TRUE;
#line 324 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_g_object_unref0 (popup);
#line 324 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_g_object_unref0 (menu);
#line 324 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			return result;
#line 2304 "midori-notebook.c"
		}
	}
#line 326 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = FALSE;
#line 326 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 2311 "midori-notebook.c"
}


static gboolean _midori_notebook_tab_button_pressed_gtk_widget_button_press_event (GtkWidget* _sender, GdkEventButton* event, gpointer self) {
	gboolean result;
	result = midori_notebook_tab_button_pressed ((MidoriNotebook*) self, _sender, event);
#line 333 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 2320 "midori-notebook.c"
}


static void _midori_notebook_tab_removed_gtk_object_destroy (GtkObject* _sender, gpointer self) {
#line 343 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_tab_removed ((MidoriNotebook*) self);
#line 2327 "midori-notebook.c"
}


static void _midori_notebook_tab_minimized_g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 344 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_tab_minimized ((MidoriNotebook*) self, pspec);
#line 2334 "midori-notebook.c"
}


void midori_notebook_insert (MidoriNotebook* self, MidoriTab* tab, gint index) {
	MidoriTally* tally = NULL;
	MidoriTab* _tmp0_;
	MidoriTally* _tmp1_;
	MidoriTally* _tmp2_;
	gboolean _tmp3_;
	MidoriTally* _tmp4_;
	gboolean _tmp5_;
	MidoriTally* _tmp6_;
	MidoriTally* _tmp7_;
	gint _tmp8_ = 0;
	MidoriTab* _tmp9_;
	gboolean _tmp10_;
	gboolean _tmp11_;
	MidoriTally* _tmp13_;
	MidoriTally* _tmp14_;
	MidoriTab* _tmp15_;
	MidoriTab* _tmp16_;
	GtkNotebook* _tmp17_;
	MidoriTab* _tmp18_;
	MidoriTally* _tmp19_;
	gint _tmp20_;
	GtkNotebook* _tmp21_;
	MidoriTab* _tmp22_;
	GtkNotebook* _tmp23_;
	MidoriTab* _tmp24_;
	MidoriTab* _tmp25_;
	MidoriTab* _tmp26_;
	guint _tmp27_;
	MidoriTab* _tmp28_;
#line 329 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 329 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (tab != NULL);
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = tab;
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = midori_tally_new (_tmp0_);
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref_sink (_tmp1_);
#line 330 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	tally = _tmp1_;
#line 331 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = tally;
#line 331 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = self->priv->_close_buttons_left;
#line 331 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_set_close_button_left (_tmp2_, _tmp3_);
#line 332 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = tally;
#line 332 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp5_ = self->priv->_close_buttons_visible;
#line 332 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tally_set_close_button_visible (_tmp4_, _tmp5_);
#line 333 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp6_ = tally;
#line 333 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GtkWidget*) _tmp6_, "button-press-event", (GCallback) _midori_notebook_tab_button_pressed_gtk_widget_button_press_event, self, 0);
#line 334 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = tally;
#line 334 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_show ((GtkWidget*) _tmp7_);
#line 335 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp9_ = tab;
#line 335 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp10_ = midori_tab_get_minimized (_tmp9_);
#line 335 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp11_ = _tmp10_;
#line 335 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp11_) {
#line 335 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp8_ = -1;
#line 2410 "midori-notebook.c"
	} else {
		gint _tmp12_;
#line 335 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp12_ = self->priv->last_tab_size;
#line 335 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp8_ = _tmp12_;
#line 2417 "midori-notebook.c"
	}
#line 335 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp13_ = tally;
#line 335 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_size_request ((GtkWidget*) _tmp13_, _tmp8_, -1);
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp14_ = tally;
#line 336 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_take_incoming_uris (self, (GtkWidget*) _tmp14_);
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp15_ = tab;
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp16_ = tab;
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_visible ((GtkWidget*) _tmp16_, TRUE);
#line 339 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_set ((GtkWidget*) _tmp15_, "can-focus", TRUE, NULL);
#line 340 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp17_ = self->notebook;
#line 340 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp18_ = tab;
#line 340 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp19_ = tally;
#line 340 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp20_ = index;
#line 340 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_notebook_insert_page (_tmp17_, (GtkWidget*) _tmp18_, (GtkWidget*) _tmp19_, _tmp20_);
#line 341 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp21_ = self->notebook;
#line 341 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp22_ = tab;
#line 341 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_notebook_set_tab_reorderable (_tmp21_, (GtkWidget*) _tmp22_, TRUE);
#line 342 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp23_ = self->notebook;
#line 342 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp24_ = tab;
#line 342 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_notebook_set_tab_detachable (_tmp23_, (GtkWidget*) _tmp24_, TRUE);
#line 343 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp25_ = tab;
#line 343 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GtkObject*) _tmp25_, "destroy", (GCallback) _midori_notebook_tab_removed_gtk_object_destroy, self, 0);
#line 344 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp26_ = tab;
#line 344 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) _tmp26_, "notify::minimized", (GCallback) _midori_notebook_tab_minimized_g_object_notify, self, 0);
#line 345 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp27_ = self->priv->_count;
#line 345 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_set_count (self, _tmp27_ + 1);
#line 346 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp28_ = tab;
#line 346 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_ref ((GObject*) _tmp28_);
#line 347 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_relayout (self);
#line 329 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (tally);
#line 2477 "midori-notebook.c"
}


static void midori_notebook_tab_removed (MidoriNotebook* self) {
	guint _tmp0_;
	guint _tmp1_;
#line 350 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 351 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_count;
#line 351 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_set_count (self, _tmp0_ - 1);
#line 352 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->priv->_count;
#line 352 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp1_ > ((guint) 0)) {
#line 353 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		midori_notebook_relayout (self);
#line 2496 "midori-notebook.c"
	}
}


static void midori_notebook_relayout (MidoriNotebook* self) {
	GtkAllocation size = {0};
	GtkNotebook* _tmp0_;
	GtkAllocation _tmp1_ = {0};
	GtkAllocation _tmp2_;
	gint _tmp3_;
#line 356 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 358 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 358 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_get_allocation ((GtkWidget*) _tmp0_, &_tmp1_);
#line 358 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	size = _tmp1_;
#line 359 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = size;
#line 359 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = _tmp2_.width;
#line 359 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_resize (self, _tmp3_);
#line 2521 "midori-notebook.c"
}


static Block6Data* block6_data_ref (Block6Data* _data6_) {
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_atomic_int_inc (&_data6_->_ref_count_);
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return _data6_;
#line 2530 "midori-notebook.c"
}


static void block6_data_unref (void * _userdata_) {
	Block6Data* _data6_;
	_data6_ = (Block6Data*) _userdata_;
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (g_atomic_int_dec_and_test (&_data6_->_ref_count_)) {
#line 2539 "midori-notebook.c"
		MidoriNotebook* self;
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		self = _data6_->self;
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_object_unref0 (_data6_->tab);
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_object_unref0 (self);
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_slice_free (Block6Data, _data6_);
#line 2549 "midori-notebook.c"
	}
}


static void __lambda16_ (Block6Data* _data6_) {
	MidoriNotebook* self;
	MidoriTab* _tmp0_;
#line 367 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = _data6_->self;
#line 368 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = _data6_->tab;
#line 368 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_emit (self, midori_notebook_signals[MIDORI_NOTEBOOK_TAB_DETACHED_SIGNAL], 0, _tmp0_, 128, 128);
#line 2563 "midori-notebook.c"
}


static void ___lambda16__gtk_action_activate (GtkAction* _sender, gpointer self) {
#line 367 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	__lambda16_ (self);
#line 2570 "midori-notebook.c"
}


static void __lambda17_ (Block6Data* _data6_) {
	MidoriNotebook* self;
	MidoriTab* _tmp0_;
	MidoriTab* _tmp1_;
	gboolean _tmp2_;
	gboolean _tmp3_;
#line 372 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = _data6_->self;
#line 373 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = _data6_->tab;
#line 373 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = _data6_->tab;
#line 373 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = midori_tab_get_minimized (_tmp1_);
#line 373 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = _tmp2_;
#line 373 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_tab_set_minimized (_tmp0_, !_tmp3_);
#line 2592 "midori-notebook.c"
}


static void ___lambda17__gtk_action_activate (GtkAction* _sender, gpointer self) {
#line 372 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	__lambda17_ (self);
#line 2599 "midori-notebook.c"
}


static void __lambda18_ (Block6Data* _data6_) {
	MidoriNotebook* self;
	gboolean found_tab = FALSE;
	GtkNotebook* _tmp0_;
	GList* _tmp1_;
#line 378 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = _data6_->self;
#line 379 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	found_tab = FALSE;
#line 380 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 380 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = gtk_container_get_children ((GtkContainer*) _tmp0_);
#line 2616 "midori-notebook.c"
	{
		GList* child_collection = NULL;
		GList* child_it = NULL;
#line 380 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		child_collection = _tmp1_;
#line 380 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		for (child_it = child_collection; child_it != NULL; child_it = child_it->next) {
#line 2624 "midori-notebook.c"
			GtkWidget* child = NULL;
#line 380 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			child = (GtkWidget*) child_it->data;
#line 2628 "midori-notebook.c"
			{
				gboolean _tmp2_;
#line 381 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp2_ = found_tab;
#line 381 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				if (_tmp2_) {
#line 2635 "midori-notebook.c"
					GtkWidget* _tmp3_;
#line 382 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp3_ = child;
#line 382 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					gtk_object_destroy ((GtkObject*) _tmp3_);
#line 2641 "midori-notebook.c"
				} else {
					GtkWidget* _tmp4_;
					MidoriTab* _tmp5_;
#line 384 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp4_ = child;
#line 384 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp5_ = _data6_->tab;
#line 384 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					found_tab = _tmp4_ == G_TYPE_CHECK_INSTANCE_CAST (_tmp5_, GTK_TYPE_WIDGET, GtkWidget);
#line 2651 "midori-notebook.c"
				}
			}
		}
#line 380 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_list_free0 (child_collection);
#line 2657 "midori-notebook.c"
	}
}


static void ___lambda18__gtk_action_activate (GtkAction* _sender, gpointer self) {
#line 378 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	__lambda18_ (self);
#line 2665 "midori-notebook.c"
}


static void __lambda19_ (Block6Data* _data6_) {
	MidoriNotebook* self;
	GtkNotebook* _tmp0_;
	GList* _tmp1_;
#line 390 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = _data6_->self;
#line 391 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 391 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = gtk_container_get_children ((GtkContainer*) _tmp0_);
#line 2679 "midori-notebook.c"
	{
		GList* child_collection = NULL;
		GList* child_it = NULL;
#line 391 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		child_collection = _tmp1_;
#line 391 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		for (child_it = child_collection; child_it != NULL; child_it = child_it->next) {
#line 2687 "midori-notebook.c"
			GtkWidget* child = NULL;
#line 391 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			child = (GtkWidget*) child_it->data;
#line 2691 "midori-notebook.c"
			{
				GtkWidget* _tmp2_;
				MidoriTab* _tmp3_;
#line 392 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp2_ = child;
#line 392 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp3_ = _data6_->tab;
#line 392 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				if (_tmp2_ != G_TYPE_CHECK_INSTANCE_CAST (_tmp3_, GTK_TYPE_WIDGET, GtkWidget)) {
#line 2701 "midori-notebook.c"
					GtkWidget* _tmp4_;
#line 393 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp4_ = child;
#line 393 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					gtk_object_destroy ((GtkObject*) _tmp4_);
#line 2707 "midori-notebook.c"
				}
			}
		}
#line 391 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_list_free0 (child_collection);
#line 2713 "midori-notebook.c"
	}
}


static void ___lambda19__gtk_action_activate (GtkAction* _sender, gpointer self) {
#line 390 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	__lambda19_ (self);
#line 2721 "midori-notebook.c"
}


static void __lambda20_ (Block6Data* _data6_) {
	MidoriNotebook* self;
	MidoriTab* _tmp0_;
#line 397 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = _data6_->self;
#line 398 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = _data6_->tab;
#line 398 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_object_destroy ((GtkObject*) _tmp0_);
#line 2734 "midori-notebook.c"
}


static void ___lambda20__gtk_action_activate (GtkAction* _sender, gpointer self) {
#line 397 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	__lambda20_ (self);
#line 2741 "midori-notebook.c"
}


MidoriContextAction* midori_notebook_get_tab_context_action (MidoriNotebook* self, MidoriTab* tab) {
	MidoriContextAction* result = NULL;
	Block6Data* _data6_;
	MidoriTab* _tmp0_;
	MidoriTab* _tmp1_;
	MidoriContextAction* menu = NULL;
	MidoriContextAction* _tmp2_;
	MidoriTab* _tmp3_;
	MidoriContextAction* _tmp4_;
	MidoriContextAction* action_window = NULL;
	MidoriContextAction* _tmp5_;
	MidoriContextAction* _tmp6_;
	MidoriContextAction* _tmp7_;
	MidoriContextAction* _tmp8_;
	const gchar* _tmp9_ = NULL;
	MidoriTab* _tmp10_;
	gboolean _tmp11_;
	gboolean _tmp12_;
	MidoriContextAction* action_minimize = NULL;
	MidoriContextAction* _tmp13_;
	MidoriContextAction* _tmp14_;
	MidoriContextAction* action_right = NULL;
	guint _tmp15_;
	MidoriContextAction* _tmp16_;
	guint _tmp17_;
	MidoriContextAction* _tmp18_;
	MidoriContextAction* action_other = NULL;
	guint _tmp19_;
	MidoriContextAction* _tmp20_;
	guint _tmp21_;
	MidoriContextAction* _tmp22_;
	MidoriContextAction* action_close = NULL;
	MidoriContextAction* _tmp23_;
	MidoriContextAction* _tmp24_;
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (tab != NULL, NULL);
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_data6_ = g_slice_new0 (Block6Data);
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_data6_->_ref_count_ = 1;
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_data6_->self = g_object_ref (self);
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = tab;
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (_data6_->tab);
#line 363 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_data6_->tab = _tmp1_;
#line 364 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = midori_context_action_new ("TabContextMenu", NULL, NULL, NULL);
#line 364 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	menu = _tmp2_;
#line 365 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = _data6_->tab;
#line 365 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = menu;
#line 365 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_emit (self, midori_notebook_signals[MIDORI_NOTEBOOK_TAB_CONTEXT_MENU_SIGNAL], 0, _tmp3_, _tmp4_);
#line 366 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp5_ = midori_context_action_new ("TabWindowNew", _ ("Open in New _Window"), NULL, "window-new");
#line 366 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	action_window = _tmp5_;
#line 367 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp6_ = action_window;
#line 367 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_data ((GtkAction*) _tmp6_, "activate", (GCallback) ___lambda16__gtk_action_activate, block6_data_ref (_data6_), (GClosureNotify) block6_data_unref, 0);
#line 370 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = menu;
#line 370 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp8_ = action_window;
#line 370 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_context_action_add (_tmp7_, (GtkAction*) _tmp8_);
#line 371 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp10_ = _data6_->tab;
#line 371 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp11_ = midori_tab_get_minimized (_tmp10_);
#line 371 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp12_ = _tmp11_;
#line 371 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp12_) {
#line 371 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp9_ = _ ("Show Tab _Label");
#line 2831 "midori-notebook.c"
	} else {
#line 371 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp9_ = _ ("Show Tab _Icon Only");
#line 2835 "midori-notebook.c"
	}
#line 371 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp13_ = midori_context_action_new ("TabMinimize", _tmp9_, NULL, NULL);
#line 371 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	action_minimize = _tmp13_;
#line 372 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_data ((GtkAction*) action_minimize, "activate", (GCallback) ___lambda17__gtk_action_activate, block6_data_ref (_data6_), (GClosureNotify) block6_data_unref, 0);
#line 375 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp14_ = menu;
#line 375 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_context_action_add (_tmp14_, (GtkAction*) action_minimize);
#line 376 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp15_ = self->priv->_count;
#line 376 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp16_ = midori_context_action_new ("TabCloseRight", ngettext ("Close Tab to the R_ight", "Close Tabs to the R_ight", (gulong) (_tmp15_ - 1)), NULL, NULL);
#line 376 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	action_right = _tmp16_;
#line 377 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp17_ = self->priv->_count;
#line 377 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_action_set_sensitive ((GtkAction*) action_right, _tmp17_ > ((guint) 1));
#line 378 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_data ((GtkAction*) action_right, "activate", (GCallback) ___lambda18__gtk_action_activate, block6_data_ref (_data6_), (GClosureNotify) block6_data_unref, 0);
#line 387 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp18_ = menu;
#line 387 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_context_action_add (_tmp18_, (GtkAction*) action_right);
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp19_ = self->priv->_count;
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp20_ = midori_context_action_new ("TabCloseOther", ngettext ("Close Ot_her Tab", "Close Ot_her Tabs", (gulong) (_tmp19_ - 1)), NULL, NULL);
#line 388 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	action_other = _tmp20_;
#line 389 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp21_ = self->priv->_count;
#line 389 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_action_set_sensitive ((GtkAction*) action_other, _tmp21_ > ((guint) 1));
#line 390 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_data ((GtkAction*) action_other, "activate", (GCallback) ___lambda19__gtk_action_activate, block6_data_ref (_data6_), (GClosureNotify) block6_data_unref, 0);
#line 395 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp22_ = menu;
#line 395 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_context_action_add (_tmp22_, (GtkAction*) action_other);
#line 396 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp23_ = midori_context_action_new ("TabClose", NULL, NULL, GTK_STOCK_CLOSE);
#line 396 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	action_close = _tmp23_;
#line 397 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_data ((GtkAction*) action_close, "activate", (GCallback) ___lambda20__gtk_action_activate, block6_data_ref (_data6_), (GClosureNotify) block6_data_unref, 0);
#line 400 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp24_ = menu;
#line 400 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_context_action_add (_tmp24_, (GtkAction*) action_close);
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = menu;
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (action_close);
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (action_other);
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (action_right);
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (action_minimize);
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (action_window);
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	block6_data_unref (_data6_);
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_data6_ = NULL;
#line 401 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 2907 "midori-notebook.c"
}


static gboolean midori_notebook_tab_button_pressed (MidoriNotebook* self, GtkWidget* label, GdkEventButton* event) {
	gboolean result = FALSE;
	MidoriTally* tally = NULL;
	GtkWidget* _tmp0_;
	MidoriTally* _tmp1_;
	GdkEventButton _tmp2_;
	guint _tmp3_;
#line 404 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 404 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (label != NULL, FALSE);
#line 404 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (event != NULL, FALSE);
#line 405 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = label;
#line 405 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp0_, MIDORI_TYPE_TALLY) ? ((MidoriTally*) _tmp0_) : NULL);
#line 405 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	tally = _tmp1_;
#line 406 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = *event;
#line 406 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = _tmp2_.button;
#line 406 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp3_ == ((guint) 1)) {
#line 408 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		result = FALSE;
#line 408 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_object_unref0 (tally);
#line 408 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		return result;
#line 2942 "midori-notebook.c"
	} else {
		GdkEventButton _tmp4_;
		guint _tmp5_;
#line 409 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp4_ = *event;
#line 409 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp5_ = _tmp4_.button;
#line 409 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		if (_tmp5_ == ((guint) 2)) {
#line 2952 "midori-notebook.c"
			MidoriTally* _tmp6_;
			MidoriTab* _tmp7_;
			MidoriTab* _tmp8_;
#line 410 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp6_ = tally;
#line 410 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp7_ = midori_tally_get_tab (_tmp6_);
#line 410 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp8_ = _tmp7_;
#line 410 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			gtk_object_destroy ((GtkObject*) _tmp8_);
#line 2964 "midori-notebook.c"
		} else {
			GdkEventButton _tmp9_;
			guint _tmp10_;
#line 411 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp9_ = *event;
#line 411 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			_tmp10_ = _tmp9_.button;
#line 411 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			if (_tmp10_ == ((guint) 3)) {
#line 2974 "midori-notebook.c"
				MidoriContextAction* menu = NULL;
				MidoriTally* _tmp11_;
				MidoriTab* _tmp12_;
				MidoriTab* _tmp13_;
				MidoriContextAction* _tmp14_;
				GtkMenu* popup = NULL;
				MidoriContextAction* _tmp15_;
				GtkMenu* _tmp16_;
				GtkMenu* _tmp17_;
				GtkMenu* _tmp18_;
				GtkMenu* _tmp19_;
				GdkEventButton _tmp20_;
				guint _tmp21_;
				GdkEventButton _tmp22_;
				guint32 _tmp23_;
#line 412 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp11_ = tally;
#line 412 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp12_ = midori_tally_get_tab (_tmp11_);
#line 412 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp13_ = _tmp12_;
#line 412 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp14_ = midori_notebook_get_tab_context_action (self, _tmp13_);
#line 412 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				menu = _tmp14_;
#line 413 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp15_ = menu;
#line 413 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp16_ = midori_context_action_create_menu (_tmp15_, NULL, FALSE);
#line 413 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				popup = _tmp16_;
#line 414 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp17_ = popup;
#line 414 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				gtk_widget_show ((GtkWidget*) _tmp17_);
#line 415 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp18_ = popup;
#line 415 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				gtk_menu_attach_to_widget (_tmp18_, (GtkWidget*) self, NULL);
#line 416 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp19_ = popup;
#line 416 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp20_ = *event;
#line 416 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp21_ = _tmp20_.button;
#line 416 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp22_ = *event;
#line 416 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp23_ = _tmp22_.time;
#line 416 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				gtk_menu_popup (_tmp19_, NULL, NULL, NULL, NULL, _tmp21_, _tmp23_);
#line 411 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_g_object_unref0 (popup);
#line 411 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_g_object_unref0 (menu);
#line 3030 "midori-notebook.c"
			}
		}
	}
#line 418 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = TRUE;
#line 418 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (tally);
#line 418 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 3040 "midori-notebook.c"
}


void midori_notebook_move (MidoriNotebook* self, MidoriTab* tab, gint index) {
	GtkNotebook* _tmp0_;
	MidoriTab* _tmp1_;
	gint _tmp2_;
#line 421 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 421 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (tab != NULL);
#line 422 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 422 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = tab;
#line 422 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = index;
#line 422 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_notebook_reorder_child (_tmp0_, (GtkWidget*) _tmp1_, _tmp2_);
#line 3060 "midori-notebook.c"
}


static gboolean midori_notebook_real_expose_event (GtkWidget* base, GdkEventExpose* event) {
	MidoriNotebook * self;
	gboolean result = FALSE;
	GtkNotebook* _tmp0_;
	GdkEventExpose _tmp1_;
	gboolean _tmp2_ = FALSE;
#line 432 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = (MidoriNotebook*) base;
#line 432 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (event != NULL, FALSE);
#line 433 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 433 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = *event;
#line 433 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_emit_by_name ((GtkWidget*) _tmp0_, "expose-event", &_tmp1_, &_tmp2_);
#line 434 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = TRUE;
#line 434 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 3084 "midori-notebook.c"
}


static void midori_notebook_real_forall_internal (GtkContainer* base, gboolean include_internal, GtkCallback callback, void* callback_target) {
	MidoriNotebook * self;
	gboolean _tmp0_;
	GtkNotebook* _tmp3_;
	GList* _tmp4_;
#line 438 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = (MidoriNotebook*) base;
#line 439 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = include_internal;
#line 439 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp0_) {
#line 3099 "midori-notebook.c"
		GtkCallback _tmp1_;
		void* _tmp1__target;
		GtkNotebook* _tmp2_;
#line 440 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp1_ = callback;
#line 440 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp1__target = callback_target;
#line 440 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp2_ = self->notebook;
#line 440 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp1_ ((GtkWidget*) _tmp2_, _tmp1__target);
#line 3111 "midori-notebook.c"
	}
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = self->notebook;
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = gtk_container_get_children ((GtkContainer*) _tmp3_);
#line 3117 "midori-notebook.c"
	{
		GList* child_collection = NULL;
		GList* child_it = NULL;
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		child_collection = _tmp4_;
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		for (child_it = child_collection; child_it != NULL; child_it = child_it->next) {
#line 3125 "midori-notebook.c"
			GtkWidget* child = NULL;
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			child = (GtkWidget*) child_it->data;
#line 3129 "midori-notebook.c"
			{
				GtkCallback _tmp5_;
				void* _tmp5__target;
				GtkWidget* _tmp6_;
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp5_ = callback;
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp5__target = callback_target;
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp6_ = child;
#line 442 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp5_ (_tmp6_, _tmp5__target);
#line 3142 "midori-notebook.c"
			}
		}
#line 441 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_list_free0 (child_collection);
#line 3147 "midori-notebook.c"
	}
}


void midori_notebook_remove (MidoriNotebook* self, MidoriTab* tab) {
	GtkNotebook* _tmp0_;
	GList* _tmp1_;
	GList* _tmp2_;
	MidoriTab* _tmp3_;
	GList* _tmp4_;
	GtkNotebook* _tmp5_;
	MidoriTab* _tmp6_;
	MidoriTab* _tmp7_;
	guint _tmp8_;
	MidoriTab* _tmp9_;
	guint _tmp10_;
	GQuark _tmp11_;
	MidoriTab* _tmp12_;
#line 446 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 446 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (tab != NULL);
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = gtk_container_get_children ((GtkContainer*) _tmp0_);
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = _tmp1_;
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = tab;
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = g_list_find (_tmp2_, (GtkWidget*) _tmp3_);
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (_tmp4_ != NULL);
#line 447 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_list_free0 (_tmp2_);
#line 449 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp5_ = self->notebook;
#line 449 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp6_ = tab;
#line 449 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_container_remove ((GtkContainer*) _tmp5_, (GtkWidget*) _tmp6_);
#line 450 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = tab;
#line 450 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_parse_name ("destroy", GTK_TYPE_OBJECT, &_tmp8_, NULL, FALSE);
#line 450 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_handlers_disconnect_matched ((GtkObject*) _tmp7_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp8_, 0, NULL, (GCallback) _midori_notebook_tab_removed_gtk_object_destroy, self);
#line 451 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp9_ = tab;
#line 451 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_parse_name ("notify::minimized", G_TYPE_OBJECT, &_tmp10_, &_tmp11_, TRUE);
#line 451 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_handlers_disconnect_matched ((GObject*) _tmp9_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_DETAIL | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp10_, _tmp11_, NULL, (GCallback) _midori_notebook_tab_minimized_g_object_notify, self);
#line 452 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_tab_removed (self);
#line 453 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp12_ = tab;
#line 453 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_unref ((GObject*) _tmp12_);
#line 3208 "midori-notebook.c"
}


static void midori_notebook_tab_minimized (MidoriNotebook* self, GParamSpec* pspec) {
	MidoriTally* tally = NULL;
	GtkNotebook* _tmp0_;
	MidoriTab* _tmp1_;
	GtkWidget* _tmp2_;
	MidoriTally* _tmp3_;
	gint _tmp4_ = 0;
	MidoriTab* _tmp5_;
	gboolean _tmp6_;
	gboolean _tmp7_;
	MidoriTally* _tmp9_;
#line 456 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 456 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 457 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 457 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->priv->_tab;
#line 457 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = gtk_notebook_get_tab_label (_tmp0_, (GtkWidget*) _tmp1_);
#line 457 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp2_, MIDORI_TYPE_TALLY) ? ((MidoriTally*) _tmp2_) : NULL);
#line 457 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	tally = _tmp3_;
#line 458 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp5_ = self->priv->_tab;
#line 458 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp6_ = midori_tab_get_minimized (_tmp5_);
#line 458 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = _tmp6_;
#line 458 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp7_) {
#line 458 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp4_ = -1;
#line 3247 "midori-notebook.c"
	} else {
		gint _tmp8_;
#line 458 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp8_ = self->priv->last_tab_size;
#line 458 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp4_ = _tmp8_;
#line 3254 "midori-notebook.c"
	}
#line 458 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp9_ = tally;
#line 458 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_widget_set_size_request ((GtkWidget*) _tmp9_, _tmp4_, -1);
#line 456 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (tally);
#line 3262 "midori-notebook.c"
}


MidoriTab* midori_notebook_get_nth_tab (MidoriNotebook* self, gint index) {
	MidoriTab* result = NULL;
	GtkNotebook* _tmp0_;
	gint _tmp1_;
	GtkWidget* _tmp2_;
	MidoriTab* _tmp3_;
#line 461 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 462 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 462 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = index;
#line 462 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = gtk_notebook_get_nth_page (_tmp0_, _tmp1_);
#line 462 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp2_, MIDORI_TYPE_TAB) ? ((MidoriTab*) _tmp2_) : NULL);
#line 462 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp3_;
#line 462 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 3286 "midori-notebook.c"
}


gint midori_notebook_get_tab_index (MidoriNotebook* self, MidoriTab* tab) {
	gint result = 0;
	GtkNotebook* _tmp0_;
	MidoriTab* _tmp1_;
	gint _tmp2_;
#line 465 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, 0);
#line 465 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (tab != NULL, 0);
#line 466 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 466 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = tab;
#line 466 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = gtk_notebook_page_num (_tmp0_, (GtkWidget*) _tmp1_);
#line 466 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp2_;
#line 466 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 3309 "midori-notebook.c"
}


static void midori_notebook_index_changed (MidoriNotebook* self, GParamSpec* pspec) {
	GtkNotebook* _tmp0_;
	gint _tmp1_;
#line 469 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 469 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 470 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 470 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->priv->_index;
#line 470 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_notebook_set_current_page (_tmp0_, _tmp1_);
#line 3326 "midori-notebook.c"
}


static void midori_notebook_tab_changed (MidoriNotebook* self, GParamSpec* pspec) {
	GtkNotebook* _tmp0_;
	GtkNotebook* _tmp1_;
	MidoriTab* _tmp2_;
	gint _tmp3_;
#line 473 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 473 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 474 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 474 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->notebook;
#line 474 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = self->priv->_tab;
#line 474 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = gtk_notebook_page_num (_tmp1_, (GtkWidget*) _tmp2_);
#line 474 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_notebook_set_current_page (_tmp0_, _tmp3_);
#line 3349 "midori-notebook.c"
}


static void midori_notebook_labels_visible_changed (MidoriNotebook* self, GParamSpec* pspec) {
	GtkNotebook* _tmp0_;
	gboolean _tmp1_;
#line 477 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 477 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 478 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 478 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->priv->_labels_visible;
#line 478 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_notebook_set_show_tabs (_tmp0_, _tmp1_);
#line 3366 "midori-notebook.c"
}


static void midori_notebook_close_buttons_visible_changed (MidoriNotebook* self, GParamSpec* pspec) {
	GtkNotebook* _tmp0_;
	GList* _tmp1_;
#line 481 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 481 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = gtk_container_get_children ((GtkContainer*) _tmp0_);
#line 3381 "midori-notebook.c"
	{
		GList* child_collection = NULL;
		GList* child_it = NULL;
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		child_collection = _tmp1_;
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		for (child_it = child_collection; child_it != NULL; child_it = child_it->next) {
#line 3389 "midori-notebook.c"
			GtkWidget* child = NULL;
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			child = (GtkWidget*) child_it->data;
#line 3393 "midori-notebook.c"
			{
				MidoriTally* tally = NULL;
				GtkNotebook* _tmp2_;
				GtkWidget* _tmp3_;
				GtkWidget* _tmp4_;
				MidoriTally* _tmp5_;
				MidoriTally* _tmp6_;
				gboolean _tmp7_;
#line 483 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp2_ = self->notebook;
#line 483 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp3_ = child;
#line 483 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp4_ = gtk_notebook_get_tab_label (_tmp2_, _tmp3_);
#line 483 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp5_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp4_, MIDORI_TYPE_TALLY) ? ((MidoriTally*) _tmp4_) : NULL);
#line 483 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				tally = _tmp5_;
#line 484 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp6_ = tally;
#line 484 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp7_ = self->priv->_close_buttons_visible;
#line 484 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				midori_tally_set_close_button_visible (_tmp6_, _tmp7_);
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_g_object_unref0 (tally);
#line 3420 "midori-notebook.c"
			}
		}
#line 482 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_list_free0 (child_collection);
#line 3425 "midori-notebook.c"
	}
}


static void midori_notebook_close_buttons_left_changed (MidoriNotebook* self, GParamSpec* pspec) {
	GtkNotebook* _tmp0_;
	GList* _tmp1_;
#line 488 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 488 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (pspec != NULL);
#line 489 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 489 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = gtk_container_get_children ((GtkContainer*) _tmp0_);
#line 3441 "midori-notebook.c"
	{
		GList* child_collection = NULL;
		GList* child_it = NULL;
#line 489 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		child_collection = _tmp1_;
#line 489 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		for (child_it = child_collection; child_it != NULL; child_it = child_it->next) {
#line 3449 "midori-notebook.c"
			GtkWidget* child = NULL;
#line 489 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			child = (GtkWidget*) child_it->data;
#line 3453 "midori-notebook.c"
			{
				MidoriTally* tally = NULL;
				GtkNotebook* _tmp2_;
				GtkWidget* _tmp3_;
				GtkWidget* _tmp4_;
				MidoriTally* _tmp5_;
				MidoriTally* _tmp6_;
				gboolean _tmp7_;
#line 490 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp2_ = self->notebook;
#line 490 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp3_ = child;
#line 490 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp4_ = gtk_notebook_get_tab_label (_tmp2_, _tmp3_);
#line 490 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp5_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp4_, MIDORI_TYPE_TALLY) ? ((MidoriTally*) _tmp4_) : NULL);
#line 490 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				tally = _tmp5_;
#line 491 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp6_ = tally;
#line 491 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp7_ = self->priv->_close_buttons_left;
#line 491 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				midori_tally_set_close_button_left (_tmp6_, _tmp7_);
#line 489 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_g_object_unref0 (tally);
#line 3480 "midori-notebook.c"
			}
		}
#line 489 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_list_free0 (child_collection);
#line 3485 "midori-notebook.c"
	}
}


static void midori_notebook_size_allocated (MidoriNotebook* self, GdkRectangle* allocation) {
	gboolean _tmp0_ = FALSE;
	gboolean _tmp1_;
#line 498 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 498 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (allocation != NULL);
#line 500 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = self->priv->_labels_visible;
#line 500 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp1_) {
#line 3501 "midori-notebook.c"
		guint _tmp2_;
#line 500 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp2_ = self->priv->_count;
#line 500 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = _tmp2_ > ((guint) 0);
#line 3507 "midori-notebook.c"
	} else {
#line 500 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = FALSE;
#line 3511 "midori-notebook.c"
	}
#line 500 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp0_) {
#line 3515 "midori-notebook.c"
		GdkRectangle _tmp3_;
		gint _tmp4_;
#line 501 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp3_ = *allocation;
#line 501 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp4_ = _tmp3_.width;
#line 501 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		midori_notebook_resize (self, _tmp4_);
#line 3524 "midori-notebook.c"
	}
}


static void midori_notebook_page_switched (MidoriNotebook* self, GtkNotebookPage* new_tab, guint new_index) {
	MidoriTab* _tmp0_;
	GtkNotebookPage* _tmp1_;
	GtkNotebookPage* _tmp2_;
	guint _tmp3_;
	GQuark _tmp4_;
	guint _tmp5_;
	GQuark _tmp6_;
	guint _tmp7_;
	GtkNotebookPage* _tmp8_;
#line 507 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 507 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (new_tab != NULL);
#line 509 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_previous;
#line 509 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = new_tab;
#line 509 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_emit (self, midori_notebook_signals[MIDORI_NOTEBOOK_TAB_SWITCHED_SIGNAL], 0, _tmp0_, G_TYPE_CHECK_INSTANCE_TYPE (_tmp1_, MIDORI_TYPE_TAB) ? ((MidoriTab*) _tmp1_) : NULL);
#line 510 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = new_tab;
#line 510 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_set_previous (self, G_TYPE_CHECK_INSTANCE_CAST (_tmp2_, MIDORI_TYPE_TAB, MidoriTab));
#line 512 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_parse_name ("notify::index", G_TYPE_OBJECT, &_tmp3_, &_tmp4_, TRUE);
#line 512 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_handlers_disconnect_matched ((GObject*) self, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_DETAIL | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp3_, _tmp4_, NULL, (GCallback) _midori_notebook_index_changed_g_object_notify, self);
#line 513 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_parse_name ("notify::tab", G_TYPE_OBJECT, &_tmp5_, &_tmp6_, TRUE);
#line 513 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_handlers_disconnect_matched ((GObject*) self, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_DETAIL | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp5_, _tmp6_, NULL, (GCallback) _midori_notebook_tab_changed_g_object_notify, self);
#line 514 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = new_index;
#line 514 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_set_index (self, (gint) _tmp7_);
#line 515 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp8_ = new_tab;
#line 515 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_set_tab (self, G_TYPE_CHECK_INSTANCE_CAST (_tmp8_, MIDORI_TYPE_TAB, MidoriTab));
#line 516 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) self, "notify::index", (GCallback) _midori_notebook_index_changed_g_object_notify, self, 0);
#line 517 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) self, "notify::tab", (GCallback) _midori_notebook_tab_changed_g_object_notify, self, 0);
#line 3573 "midori-notebook.c"
}


static void midori_notebook_page_moved (MidoriNotebook* self, GtkWidget* moving_tab, guint new_index) {
	GtkWidget* _tmp0_;
	guint _tmp1_;
	guint _tmp2_;
	GQuark _tmp3_;
	MidoriTab* _tmp4_;
	gint _tmp5_;
#line 520 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 520 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (moving_tab != NULL);
#line 521 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = moving_tab;
#line 521 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = new_index;
#line 521 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_emit (self, midori_notebook_signals[MIDORI_NOTEBOOK_TAB_MOVED_SIGNAL], 0, G_TYPE_CHECK_INSTANCE_TYPE (_tmp0_, MIDORI_TYPE_TAB) ? ((MidoriTab*) _tmp0_) : NULL, _tmp1_);
#line 523 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_parse_name ("notify::index", G_TYPE_OBJECT, &_tmp2_, &_tmp3_, TRUE);
#line 523 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_handlers_disconnect_matched ((GObject*) self, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_DETAIL | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp2_, _tmp3_, NULL, (GCallback) _midori_notebook_index_changed_g_object_notify, self);
#line 524 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = self->priv->_tab;
#line 524 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp5_ = midori_notebook_get_tab_index (self, _tmp4_);
#line 524 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_set_index (self, (gint) _tmp5_);
#line 525 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_connect_object ((GObject*) self, "notify::index", (GCallback) _midori_notebook_index_changed_g_object_notify, self, 0);
#line 3606 "midori-notebook.c"
}


static GtkNotebook* midori_notebook_window_created (MidoriNotebook* self, GtkWidget* tab, gint x, gint y) {
	GtkNotebook* result = NULL;
	GtkWidget* _tmp0_;
	gint _tmp1_;
	gint _tmp2_;
#line 528 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 528 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (tab != NULL, NULL);
#line 529 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = tab;
#line 529 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = x;
#line 529 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = y;
#line 529 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_emit (self, midori_notebook_signals[MIDORI_NOTEBOOK_TAB_DETACHED_SIGNAL], 0, G_TYPE_CHECK_INSTANCE_TYPE (_tmp0_, MIDORI_TYPE_TAB) ? ((MidoriTab*) _tmp0_) : NULL, _tmp1_, _tmp2_);
#line 531 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = G_TYPE_CHECK_INSTANCE_CAST (NULL, GTK_TYPE_NOTEBOOK, GtkNotebook);
#line 531 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 3631 "midori-notebook.c"
}


static void midori_notebook_resize (MidoriNotebook* self, gint new_size) {
	gint n = 0;
	guint _tmp0_;
	gint _tmp1_;
	gint _tmp2_;
	gint _tmp3_;
	gint icon_size = 0;
	GtkSettings* _tmp4_;
	gint _tmp5_ = 0;
	gint max_size = 0;
	gint min_size = 0;
	gint _tmp6_;
	gboolean _tmp7_;
	gint _tmp10_;
	gint _tmp11_;
	gint _tmp12_;
	gint _tmp13_;
	gint _tmp14_;
	gint _tmp15_;
	gint _tmp16_;
	gint _tmp17_;
	GtkNotebook* _tmp18_;
	GList* _tmp19_;
#line 534 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 535 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_count;
#line 535 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = MAX (1, (gint) _tmp0_);
#line 535 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	n = _tmp1_;
#line 536 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = new_size;
#line 536 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp3_ = n;
#line 536 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	new_size = _tmp2_ / _tmp3_;
#line 537 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	icon_size = 16;
#line 538 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = gtk_widget_get_settings ((GtkWidget*) self);
#line 538 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	gtk_icon_size_lookup_for_settings (_tmp4_, GTK_ICON_SIZE_MENU, &_tmp5_, NULL);
#line 538 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	icon_size = _tmp5_;
#line 540 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	max_size = 150;
#line 541 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp6_ = icon_size;
#line 541 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	min_size = _tmp6_;
#line 542 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp7_ = self->priv->_close_buttons_visible;
#line 542 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp7_) {
#line 3690 "midori-notebook.c"
		gint _tmp8_;
		gint _tmp9_;
#line 543 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp8_ = min_size;
#line 543 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp9_ = icon_size;
#line 543 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		min_size = _tmp8_ + _tmp9_;
#line 3699 "midori-notebook.c"
	}
#line 544 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp10_ = new_size;
#line 544 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp11_ = min_size;
#line 544 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp12_ = max_size;
#line 544 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp13_ = CLAMP (_tmp10_, _tmp11_, _tmp12_);
#line 544 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	new_size = _tmp13_;
#line 545 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp14_ = new_size;
#line 545 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp15_ = self->priv->last_tab_size;
#line 545 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp16_ = abs (_tmp14_ - _tmp15_);
#line 545 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (_tmp16_ < 3) {
#line 546 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		return;
#line 3721 "midori-notebook.c"
	}
#line 548 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp17_ = new_size;
#line 548 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->last_tab_size = _tmp17_;
#line 549 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp18_ = self->notebook;
#line 549 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp19_ = gtk_container_get_children ((GtkContainer*) _tmp18_);
#line 3731 "midori-notebook.c"
	{
		GList* child_collection = NULL;
		GList* child_it = NULL;
#line 549 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		child_collection = _tmp19_;
#line 549 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		for (child_it = child_collection; child_it != NULL; child_it = child_it->next) {
#line 3739 "midori-notebook.c"
			GtkWidget* child = NULL;
#line 549 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
			child = (GtkWidget*) child_it->data;
#line 3743 "midori-notebook.c"
			{
				MidoriTab* tab = NULL;
				GtkWidget* _tmp20_;
				MidoriTab* _tmp21_;
				MidoriTally* tally = NULL;
				GtkNotebook* _tmp22_;
				GtkWidget* _tmp23_;
				GtkWidget* _tmp24_;
				MidoriTally* _tmp25_;
				gint _tmp26_ = 0;
				MidoriTab* _tmp27_;
				gboolean _tmp28_;
				gboolean _tmp29_;
				MidoriTally* _tmp31_;
#line 550 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp20_ = child;
#line 550 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp21_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp20_, MIDORI_TYPE_TAB) ? ((MidoriTab*) _tmp20_) : NULL);
#line 550 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				tab = _tmp21_;
#line 551 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp22_ = self->notebook;
#line 551 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp23_ = child;
#line 551 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp24_ = gtk_notebook_get_tab_label (_tmp22_, _tmp23_);
#line 551 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp25_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp24_, MIDORI_TYPE_TALLY) ? ((MidoriTally*) _tmp24_) : NULL);
#line 551 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				tally = _tmp25_;
#line 552 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp27_ = tab;
#line 552 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp28_ = midori_tab_get_minimized (_tmp27_);
#line 552 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp29_ = _tmp28_;
#line 552 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				if (_tmp29_) {
#line 552 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp26_ = -1;
#line 3784 "midori-notebook.c"
				} else {
					gint _tmp30_;
#line 552 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp30_ = self->priv->last_tab_size;
#line 552 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
					_tmp26_ = _tmp30_;
#line 3791 "midori-notebook.c"
				}
#line 552 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_tmp31_ = tally;
#line 552 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				gtk_widget_set_size_request ((GtkWidget*) _tmp31_, _tmp26_, -1);
#line 549 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_g_object_unref0 (tally);
#line 549 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
				_g_object_unref0 (tab);
#line 3801 "midori-notebook.c"
			}
		}
#line 549 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_list_free0 (child_collection);
#line 3806 "midori-notebook.c"
	}
}


guint midori_notebook_get_count (MidoriNotebook* self) {
	guint result;
	guint _tmp0_;
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, 0U);
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_count;
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp0_;
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 3822 "midori-notebook.c"
}


static void midori_notebook_set_count (MidoriNotebook* self, guint value) {
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (midori_notebook_get_count (self) != value) {
#line 3831 "midori-notebook.c"
		guint _tmp0_;
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = value;
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		self->priv->_count = _tmp0_;
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_object_notify_by_pspec ((GObject *) self, midori_notebook_properties[MIDORI_NOTEBOOK_COUNT_PROPERTY]);
#line 3839 "midori-notebook.c"
	}
}


gint midori_notebook_get_index (MidoriNotebook* self) {
	gint result;
	gint _tmp0_;
#line 173 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, 0);
#line 173 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_index;
#line 173 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp0_;
#line 173 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 3855 "midori-notebook.c"
}


void midori_notebook_set_index (MidoriNotebook* self, gint value) {
#line 173 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 173 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (midori_notebook_get_index (self) != value) {
#line 3864 "midori-notebook.c"
		gint _tmp0_;
#line 173 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = value;
#line 173 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		self->priv->_index = _tmp0_;
#line 173 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_object_notify_by_pspec ((GObject *) self, midori_notebook_properties[MIDORI_NOTEBOOK_INDEX_PROPERTY]);
#line 3872 "midori-notebook.c"
	}
}


MidoriTab* midori_notebook_get_tab (MidoriNotebook* self) {
	MidoriTab* result;
	MidoriTab* _tmp0_;
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_tab;
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp0_;
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 3888 "midori-notebook.c"
}


void midori_notebook_set_tab (MidoriNotebook* self, MidoriTab* value) {
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (midori_notebook_get_tab (self) != value) {
#line 3897 "midori-notebook.c"
		MidoriTab* _tmp0_;
		MidoriTab* _tmp1_;
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = value;
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp1_ = _g_object_ref0 (_tmp0_);
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_g_object_unref0 (self->priv->_tab);
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		self->priv->_tab = _tmp1_;
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_object_notify_by_pspec ((GObject *) self, midori_notebook_properties[MIDORI_NOTEBOOK_TAB_PROPERTY]);
#line 3910 "midori-notebook.c"
	}
}


static MidoriTab* midori_notebook_get_previous (MidoriNotebook* self) {
	MidoriTab* result;
	MidoriTab* _tmp0_;
#line 177 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 177 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_previous;
#line 177 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp0_;
#line 177 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 3926 "midori-notebook.c"
}


static void midori_notebook_set_previous (MidoriNotebook* self, MidoriTab* value) {
	MidoriTab* _tmp0_;
	MidoriTab* _tmp1_;
#line 177 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 177 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = value;
#line 177 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 177 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->_previous);
#line 177 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->_previous = _tmp1_;
#line 3943 "midori-notebook.c"
}


gboolean midori_notebook_get_close_buttons_left (MidoriNotebook* self) {
	gboolean result;
	gboolean _tmp0_;
#line 180 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 180 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_close_buttons_left;
#line 180 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp0_;
#line 180 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 3958 "midori-notebook.c"
}


void midori_notebook_set_close_buttons_left (MidoriNotebook* self, gboolean value) {
#line 180 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 180 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (midori_notebook_get_close_buttons_left (self) != value) {
#line 3967 "midori-notebook.c"
		gboolean _tmp0_;
#line 180 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = value;
#line 180 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		self->priv->_close_buttons_left = _tmp0_;
#line 180 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_object_notify_by_pspec ((GObject *) self, midori_notebook_properties[MIDORI_NOTEBOOK_CLOSE_BUTTONS_LEFT_PROPERTY]);
#line 3975 "midori-notebook.c"
	}
}


gboolean midori_notebook_get_close_buttons_visible (MidoriNotebook* self) {
	gboolean result;
	gboolean _tmp0_;
#line 182 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 182 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_close_buttons_visible;
#line 182 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp0_;
#line 182 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 3991 "midori-notebook.c"
}


void midori_notebook_set_close_buttons_visible (MidoriNotebook* self, gboolean value) {
#line 182 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 182 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (midori_notebook_get_close_buttons_visible (self) != value) {
#line 4000 "midori-notebook.c"
		gboolean _tmp0_;
#line 182 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = value;
#line 182 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		self->priv->_close_buttons_visible = _tmp0_;
#line 182 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_object_notify_by_pspec ((GObject *) self, midori_notebook_properties[MIDORI_NOTEBOOK_CLOSE_BUTTONS_VISIBLE_PROPERTY]);
#line 4008 "midori-notebook.c"
	}
}


gboolean midori_notebook_get_labels_visible (MidoriNotebook* self) {
	gboolean result;
	gboolean _tmp0_;
#line 184 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 184 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->priv->_labels_visible;
#line 184 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	result = _tmp0_;
#line 184 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	return result;
#line 4024 "midori-notebook.c"
}


void midori_notebook_set_labels_visible (MidoriNotebook* self, gboolean value) {
#line 184 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (self != NULL);
#line 184 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (midori_notebook_get_labels_visible (self) != value) {
#line 4033 "midori-notebook.c"
		gboolean _tmp0_;
#line 184 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		_tmp0_ = value;
#line 184 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		self->priv->_labels_visible = _tmp0_;
#line 184 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_object_notify_by_pspec ((GObject *) self, midori_notebook_properties[MIDORI_NOTEBOOK_LABELS_VISIBLE_PROPERTY]);
#line 4041 "midori-notebook.c"
	}
}


static void g_cclosure_user_marshal_VOID__OBJECT_OBJECT (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) {
	typedef void (*GMarshalFunc_VOID__OBJECT_OBJECT) (gpointer data1, gpointer arg_1, gpointer arg_2, gpointer data2);
	register GMarshalFunc_VOID__OBJECT_OBJECT callback;
	register GCClosure * cc;
	register gpointer data1;
	register gpointer data2;
	cc = (GCClosure *) closure;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (n_param_values == 3);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (G_CCLOSURE_SWAP_DATA (closure)) {
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data1 = closure->data;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data2 = param_values->data[0].v_pointer;
#line 4061 "midori-notebook.c"
	} else {
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data1 = param_values->data[0].v_pointer;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data2 = closure->data;
#line 4067 "midori-notebook.c"
	}
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	callback = (GMarshalFunc_VOID__OBJECT_OBJECT) (marshal_data ? marshal_data : cc->callback);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	callback (data1, g_value_get_object (param_values + 1), g_value_get_object (param_values + 2), data2);
#line 4073 "midori-notebook.c"
}


static void g_cclosure_user_marshal_VOID__OBJECT_UINT (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) {
	typedef void (*GMarshalFunc_VOID__OBJECT_UINT) (gpointer data1, gpointer arg_1, guint arg_2, gpointer data2);
	register GMarshalFunc_VOID__OBJECT_UINT callback;
	register GCClosure * cc;
	register gpointer data1;
	register gpointer data2;
	cc = (GCClosure *) closure;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (n_param_values == 3);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (G_CCLOSURE_SWAP_DATA (closure)) {
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data1 = closure->data;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data2 = param_values->data[0].v_pointer;
#line 4092 "midori-notebook.c"
	} else {
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data1 = param_values->data[0].v_pointer;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data2 = closure->data;
#line 4098 "midori-notebook.c"
	}
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	callback = (GMarshalFunc_VOID__OBJECT_UINT) (marshal_data ? marshal_data : cc->callback);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	callback (data1, g_value_get_object (param_values + 1), g_value_get_uint (param_values + 2), data2);
#line 4104 "midori-notebook.c"
}


static void g_cclosure_user_marshal_VOID__OBJECT_INT_INT (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) {
	typedef void (*GMarshalFunc_VOID__OBJECT_INT_INT) (gpointer data1, gpointer arg_1, gint arg_2, gint arg_3, gpointer data2);
	register GMarshalFunc_VOID__OBJECT_INT_INT callback;
	register GCClosure * cc;
	register gpointer data1;
	register gpointer data2;
	cc = (GCClosure *) closure;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_return_if_fail (n_param_values == 4);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	if (G_CCLOSURE_SWAP_DATA (closure)) {
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data1 = closure->data;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data2 = param_values->data[0].v_pointer;
#line 4123 "midori-notebook.c"
	} else {
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data1 = param_values->data[0].v_pointer;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		data2 = closure->data;
#line 4129 "midori-notebook.c"
	}
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	callback = (GMarshalFunc_VOID__OBJECT_INT_INT) (marshal_data ? marshal_data : cc->callback);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	callback (data1, g_value_get_object (param_values + 1), g_value_get_int (param_values + 2), g_value_get_int (param_values + 3), data2);
#line 4135 "midori-notebook.c"
}


static void midori_notebook_class_init (MidoriNotebookClass * klass) {
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_parent_class = g_type_class_peek_parent (klass);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_type_class_add_private (klass, sizeof (MidoriNotebookPrivate));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	((GtkWidgetClass *) klass)->expose_event = (gboolean (*) (GtkWidget *, GdkEventExpose*)) midori_notebook_real_expose_event;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	((GtkContainerClass *) klass)->forall = (void (*) (GtkContainer *, gboolean, GtkCallback, void*)) midori_notebook_real_forall_internal;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	G_OBJECT_CLASS (klass)->get_property = _vala_midori_notebook_get_property;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	G_OBJECT_CLASS (klass)->set_property = _vala_midori_notebook_set_property;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	G_OBJECT_CLASS (klass)->finalize = midori_notebook_finalize;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), MIDORI_NOTEBOOK_COUNT_PROPERTY, midori_notebook_properties[MIDORI_NOTEBOOK_COUNT_PROPERTY] = g_param_spec_uint ("count", "count", "count", 0, G_MAXUINT, (guint) 0, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), MIDORI_NOTEBOOK_INDEX_PROPERTY, midori_notebook_properties[MIDORI_NOTEBOOK_INDEX_PROPERTY] = g_param_spec_int ("index", "index", "index", G_MININT, G_MAXINT, -1, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), MIDORI_NOTEBOOK_TAB_PROPERTY, midori_notebook_properties[MIDORI_NOTEBOOK_TAB_PROPERTY] = g_param_spec_object ("tab", "tab", "tab", MIDORI_TYPE_TAB, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), MIDORI_NOTEBOOK_CLOSE_BUTTONS_LEFT_PROPERTY, midori_notebook_properties[MIDORI_NOTEBOOK_CLOSE_BUTTONS_LEFT_PROPERTY] = g_param_spec_boolean ("close-buttons-left", "close-buttons-left", "close-buttons-left", TRUE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), MIDORI_NOTEBOOK_CLOSE_BUTTONS_VISIBLE_PROPERTY, midori_notebook_properties[MIDORI_NOTEBOOK_CLOSE_BUTTONS_VISIBLE_PROPERTY] = g_param_spec_boolean ("close-buttons-visible", "close-buttons-visible", "close-buttons-visible", TRUE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), MIDORI_NOTEBOOK_LABELS_VISIBLE_PROPERTY, midori_notebook_properties[MIDORI_NOTEBOOK_LABELS_VISIBLE_PROPERTY] = g_param_spec_boolean ("labels-visible", "labels-visible", "labels-visible", TRUE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_signals[MIDORI_NOTEBOOK_TAB_CONTEXT_MENU_SIGNAL] = g_signal_new ("tab-context-menu", MIDORI_TYPE_NOTEBOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__OBJECT_OBJECT, G_TYPE_NONE, 2, MIDORI_TYPE_TAB, MIDORI_TYPE_CONTEXT_ACTION);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_signals[MIDORI_NOTEBOOK_CONTEXT_MENU_SIGNAL] = g_signal_new ("context-menu", MIDORI_TYPE_NOTEBOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__OBJECT, G_TYPE_NONE, 1, MIDORI_TYPE_CONTEXT_ACTION);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_signals[MIDORI_NOTEBOOK_TAB_SWITCHED_SIGNAL] = g_signal_new ("tab-switched", MIDORI_TYPE_NOTEBOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__OBJECT_OBJECT, G_TYPE_NONE, 2, MIDORI_TYPE_TAB, MIDORI_TYPE_TAB);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_signals[MIDORI_NOTEBOOK_TAB_MOVED_SIGNAL] = g_signal_new ("tab-moved", MIDORI_TYPE_NOTEBOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__OBJECT_UINT, G_TYPE_NONE, 2, MIDORI_TYPE_TAB, G_TYPE_UINT);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_signals[MIDORI_NOTEBOOK_TAB_DETACHED_SIGNAL] = g_signal_new ("tab-detached", MIDORI_TYPE_NOTEBOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__OBJECT_INT_INT, G_TYPE_NONE, 3, MIDORI_TYPE_TAB, G_TYPE_INT, G_TYPE_INT);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	midori_notebook_signals[MIDORI_NOTEBOOK_NEW_TAB_SIGNAL] = g_signal_new ("new-tab", MIDORI_TYPE_NOTEBOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
#line 4178 "midori-notebook.c"
}


static void midori_notebook_instance_init (MidoriNotebook * self) {
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv = MIDORI_NOTEBOOK_GET_PRIVATE (self);
#line 155 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->last_tab_size = 0;
#line 171 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->_count = (guint) 0;
#line 173 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->_index = -1;
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->_tab = NULL;
#line 177 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->_previous = NULL;
#line 180 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->_close_buttons_left = TRUE;
#line 182 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->_close_buttons_visible = TRUE;
#line 184 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self->priv->_labels_visible = TRUE;
#line 4201 "midori-notebook.c"
}


static void midori_notebook_finalize (GObject * obj) {
	MidoriNotebook * self;
	GtkNotebook* _tmp0_;
	guint _tmp1_;
	GtkNotebook* _tmp2_;
	guint _tmp3_;
	GtkNotebook* _tmp4_;
	guint _tmp5_;
	GtkNotebook* _tmp6_;
	guint _tmp7_;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, MIDORI_TYPE_NOTEBOOK, MidoriNotebook);
#line 274 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp0_ = self->notebook;
#line 274 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_parse_name ("size-allocate", GTK_TYPE_WIDGET, &_tmp1_, NULL, FALSE);
#line 274 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_handlers_disconnect_matched ((GtkWidget*) _tmp0_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp1_, 0, NULL, (GCallback) _midori_notebook_size_allocated_gtk_widget_size_allocate, self);
#line 275 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp2_ = self->notebook;
#line 275 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_parse_name ("switch-page", GTK_TYPE_NOTEBOOK, &_tmp3_, NULL, FALSE);
#line 275 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_handlers_disconnect_matched (_tmp2_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp3_, 0, NULL, (GCallback) _midori_notebook_page_switched_gtk_notebook_switch_page, self);
#line 276 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp4_ = self->notebook;
#line 276 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_parse_name ("page-reordered", GTK_TYPE_NOTEBOOK, &_tmp5_, NULL, FALSE);
#line 276 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_handlers_disconnect_matched (_tmp4_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp5_, 0, NULL, (GCallback) _midori_notebook_page_moved_gtk_notebook_page_reordered, self);
#line 277 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_tmp6_ = self->notebook;
#line 277 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_parse_name ("create-window", GTK_TYPE_NOTEBOOK, &_tmp7_, NULL, FALSE);
#line 277 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	g_signal_handlers_disconnect_matched (_tmp6_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp7_, 0, NULL, (GCallback) _midori_notebook_window_created_gtk_notebook_create_window, self);
#line 154 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->notebook);
#line 175 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->_tab);
#line 177 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	_g_object_unref0 (self->priv->_previous);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	G_OBJECT_CLASS (midori_notebook_parent_class)->finalize (obj);
#line 4249 "midori-notebook.c"
}


GType midori_notebook_get_type (void) {
	static volatile gsize midori_notebook_type_id__volatile = 0;
	if (g_once_init_enter (&midori_notebook_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (MidoriNotebookClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) midori_notebook_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (MidoriNotebook), 0, (GInstanceInitFunc) midori_notebook_instance_init, NULL };
		GType midori_notebook_type_id;
		midori_notebook_type_id = g_type_register_static (GTK_TYPE_EVENT_BOX, "MidoriNotebook", &g_define_type_info, 0);
		g_once_init_leave (&midori_notebook_type_id__volatile, midori_notebook_type_id);
	}
	return midori_notebook_type_id__volatile;
}


static void _vala_midori_notebook_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) {
	MidoriNotebook * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, MIDORI_TYPE_NOTEBOOK, MidoriNotebook);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	switch (property_id) {
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_COUNT_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_value_set_uint (value, midori_notebook_get_count (self));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_INDEX_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_value_set_int (value, midori_notebook_get_index (self));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_TAB_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_value_set_object (value, midori_notebook_get_tab (self));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_CLOSE_BUTTONS_LEFT_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_value_set_boolean (value, midori_notebook_get_close_buttons_left (self));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_CLOSE_BUTTONS_VISIBLE_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_value_set_boolean (value, midori_notebook_get_close_buttons_visible (self));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_LABELS_VISIBLE_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		g_value_set_boolean (value, midori_notebook_get_labels_visible (self));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 4306 "midori-notebook.c"
		default:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 4312 "midori-notebook.c"
	}
}


static void _vala_midori_notebook_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec) {
	MidoriNotebook * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, MIDORI_TYPE_NOTEBOOK, MidoriNotebook);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
	switch (property_id) {
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_COUNT_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		midori_notebook_set_count (self, g_value_get_uint (value));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_INDEX_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		midori_notebook_set_index (self, g_value_get_int (value));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_TAB_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		midori_notebook_set_tab (self, g_value_get_object (value));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_CLOSE_BUTTONS_LEFT_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		midori_notebook_set_close_buttons_left (self, g_value_get_boolean (value));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_CLOSE_BUTTONS_VISIBLE_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		midori_notebook_set_close_buttons_visible (self, g_value_get_boolean (value));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		case MIDORI_NOTEBOOK_LABELS_VISIBLE_PROPERTY:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		midori_notebook_set_labels_visible (self, g_value_get_boolean (value));
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 4358 "midori-notebook.c"
		default:
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
#line 153 "/usr/src/ports/midori/midori-0.5.11-2.x86_64/src/midori-0.5.11/midori/midori-notebook.vala"
		break;
#line 4364 "midori-notebook.c"
	}
}


static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) {
	if ((array != NULL) && (destroy_func != NULL)) {
		int i;
		for (i = 0; i < array_length; i = i + 1) {
			if (((gpointer*) array)[i] != NULL) {
				destroy_func (((gpointer*) array)[i]);
			}
		}
	}
}


static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func) {
	_vala_array_destroy (array, array_length, destroy_func);
	g_free (array);
}


static gint _vala_array_length (gpointer array) {
	int length;
	length = 0;
	if (array) {
		while (((gpointer*) array)[length]) {
			length++;
		}
	}
	return length;
}



