/* SectionBoard.c generated by valac 0.56.19, the Vala compiler
 * generated from SectionBoard.vala, do not modify */

/*
 * Copyright © 2023 Alain M. (https://github.com/alainm23/planify)
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public
 * License as published by the Free Software Foundation; either
 * version 3 of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * General Public License for more details.
 *
 * You should have received a copy of the GNU General Public
 * License along with this program; if not, write to the
 * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
 * Boston, MA 02110-1301 USA
 *
 * Authored by: Alain M. <alainmh23@gmail.com>
 */

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

#define LAYOUTS_SECTION_BOARD_PAGE_SIZE CONSTANTS_COMPLETED_PAGE_SIZE
#if !defined(VALA_STRICT_C)
#if !defined(__clang__) && defined(__GNUC__) && (__GNUC__ >= 14)
#pragma GCC diagnostic warning "-Wincompatible-pointer-types"
#elif defined(__clang__) && (__clang_major__ >= 16)
#pragma clang diagnostic ignored "-Wincompatible-function-pointer-types"
#pragma clang diagnostic ignored "-Wincompatible-pointer-types"
#endif
#endif
#if !defined(VALA_EXTERN)
#if defined(_MSC_VER)
#define VALA_EXTERN __declspec(dllexport) extern
#elif __GNUC__ >= 4
#define VALA_EXTERN __attribute__((visibility("default"))) extern
#else
#define VALA_EXTERN extern
#endif
#endif

#define LAYOUTS_TYPE_SECTION_BOARD (layouts_section_board_get_type ())
#define LAYOUTS_SECTION_BOARD(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), LAYOUTS_TYPE_SECTION_BOARD, LayoutsSectionBoard))
#define LAYOUTS_SECTION_BOARD_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), LAYOUTS_TYPE_SECTION_BOARD, LayoutsSectionBoardClass))
#define LAYOUTS_IS_SECTION_BOARD(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), LAYOUTS_TYPE_SECTION_BOARD))
#define LAYOUTS_IS_SECTION_BOARD_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), LAYOUTS_TYPE_SECTION_BOARD))
#define LAYOUTS_SECTION_BOARD_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), LAYOUTS_TYPE_SECTION_BOARD, LayoutsSectionBoardClass))

typedef struct _LayoutsSectionBoard LayoutsSectionBoard;
typedef struct _LayoutsSectionBoardClass LayoutsSectionBoardClass;
typedef struct _LayoutsSectionBoardPrivate LayoutsSectionBoardPrivate;

#define LAYOUTS_TYPE_ITEM_BASE (layouts_item_base_get_type ())
#define LAYOUTS_ITEM_BASE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), LAYOUTS_TYPE_ITEM_BASE, LayoutsItemBase))
#define LAYOUTS_ITEM_BASE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), LAYOUTS_TYPE_ITEM_BASE, LayoutsItemBaseClass))
#define LAYOUTS_IS_ITEM_BASE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), LAYOUTS_TYPE_ITEM_BASE))
#define LAYOUTS_IS_ITEM_BASE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), LAYOUTS_TYPE_ITEM_BASE))
#define LAYOUTS_ITEM_BASE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), LAYOUTS_TYPE_ITEM_BASE, LayoutsItemBaseClass))

typedef struct _LayoutsItemBase LayoutsItemBase;
typedef struct _LayoutsItemBaseClass LayoutsItemBaseClass;

#define LAYOUTS_TYPE_ITEM_BOARD (layouts_item_board_get_type ())
#define LAYOUTS_ITEM_BOARD(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), LAYOUTS_TYPE_ITEM_BOARD, LayoutsItemBoard))
#define LAYOUTS_ITEM_BOARD_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), LAYOUTS_TYPE_ITEM_BOARD, LayoutsItemBoardClass))
#define LAYOUTS_IS_ITEM_BOARD(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), LAYOUTS_TYPE_ITEM_BOARD))
#define LAYOUTS_IS_ITEM_BOARD_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), LAYOUTS_TYPE_ITEM_BOARD))
#define LAYOUTS_ITEM_BOARD_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), LAYOUTS_TYPE_ITEM_BOARD, LayoutsItemBoardClass))

typedef struct _LayoutsItemBoard LayoutsItemBoard;
typedef struct _LayoutsItemBoardClass LayoutsItemBoardClass;
enum  {
	LAYOUTS_SECTION_BOARD_0_PROPERTY,
	LAYOUTS_SECTION_BOARD_SECTION_PROPERTY,
	LAYOUTS_SECTION_BOARD_IS_INBOX_SECTION_PROPERTY,
	LAYOUTS_SECTION_BOARD_IS_LOADING_PROPERTY,
	LAYOUTS_SECTION_BOARD_SECTION_COUNT_PROPERTY,
	LAYOUTS_SECTION_BOARD_NUM_PROPERTIES
};
static GParamSpec* layouts_section_board_properties[LAYOUTS_SECTION_BOARD_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 _g_date_time_unref0(var) ((var == NULL) ? NULL : (var = (g_date_time_unref (var), NULL)))

#define DIALOGS_TYPE_SECTION (dialogs_section_get_type ())
#define DIALOGS_SECTION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DIALOGS_TYPE_SECTION, DialogsSection))
#define DIALOGS_SECTION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DIALOGS_TYPE_SECTION, DialogsSectionClass))
#define DIALOGS_IS_SECTION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DIALOGS_TYPE_SECTION))
#define DIALOGS_IS_SECTION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DIALOGS_TYPE_SECTION))
#define DIALOGS_SECTION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DIALOGS_TYPE_SECTION, DialogsSectionClass))

typedef struct _DialogsSection DialogsSection;
typedef struct _DialogsSectionClass DialogsSectionClass;

#define TYPE_PLANIFY (planify_get_type ())
#define PLANIFY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PLANIFY, Planify))
#define PLANIFY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PLANIFY, PlanifyClass))
#define IS_PLANIFY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PLANIFY))
#define IS_PLANIFY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PLANIFY))
#define PLANIFY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PLANIFY, PlanifyClass))

typedef struct _Planify Planify;
typedef struct _PlanifyClass PlanifyClass;
typedef struct _PlanifyPrivate PlanifyPrivate;

#define TYPE_MAIN_WINDOW (main_window_get_type ())
#define MAIN_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_MAIN_WINDOW, MainWindow))
#define MAIN_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_MAIN_WINDOW, MainWindowClass))
#define IS_MAIN_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_MAIN_WINDOW))
#define IS_MAIN_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_MAIN_WINDOW))
#define MAIN_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_MAIN_WINDOW, MainWindowClass))

typedef struct _MainWindow MainWindow;
typedef struct _MainWindowClass MainWindowClass;

#define DIALOGS_PROJECT_PICKER_TYPE_PROJECT_PICKER (dialogs_project_picker_project_picker_get_type ())
#define DIALOGS_PROJECT_PICKER_PROJECT_PICKER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DIALOGS_PROJECT_PICKER_TYPE_PROJECT_PICKER, DialogsProjectPickerProjectPicker))
#define DIALOGS_PROJECT_PICKER_PROJECT_PICKER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DIALOGS_PROJECT_PICKER_TYPE_PROJECT_PICKER, DialogsProjectPickerProjectPickerClass))
#define DIALOGS_PROJECT_PICKER_IS_PROJECT_PICKER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DIALOGS_PROJECT_PICKER_TYPE_PROJECT_PICKER))
#define DIALOGS_PROJECT_PICKER_IS_PROJECT_PICKER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DIALOGS_PROJECT_PICKER_TYPE_PROJECT_PICKER))
#define DIALOGS_PROJECT_PICKER_PROJECT_PICKER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DIALOGS_PROJECT_PICKER_TYPE_PROJECT_PICKER, DialogsProjectPickerProjectPickerClass))

typedef struct _DialogsProjectPickerProjectPicker DialogsProjectPickerProjectPicker;
typedef struct _DialogsProjectPickerProjectPickerClass DialogsProjectPickerProjectPickerClass;

#define DIALOGS_TYPE_MANAGE_SECTION_ORDER (dialogs_manage_section_order_get_type ())
#define DIALOGS_MANAGE_SECTION_ORDER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DIALOGS_TYPE_MANAGE_SECTION_ORDER, DialogsManageSectionOrder))
#define DIALOGS_MANAGE_SECTION_ORDER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DIALOGS_TYPE_MANAGE_SECTION_ORDER, DialogsManageSectionOrderClass))
#define DIALOGS_IS_MANAGE_SECTION_ORDER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DIALOGS_TYPE_MANAGE_SECTION_ORDER))
#define DIALOGS_IS_MANAGE_SECTION_ORDER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DIALOGS_TYPE_MANAGE_SECTION_ORDER))
#define DIALOGS_MANAGE_SECTION_ORDER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DIALOGS_TYPE_MANAGE_SECTION_ORDER, DialogsManageSectionOrderClass))

typedef struct _DialogsManageSectionOrder DialogsManageSectionOrder;
typedef struct _DialogsManageSectionOrderClass DialogsManageSectionOrderClass;
#define _http_response_unref0(var) ((var == NULL) ? NULL : (var = (http_response_unref (var), NULL)))

#define DIALOGS_TYPE_COMPLETED_TASKS (dialogs_completed_tasks_get_type ())
#define DIALOGS_COMPLETED_TASKS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DIALOGS_TYPE_COMPLETED_TASKS, DialogsCompletedTasks))
#define DIALOGS_COMPLETED_TASKS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DIALOGS_TYPE_COMPLETED_TASKS, DialogsCompletedTasksClass))
#define DIALOGS_IS_COMPLETED_TASKS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DIALOGS_TYPE_COMPLETED_TASKS))
#define DIALOGS_IS_COMPLETED_TASKS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DIALOGS_TYPE_COMPLETED_TASKS))
#define DIALOGS_COMPLETED_TASKS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DIALOGS_TYPE_COMPLETED_TASKS, DialogsCompletedTasksClass))

typedef struct _DialogsCompletedTasks DialogsCompletedTasks;
typedef struct _DialogsCompletedTasksClass DialogsCompletedTasksClass;

#define DIALOGS_TYPE_QUICK_ADD (dialogs_quick_add_get_type ())
#define DIALOGS_QUICK_ADD(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DIALOGS_TYPE_QUICK_ADD, DialogsQuickAdd))
#define DIALOGS_QUICK_ADD_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DIALOGS_TYPE_QUICK_ADD, DialogsQuickAddClass))
#define DIALOGS_IS_QUICK_ADD(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DIALOGS_TYPE_QUICK_ADD))
#define DIALOGS_IS_QUICK_ADD_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DIALOGS_TYPE_QUICK_ADD))
#define DIALOGS_QUICK_ADD_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DIALOGS_TYPE_QUICK_ADD, DialogsQuickAddClass))

typedef struct _DialogsQuickAdd DialogsQuickAdd;
typedef struct _DialogsQuickAddClass DialogsQuickAddClass;
typedef struct _Block46Data Block46Data;
typedef struct _Block47Data Block47Data;

#define WIDGETS_TYPE_SCROLLED_WINDOW (widgets_scrolled_window_get_type ())
#define WIDGETS_SCROLLED_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), WIDGETS_TYPE_SCROLLED_WINDOW, WidgetsScrolledWindow))
#define WIDGETS_SCROLLED_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), WIDGETS_TYPE_SCROLLED_WINDOW, WidgetsScrolledWindowClass))
#define WIDGETS_IS_SCROLLED_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), WIDGETS_TYPE_SCROLLED_WINDOW))
#define WIDGETS_IS_SCROLLED_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), WIDGETS_TYPE_SCROLLED_WINDOW))
#define WIDGETS_SCROLLED_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), WIDGETS_TYPE_SCROLLED_WINDOW, WidgetsScrolledWindowClass))

typedef struct _WidgetsScrolledWindow WidgetsScrolledWindow;
typedef struct _WidgetsScrolledWindowClass WidgetsScrolledWindowClass;

struct _LayoutsSectionBoard {
	GtkFlowBoxChild parent_instance;
	LayoutsSectionBoardPrivate * priv;
	GeeHashMap* items_map;
	GeeHashMap* checked_items_map;
};

struct _LayoutsSectionBoardClass {
	GtkFlowBoxChildClass parent_class;
};

struct _LayoutsSectionBoardPrivate {
	ObjectsSection* _section;
	GtkGrid* widget_color;
	GtkLabel* name_label;
	GtkLabel* count_label;
	GtkLabel* description_label;
	GtkRevealer* description_revealer;
	GtkListBox* listbox;
	GtkBox* listbox_target;
	GtkListBox* checked_listbox;
	GtkButton* load_more_button;
	GtkRevealer* load_more_button_revealer;
	GtkRevealer* checked_revealer;
	GtkBox* content_box;
	GeeHashMap* signals_map;
	GeeArrayList* completed_items_list;
	gint completed_page_index;
};

struct _Planify {
	AdwApplication parent_instance;
	PlanifyPrivate * priv;
	MainWindow* main_window;
};

struct _PlanifyClass {
	AdwApplicationClass parent_class;
};

struct _Block46Data {
	int _ref_count_;
	LayoutsSectionBoard* self;
	gchar* old_section_id;
};

struct _Block47Data {
	int _ref_count_;
	LayoutsSectionBoard* self;
	LayoutsItemBoard* picked_widget;
};

static gint LayoutsSectionBoard_private_offset;
static gpointer layouts_section_board_parent_class = NULL;
VALA_EXTERN Planify* planify__instance;

VALA_EXTERN GType layouts_section_board_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (LayoutsSectionBoard, g_object_unref)
VALA_EXTERN GType layouts_item_base_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (LayoutsItemBase, g_object_unref)
VALA_EXTERN GType layouts_item_board_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (LayoutsItemBoard, g_object_unref)
VALA_EXTERN LayoutsSectionBoard* layouts_section_board_new (ObjectsSection* section);
VALA_EXTERN LayoutsSectionBoard* layouts_section_board_construct (GType object_type,
                                                      ObjectsSection* section);
VALA_EXTERN LayoutsSectionBoard* layouts_section_board_new_for_project (ObjectsProject* project);
VALA_EXTERN LayoutsSectionBoard* layouts_section_board_construct_for_project (GType object_type,
                                                                  ObjectsProject* project);
static void layouts_section_board_update_request (LayoutsSectionBoard* self);
VALA_EXTERN ObjectsSection* layouts_section_board_get_section (LayoutsSectionBoard* self);
static void layouts_section_board_update_count_label (LayoutsSectionBoard* self,
                                               gint count);
static void layouts_section_board_refresh_count_label (LayoutsSectionBoard* self);
VALA_EXTERN gboolean layouts_section_board_get_is_inbox_section (LayoutsSectionBoard* self);
static gint layouts_section_board_get_subitem_count (LayoutsSectionBoard* self,
                                              ObjectsItem* item);
VALA_EXTERN void layouts_section_board_add_items (LayoutsSectionBoard* self);
static gint __lambda684_ (LayoutsSectionBoard* self,
                   ObjectsItem* item1,
                   ObjectsItem* item2);
static gint ___lambda684__gcompare_data_func (gconstpointer a,
                                       gconstpointer b,
                                       gpointer self);
VALA_EXTERN void layouts_section_board_add_item (LayoutsSectionBoard* self,
                                     ObjectsItem* item,
                                     gint position);
static void layouts_section_board_update_sort (LayoutsSectionBoard* self);
static gint layouts_section_board_set_sort_func (LayoutsSectionBoard* self,
                                          GtkListBoxRow* lbrow,
                                          GtkListBoxRow* lbbefore);
static gint _layouts_section_board_set_sort_func_gtk_list_box_sort_func (GtkListBoxRow* row1,
                                                                  GtkListBoxRow* row2,
                                                                  gpointer self);
VALA_EXTERN ObjectsItem* layouts_item_base_get_item (LayoutsItemBase* self);
VALA_EXTERN LayoutsItemBoard* layouts_item_board_new (ObjectsItem* item);
VALA_EXTERN LayoutsItemBoard* layouts_item_board_construct (GType object_type,
                                                ObjectsItem* item);
static void layouts_section_board_show_completed_changed (LayoutsSectionBoard* self);
VALA_EXTERN void layouts_section_board_add_completed_items (LayoutsSectionBoard* self);
VALA_EXTERN void layouts_item_base_hide_destroy (LayoutsItemBase* self);
static gint __lambda685_ (LayoutsSectionBoard* self,
                   ObjectsItem* a,
                   ObjectsItem* b);
static gint ___lambda685__gcompare_data_func (gconstpointer a,
                                       gconstpointer b,
                                       gpointer self);
static void layouts_section_board_load_next_completed_page (LayoutsSectionBoard* self);
VALA_EXTERN void layouts_section_board_add_complete_item (LayoutsSectionBoard* self,
                                              ObjectsItem* item);
static void layouts_section_board_update_load_more_button_label (LayoutsSectionBoard* self);
static GtkPopover* layouts_section_board_build_context_menu (LayoutsSectionBoard* self);
static void __lambda686_ (LayoutsSectionBoard* self);
VALA_EXTERN void layouts_section_board_prepare_new_item (LayoutsSectionBoard* self,
                                             const gchar* content,
                                             NewTaskPosition new_task_position);
static void ___lambda686__gtk_button_clicked (GtkButton* _sender,
                                       gpointer self);
static void __lambda687_ (LayoutsSectionBoard* self);
VALA_EXTERN GType dialogs_section_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DialogsSection, g_object_unref)
VALA_EXTERN DialogsSection* dialogs_section_new (ObjectsSection* section);
VALA_EXTERN DialogsSection* dialogs_section_construct (GType object_type,
                                           ObjectsSection* section);
VALA_EXTERN GType planify_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (Planify, g_object_unref)
VALA_EXTERN GType main_window_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (MainWindow, g_object_unref)
static void ___lambda687__gtk_button_clicked (GtkButton* _sender,
                                       gpointer self);
static void __lambda688_ (LayoutsSectionBoard* self);
VALA_EXTERN GType dialogs_project_picker_project_picker_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DialogsProjectPickerProjectPicker, g_object_unref)
VALA_EXTERN DialogsProjectPickerProjectPicker* dialogs_project_picker_project_picker_new_for_source (ObjectsSource* source);
VALA_EXTERN DialogsProjectPickerProjectPicker* dialogs_project_picker_project_picker_construct_for_source (GType object_type,
                                                                                               ObjectsSource* source);
VALA_EXTERN void dialogs_project_picker_project_picker_set_project (DialogsProjectPickerProjectPicker* self,
                                                        ObjectsProject* value);
static void __lambda689_ (LayoutsSectionBoard* self,
                   const gchar* type,
                   const gchar* id);
static void layouts_section_board_move_section (LayoutsSectionBoard* self,
                                         const gchar* project_id);
static void ___lambda689__dialogs_project_picker_project_picker_changed (DialogsProjectPickerProjectPicker* _sender,
                                                                  const gchar* type,
                                                                  const gchar* id,
                                                                  gpointer self);
static void ___lambda688__gtk_button_clicked (GtkButton* _sender,
                                       gpointer self);
static void __lambda691_ (LayoutsSectionBoard* self);
VALA_EXTERN GType dialogs_manage_section_order_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DialogsManageSectionOrder, g_object_unref)
VALA_EXTERN DialogsManageSectionOrder* dialogs_manage_section_order_new (ObjectsProject* project);
VALA_EXTERN DialogsManageSectionOrder* dialogs_manage_section_order_construct (GType object_type,
                                                                   ObjectsProject* project);
static void ___lambda691__gtk_button_clicked (GtkButton* _sender,
                                       gpointer self);
static void __lambda692_ (LayoutsSectionBoard* self);
VALA_EXTERN Planify* planify_get_instance (void);
static void ___lambda692__gtk_button_clicked (GtkButton* _sender,
                                       gpointer self);
static void __lambda693_ (LayoutsSectionBoard* self);
static void __lambda694_ (LayoutsSectionBoard* self,
                   const gchar* response);
VALA_EXTERN void layouts_section_board_set_is_loading (LayoutsSectionBoard* self,
                                           gboolean value);
static void ____lambda695_ (LayoutsSectionBoard* self,
                     GObject* obj,
                     GAsyncResult* res);
static void _____lambda695__gasync_ready_callback (GObject* source_object,
                                            GAsyncResult* res,
                                            gpointer self);
static void ___lambda694__adw_alert_dialog_response (AdwAlertDialog* _sender,
                                              const gchar* response,
                                              gpointer self);
static void ___lambda693__gtk_button_clicked (GtkButton* _sender,
                                       gpointer self);
static void __lambda696_ (LayoutsSectionBoard* self);
VALA_EXTERN GType dialogs_completed_tasks_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DialogsCompletedTasks, g_object_unref)
VALA_EXTERN DialogsCompletedTasks* dialogs_completed_tasks_new (ObjectsProject* project);
VALA_EXTERN DialogsCompletedTasks* dialogs_completed_tasks_construct (GType object_type,
                                                          ObjectsProject* project);
VALA_EXTERN void dialogs_completed_tasks_add_update_filter (DialogsCompletedTasks* self,
                                                ObjectsSection* section);
static void ___lambda696__gtk_button_clicked (GtkButton* _sender,
                                       gpointer self);
static void __lambda697_ (LayoutsSectionBoard* self);
static void ___lambda697__gtk_button_clicked (GtkButton* _sender,
                                       gpointer self);
VALA_EXTERN GType dialogs_quick_add_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DialogsQuickAdd, g_object_unref)
VALA_EXTERN DialogsQuickAdd* dialogs_quick_add_new (void);
VALA_EXTERN DialogsQuickAdd* dialogs_quick_add_construct (GType object_type);
VALA_EXTERN void dialogs_quick_add_for_base_object (DialogsQuickAdd* self,
                                        ObjectsBaseObject* base_object);
VALA_EXTERN void dialogs_quick_add_update_content (DialogsQuickAdd* self,
                                       const gchar* content);
VALA_EXTERN void dialogs_quick_add_set_new_task_position (DialogsQuickAdd* self,
                                              NewTaskPosition value);
static Block46Data* block46_data_ref (Block46Data* _data46_);
static void block46_data_unref (void * _userdata_);
static void ___lambda690_ (Block46Data* _data46_,
                    GObject* obj,
                    GAsyncResult* res);
static void ____lambda690__gasync_ready_callback (GObject* source_object,
                                           GAsyncResult* res,
                                           gpointer self);
static void layouts_section_board_build_drag_and_drop (LayoutsSectionBoard* self);
static void layouts_section_board_build_drop_target (LayoutsSectionBoard* self);
static gboolean __lambda698_ (LayoutsSectionBoard* self,
                       GValue* value,
                       gdouble x,
                       gdouble y);
static Block47Data* block47_data_ref (Block47Data* _data47_);
static void block47_data_unref (void * _userdata_);
VALA_EXTERN void layouts_item_board_drag_end (LayoutsItemBoard* self);
static void ___lambda699_ (Block47Data* _data47_,
                    GObject* obj,
                    GAsyncResult* res);
static void ____lambda699__gasync_ready_callback (GObject* source_object,
                                           GAsyncResult* res,
                                           gpointer self);
VALA_EXTERN void utils_task_utils_update_single_item_order (GtkListBox* listbox,
                                                LayoutsItemBase* moved_row,
                                                gint new_index);
static gboolean ___lambda698__gtk_drop_target_drop (GtkDropTarget* _sender,
                                             GValue* value,
                                             gdouble x,
                                             gdouble y,
                                             gpointer self);
VALA_EXTERN void layouts_section_board_hide_destroy (LayoutsSectionBoard* self);
VALA_EXTERN void layouts_section_board_clean_up (LayoutsSectionBoard* self);
static gboolean __lambda700_ (LayoutsSectionBoard* self);
static gboolean ___lambda700__gsource_func (gpointer self);
VALA_EXTERN void layouts_item_base_clean_up (LayoutsItemBase* self);
static void _g_object_unref0_ (gpointer var);
static inline void _g_list_free__g_object_unref0_ (GList* self);
static void layouts_section_board_set_section (LayoutsSectionBoard* self,
                                        ObjectsSection* value);
VALA_EXTERN gint layouts_section_board_get_section_count (LayoutsSectionBoard* self);
static GObject * layouts_section_board_constructor (GType type,
                                             guint n_construct_properties,
                                             GObjectConstructParam * construct_properties);
VALA_EXTERN GType widgets_scrolled_window_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (WidgetsScrolledWindow, g_object_unref)
VALA_EXTERN WidgetsScrolledWindow* widgets_scrolled_window_new (GtkWidget* widget,
                                                    GtkOrientation orientation);
VALA_EXTERN WidgetsScrolledWindow* widgets_scrolled_window_construct (GType object_type,
                                                          GtkWidget* widget,
                                                          GtkOrientation orientation);
static gboolean _layouts_section_board___lambda701_ (LayoutsSectionBoard* self,
                                              GtkListBoxRow* row);
VALA_EXTERN gboolean utils_task_utils_items_filter_func (ObjectsItem* item,
                                             GeeHashMap* filters);
static gboolean __layouts_section_board___lambda701__gtk_list_box_filter_func (GtkListBoxRow* row,
                                                                        gpointer self);
static void _layouts_section_board___lambda702_ (LayoutsSectionBoard* self,
                                          GtkListBoxRow* row);
static void __layouts_section_board___lambda702__gtk_list_box_row_selected (GtkListBox* _sender,
                                                                     GtkListBoxRow* row,
                                                                     gpointer self);
static void _layouts_section_board___lambda703_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda703__objects_base_object_updated (ObjectsBaseObject* _sender,
                                                                       const gchar* update_id,
                                                                       gpointer self);
static void _layouts_section_board____lambda704_ (LayoutsSectionBoard* self,
                                           ObjectsItem* item);
static void __layouts_section_board____lambda704__objects_project_item_added (ObjectsProject* _sender,
                                                                       ObjectsItem* item,
                                                                       gpointer self);
static void _layouts_section_board____lambda705_ (LayoutsSectionBoard* self);
static void __layouts_section_board____lambda705__objects_base_object_count_updated (ObjectsBaseObject* _sender,
                                                                              gpointer self);
static void _layouts_section_board____lambda706_ (LayoutsSectionBoard* self,
                                           ObjectsItem* item);
static void __layouts_section_board____lambda706__objects_section_item_added (ObjectsSection* _sender,
                                                                       ObjectsItem* item,
                                                                       gpointer self);
static void _layouts_section_board___lambda707_ (LayoutsSectionBoard* self,
                                          ObjectsItem* item,
                                          gboolean old_checked);
static void __layouts_section_board___lambda707__services_event_bus_checked_toggled (ServicesEventBus* _sender,
                                                                              ObjectsItem* item,
                                                                              gboolean old_checked,
                                                                              gpointer self);
static void _layouts_section_board___lambda708_ (LayoutsSectionBoard* self,
                                          ObjectsItem* item,
                                          const gchar* update_id);
VALA_EXTERN void layouts_item_base_update_request (LayoutsItemBase* self);
static void __layouts_section_board___lambda708__services_store_item_updated (ServicesStore* _sender,
                                                                       ObjectsItem* item,
                                                                       const gchar* update_id,
                                                                       gpointer self);
static void _layouts_section_board___lambda709_ (LayoutsSectionBoard* self,
                                          ObjectsItem* item);
static void __layouts_section_board___lambda709__services_store_item_pin_change (ServicesStore* _sender,
                                                                          ObjectsItem* item,
                                                                          gpointer self);
static void _layouts_section_board___lambda710_ (LayoutsSectionBoard* self,
                                          ObjectsItem* item);
static void __layouts_section_board___lambda710__services_store_item_deleted (ServicesStore* _sender,
                                                                       ObjectsItem* item,
                                                                       gpointer self);
static void _layouts_section_board___lambda711_ (LayoutsSectionBoard* self,
                                          ObjectsItem* item,
                                          const gchar* old_project_id,
                                          const gchar* old_section_id,
                                          const gchar* old_parent_id);
static void __layouts_section_board___lambda711__services_event_bus_item_moved (ServicesEventBus* _sender,
                                                                         ObjectsItem* item,
                                                                         const gchar* old_project_id,
                                                                         const gchar* old_section_id,
                                                                         const gchar* old_parent_id,
                                                                         gpointer self);
static void _layouts_section_board___lambda712_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda712__objects_project_sorted_by_changed (ObjectsProject* _sender,
                                                                             gpointer self);
static void _layouts_section_board___lambda713_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda713__objects_project_sort_order_changed (ObjectsProject* _sender,
                                                                              gpointer self);
static void _layouts_section_board___lambda714_ (LayoutsSectionBoard* self,
                                          const gchar* project_id,
                                          const gchar* section_id,
                                          gboolean value);
static void __layouts_section_board___lambda714__services_event_bus_update_section_sort_func (ServicesEventBus* _sender,
                                                                                       const gchar* project_id,
                                                                                       const gchar* section_id,
                                                                                       gboolean active,
                                                                                       gpointer self);
static void _layouts_section_board___lambda715_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda715__objects_section_section_count_updated (ObjectsSection* _sender,
                                                                                 gpointer self);
static void _layouts_section_board___lambda716_ (LayoutsSectionBoard* self,
                                          GtkWidget* _row,
                                          const gchar* old_section_id);
static void __layouts_section_board___lambda716__services_event_bus_update_inserted_item_map (ServicesEventBus* _sender,
                                                                                       GtkWidget* row,
                                                                                       const gchar* old_section_id,
                                                                                       const gchar* old_parent_id,
                                                                                       gpointer self);
static void _layouts_section_board___lambda717_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda717__objects_base_object_filter_added (ObjectsBaseObject* _sender,
                                                                            ObjectsFiltersFilterItem* filters,
                                                                            gpointer self);
static void _layouts_section_board___lambda718_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda718__objects_base_object_filter_removed (ObjectsBaseObject* _sender,
                                                                              ObjectsFiltersFilterItem* filters,
                                                                              gpointer self);
static void _layouts_section_board___lambda719_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda719__objects_base_object_filter_updated (ObjectsBaseObject* _sender,
                                                                              ObjectsFiltersFilterItem* filters,
                                                                              gpointer self);
static void _layouts_section_board___lambda720_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda720__objects_base_object_sensitive_change (ObjectsBaseObject* _sender,
                                                                                gpointer self);
static void _layouts_section_board___lambda721_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda721__objects_base_object_loading_change (ObjectsBaseObject* _sender,
                                                                              gpointer self);
static void _layouts_section_board___lambda722_ (LayoutsSectionBoard* self,
                                          gint n_press,
                                          gdouble x,
                                          gdouble y);
static void __layouts_section_board___lambda722__gtk_gesture_click_released (GtkGestureClick* _sender,
                                                                      gint n_press,
                                                                      gdouble x,
                                                                      gdouble y,
                                                                      gpointer self);
static void _layouts_section_board_show_completed_changed_objects_project_show_completed_changed (ObjectsProject* _sender,
                                                                                           gpointer self);
static void _layouts_section_board___lambda723_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda723__gtk_button_clicked (GtkButton* _sender,
                                                              gpointer self);
static void _layouts_section_board___lambda724_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda724__gtk_button_clicked (GtkButton* _sender,
                                                              gpointer self);
static void _layouts_section_board___lambda725_ (LayoutsSectionBoard* self);
static void __layouts_section_board___lambda725__objects_source_sync_finished (ObjectsSource* _sender,
                                                                        gpointer self);
static void _layouts_section_board___lambda726_ (LayoutsSectionBoard* self,
                                          const gchar* project_id,
                                          gboolean active);
static void __layouts_section_board___lambda726__services_event_bus_drag_n_drop_active (ServicesEventBus* _sender,
                                                                                 const gchar* project_id,
                                                                                 gboolean active,
                                                                                 gpointer self);
static void layouts_section_board_finalize (GObject * obj);
static GType layouts_section_board_get_type_once (void);
static void _vala_layouts_section_board_get_property (GObject * object,
                                               guint property_id,
                                               GValue * value,
                                               GParamSpec * pspec);
static void _vala_layouts_section_board_set_property (GObject * object,
                                               guint property_id,
                                               const GValue * value,
                                               GParamSpec * pspec);
static void _vala_array_destroy (gpointer array,
                          gssize array_length,
                          GDestroyNotify destroy_func);
static void _vala_array_free (gpointer array,
                       gssize array_length,
                       GDestroyNotify destroy_func);

static inline gpointer
layouts_section_board_get_instance_private (LayoutsSectionBoard* self)
{
	return G_STRUCT_MEMBER_P (self, LayoutsSectionBoard_private_offset);
}

LayoutsSectionBoard*
layouts_section_board_construct (GType object_type,
                                 ObjectsSection* section)
{
	LayoutsSectionBoard * self = NULL;
	g_return_val_if_fail (section != NULL, NULL);
	self = (LayoutsSectionBoard*) g_object_new (object_type, "section", section, "focusable", FALSE, "width-request", 350, "vexpand", TRUE, NULL);
	return self;
}

LayoutsSectionBoard*
layouts_section_board_new (ObjectsSection* section)
{
	return layouts_section_board_construct (LAYOUTS_TYPE_SECTION_BOARD, section);
}

LayoutsSectionBoard*
layouts_section_board_construct_for_project (GType object_type,
                                             ObjectsProject* project)
{
	LayoutsSectionBoard * self = NULL;
	ObjectsSection* section = NULL;
	ObjectsSection* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	g_return_val_if_fail (project != NULL, NULL);
	_tmp0_ = objects_section_new ();
	section = _tmp0_;
	objects_base_object_set_id ((ObjectsBaseObject*) section, "");
	_tmp1_ = objects_base_object_get_id ((ObjectsBaseObject*) project);
	_tmp2_ = _tmp1_;
	objects_section_set_project_id (section, _tmp2_);
	objects_base_object_set_name ((ObjectsBaseObject*) section, _ ("(No Section)"));
	self = (LayoutsSectionBoard*) g_object_new (object_type, "section", section, "focusable", FALSE, "width-request", 350, "vexpand", TRUE, NULL);
	_g_object_unref0 (section);
	return self;
}

LayoutsSectionBoard*
layouts_section_board_new_for_project (ObjectsProject* project)
{
	return layouts_section_board_construct_for_project (LAYOUTS_TYPE_SECTION_BOARD, project);
}

static gchar*
string_strip (const gchar* self)
{
	gchar* _result_ = NULL;
	gchar* _tmp0_;
	gchar* result;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = g_strdup (self);
	_result_ = _tmp0_;
	g_strstrip (_result_);
	result = _result_;
	return result;
}

static void
layouts_section_board_update_request (LayoutsSectionBoard* self)
{
	GtkLabel* _tmp0_;
	ObjectsSection* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	GtkLabel* _tmp4_;
	ObjectsSection* _tmp5_;
	const gchar* _tmp6_;
	const gchar* _tmp7_;
	gchar* _tmp8_;
	gchar* _tmp9_;
	GtkRevealer* _tmp10_;
	GtkLabel* _tmp11_;
	const gchar* _tmp12_;
	const gchar* _tmp13_;
	gint _tmp14_;
	gint _tmp15_;
	Util* _tmp16_;
	Util* _tmp17_;
	Util* _tmp18_;
	Util* _tmp19_;
	ObjectsSection* _tmp20_;
	const gchar* _tmp21_;
	const gchar* _tmp22_;
	gchar* _tmp23_;
	gchar* _tmp24_;
	GtkGrid* _tmp25_;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->priv->name_label;
	_tmp1_ = self->priv->_section;
	_tmp2_ = objects_base_object_get_name ((ObjectsBaseObject*) _tmp1_);
	_tmp3_ = _tmp2_;
	gtk_label_set_label (_tmp0_, _tmp3_);
	_tmp4_ = self->priv->description_label;
	_tmp5_ = self->priv->_section;
	_tmp6_ = objects_section_get_description (_tmp5_);
	_tmp7_ = _tmp6_;
	_tmp8_ = string_strip (_tmp7_);
	_tmp9_ = _tmp8_;
	gtk_label_set_label (_tmp4_, _tmp9_);
	_g_free0 (_tmp9_);
	_tmp10_ = self->priv->description_revealer;
	_tmp11_ = self->priv->description_label;
	_tmp12_ = gtk_label_get_label (_tmp11_);
	_tmp13_ = _tmp12_;
	_tmp14_ = strlen (_tmp13_);
	_tmp15_ = _tmp14_;
	gtk_revealer_set_reveal_child (_tmp10_, _tmp15_ > 0);
	_tmp16_ = util_get_default ();
	_tmp17_ = _tmp16_;
	_tmp18_ = util_get_default ();
	_tmp19_ = _tmp18_;
	_tmp20_ = self->priv->_section;
	_tmp21_ = objects_base_object_get_color ((ObjectsBaseObject*) _tmp20_);
	_tmp22_ = _tmp21_;
	_tmp23_ = util_get_color (_tmp19_, _tmp22_);
	_tmp24_ = _tmp23_;
	_tmp25_ = self->priv->widget_color;
	util_set_widget_color (_tmp17_, _tmp24_, (GtkWidget*) _tmp25_);
	_g_free0 (_tmp24_);
	_g_object_unref0 (_tmp19_);
	_g_object_unref0 (_tmp17_);
}

static void
layouts_section_board_update_count_label (LayoutsSectionBoard* self,
                                          gint count)
{
	gchar* _tmp0_ = NULL;
	GtkLabel* _tmp3_;
	g_return_if_fail (self != NULL);
	if (count <= 0) {
		gchar* _tmp1_;
		_tmp1_ = g_strdup ("");
		_g_free0 (_tmp0_);
		_tmp0_ = _tmp1_;
	} else {
		gchar* _tmp2_;
		_tmp2_ = g_strdup_printf ("%i", count);
		_g_free0 (_tmp0_);
		_tmp0_ = _tmp2_;
	}
	_tmp3_ = self->priv->count_label;
	gtk_label_set_label (_tmp3_, _tmp0_);
	_g_free0 (_tmp0_);
}

static void
layouts_section_board_refresh_count_label (LayoutsSectionBoard* self)
{
	gint count = 0;
	gboolean _tmp0_;
	gboolean _tmp1_;
	g_return_if_fail (self != NULL);
	_tmp0_ = layouts_section_board_get_is_inbox_section (self);
	_tmp1_ = _tmp0_;
	if (_tmp1_) {
		count = 0;
		{
			GeeArrayList* _item_list = NULL;
			ObjectsSection* _tmp2_;
			ObjectsProject* _tmp3_;
			ObjectsProject* _tmp4_;
			GeeArrayList* _tmp5_;
			GeeArrayList* _tmp6_;
			gint _item_size = 0;
			GeeArrayList* _tmp7_;
			gint _tmp8_;
			gint _tmp9_;
			gint _item_index = 0;
			_tmp2_ = self->priv->_section;
			_tmp3_ = objects_section_get_project (_tmp2_);
			_tmp4_ = _tmp3_;
			_tmp5_ = objects_project_get_items (_tmp4_);
			_tmp6_ = _tmp5_;
			_item_list = _tmp6_;
			_tmp7_ = _item_list;
			_tmp8_ = gee_abstract_collection_get_size ((GeeAbstractCollection*) _tmp7_);
			_tmp9_ = _tmp8_;
			_item_size = _tmp9_;
			_item_index = -1;
			while (TRUE) {
				gint _tmp10_;
				gint _tmp11_;
				ObjectsItem* item = NULL;
				GeeArrayList* _tmp12_;
				gpointer _tmp13_;
				ObjectsItem* _tmp14_;
				gboolean _tmp15_;
				gboolean _tmp16_;
				_item_index = _item_index + 1;
				_tmp10_ = _item_index;
				_tmp11_ = _item_size;
				if (!(_tmp10_ < _tmp11_)) {
					break;
				}
				_tmp12_ = _item_list;
				_tmp13_ = gee_abstract_list_get ((GeeAbstractList*) _tmp12_, _item_index);
				item = (ObjectsItem*) _tmp13_;
				_tmp14_ = item;
				_tmp15_ = objects_item_get_checked (_tmp14_);
				_tmp16_ = _tmp15_;
				if (!_tmp16_) {
					gint _tmp17_;
					ObjectsItem* _tmp18_;
					_tmp17_ = count;
					count = _tmp17_ + 1;
					_tmp18_ = item;
					count += layouts_section_board_get_subitem_count (self, _tmp18_);
				}
				_g_object_unref0 (item);
			}
		}
	} else {
		ObjectsSection* _tmp19_;
		gint _tmp20_;
		gint _tmp21_;
		_tmp19_ = self->priv->_section;
		_tmp20_ = objects_section_get_section_count (_tmp19_);
		_tmp21_ = _tmp20_;
		count = _tmp21_;
	}
	layouts_section_board_update_count_label (self, count);
}

static gint
layouts_section_board_get_subitem_count (LayoutsSectionBoard* self,
                                         ObjectsItem* item)
{
	gint count = 0;
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	g_return_val_if_fail (item != NULL, -1);
	count = 0;
	{
		GeeArrayList* _subitem_list = NULL;
		ServicesStore* _tmp0_;
		GeeArrayList* _tmp1_;
		gint _subitem_size = 0;
		GeeArrayList* _tmp2_;
		gint _tmp3_;
		gint _tmp4_;
		gint _subitem_index = 0;
		_tmp0_ = services_store_instance ();
		_tmp1_ = services_store_get_subitems (_tmp0_, item);
		_subitem_list = _tmp1_;
		_tmp2_ = _subitem_list;
		_tmp3_ = gee_abstract_collection_get_size ((GeeAbstractCollection*) _tmp2_);
		_tmp4_ = _tmp3_;
		_subitem_size = _tmp4_;
		_subitem_index = -1;
		while (TRUE) {
			gint _tmp5_;
			gint _tmp6_;
			ObjectsItem* subitem = NULL;
			GeeArrayList* _tmp7_;
			gpointer _tmp8_;
			ObjectsItem* _tmp9_;
			gboolean _tmp10_;
			gboolean _tmp11_;
			_subitem_index = _subitem_index + 1;
			_tmp5_ = _subitem_index;
			_tmp6_ = _subitem_size;
			if (!(_tmp5_ < _tmp6_)) {
				break;
			}
			_tmp7_ = _subitem_list;
			_tmp8_ = gee_abstract_list_get ((GeeAbstractList*) _tmp7_, _subitem_index);
			subitem = (ObjectsItem*) _tmp8_;
			_tmp9_ = subitem;
			_tmp10_ = objects_item_get_checked (_tmp9_);
			_tmp11_ = _tmp10_;
			if (!_tmp11_) {
				gint _tmp12_;
				ObjectsItem* _tmp13_;
				_tmp12_ = count;
				count = _tmp12_ + 1;
				_tmp13_ = subitem;
				count += layouts_section_board_get_subitem_count (self, _tmp13_);
			}
			_g_object_unref0 (subitem);
		}
		_g_object_unref0 (_subitem_list);
	}
	result = count;
	return result;
}

static gpointer
_g_object_ref0 (gpointer self)
{
	return self ? g_object_ref (self) : NULL;
}

static gint
__lambda684_ (LayoutsSectionBoard* self,
              ObjectsItem* item1,
              ObjectsItem* item2)
{
	Util* _tmp0_;
	Util* _tmp1_;
	ObjectsSection* _tmp2_;
	ObjectsProject* _tmp3_;
	ObjectsProject* _tmp4_;
	SortedByType _tmp5_;
	SortedByType _tmp6_;
	ObjectsSection* _tmp7_;
	ObjectsProject* _tmp8_;
	ObjectsProject* _tmp9_;
	SortOrderType _tmp10_;
	SortOrderType _tmp11_;
	gint _tmp12_;
	gint result;
	g_return_val_if_fail (item1 != NULL, -1);
	g_return_val_if_fail (item2 != NULL, -1);
	_tmp0_ = util_get_default ();
	_tmp1_ = _tmp0_;
	_tmp2_ = self->priv->_section;
	_tmp3_ = objects_section_get_project (_tmp2_);
	_tmp4_ = _tmp3_;
	_tmp5_ = objects_project_get_sorted_by (_tmp4_);
	_tmp6_ = _tmp5_;
	_tmp7_ = self->priv->_section;
	_tmp8_ = objects_section_get_project (_tmp7_);
	_tmp9_ = _tmp8_;
	_tmp10_ = objects_project_get_sort_order (_tmp9_);
	_tmp11_ = _tmp10_;
	_tmp12_ = util_set_item_sort_func (_tmp1_, item1, item2, _tmp6_, _tmp11_);
	_g_object_unref0 (_tmp1_);
	result = _tmp12_;
	return result;
}

static gint
___lambda684__gcompare_data_func (gconstpointer a,
                                  gconstpointer b,
                                  gpointer self)
{
	gint result;
	result = __lambda684_ ((LayoutsSectionBoard*) self, (ObjectsItem*) a, (ObjectsItem*) b);
	return result;
}

void
layouts_section_board_add_items (LayoutsSectionBoard* self)
{
	GeeHashMap* _tmp0_;
	GeeArrayList* _tmp1_ = NULL;
	gboolean _tmp2_;
	gboolean _tmp3_;
	GeeArrayList* items = NULL;
	GeeArrayList* _tmp12_;
	GeeArrayList* _tmp13_;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->items_map;
	gee_abstract_map_clear ((GeeAbstractMap*) _tmp0_);
	_tmp2_ = layouts_section_board_get_is_inbox_section (self);
	_tmp3_ = _tmp2_;
	if (_tmp3_) {
		ObjectsSection* _tmp4_;
		ObjectsProject* _tmp5_;
		ObjectsProject* _tmp6_;
		GeeArrayList* _tmp7_;
		GeeArrayList* _tmp8_;
		_tmp4_ = self->priv->_section;
		_tmp5_ = objects_section_get_project (_tmp4_);
		_tmp6_ = _tmp5_;
		_tmp7_ = objects_project_get_items (_tmp6_);
		_tmp8_ = _tmp7_;
		_tmp1_ = _tmp8_;
	} else {
		ObjectsSection* _tmp9_;
		GeeArrayList* _tmp10_;
		GeeArrayList* _tmp11_;
		_tmp9_ = self->priv->_section;
		_tmp10_ = objects_section_get_items (_tmp9_);
		_tmp11_ = _tmp10_;
		_tmp1_ = _tmp11_;
	}
	_tmp12_ = _g_object_ref0 (_tmp1_);
	items = _tmp12_;
	_tmp13_ = items;
	gee_list_sort ((GeeList*) _tmp13_, ___lambda684__gcompare_data_func, g_object_ref (self), g_object_unref);
	{
		GeeArrayList* _item_list = NULL;
		GeeArrayList* _tmp14_;
		gint _item_size = 0;
		GeeArrayList* _tmp15_;
		gint _tmp16_;
		gint _tmp17_;
		gint _item_index = 0;
		_tmp14_ = items;
		_item_list = _tmp14_;
		_tmp15_ = _item_list;
		_tmp16_ = gee_abstract_collection_get_size ((GeeAbstractCollection*) _tmp15_);
		_tmp17_ = _tmp16_;
		_item_size = _tmp17_;
		_item_index = -1;
		while (TRUE) {
			gint _tmp18_;
			gint _tmp19_;
			ObjectsItem* item = NULL;
			GeeArrayList* _tmp20_;
			gpointer _tmp21_;
			ObjectsItem* _tmp22_;
			_item_index = _item_index + 1;
			_tmp18_ = _item_index;
			_tmp19_ = _item_size;
			if (!(_tmp18_ < _tmp19_)) {
				break;
			}
			_tmp20_ = _item_list;
			_tmp21_ = gee_abstract_list_get ((GeeAbstractList*) _tmp20_, _item_index);
			item = (ObjectsItem*) _tmp21_;
			_tmp22_ = item;
			layouts_section_board_add_item (self, _tmp22_, -1);
			_g_object_unref0 (item);
		}
	}
	layouts_section_board_update_sort (self);
	_g_object_unref0 (items);
}

static gint
_layouts_section_board_set_sort_func_gtk_list_box_sort_func (GtkListBoxRow* row1,
                                                             GtkListBoxRow* row2,
                                                             gpointer self)
{
	gint result;
	result = layouts_section_board_set_sort_func ((LayoutsSectionBoard*) self, row1, row2);
	return result;
}

static void
layouts_section_board_update_sort (LayoutsSectionBoard* self)
{
	GtkListBox* _tmp0_;
	GtkListBox* _tmp1_;
	GtkListBox* _tmp2_;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->priv->listbox;
	gtk_list_box_set_sort_func (_tmp0_, _layouts_section_board_set_sort_func_gtk_list_box_sort_func, g_object_ref (self), g_object_unref);
	_tmp1_ = self->priv->listbox;
	gtk_list_box_set_sort_func (_tmp1_, NULL, NULL, NULL);
	_tmp2_ = self->priv->listbox;
	gtk_list_box_invalidate_filter (_tmp2_);
}

static gint
layouts_section_board_set_sort_func (LayoutsSectionBoard* self,
                                     GtkListBoxRow* lbrow,
                                     GtkListBoxRow* lbbefore)
{
	ObjectsItem* item1 = NULL;
	ObjectsItem* _tmp0_;
	ObjectsItem* _tmp1_;
	ObjectsItem* _tmp2_;
	ObjectsItem* item2 = NULL;
	ObjectsItem* _tmp3_;
	ObjectsItem* _tmp4_;
	ObjectsItem* _tmp5_;
	Util* _tmp6_;
	Util* _tmp7_;
	ObjectsSection* _tmp8_;
	ObjectsProject* _tmp9_;
	ObjectsProject* _tmp10_;
	SortedByType _tmp11_;
	SortedByType _tmp12_;
	ObjectsSection* _tmp13_;
	ObjectsProject* _tmp14_;
	ObjectsProject* _tmp15_;
	SortOrderType _tmp16_;
	SortOrderType _tmp17_;
	gint _tmp18_;
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	g_return_val_if_fail (lbrow != NULL, -1);
	g_return_val_if_fail (lbbefore != NULL, -1);
	_tmp0_ = layouts_item_base_get_item ((LayoutsItemBase*) G_TYPE_CHECK_INSTANCE_CAST (lbrow, LAYOUTS_TYPE_ITEM_BOARD, LayoutsItemBoard));
	_tmp1_ = _tmp0_;
	_tmp2_ = _g_object_ref0 (_tmp1_);
	item1 = _tmp2_;
	_tmp3_ = layouts_item_base_get_item ((LayoutsItemBase*) G_TYPE_CHECK_INSTANCE_CAST (lbbefore, LAYOUTS_TYPE_ITEM_BOARD, LayoutsItemBoard));
	_tmp4_ = _tmp3_;
	_tmp5_ = _g_object_ref0 (_tmp4_);
	item2 = _tmp5_;
	_tmp6_ = util_get_default ();
	_tmp7_ = _tmp6_;
	_tmp8_ = self->priv->_section;
	_tmp9_ = objects_section_get_project (_tmp8_);
	_tmp10_ = _tmp9_;
	_tmp11_ = objects_project_get_sorted_by (_tmp10_);
	_tmp12_ = _tmp11_;
	_tmp13_ = self->priv->_section;
	_tmp14_ = objects_section_get_project (_tmp13_);
	_tmp15_ = _tmp14_;
	_tmp16_ = objects_project_get_sort_order (_tmp15_);
	_tmp17_ = _tmp16_;
	_tmp18_ = util_set_item_sort_func (_tmp7_, item1, item2, _tmp12_, _tmp17_);
	_g_object_unref0 (_tmp7_);
	result = _tmp18_;
	_g_object_unref0 (item2);
	_g_object_unref0 (item1);
	return result;
}

void
layouts_section_board_add_item (LayoutsSectionBoard* self,
                                ObjectsItem* item,
                                gint position)
{
	gboolean _tmp0_;
	gboolean _tmp1_;
	gboolean _tmp2_;
	gboolean _tmp3_;
	GeeHashMap* _tmp4_;
	const gchar* _tmp5_;
	const gchar* _tmp6_;
	GeeHashMap* _tmp7_;
	const gchar* _tmp8_;
	const gchar* _tmp9_;
	LayoutsItemBoard* _tmp10_;
	LayoutsItemBoard* _tmp11_;
	GtkListBox* _tmp12_;
	GeeHashMap* _tmp13_;
	const gchar* _tmp14_;
	const gchar* _tmp15_;
	gpointer _tmp16_;
	LayoutsItemBoard* _tmp17_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (item != NULL);
	_tmp0_ = objects_item_get_checked (item);
	_tmp1_ = _tmp0_;
	if (_tmp1_) {
		return;
	}
	_tmp2_ = objects_item_get_pinned (item);
	_tmp3_ = _tmp2_;
	if (_tmp3_) {
		return;
	}
	_tmp4_ = self->items_map;
	_tmp5_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
	_tmp6_ = _tmp5_;
	if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp4_, _tmp6_)) {
		return;
	}
	_tmp7_ = self->items_map;
	_tmp8_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
	_tmp9_ = _tmp8_;
	_tmp10_ = layouts_item_board_new (item);
	g_object_ref_sink (_tmp10_);
	_tmp11_ = _tmp10_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp7_, _tmp9_, _tmp11_);
	_g_object_unref0 (_tmp11_);
	_tmp12_ = self->priv->listbox;
	_tmp13_ = self->items_map;
	_tmp14_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
	_tmp15_ = _tmp14_;
	_tmp16_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp13_, _tmp15_);
	_tmp17_ = (LayoutsItemBoard*) _tmp16_;
	gtk_list_box_append (_tmp12_, (GtkWidget*) _tmp17_);
	_g_object_unref0 (_tmp17_);
}

static void
layouts_section_board_show_completed_changed (LayoutsSectionBoard* self)
{
	ObjectsSection* _tmp0_;
	ObjectsProject* _tmp1_;
	ObjectsProject* _tmp2_;
	gboolean _tmp3_;
	gboolean _tmp4_;
	GtkRevealer* _tmp16_;
	ObjectsSection* _tmp17_;
	ObjectsProject* _tmp18_;
	ObjectsProject* _tmp19_;
	gboolean _tmp20_;
	gboolean _tmp21_;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->priv->_section;
	_tmp1_ = objects_section_get_project (_tmp0_);
	_tmp2_ = _tmp1_;
	_tmp3_ = objects_project_get_show_completed (_tmp2_);
	_tmp4_ = _tmp3_;
	if (_tmp4_) {
		layouts_section_board_add_completed_items (self);
	} else {
		GeeHashMap* _tmp15_;
		{
			GeeIterator* _row_it = NULL;
			GeeHashMap* _tmp5_;
			GeeCollection* _tmp6_;
			GeeCollection* _tmp7_;
			GeeCollection* _tmp8_;
			GeeIterator* _tmp9_;
			GeeIterator* _tmp10_;
			_tmp5_ = self->checked_items_map;
			_tmp6_ = gee_abstract_map_get_values ((GeeAbstractMap*) _tmp5_);
			_tmp7_ = _tmp6_;
			_tmp8_ = _tmp7_;
			_tmp9_ = gee_iterable_iterator ((GeeIterable*) _tmp8_);
			_tmp10_ = _tmp9_;
			_g_object_unref0 (_tmp8_);
			_row_it = _tmp10_;
			while (TRUE) {
				GeeIterator* _tmp11_;
				LayoutsItemBoard* row = NULL;
				GeeIterator* _tmp12_;
				gpointer _tmp13_;
				LayoutsItemBoard* _tmp14_;
				_tmp11_ = _row_it;
				if (!gee_iterator_next (_tmp11_)) {
					break;
				}
				_tmp12_ = _row_it;
				_tmp13_ = gee_iterator_get (_tmp12_);
				row = (LayoutsItemBoard*) _tmp13_;
				_tmp14_ = row;
				layouts_item_base_hide_destroy ((LayoutsItemBase*) _tmp14_);
				_g_object_unref0 (row);
			}
			_g_object_unref0 (_row_it);
		}
		_tmp15_ = self->checked_items_map;
		gee_abstract_map_clear ((GeeAbstractMap*) _tmp15_);
	}
	_tmp16_ = self->priv->checked_revealer;
	_tmp17_ = self->priv->_section;
	_tmp18_ = objects_section_get_project (_tmp17_);
	_tmp19_ = _tmp18_;
	_tmp20_ = objects_project_get_show_completed (_tmp19_);
	_tmp21_ = _tmp20_;
	gtk_revealer_set_reveal_child (_tmp16_, _tmp21_);
}

static gint
__lambda685_ (LayoutsSectionBoard* self,
              ObjectsItem* a,
              ObjectsItem* b)
{
	GDateTime* completed_a = NULL;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	GDateTime* _tmp2_;
	GDateTime* _tmp3_;
	GDateTime* _tmp4_;
	GDateTime* _tmp5_;
	GDateTime* completed_b = NULL;
	const gchar* _tmp6_;
	const gchar* _tmp7_;
	GDateTime* _tmp8_;
	GDateTime* _tmp9_;
	GDateTime* _tmp10_;
	GDateTime* _tmp11_;
	gint result;
	g_return_val_if_fail (a != NULL, -1);
	g_return_val_if_fail (b != NULL, -1);
	_tmp0_ = objects_item_get_completed_at (a);
	_tmp1_ = _tmp0_;
	_tmp2_ = utils_datetime_get_date_from_string (_tmp1_);
	_tmp3_ = _tmp2_;
	_tmp4_ = utils_datetime_get_date_only (_tmp3_);
	_tmp5_ = _tmp4_;
	_g_date_time_unref0 (_tmp3_);
	completed_a = _tmp5_;
	_tmp6_ = objects_item_get_completed_at (b);
	_tmp7_ = _tmp6_;
	_tmp8_ = utils_datetime_get_date_from_string (_tmp7_);
	_tmp9_ = _tmp8_;
	_tmp10_ = utils_datetime_get_date_only (_tmp9_);
	_tmp11_ = _tmp10_;
	_g_date_time_unref0 (_tmp9_);
	completed_b = _tmp11_;
	result = g_date_time_compare (completed_b, completed_a);
	_g_date_time_unref0 (completed_b);
	_g_date_time_unref0 (completed_a);
	return result;
}

static gint
___lambda685__gcompare_data_func (gconstpointer a,
                                  gconstpointer b,
                                  gpointer self)
{
	gint result;
	result = __lambda685_ ((LayoutsSectionBoard*) self, (ObjectsItem*) a, (ObjectsItem*) b);
	return result;
}

void
layouts_section_board_add_completed_items (LayoutsSectionBoard* self)
{
	GeeHashMap* _tmp10_;
	GeeArrayList* _tmp11_;
	GeeArrayList* _tmp12_ = NULL;
	gboolean _tmp13_;
	gboolean _tmp14_;
	GeeArrayList* _tmp35_;
	g_return_if_fail (self != NULL);
	{
		GeeIterator* _row_it = NULL;
		GeeHashMap* _tmp0_;
		GeeCollection* _tmp1_;
		GeeCollection* _tmp2_;
		GeeCollection* _tmp3_;
		GeeIterator* _tmp4_;
		GeeIterator* _tmp5_;
		_tmp0_ = self->checked_items_map;
		_tmp1_ = gee_abstract_map_get_values ((GeeAbstractMap*) _tmp0_);
		_tmp2_ = _tmp1_;
		_tmp3_ = _tmp2_;
		_tmp4_ = gee_iterable_iterator ((GeeIterable*) _tmp3_);
		_tmp5_ = _tmp4_;
		_g_object_unref0 (_tmp3_);
		_row_it = _tmp5_;
		while (TRUE) {
			GeeIterator* _tmp6_;
			LayoutsItemBoard* row = NULL;
			GeeIterator* _tmp7_;
			gpointer _tmp8_;
			LayoutsItemBoard* _tmp9_;
			_tmp6_ = _row_it;
			if (!gee_iterator_next (_tmp6_)) {
				break;
			}
			_tmp7_ = _row_it;
			_tmp8_ = gee_iterator_get (_tmp7_);
			row = (LayoutsItemBoard*) _tmp8_;
			_tmp9_ = row;
			layouts_item_base_hide_destroy ((LayoutsItemBase*) _tmp9_);
			_g_object_unref0 (row);
		}
		_g_object_unref0 (_row_it);
	}
	_tmp10_ = self->checked_items_map;
	gee_abstract_map_clear ((GeeAbstractMap*) _tmp10_);
	_tmp11_ = gee_array_list_new (OBJECTS_TYPE_ITEM, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, NULL, NULL, NULL);
	_g_object_unref0 (self->priv->completed_items_list);
	self->priv->completed_items_list = _tmp11_;
	_tmp13_ = layouts_section_board_get_is_inbox_section (self);
	_tmp14_ = _tmp13_;
	if (_tmp14_) {
		ObjectsSection* _tmp15_;
		ObjectsProject* _tmp16_;
		ObjectsProject* _tmp17_;
		GeeArrayList* _tmp18_;
		GeeArrayList* _tmp19_;
		_tmp15_ = self->priv->_section;
		_tmp16_ = objects_section_get_project (_tmp15_);
		_tmp17_ = _tmp16_;
		_tmp18_ = objects_project_get_items (_tmp17_);
		_tmp19_ = _tmp18_;
		_tmp12_ = _tmp19_;
	} else {
		ObjectsSection* _tmp20_;
		GeeArrayList* _tmp21_;
		GeeArrayList* _tmp22_;
		_tmp20_ = self->priv->_section;
		_tmp21_ = objects_section_get_items (_tmp20_);
		_tmp22_ = _tmp21_;
		_tmp12_ = _tmp22_;
	}
	{
		GeeArrayList* _item_list = NULL;
		gint _item_size = 0;
		GeeArrayList* _tmp23_;
		gint _tmp24_;
		gint _tmp25_;
		gint _item_index = 0;
		_item_list = _tmp12_;
		_tmp23_ = _item_list;
		_tmp24_ = gee_abstract_collection_get_size ((GeeAbstractCollection*) _tmp23_);
		_tmp25_ = _tmp24_;
		_item_size = _tmp25_;
		_item_index = -1;
		while (TRUE) {
			gint _tmp26_;
			gint _tmp27_;
			ObjectsItem* item = NULL;
			GeeArrayList* _tmp28_;
			gpointer _tmp29_;
			ObjectsItem* _tmp30_;
			gboolean _tmp31_;
			gboolean _tmp32_;
			_item_index = _item_index + 1;
			_tmp26_ = _item_index;
			_tmp27_ = _item_size;
			if (!(_tmp26_ < _tmp27_)) {
				break;
			}
			_tmp28_ = _item_list;
			_tmp29_ = gee_abstract_list_get ((GeeAbstractList*) _tmp28_, _item_index);
			item = (ObjectsItem*) _tmp29_;
			_tmp30_ = item;
			_tmp31_ = objects_item_get_checked (_tmp30_);
			_tmp32_ = _tmp31_;
			if (_tmp32_) {
				GeeArrayList* _tmp33_;
				ObjectsItem* _tmp34_;
				_tmp33_ = self->priv->completed_items_list;
				_tmp34_ = item;
				gee_abstract_collection_add ((GeeAbstractCollection*) _tmp33_, _tmp34_);
			}
			_g_object_unref0 (item);
		}
	}
	_tmp35_ = self->priv->completed_items_list;
	gee_list_sort ((GeeList*) _tmp35_, ___lambda685__gcompare_data_func, g_object_ref (self), g_object_unref);
	self->priv->completed_page_index = 0;
	layouts_section_board_load_next_completed_page (self);
}

static void
layouts_section_board_load_next_completed_page (LayoutsSectionBoard* self)
{
	gint start = 0;
	gint _tmp0_ = 0;
	GeeArrayList* _tmp1_;
	gint _tmp2_;
	gint _tmp3_;
	gint end = 0;
	gint _tmp12_;
	g_return_if_fail (self != NULL);
	start = self->priv->completed_page_index * LAYOUTS_SECTION_BOARD_PAGE_SIZE;
	_tmp1_ = self->priv->completed_items_list;
	_tmp2_ = gee_abstract_collection_get_size ((GeeAbstractCollection*) _tmp1_);
	_tmp3_ = _tmp2_;
	if ((start + LAYOUTS_SECTION_BOARD_PAGE_SIZE) < _tmp3_) {
		_tmp0_ = start + LAYOUTS_SECTION_BOARD_PAGE_SIZE;
	} else {
		GeeArrayList* _tmp4_;
		gint _tmp5_;
		gint _tmp6_;
		_tmp4_ = self->priv->completed_items_list;
		_tmp5_ = gee_abstract_collection_get_size ((GeeAbstractCollection*) _tmp4_);
		_tmp6_ = _tmp5_;
		_tmp0_ = _tmp6_;
	}
	end = _tmp0_;
	{
		gint i = 0;
		i = start;
		{
			gboolean _tmp7_ = FALSE;
			_tmp7_ = TRUE;
			while (TRUE) {
				ObjectsItem* item = NULL;
				GeeArrayList* _tmp9_;
				gpointer _tmp10_;
				ObjectsItem* _tmp11_;
				if (!_tmp7_) {
					gint _tmp8_;
					_tmp8_ = i;
					i = _tmp8_ + 1;
				}
				_tmp7_ = FALSE;
				if (!(i < end)) {
					break;
				}
				_tmp9_ = self->priv->completed_items_list;
				_tmp10_ = gee_abstract_list_get ((GeeAbstractList*) _tmp9_, i);
				item = (ObjectsItem*) _tmp10_;
				_tmp11_ = item;
				layouts_section_board_add_complete_item (self, _tmp11_);
				_g_object_unref0 (item);
			}
		}
	}
	_tmp12_ = self->priv->completed_page_index;
	self->priv->completed_page_index = _tmp12_ + 1;
	layouts_section_board_update_load_more_button_label (self);
}

static void
layouts_section_board_update_load_more_button_label (LayoutsSectionBoard* self)
{
	gint loaded = 0;
	gint remaining = 0;
	GeeArrayList* _tmp0_;
	gint _tmp1_;
	gint _tmp2_;
	g_return_if_fail (self != NULL);
	loaded = self->priv->completed_page_index * LAYOUTS_SECTION_BOARD_PAGE_SIZE;
	_tmp0_ = self->priv->completed_items_list;
	_tmp1_ = gee_abstract_collection_get_size ((GeeAbstractCollection*) _tmp0_);
	_tmp2_ = _tmp1_;
	remaining = _tmp2_ - loaded;
	if (remaining > 0) {
		gint _tmp3_ = 0;
		gint to_show = 0;
		GtkButton* _tmp4_;
		gchar* _tmp5_;
		gchar* _tmp6_;
		GtkRevealer* _tmp7_;
		if (remaining < LAYOUTS_SECTION_BOARD_PAGE_SIZE) {
			_tmp3_ = remaining;
		} else {
			_tmp3_ = LAYOUTS_SECTION_BOARD_PAGE_SIZE;
		}
		to_show = _tmp3_;
		_tmp4_ = self->priv->load_more_button;
		_tmp5_ = g_strdup_printf ("+%d %s", to_show, _ ("completed tasks"));
		_tmp6_ = _tmp5_;
		gtk_button_set_label (_tmp4_, _tmp6_);
		_g_free0 (_tmp6_);
		_tmp7_ = self->priv->load_more_button_revealer;
		gtk_revealer_set_reveal_child (_tmp7_, TRUE);
	} else {
		GtkButton* _tmp8_;
		GtkRevealer* _tmp9_;
		_tmp8_ = self->priv->load_more_button;
		gtk_button_set_label (_tmp8_, "No more tasks");
		_tmp9_ = self->priv->load_more_button_revealer;
		gtk_revealer_set_reveal_child (_tmp9_, FALSE);
	}
}

void
layouts_section_board_add_complete_item (LayoutsSectionBoard* self,
                                         ObjectsItem* item)
{
	gboolean _tmp0_ = FALSE;
	ObjectsSection* _tmp1_;
	ObjectsProject* _tmp2_;
	ObjectsProject* _tmp3_;
	gboolean _tmp4_;
	gboolean _tmp5_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (item != NULL);
	_tmp1_ = self->priv->_section;
	_tmp2_ = objects_section_get_project (_tmp1_);
	_tmp3_ = _tmp2_;
	_tmp4_ = objects_project_get_show_completed (_tmp3_);
	_tmp5_ = _tmp4_;
	if (_tmp5_) {
		gboolean _tmp6_;
		gboolean _tmp7_;
		_tmp6_ = objects_item_get_checked (item);
		_tmp7_ = _tmp6_;
		_tmp0_ = _tmp7_;
	} else {
		_tmp0_ = FALSE;
	}
	if (_tmp0_) {
		GeeHashMap* _tmp8_;
		const gchar* _tmp9_;
		const gchar* _tmp10_;
		_tmp8_ = self->checked_items_map;
		_tmp9_ = objects_base_object_get_id_string ((ObjectsBaseObject*) item);
		_tmp10_ = _tmp9_;
		if (!gee_abstract_map_has_key ((GeeAbstractMap*) _tmp8_, _tmp10_)) {
			GeeHashMap* _tmp11_;
			const gchar* _tmp12_;
			const gchar* _tmp13_;
			LayoutsItemBoard* _tmp14_;
			LayoutsItemBoard* _tmp15_;
			GtkListBox* _tmp16_;
			GeeHashMap* _tmp17_;
			const gchar* _tmp18_;
			const gchar* _tmp19_;
			gpointer _tmp20_;
			LayoutsItemBoard* _tmp21_;
			_tmp11_ = self->checked_items_map;
			_tmp12_ = objects_base_object_get_id_string ((ObjectsBaseObject*) item);
			_tmp13_ = _tmp12_;
			_tmp14_ = layouts_item_board_new (item);
			g_object_ref_sink (_tmp14_);
			_tmp15_ = _tmp14_;
			gee_abstract_map_set ((GeeAbstractMap*) _tmp11_, _tmp13_, _tmp15_);
			_g_object_unref0 (_tmp15_);
			_tmp16_ = self->priv->checked_listbox;
			_tmp17_ = self->checked_items_map;
			_tmp18_ = objects_base_object_get_id_string ((ObjectsBaseObject*) item);
			_tmp19_ = _tmp18_;
			_tmp20_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp17_, _tmp19_);
			_tmp21_ = (LayoutsItemBoard*) _tmp20_;
			gtk_list_box_append (_tmp16_, (GtkWidget*) _tmp21_);
			_g_object_unref0 (_tmp21_);
		}
	}
}

static void
__lambda686_ (LayoutsSectionBoard* self)
{
	ServicesSettings* _tmp0_;
	ServicesSettings* _tmp1_;
	_tmp0_ = services_settings_get_default ();
	_tmp1_ = _tmp0_;
	layouts_section_board_prepare_new_item (self, "", services_settings_get_new_task_position (_tmp1_));
	_g_object_unref0 (_tmp1_);
}

static void
___lambda686__gtk_button_clicked (GtkButton* _sender,
                                  gpointer self)
{
	__lambda686_ ((LayoutsSectionBoard*) self);
}

static void
__lambda687_ (LayoutsSectionBoard* self)
{
	DialogsSection* dialog = NULL;
	ObjectsSection* _tmp0_;
	DialogsSection* _tmp1_;
	Planify* _tmp2_;
	MainWindow* _tmp3_;
	_tmp0_ = self->priv->_section;
	_tmp1_ = dialogs_section_new (_tmp0_);
	g_object_ref_sink (_tmp1_);
	dialog = _tmp1_;
	_tmp2_ = planify__instance;
	_tmp3_ = _tmp2_->main_window;
	adw_dialog_present ((AdwDialog*) dialog, (GtkWidget*) _tmp3_);
	_g_object_unref0 (dialog);
}

static void
___lambda687__gtk_button_clicked (GtkButton* _sender,
                                  gpointer self)
{
	__lambda687_ ((LayoutsSectionBoard*) self);
}

static void
__lambda689_ (LayoutsSectionBoard* self,
              const gchar* type,
              const gchar* id)
{
	g_return_if_fail (type != NULL);
	g_return_if_fail (id != NULL);
	if (g_strcmp0 (type, "project") == 0) {
		layouts_section_board_move_section (self, id);
	}
}

static void
___lambda689__dialogs_project_picker_project_picker_changed (DialogsProjectPickerProjectPicker* _sender,
                                                             const gchar* type,
                                                             const gchar* id,
                                                             gpointer self)
{
	__lambda689_ ((LayoutsSectionBoard*) self, type, id);
}

static void
__lambda688_ (LayoutsSectionBoard* self)
{
	DialogsProjectPickerProjectPicker* dialog = NULL;
	ObjectsSection* _tmp0_;
	ObjectsSource* _tmp1_;
	ObjectsSource* _tmp2_;
	DialogsProjectPickerProjectPicker* _tmp3_;
	ObjectsSection* _tmp4_;
	ObjectsProject* _tmp5_;
	ObjectsProject* _tmp6_;
	Planify* _tmp7_;
	MainWindow* _tmp8_;
	_tmp0_ = self->priv->_section;
	_tmp1_ = objects_base_object_get_source ((ObjectsBaseObject*) _tmp0_);
	_tmp2_ = _tmp1_;
	_tmp3_ = dialogs_project_picker_project_picker_new_for_source (_tmp2_);
	g_object_ref_sink (_tmp3_);
	dialog = _tmp3_;
	_tmp4_ = self->priv->_section;
	_tmp5_ = objects_section_get_project (_tmp4_);
	_tmp6_ = _tmp5_;
	dialogs_project_picker_project_picker_set_project (dialog, _tmp6_);
	_tmp7_ = planify__instance;
	_tmp8_ = _tmp7_->main_window;
	adw_dialog_present ((AdwDialog*) dialog, (GtkWidget*) _tmp8_);
	g_signal_connect_object (dialog, "changed", (GCallback) ___lambda689__dialogs_project_picker_project_picker_changed, self, 0);
	_g_object_unref0 (dialog);
}

static void
___lambda688__gtk_button_clicked (GtkButton* _sender,
                                  gpointer self)
{
	__lambda688_ ((LayoutsSectionBoard*) self);
}

static void
__lambda691_ (LayoutsSectionBoard* self)
{
	DialogsManageSectionOrder* dialog = NULL;
	ObjectsSection* _tmp0_;
	ObjectsProject* _tmp1_;
	ObjectsProject* _tmp2_;
	DialogsManageSectionOrder* _tmp3_;
	Planify* _tmp4_;
	MainWindow* _tmp5_;
	_tmp0_ = self->priv->_section;
	_tmp1_ = objects_section_get_project (_tmp0_);
	_tmp2_ = _tmp1_;
	_tmp3_ = dialogs_manage_section_order_new (_tmp2_);
	g_object_ref_sink (_tmp3_);
	dialog = _tmp3_;
	_tmp4_ = planify__instance;
	_tmp5_ = _tmp4_->main_window;
	adw_dialog_present ((AdwDialog*) dialog, (GtkWidget*) _tmp5_);
	_g_object_unref0 (dialog);
}

static void
___lambda691__gtk_button_clicked (GtkButton* _sender,
                                  gpointer self)
{
	__lambda691_ ((LayoutsSectionBoard*) self);
}

static void
__lambda692_ (LayoutsSectionBoard* self)
{
	ObjectsSection* _tmp0_;
	Planify* _tmp1_;
	Planify* _tmp2_;
	MainWindow* _tmp3_;
	_tmp0_ = self->priv->_section;
	_tmp1_ = planify_get_instance ();
	_tmp2_ = _tmp1_;
	_tmp3_ = _tmp2_->main_window;
	objects_section_archive_section (_tmp0_, G_TYPE_CHECK_INSTANCE_CAST (_tmp3_, gtk_window_get_type (), GtkWindow));
}

static void
___lambda692__gtk_button_clicked (GtkButton* _sender,
                                  gpointer self)
{
	__lambda692_ ((LayoutsSectionBoard*) self);
}

static void
____lambda695_ (LayoutsSectionBoard* self,
                GObject* obj,
                GAsyncResult* res)
{
	ServicesTodoist* _tmp0_;
	ServicesTodoist* _tmp1_;
	HttpResponse* _tmp2_;
	HttpResponse* _tmp3_;
	ServicesStore* _tmp4_;
	ObjectsSection* _tmp5_;
	g_return_if_fail (res != NULL);
	_tmp0_ = services_todoist_get_default ();
	_tmp1_ = _tmp0_;
	_tmp2_ = services_todoist_delete_finish (_tmp1_, res);
	_tmp3_ = _tmp2_;
	_http_response_unref0 (_tmp3_);
	_g_object_unref0 (_tmp1_);
	_tmp4_ = services_store_instance ();
	_tmp5_ = self->priv->_section;
	services_store_delete_section (_tmp4_, _tmp5_);
}

static void
_____lambda695__gasync_ready_callback (GObject* source_object,
                                       GAsyncResult* res,
                                       gpointer self)
{
	____lambda695_ ((LayoutsSectionBoard*) self, source_object, res);
	g_object_unref (self);
}

static void
__lambda694_ (LayoutsSectionBoard* self,
              const gchar* response)
{
	g_return_if_fail (response != NULL);
	if (g_strcmp0 (response, "delete") == 0) {
		ObjectsSection* _tmp0_;
		ObjectsProject* _tmp1_;
		ObjectsProject* _tmp2_;
		SourceType _tmp3_;
		SourceType _tmp4_;
		layouts_section_board_set_is_loading (self, TRUE);
		_tmp0_ = self->priv->_section;
		_tmp1_ = objects_section_get_project (_tmp0_);
		_tmp2_ = _tmp1_;
		_tmp3_ = objects_project_get_source_type (_tmp2_);
		_tmp4_ = _tmp3_;
		if (_tmp4_ == SOURCE_TYPE_TODOIST) {
			ServicesTodoist* _tmp5_;
			ServicesTodoist* _tmp6_;
			ObjectsSection* _tmp7_;
			_tmp5_ = services_todoist_get_default ();
			_tmp6_ = _tmp5_;
			_tmp7_ = self->priv->_section;
			services_todoist_delete (_tmp6_, (ObjectsBaseObject*) _tmp7_, _____lambda695__gasync_ready_callback, g_object_ref (self));
			_g_object_unref0 (_tmp6_);
		} else {
			ServicesStore* _tmp8_;
			ObjectsSection* _tmp9_;
			_tmp8_ = services_store_instance ();
			_tmp9_ = self->priv->_section;
			services_store_delete_section (_tmp8_, _tmp9_);
		}
	}
}

static void
___lambda694__adw_alert_dialog_response (AdwAlertDialog* _sender,
                                         const gchar* response,
                                         gpointer self)
{
	__lambda694_ ((LayoutsSectionBoard*) self, response);
}

static void
__lambda693_ (LayoutsSectionBoard* self)
{
	AdwAlertDialog* dialog = NULL;
	ObjectsSection* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	gchar* _tmp4_;
	AdwAlertDialog* _tmp5_;
	AdwAlertDialog* _tmp6_;
	Planify* _tmp7_;
	MainWindow* _tmp8_;
	_tmp0_ = self->priv->_section;
	_tmp1_ = objects_base_object_get_name ((ObjectsBaseObject*) _tmp0_);
	_tmp2_ = _tmp1_;
	_tmp3_ = g_strdup_printf ("Delete Section %s", _tmp2_);
	_tmp4_ = _tmp3_;
	_tmp5_ = (AdwAlertDialog*) adw_alert_dialog_new (_ (_tmp4_), _ ("This can not be undone"));
	g_object_ref_sink (_tmp5_);
	_tmp6_ = _tmp5_;
	_g_free0 (_tmp4_);
	dialog = _tmp6_;
	adw_alert_dialog_add_response (dialog, "cancel", _ ("Cancel"));
	adw_alert_dialog_add_response (dialog, "delete", _ ("Delete"));
	adw_alert_dialog_set_response_appearance (dialog, "delete", ADW_RESPONSE_DESTRUCTIVE);
	_tmp7_ = planify__instance;
	_tmp8_ = _tmp7_->main_window;
	adw_dialog_present ((AdwDialog*) dialog, (GtkWidget*) _tmp8_);
	g_signal_connect_object (dialog, "response", (GCallback) ___lambda694__adw_alert_dialog_response, self, 0);
	_g_object_unref0 (dialog);
}

static void
___lambda693__gtk_button_clicked (GtkButton* _sender,
                                  gpointer self)
{
	__lambda693_ ((LayoutsSectionBoard*) self);
}

static void
__lambda696_ (LayoutsSectionBoard* self)
{
	DialogsCompletedTasks* dialog = NULL;
	ObjectsSection* _tmp0_;
	ObjectsProject* _tmp1_;
	ObjectsProject* _tmp2_;
	DialogsCompletedTasks* _tmp3_;
	ObjectsSection* _tmp4_;
	Planify* _tmp5_;
	MainWindow* _tmp6_;
	_tmp0_ = self->priv->_section;
	_tmp1_ = objects_section_get_project (_tmp0_);
	_tmp2_ = _tmp1_;
	_tmp3_ = dialogs_completed_tasks_new (_tmp2_);
	g_object_ref_sink (_tmp3_);
	dialog = _tmp3_;
	_tmp4_ = self->priv->_section;
	dialogs_completed_tasks_add_update_filter (dialog, _tmp4_);
	_tmp5_ = planify__instance;
	_tmp6_ = _tmp5_->main_window;
	adw_dialog_present ((AdwDialog*) dialog, (GtkWidget*) _tmp6_);
	_g_object_unref0 (dialog);
}

static void
___lambda696__gtk_button_clicked (GtkButton* _sender,
                                  gpointer self)
{
	__lambda696_ ((LayoutsSectionBoard*) self);
}

static void
__lambda697_ (LayoutsSectionBoard* self)
{
	Util* _tmp0_;
	Util* _tmp1_;
	ObjectsSection* _tmp2_;
	ObjectsSection* _tmp3_;
	const gchar* _tmp4_;
	const gchar* _tmp5_;
	_tmp0_ = util_get_default ();
	_tmp1_ = _tmp0_;
	_tmp2_ = self->priv->_section;
	_tmp3_ = self->priv->_section;
	_tmp4_ = objects_section_get_project_id (_tmp3_);
	_tmp5_ = _tmp4_;
	util_duplicate_section (_tmp1_, _tmp2_, _tmp5_, TRUE, NULL, NULL);
	_g_object_unref0 (_tmp1_);
}

static void
___lambda697__gtk_button_clicked (GtkButton* _sender,
                                  gpointer self)
{
	__lambda697_ ((LayoutsSectionBoard*) self);
}

static GtkPopover*
layouts_section_board_build_context_menu (LayoutsSectionBoard* self)
{
	WidgetsContextMenuMenuItem* add_item = NULL;
	WidgetsContextMenuMenuItem* _tmp0_;
	WidgetsContextMenuMenuItem* edit_item = NULL;
	WidgetsContextMenuMenuItem* _tmp1_;
	WidgetsContextMenuMenuItem* move_item = NULL;
	WidgetsContextMenuMenuItem* _tmp2_;
	WidgetsContextMenuMenuItem* manage_item = NULL;
	WidgetsContextMenuMenuItem* _tmp3_;
	WidgetsContextMenuMenuItem* duplicate_item = NULL;
	WidgetsContextMenuMenuItem* _tmp4_;
	WidgetsContextMenuMenuItem* show_completed_item = NULL;
	WidgetsContextMenuMenuItem* _tmp5_;
	WidgetsContextMenuMenuItem* archive_item = NULL;
	WidgetsContextMenuMenuItem* _tmp6_;
	WidgetsContextMenuMenuItem* delete_item = NULL;
	WidgetsContextMenuMenuItem* _tmp7_;
	WidgetsContextMenuMenuItem* _tmp8_;
	GtkBox* menu_box = NULL;
	GtkBox* _tmp9_;
	GtkBox* _tmp10_;
	GtkBox* _tmp11_;
	GtkBox* _tmp12_;
	WidgetsContextMenuMenuItem* _tmp13_;
	gboolean _tmp14_;
	gboolean _tmp15_;
	GtkPopover* menu_popover = NULL;
	GtkBox* _tmp49_;
	GtkWidget* _tmp50_;
	GtkPopover* _tmp51_ = NULL;
	WidgetsContextMenuMenuItem* _tmp52_;
	WidgetsContextMenuMenuItem* _tmp53_;
	WidgetsContextMenuMenuItem* _tmp54_;
	WidgetsContextMenuMenuItem* _tmp55_;
	WidgetsContextMenuMenuItem* _tmp56_;
	WidgetsContextMenuMenuItem* _tmp57_;
	WidgetsContextMenuMenuItem* _tmp58_;
	WidgetsContextMenuMenuItem* _tmp59_;
	GtkPopover* result;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = widgets_context_menu_menu_item_new (_ ("Add Task"), "plus-large-symbolic");
	g_object_ref_sink (_tmp0_);
	add_item = _tmp0_;
	_tmp1_ = widgets_context_menu_menu_item_new (_ ("Edit Section"), "edit-symbolic");
	g_object_ref_sink (_tmp1_);
	edit_item = _tmp1_;
	_tmp2_ = widgets_context_menu_menu_item_new (_ ("Move Section"), "arrow3-right-symbolic");
	g_object_ref_sink (_tmp2_);
	move_item = _tmp2_;
	_tmp3_ = widgets_context_menu_menu_item_new (_ ("Manage Sections"), "view-list-ordered-symbolic");
	g_object_ref_sink (_tmp3_);
	manage_item = _tmp3_;
	_tmp4_ = widgets_context_menu_menu_item_new (_ ("Duplicate"), "tabs-stack-symbolic");
	g_object_ref_sink (_tmp4_);
	duplicate_item = _tmp4_;
	_tmp5_ = widgets_context_menu_menu_item_new (_ ("Show Completed Tasks"), "check-round-outline-symbolic");
	g_object_ref_sink (_tmp5_);
	show_completed_item = _tmp5_;
	_tmp6_ = widgets_context_menu_menu_item_new (_ ("Archive"), "shoe-box-symbolic");
	g_object_ref_sink (_tmp6_);
	archive_item = _tmp6_;
	_tmp7_ = widgets_context_menu_menu_item_new (_ ("Delete Section"), "user-trash-symbolic");
	g_object_ref_sink (_tmp7_);
	delete_item = _tmp7_;
	_tmp8_ = delete_item;
	gtk_widget_add_css_class ((GtkWidget*) _tmp8_, "menu-item-danger");
	_tmp9_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
	g_object_ref_sink (_tmp9_);
	menu_box = _tmp9_;
	_tmp10_ = menu_box;
	_tmp11_ = menu_box;
	gtk_widget_set_margin_bottom ((GtkWidget*) _tmp11_, 3);
	gtk_widget_set_margin_top ((GtkWidget*) _tmp10_, 3);
	_tmp12_ = menu_box;
	_tmp13_ = add_item;
	gtk_box_append (_tmp12_, (GtkWidget*) _tmp13_);
	_tmp14_ = layouts_section_board_get_is_inbox_section (self);
	_tmp15_ = _tmp14_;
	if (!_tmp15_) {
		GtkBox* _tmp16_;
		WidgetsContextMenuMenuSeparator* _tmp17_;
		WidgetsContextMenuMenuSeparator* _tmp18_;
		GtkBox* _tmp19_;
		WidgetsContextMenuMenuItem* _tmp20_;
		GtkBox* _tmp21_;
		WidgetsContextMenuMenuItem* _tmp22_;
		GtkBox* _tmp23_;
		WidgetsContextMenuMenuItem* _tmp24_;
		GtkBox* _tmp25_;
		WidgetsContextMenuMenuItem* _tmp26_;
		GtkBox* _tmp27_;
		WidgetsContextMenuMenuSeparator* _tmp28_;
		WidgetsContextMenuMenuSeparator* _tmp29_;
		GtkBox* _tmp30_;
		WidgetsContextMenuMenuItem* _tmp31_;
		GtkBox* _tmp32_;
		WidgetsContextMenuMenuSeparator* _tmp33_;
		WidgetsContextMenuMenuSeparator* _tmp34_;
		GtkBox* _tmp35_;
		WidgetsContextMenuMenuItem* _tmp36_;
		GtkBox* _tmp37_;
		WidgetsContextMenuMenuItem* _tmp38_;
		_tmp16_ = menu_box;
		_tmp17_ = widgets_context_menu_menu_separator_new ();
		g_object_ref_sink (_tmp17_);
		_tmp18_ = _tmp17_;
		gtk_box_append (_tmp16_, (GtkWidget*) _tmp18_);
		_g_object_unref0 (_tmp18_);
		_tmp19_ = menu_box;
		_tmp20_ = edit_item;
		gtk_box_append (_tmp19_, (GtkWidget*) _tmp20_);
		_tmp21_ = menu_box;
		_tmp22_ = move_item;
		gtk_box_append (_tmp21_, (GtkWidget*) _tmp22_);
		_tmp23_ = menu_box;
		_tmp24_ = manage_item;
		gtk_box_append (_tmp23_, (GtkWidget*) _tmp24_);
		_tmp25_ = menu_box;
		_tmp26_ = duplicate_item;
		gtk_box_append (_tmp25_, (GtkWidget*) _tmp26_);
		_tmp27_ = menu_box;
		_tmp28_ = widgets_context_menu_menu_separator_new ();
		g_object_ref_sink (_tmp28_);
		_tmp29_ = _tmp28_;
		gtk_box_append (_tmp27_, (GtkWidget*) _tmp29_);
		_g_object_unref0 (_tmp29_);
		_tmp30_ = menu_box;
		_tmp31_ = show_completed_item;
		gtk_box_append (_tmp30_, (GtkWidget*) _tmp31_);
		_tmp32_ = menu_box;
		_tmp33_ = widgets_context_menu_menu_separator_new ();
		g_object_ref_sink (_tmp33_);
		_tmp34_ = _tmp33_;
		gtk_box_append (_tmp32_, (GtkWidget*) _tmp34_);
		_g_object_unref0 (_tmp34_);
		_tmp35_ = menu_box;
		_tmp36_ = archive_item;
		gtk_box_append (_tmp35_, (GtkWidget*) _tmp36_);
		_tmp37_ = menu_box;
		_tmp38_ = delete_item;
		gtk_box_append (_tmp37_, (GtkWidget*) _tmp38_);
	} else {
		GtkBox* _tmp39_;
		WidgetsContextMenuMenuSeparator* _tmp40_;
		WidgetsContextMenuMenuSeparator* _tmp41_;
		GtkBox* _tmp42_;
		WidgetsContextMenuMenuItem* _tmp43_;
		GtkBox* _tmp44_;
		WidgetsContextMenuMenuSeparator* _tmp45_;
		WidgetsContextMenuMenuSeparator* _tmp46_;
		GtkBox* _tmp47_;
		WidgetsContextMenuMenuItem* _tmp48_;
		_tmp39_ = menu_box;
		_tmp40_ = widgets_context_menu_menu_separator_new ();
		g_object_ref_sink (_tmp40_);
		_tmp41_ = _tmp40_;
		gtk_box_append (_tmp39_, (GtkWidget*) _tmp41_);
		_g_object_unref0 (_tmp41_);
		_tmp42_ = menu_box;
		_tmp43_ = show_completed_item;
		gtk_box_append (_tmp42_, (GtkWidget*) _tmp43_);
		_tmp44_ = menu_box;
		_tmp45_ = widgets_context_menu_menu_separator_new ();
		g_object_ref_sink (_tmp45_);
		_tmp46_ = _tmp45_;
		gtk_box_append (_tmp44_, (GtkWidget*) _tmp46_);
		_g_object_unref0 (_tmp46_);
		_tmp47_ = menu_box;
		_tmp48_ = manage_item;
		gtk_box_append (_tmp47_, (GtkWidget*) _tmp48_);
	}
	_tmp49_ = menu_box;
	_tmp50_ = _g_object_ref0 ((GtkWidget*) _tmp49_);
	_tmp51_ = (GtkPopover*) gtk_popover_new ();
	gtk_popover_set_has_arrow (_tmp51_, FALSE);
	gtk_popover_set_child (_tmp51_, _tmp50_);
	_g_object_unref0 (_tmp50_);
	gtk_popover_set_position (_tmp51_, GTK_POS_BOTTOM);
	g_object_set ((GtkWidget*) _tmp51_, "width-request", 250, NULL);
	g_object_ref_sink (_tmp51_);
	menu_popover = _tmp51_;
	_tmp52_ = add_item;
	g_signal_connect_object ((GtkButton*) _tmp52_, "clicked", (GCallback) ___lambda686__gtk_button_clicked, self, 0);
	_tmp53_ = edit_item;
	g_signal_connect_object ((GtkButton*) _tmp53_, "clicked", (GCallback) ___lambda687__gtk_button_clicked, self, 0);
	_tmp54_ = move_item;
	g_signal_connect_object ((GtkButton*) _tmp54_, "clicked", (GCallback) ___lambda688__gtk_button_clicked, self, 0);
	_tmp55_ = manage_item;
	g_signal_connect_object ((GtkButton*) _tmp55_, "clicked", (GCallback) ___lambda691__gtk_button_clicked, self, 0);
	_tmp56_ = archive_item;
	g_signal_connect_object ((GtkButton*) _tmp56_, "clicked", (GCallback) ___lambda692__gtk_button_clicked, self, 0);
	_tmp57_ = delete_item;
	g_signal_connect_object ((GtkButton*) _tmp57_, "clicked", (GCallback) ___lambda693__gtk_button_clicked, self, 0);
	_tmp58_ = show_completed_item;
	g_signal_connect_object ((GtkButton*) _tmp58_, "clicked", (GCallback) ___lambda696__gtk_button_clicked, self, 0);
	_tmp59_ = duplicate_item;
	g_signal_connect_object ((GtkButton*) _tmp59_, "clicked", (GCallback) ___lambda697__gtk_button_clicked, self, 0);
	result = menu_popover;
	_g_object_unref0 (menu_box);
	_g_object_unref0 (delete_item);
	_g_object_unref0 (archive_item);
	_g_object_unref0 (show_completed_item);
	_g_object_unref0 (duplicate_item);
	_g_object_unref0 (manage_item);
	_g_object_unref0 (move_item);
	_g_object_unref0 (edit_item);
	_g_object_unref0 (add_item);
	return result;
}

void
layouts_section_board_prepare_new_item (LayoutsSectionBoard* self,
                                        const gchar* content,
                                        NewTaskPosition new_task_position)
{
	DialogsQuickAdd* dialog = NULL;
	DialogsQuickAdd* _tmp0_;
	ObjectsSection* _tmp1_;
	Planify* _tmp2_;
	MainWindow* _tmp3_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (content != NULL);
	_tmp0_ = dialogs_quick_add_new ();
	g_object_ref_sink (_tmp0_);
	dialog = _tmp0_;
	_tmp1_ = self->priv->_section;
	dialogs_quick_add_for_base_object (dialog, (ObjectsBaseObject*) _tmp1_);
	dialogs_quick_add_update_content (dialog, content);
	dialogs_quick_add_set_new_task_position (dialog, new_task_position);
	_tmp2_ = planify__instance;
	_tmp3_ = _tmp2_->main_window;
	adw_dialog_present ((AdwDialog*) dialog, (GtkWidget*) _tmp3_);
	_g_object_unref0 (dialog);
}

static Block46Data*
block46_data_ref (Block46Data* _data46_)
{
	g_atomic_int_inc (&_data46_->_ref_count_);
	return _data46_;
}

static void
block46_data_unref (void * _userdata_)
{
	Block46Data* _data46_;
	_data46_ = (Block46Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data46_->_ref_count_)) {
		LayoutsSectionBoard* self;
		self = _data46_->self;
		_g_free0 (_data46_->old_section_id);
		_g_object_unref0 (self);
		g_slice_free (Block46Data, _data46_);
	}
}

static void
___lambda690_ (Block46Data* _data46_,
               GObject* obj,
               GAsyncResult* res)
{
	LayoutsSectionBoard* self;
	ServicesTodoist* _tmp0_;
	ServicesTodoist* _tmp1_;
	HttpResponse* _tmp2_;
	HttpResponse* _tmp3_;
	gboolean _tmp4_;
	gboolean _tmp5_;
	gboolean _tmp6_;
	self = _data46_->self;
	g_return_if_fail (res != NULL);
	_tmp0_ = services_todoist_get_default ();
	_tmp1_ = _tmp0_;
	_tmp2_ = services_todoist_move_project_section_finish (_tmp1_, res);
	_tmp3_ = _tmp2_;
	_tmp4_ = http_response_get_status (_tmp3_);
	_tmp5_ = _tmp4_;
	_tmp6_ = _tmp5_;
	_http_response_unref0 (_tmp3_);
	_g_object_unref0 (_tmp1_);
	if (_tmp6_) {
		ServicesStore* _tmp7_;
		ObjectsSection* _tmp8_;
		const gchar* _tmp9_;
		_tmp7_ = services_store_instance ();
		_tmp8_ = self->priv->_section;
		_tmp9_ = _data46_->old_section_id;
		services_store_move_section (_tmp7_, _tmp8_, _tmp9_);
		layouts_section_board_set_is_loading (self, FALSE);
	}
}

static void
____lambda690__gasync_ready_callback (GObject* source_object,
                                      GAsyncResult* res,
                                      gpointer self)
{
	___lambda690_ (self, source_object, res);
	block46_data_unref (self);
}

static void
layouts_section_board_move_section (LayoutsSectionBoard* self,
                                    const gchar* project_id)
{
	Block46Data* _data46_;
	ObjectsSection* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	ObjectsSection* _tmp4_;
	ObjectsSection* _tmp5_;
	ObjectsProject* _tmp6_;
	ObjectsProject* _tmp7_;
	SourceType _tmp8_;
	SourceType _tmp9_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (project_id != NULL);
	_data46_ = g_slice_new0 (Block46Data);
	_data46_->_ref_count_ = 1;
	_data46_->self = g_object_ref (self);
	_tmp0_ = self->priv->_section;
	_tmp1_ = objects_section_get_project_id (_tmp0_);
	_tmp2_ = _tmp1_;
	_tmp3_ = g_strdup (_tmp2_);
	_data46_->old_section_id = _tmp3_;
	_tmp4_ = self->priv->_section;
	objects_section_set_project_id (_tmp4_, project_id);
	_tmp5_ = self->priv->_section;
	_tmp6_ = objects_section_get_project (_tmp5_);
	_tmp7_ = _tmp6_;
	_tmp8_ = objects_project_get_source_type (_tmp7_);
	_tmp9_ = _tmp8_;
	if (_tmp9_ == SOURCE_TYPE_TODOIST) {
		ServicesTodoist* _tmp10_;
		ServicesTodoist* _tmp11_;
		ObjectsSection* _tmp12_;
		layouts_section_board_set_is_loading (self, TRUE);
		_tmp10_ = services_todoist_get_default ();
		_tmp11_ = _tmp10_;
		_tmp12_ = self->priv->_section;
		services_todoist_move_project_section (_tmp11_, (ObjectsBaseObject*) _tmp12_, project_id, ____lambda690__gasync_ready_callback, block46_data_ref (_data46_));
		_g_object_unref0 (_tmp11_);
	} else {
		ObjectsSection* _tmp13_;
		ObjectsProject* _tmp14_;
		ObjectsProject* _tmp15_;
		SourceType _tmp16_;
		SourceType _tmp17_;
		_tmp13_ = self->priv->_section;
		_tmp14_ = objects_section_get_project (_tmp13_);
		_tmp15_ = _tmp14_;
		_tmp16_ = objects_project_get_source_type (_tmp15_);
		_tmp17_ = _tmp16_;
		if (_tmp17_ == SOURCE_TYPE_LOCAL) {
			ServicesStore* _tmp18_;
			ObjectsSection* _tmp19_;
			_tmp18_ = services_store_instance ();
			_tmp19_ = self->priv->_section;
			services_store_move_section (_tmp18_, _tmp19_, project_id);
			layouts_section_board_set_is_loading (self, FALSE);
		}
	}
	block46_data_unref (_data46_);
	_data46_ = NULL;
}

static void
layouts_section_board_build_drag_and_drop (LayoutsSectionBoard* self)
{
	g_return_if_fail (self != NULL);
	layouts_section_board_build_drop_target (self);
}

static Block47Data*
block47_data_ref (Block47Data* _data47_)
{
	g_atomic_int_inc (&_data47_->_ref_count_);
	return _data47_;
}

static void
block47_data_unref (void * _userdata_)
{
	Block47Data* _data47_;
	_data47_ = (Block47Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data47_->_ref_count_)) {
		LayoutsSectionBoard* self;
		self = _data47_->self;
		_g_object_unref0 (_data47_->picked_widget);
		_g_object_unref0 (self);
		g_slice_free (Block47Data, _data47_);
	}
}

static void
___lambda699_ (Block47Data* _data47_,
               GObject* obj,
               GAsyncResult* res)
{
	LayoutsSectionBoard* self;
	ServicesTodoist* _tmp0_;
	ServicesTodoist* _tmp1_;
	HttpResponse* _tmp2_;
	HttpResponse* _tmp3_;
	gboolean _tmp4_;
	gboolean _tmp5_;
	gboolean _tmp6_;
	self = _data47_->self;
	g_return_if_fail (res != NULL);
	_tmp0_ = services_todoist_get_default ();
	_tmp1_ = _tmp0_;
	_tmp2_ = services_todoist_move_item_finish (_tmp1_, res);
	_tmp3_ = _tmp2_;
	_tmp4_ = http_response_get_status (_tmp3_);
	_tmp5_ = _tmp4_;
	_tmp6_ = _tmp5_;
	_http_response_unref0 (_tmp3_);
	_g_object_unref0 (_tmp1_);
	if (_tmp6_) {
		ServicesStore* _tmp7_;
		LayoutsItemBoard* _tmp8_;
		ObjectsItem* _tmp9_;
		ObjectsItem* _tmp10_;
		_tmp7_ = services_store_instance ();
		_tmp8_ = _data47_->picked_widget;
		_tmp9_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp8_);
		_tmp10_ = _tmp9_;
		services_store_move_item (_tmp7_, _tmp10_, "", "", "");
	}
}

static void
____lambda699__gasync_ready_callback (GObject* source_object,
                                      GAsyncResult* res,
                                      gpointer self)
{
	___lambda699_ (self, source_object, res);
	block47_data_unref (self);
}

static gboolean
__lambda698_ (LayoutsSectionBoard* self,
              GValue* value,
              gdouble x,
              gdouble y)
{
	Block47Data* _data47_;
	GValue _tmp0_;
	LayoutsItemBoard* _tmp1_;
	LayoutsItemBoard* _tmp2_;
	gchar* old_section_id = NULL;
	LayoutsItemBoard* _tmp3_;
	ObjectsItem* _tmp4_;
	ObjectsItem* _tmp5_;
	const gchar* _tmp6_;
	const gchar* _tmp7_;
	gchar* _tmp8_;
	gchar* old_parent_id = NULL;
	LayoutsItemBoard* _tmp9_;
	ObjectsItem* _tmp10_;
	ObjectsItem* _tmp11_;
	const gchar* _tmp12_;
	const gchar* _tmp13_;
	gchar* _tmp14_;
	LayoutsItemBoard* _tmp15_;
	ObjectsItem* _tmp16_;
	ObjectsItem* _tmp17_;
	ObjectsSection* _tmp18_;
	const gchar* _tmp19_;
	const gchar* _tmp20_;
	LayoutsItemBoard* _tmp21_;
	ObjectsItem* _tmp22_;
	ObjectsItem* _tmp23_;
	ObjectsSection* _tmp24_;
	const gchar* _tmp25_;
	const gchar* _tmp26_;
	LayoutsItemBoard* _tmp27_;
	ObjectsItem* _tmp28_;
	ObjectsItem* _tmp29_;
	LayoutsItemBoard* _tmp30_;
	ObjectsItem* _tmp31_;
	ObjectsItem* _tmp32_;
	ObjectsProject* _tmp33_;
	ObjectsProject* _tmp34_;
	SourceType _tmp35_;
	SourceType _tmp36_;
	GtkListBox* source_list = NULL;
	LayoutsItemBoard* _tmp67_;
	GtkWidget* _tmp68_;
	GtkWidget* _tmp69_;
	GtkListBox* _tmp70_;
	LayoutsItemBoard* _tmp71_;
	GtkListBox* _tmp72_;
	LayoutsItemBoard* _tmp73_;
	GtkListBox* _tmp74_;
	LayoutsItemBoard* _tmp75_;
	LayoutsItemBoard* _tmp76_;
	ServicesEventBus* _tmp77_;
	ServicesEventBus* _tmp78_;
	LayoutsItemBoard* _tmp79_;
	const gchar* _tmp80_;
	const gchar* _tmp81_;
	ObjectsSection* _tmp82_;
	ObjectsProject* _tmp83_;
	ObjectsProject* _tmp84_;
	gboolean result;
	g_return_val_if_fail (value != NULL, FALSE);
	_data47_ = g_slice_new0 (Block47Data);
	_data47_->_ref_count_ = 1;
	_data47_->self = g_object_ref (self);
	_tmp0_ = *value;
	_tmp1_ = _g_object_ref0 (g_value_get_object (&_tmp0_));
	_data47_->picked_widget = _tmp1_;
	_tmp2_ = _data47_->picked_widget;
	layouts_item_board_drag_end (_tmp2_);
	_tmp3_ = _data47_->picked_widget;
	_tmp4_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp3_);
	_tmp5_ = _tmp4_;
	_tmp6_ = objects_item_get_section_id (_tmp5_);
	_tmp7_ = _tmp6_;
	_tmp8_ = g_strdup (_tmp7_);
	old_section_id = _tmp8_;
	_tmp9_ = _data47_->picked_widget;
	_tmp10_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp9_);
	_tmp11_ = _tmp10_;
	_tmp12_ = objects_item_get_parent_id (_tmp11_);
	_tmp13_ = _tmp12_;
	_tmp14_ = g_strdup (_tmp13_);
	old_parent_id = _tmp14_;
	_tmp15_ = _data47_->picked_widget;
	_tmp16_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp15_);
	_tmp17_ = _tmp16_;
	_tmp18_ = self->priv->_section;
	_tmp19_ = objects_section_get_project_id (_tmp18_);
	_tmp20_ = _tmp19_;
	objects_item_set_project_id (_tmp17_, _tmp20_);
	_tmp21_ = _data47_->picked_widget;
	_tmp22_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp21_);
	_tmp23_ = _tmp22_;
	_tmp24_ = self->priv->_section;
	_tmp25_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp24_);
	_tmp26_ = _tmp25_;
	objects_item_set_section_id (_tmp23_, _tmp26_);
	_tmp27_ = _data47_->picked_widget;
	_tmp28_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp27_);
	_tmp29_ = _tmp28_;
	objects_item_set_parent_id (_tmp29_, "");
	_tmp30_ = _data47_->picked_widget;
	_tmp31_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp30_);
	_tmp32_ = _tmp31_;
	_tmp33_ = objects_item_get_project (_tmp32_);
	_tmp34_ = _tmp33_;
	_tmp35_ = objects_project_get_source_type (_tmp34_);
	_tmp36_ = _tmp35_;
	if (_tmp36_ == SOURCE_TYPE_TODOIST) {
		gchar* type = NULL;
		gchar* _tmp37_;
		gchar* id = NULL;
		ObjectsSection* _tmp38_;
		const gchar* _tmp39_;
		const gchar* _tmp40_;
		gchar* _tmp41_;
		gboolean _tmp42_;
		gboolean _tmp43_;
		ServicesTodoist* _tmp49_;
		ServicesTodoist* _tmp50_;
		LayoutsItemBoard* _tmp51_;
		ObjectsItem* _tmp52_;
		ObjectsItem* _tmp53_;
		const gchar* _tmp54_;
		const gchar* _tmp55_;
		_tmp37_ = g_strdup ("section_id");
		type = _tmp37_;
		_tmp38_ = self->priv->_section;
		_tmp39_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp38_);
		_tmp40_ = _tmp39_;
		_tmp41_ = g_strdup (_tmp40_);
		id = _tmp41_;
		_tmp42_ = layouts_section_board_get_is_inbox_section (self);
		_tmp43_ = _tmp42_;
		if (_tmp43_) {
			gchar* _tmp44_;
			ObjectsSection* _tmp45_;
			const gchar* _tmp46_;
			const gchar* _tmp47_;
			gchar* _tmp48_;
			_tmp44_ = g_strdup ("project_id");
			_g_free0 (type);
			type = _tmp44_;
			_tmp45_ = self->priv->_section;
			_tmp46_ = objects_section_get_project_id (_tmp45_);
			_tmp47_ = _tmp46_;
			_tmp48_ = g_strdup (_tmp47_);
			_g_free0 (id);
			id = _tmp48_;
		}
		_tmp49_ = services_todoist_get_default ();
		_tmp50_ = _tmp49_;
		_tmp51_ = _data47_->picked_widget;
		_tmp52_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp51_);
		_tmp53_ = _tmp52_;
		_tmp54_ = type;
		_tmp55_ = id;
		services_todoist_move_item (_tmp50_, _tmp53_, _tmp54_, _tmp55_, ____lambda699__gasync_ready_callback, block47_data_ref (_data47_));
		_g_object_unref0 (_tmp50_);
		_g_free0 (id);
		_g_free0 (type);
	} else {
		LayoutsItemBoard* _tmp56_;
		ObjectsItem* _tmp57_;
		ObjectsItem* _tmp58_;
		ObjectsProject* _tmp59_;
		ObjectsProject* _tmp60_;
		SourceType _tmp61_;
		SourceType _tmp62_;
		_tmp56_ = _data47_->picked_widget;
		_tmp57_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp56_);
		_tmp58_ = _tmp57_;
		_tmp59_ = objects_item_get_project (_tmp58_);
		_tmp60_ = _tmp59_;
		_tmp61_ = objects_project_get_source_type (_tmp60_);
		_tmp62_ = _tmp61_;
		if (_tmp62_ == SOURCE_TYPE_LOCAL) {
			ServicesStore* _tmp63_;
			LayoutsItemBoard* _tmp64_;
			ObjectsItem* _tmp65_;
			ObjectsItem* _tmp66_;
			_tmp63_ = services_store_instance ();
			_tmp64_ = _data47_->picked_widget;
			_tmp65_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp64_);
			_tmp66_ = _tmp65_;
			services_store_move_item (_tmp63_, _tmp66_, "", "", "");
		}
	}
	_tmp67_ = _data47_->picked_widget;
	_tmp68_ = gtk_widget_get_parent ((GtkWidget*) _tmp67_);
	_tmp69_ = _tmp68_;
	_tmp70_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_CAST (_tmp69_, gtk_list_box_get_type (), GtkListBox));
	source_list = _tmp70_;
	_tmp71_ = _data47_->picked_widget;
	gtk_list_box_remove (source_list, (GtkWidget*) _tmp71_);
	_tmp72_ = self->priv->listbox;
	_tmp73_ = _data47_->picked_widget;
	gtk_list_box_append (_tmp72_, (GtkWidget*) _tmp73_);
	_tmp74_ = self->priv->listbox;
	_tmp75_ = _data47_->picked_widget;
	_tmp76_ = _data47_->picked_widget;
	utils_task_utils_update_single_item_order (_tmp74_, (LayoutsItemBase*) _tmp75_, gtk_list_box_row_get_index ((GtkListBoxRow*) _tmp76_));
	_tmp77_ = services_event_bus_get_default ();
	_tmp78_ = _tmp77_;
	_tmp79_ = _data47_->picked_widget;
	_tmp80_ = old_section_id;
	_tmp81_ = old_parent_id;
	g_signal_emit_by_name (_tmp78_, "update-inserted-item-map", (GtkWidget*) _tmp79_, _tmp80_, _tmp81_);
	_g_object_unref0 (_tmp78_);
	_tmp82_ = self->priv->_section;
	_tmp83_ = objects_section_get_project (_tmp82_);
	_tmp84_ = _tmp83_;
	objects_base_object_count_update ((ObjectsBaseObject*) _tmp84_);
	result = TRUE;
	_g_object_unref0 (source_list);
	_g_free0 (old_parent_id);
	_g_free0 (old_section_id);
	block47_data_unref (_data47_);
	_data47_ = NULL;
	return result;
}

static gboolean
___lambda698__gtk_drop_target_drop (GtkDropTarget* _sender,
                                    GValue* value,
                                    gdouble x,
                                    gdouble y,
                                    gpointer self)
{
	gboolean result;
	result = __lambda698_ ((LayoutsSectionBoard*) self, value, x, y);
	return result;
}

static void
layouts_section_board_build_drop_target (LayoutsSectionBoard* self)
{
	GtkDropTarget* drop_target = NULL;
	GtkDropTarget* _tmp0_;
	GtkBox* _tmp1_;
	GtkEventController* _tmp2_;
	GeeHashMap* _tmp3_;
	gulong _tmp4_;
	g_return_if_fail (self != NULL);
	_tmp0_ = gtk_drop_target_new (LAYOUTS_TYPE_ITEM_BOARD, GDK_ACTION_MOVE);
	drop_target = _tmp0_;
	_tmp1_ = self->priv->content_box;
	_tmp2_ = _g_object_ref0 ((GtkEventController*) drop_target);
	gtk_widget_add_controller ((GtkWidget*) _tmp1_, _tmp2_);
	_tmp3_ = self->priv->signals_map;
	_tmp4_ = g_signal_connect_object (drop_target, "drop", (GCallback) ___lambda698__gtk_drop_target_drop, self, 0);
	gee_abstract_map_set ((GeeAbstractMap*) _tmp3_, (gpointer) ((guintptr) _tmp4_), (GObject*) drop_target);
	_g_object_unref0 (drop_target);
}

static gboolean
__lambda700_ (LayoutsSectionBoard* self)
{
	GtkWidget* _tmp0_;
	GtkWidget* _tmp1_;
	gboolean result;
	_tmp0_ = gtk_widget_get_parent ((GtkWidget*) self);
	_tmp1_ = _tmp0_;
	gtk_flow_box_remove (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, gtk_flow_box_get_type (), GtkFlowBox), (GtkWidget*) self);
	result = G_SOURCE_REMOVE;
	return result;
}

static gboolean
___lambda700__gsource_func (gpointer self)
{
	gboolean result;
	result = __lambda700_ ((LayoutsSectionBoard*) self);
	return result;
}

void
layouts_section_board_hide_destroy (LayoutsSectionBoard* self)
{
	g_return_if_fail (self != NULL);
	gtk_widget_set_visible ((GtkWidget*) self, FALSE);
	layouts_section_board_clean_up (self);
	g_timeout_add_full (G_PRIORITY_DEFAULT, (guint) 225, ___lambda700__gsource_func, g_object_ref (self), g_object_unref);
}

static void
_g_object_unref0_ (gpointer var)
{
	(var == NULL) ? NULL : (var = (g_object_unref (var), NULL));
}

static inline void
_g_list_free__g_object_unref0_ (GList* self)
{
	g_list_free_full (self, (GDestroyNotify) _g_object_unref0_);
}

void
layouts_section_board_clean_up (LayoutsSectionBoard* self)
{
	GtkListBox* _tmp0_;
	GtkListBox* _tmp1_;
	Util* _tmp2_;
	Util* _tmp3_;
	GtkListBox* _tmp4_;
	GList* _tmp5_;
	GList* _tmp6_;
	Util* _tmp9_;
	Util* _tmp10_;
	GtkListBox* _tmp11_;
	GList* _tmp12_;
	GList* _tmp13_;
	GeeHashMap* _tmp31_;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->priv->listbox;
	gtk_list_box_set_sort_func (_tmp0_, NULL, NULL, NULL);
	_tmp1_ = self->priv->listbox;
	gtk_list_box_set_filter_func (_tmp1_, NULL, NULL, NULL);
	_tmp2_ = util_get_default ();
	_tmp3_ = _tmp2_;
	_tmp4_ = self->priv->listbox;
	_tmp5_ = util_get_children (_tmp3_, _tmp4_);
	_tmp6_ = _tmp5_;
	_g_object_unref0 (_tmp3_);
	{
		GList* row_collection = NULL;
		GList* row_it = NULL;
		row_collection = _tmp6_;
		for (row_it = row_collection; row_it != NULL; row_it = row_it->next) {
			GtkListBoxRow* _tmp7_;
			GtkListBoxRow* row = NULL;
			_tmp7_ = _g_object_ref0 ((GtkListBoxRow*) row_it->data);
			row = _tmp7_;
			{
				GtkListBoxRow* _tmp8_;
				_tmp8_ = row;
				layouts_item_base_clean_up ((LayoutsItemBase*) G_TYPE_CHECK_INSTANCE_CAST (_tmp8_, LAYOUTS_TYPE_ITEM_BOARD, LayoutsItemBoard));
				_g_object_unref0 (row);
			}
		}
		(row_collection == NULL) ? NULL : (row_collection = (_g_list_free__g_object_unref0_ (row_collection), NULL));
	}
	_tmp9_ = util_get_default ();
	_tmp10_ = _tmp9_;
	_tmp11_ = self->priv->checked_listbox;
	_tmp12_ = util_get_children (_tmp10_, _tmp11_);
	_tmp13_ = _tmp12_;
	_g_object_unref0 (_tmp10_);
	{
		GList* row_collection = NULL;
		GList* row_it = NULL;
		row_collection = _tmp13_;
		for (row_it = row_collection; row_it != NULL; row_it = row_it->next) {
			GtkListBoxRow* _tmp14_;
			GtkListBoxRow* row = NULL;
			_tmp14_ = _g_object_ref0 ((GtkListBoxRow*) row_it->data);
			row = _tmp14_;
			{
				GtkListBoxRow* _tmp15_;
				_tmp15_ = row;
				layouts_item_base_clean_up ((LayoutsItemBase*) G_TYPE_CHECK_INSTANCE_CAST (_tmp15_, LAYOUTS_TYPE_ITEM_BOARD, LayoutsItemBoard));
				_g_object_unref0 (row);
			}
		}
		(row_collection == NULL) ? NULL : (row_collection = (_g_list_free__g_object_unref0_ (row_collection), NULL));
	}
	{
		GeeIterator* _entry_it = NULL;
		GeeHashMap* _tmp16_;
		GeeSet* _tmp17_;
		GeeSet* _tmp18_;
		GeeSet* _tmp19_;
		GeeIterator* _tmp20_;
		GeeIterator* _tmp21_;
		_tmp16_ = self->priv->signals_map;
		_tmp17_ = gee_abstract_map_get_entries ((GeeAbstractMap*) _tmp16_);
		_tmp18_ = _tmp17_;
		_tmp19_ = _tmp18_;
		_tmp20_ = gee_iterable_iterator ((GeeIterable*) _tmp19_);
		_tmp21_ = _tmp20_;
		_g_object_unref0 (_tmp19_);
		_entry_it = _tmp21_;
		while (TRUE) {
			GeeIterator* _tmp22_;
			GeeMapEntry* entry = NULL;
			GeeIterator* _tmp23_;
			gpointer _tmp24_;
			GeeMapEntry* _tmp25_;
			gconstpointer _tmp26_;
			gconstpointer _tmp27_;
			GeeMapEntry* _tmp28_;
			gconstpointer _tmp29_;
			gconstpointer _tmp30_;
			_tmp22_ = _entry_it;
			if (!gee_iterator_next (_tmp22_)) {
				break;
			}
			_tmp23_ = _entry_it;
			_tmp24_ = gee_iterator_get (_tmp23_);
			entry = (GeeMapEntry*) _tmp24_;
			_tmp25_ = entry;
			_tmp26_ = gee_map_entry_get_value (_tmp25_);
			_tmp27_ = _tmp26_;
			_tmp28_ = entry;
			_tmp29_ = gee_map_entry_get_key (_tmp28_);
			_tmp30_ = _tmp29_;
			g_signal_handler_disconnect ((GObject*) _tmp27_, (gulong) ((guintptr) _tmp30_));
			_g_object_unref0 (entry);
		}
		_g_object_unref0 (_entry_it);
	}
	_tmp31_ = self->priv->signals_map;
	gee_abstract_map_clear ((GeeAbstractMap*) _tmp31_);
}

ObjectsSection*
layouts_section_board_get_section (LayoutsSectionBoard* self)
{
	ObjectsSection* result;
	ObjectsSection* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_section;
	result = _tmp0_;
	return result;
}

static void
layouts_section_board_set_section (LayoutsSectionBoard* self,
                                   ObjectsSection* value)
{
	ObjectsSection* old_value;
	g_return_if_fail (self != NULL);
	old_value = layouts_section_board_get_section (self);
	if (old_value != value) {
		ObjectsSection* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_section);
		self->priv->_section = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, layouts_section_board_properties[LAYOUTS_SECTION_BOARD_SECTION_PROPERTY]);
	}
}

gboolean
layouts_section_board_get_is_inbox_section (LayoutsSectionBoard* self)
{
	gboolean result;
	ObjectsSection* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	g_return_val_if_fail (self != NULL, FALSE);
	_tmp0_ = self->priv->_section;
	_tmp1_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp0_);
	_tmp2_ = _tmp1_;
	result = g_strcmp0 (_tmp2_, "") == 0;
	return result;
}

void
layouts_section_board_set_is_loading (LayoutsSectionBoard* self,
                                      gboolean value)
{
	g_return_if_fail (self != NULL);
	g_object_notify_by_pspec ((GObject *) self, layouts_section_board_properties[LAYOUTS_SECTION_BOARD_IS_LOADING_PROPERTY]);
}

gint
layouts_section_board_get_section_count (LayoutsSectionBoard* self)
{
	gint result;
	GeeHashMap* _tmp0_;
	gint _tmp1_;
	gint _tmp2_;
	g_return_val_if_fail (self != NULL, -1);
	_tmp0_ = self->items_map;
	_tmp1_ = gee_abstract_map_get_size ((GeeAbstractMap*) _tmp0_);
	_tmp2_ = _tmp1_;
	result = _tmp2_;
	return result;
}

static gboolean
_layouts_section_board___lambda701_ (LayoutsSectionBoard* self,
                                     GtkListBoxRow* row)
{
	ObjectsItem* item = NULL;
	ObjectsItem* _tmp0_;
	ObjectsItem* _tmp1_;
	ObjectsItem* _tmp2_;
	ObjectsItem* _tmp3_;
	ObjectsSection* _tmp4_;
	ObjectsProject* _tmp5_;
	ObjectsProject* _tmp6_;
	GeeHashMap* _tmp7_;
	gboolean result;
	g_return_val_if_fail (row != NULL, FALSE);
	_tmp0_ = layouts_item_base_get_item ((LayoutsItemBase*) G_TYPE_CHECK_INSTANCE_CAST (row, LAYOUTS_TYPE_ITEM_BOARD, LayoutsItemBoard));
	_tmp1_ = _tmp0_;
	_tmp2_ = _g_object_ref0 (_tmp1_);
	item = _tmp2_;
	_tmp3_ = item;
	_tmp4_ = self->priv->_section;
	_tmp5_ = objects_section_get_project (_tmp4_);
	_tmp6_ = _tmp5_;
	_tmp7_ = ((ObjectsBaseObject*) _tmp6_)->filters;
	result = utils_task_utils_items_filter_func (_tmp3_, _tmp7_);
	_g_object_unref0 (item);
	return result;
}

static gboolean
__layouts_section_board___lambda701__gtk_list_box_filter_func (GtkListBoxRow* row,
                                                               gpointer self)
{
	gboolean result;
	result = _layouts_section_board___lambda701_ ((LayoutsSectionBoard*) self, row);
	return result;
}

static void
_layouts_section_board___lambda702_ (LayoutsSectionBoard* self,
                                     GtkListBoxRow* row)
{
	ObjectsItem* item = NULL;
	ObjectsItem* _tmp0_;
	ObjectsItem* _tmp1_;
	ObjectsItem* _tmp2_;
	_tmp0_ = layouts_item_base_get_item ((LayoutsItemBase*) G_TYPE_CHECK_INSTANCE_CAST (row, LAYOUTS_TYPE_ITEM_BOARD, LayoutsItemBoard));
	_tmp1_ = _tmp0_;
	_tmp2_ = _g_object_ref0 (_tmp1_);
	item = _tmp2_;
	_g_object_unref0 (item);
}

static void
__layouts_section_board___lambda702__gtk_list_box_row_selected (GtkListBox* _sender,
                                                                GtkListBoxRow* row,
                                                                gpointer self)
{
	_layouts_section_board___lambda702_ ((LayoutsSectionBoard*) self, row);
}

static void
_layouts_section_board___lambda703_ (LayoutsSectionBoard* self)
{
	layouts_section_board_update_request (self);
}

static void
__layouts_section_board___lambda703__objects_base_object_updated (ObjectsBaseObject* _sender,
                                                                  const gchar* update_id,
                                                                  gpointer self)
{
	_layouts_section_board___lambda703_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board____lambda704_ (LayoutsSectionBoard* self,
                                      ObjectsItem* item)
{
	g_return_if_fail (item != NULL);
	layouts_section_board_add_item (self, item, -1);
}

static void
__layouts_section_board____lambda704__objects_project_item_added (ObjectsProject* _sender,
                                                                  ObjectsItem* item,
                                                                  gpointer self)
{
	_layouts_section_board____lambda704_ ((LayoutsSectionBoard*) self, item);
}

static void
_layouts_section_board____lambda705_ (LayoutsSectionBoard* self)
{
	layouts_section_board_refresh_count_label (self);
}

static void
__layouts_section_board____lambda705__objects_base_object_count_updated (ObjectsBaseObject* _sender,
                                                                         gpointer self)
{
	_layouts_section_board____lambda705_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board____lambda706_ (LayoutsSectionBoard* self,
                                      ObjectsItem* item)
{
	g_return_if_fail (item != NULL);
	layouts_section_board_add_item (self, item, -1);
}

static void
__layouts_section_board____lambda706__objects_section_item_added (ObjectsSection* _sender,
                                                                  ObjectsItem* item,
                                                                  gpointer self)
{
	_layouts_section_board____lambda706_ ((LayoutsSectionBoard*) self, item);
}

static void
_layouts_section_board___lambda707_ (LayoutsSectionBoard* self,
                                     ObjectsItem* item,
                                     gboolean old_checked)
{
	gboolean _tmp0_ = FALSE;
	gboolean _tmp1_ = FALSE;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	ObjectsSection* _tmp4_;
	const gchar* _tmp5_;
	const gchar* _tmp6_;
	g_return_if_fail (item != NULL);
	_tmp2_ = objects_item_get_project_id (item);
	_tmp3_ = _tmp2_;
	_tmp4_ = self->priv->_section;
	_tmp5_ = objects_section_get_project_id (_tmp4_);
	_tmp6_ = _tmp5_;
	if (g_strcmp0 (_tmp3_, _tmp6_) == 0) {
		const gchar* _tmp7_;
		const gchar* _tmp8_;
		ObjectsSection* _tmp9_;
		const gchar* _tmp10_;
		const gchar* _tmp11_;
		_tmp7_ = objects_item_get_section_id (item);
		_tmp8_ = _tmp7_;
		_tmp9_ = self->priv->_section;
		_tmp10_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp9_);
		_tmp11_ = _tmp10_;
		_tmp1_ = g_strcmp0 (_tmp8_, _tmp11_) == 0;
	} else {
		_tmp1_ = FALSE;
	}
	if (_tmp1_) {
		gboolean _tmp12_;
		gboolean _tmp13_;
		_tmp12_ = objects_item_get_has_parent (item);
		_tmp13_ = _tmp12_;
		_tmp0_ = !_tmp13_;
	} else {
		_tmp0_ = FALSE;
	}
	if (_tmp0_) {
		if (!old_checked) {
			GeeHashMap* _tmp14_;
			const gchar* _tmp15_;
			const gchar* _tmp16_;
			GeeHashMap* _tmp25_;
			const gchar* _tmp26_;
			const gchar* _tmp27_;
			_tmp14_ = self->items_map;
			_tmp15_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
			_tmp16_ = _tmp15_;
			if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp14_, _tmp16_)) {
				GeeHashMap* _tmp17_;
				const gchar* _tmp18_;
				const gchar* _tmp19_;
				gpointer _tmp20_;
				LayoutsItemBoard* _tmp21_;
				GeeHashMap* _tmp22_;
				const gchar* _tmp23_;
				const gchar* _tmp24_;
				_tmp17_ = self->items_map;
				_tmp18_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
				_tmp19_ = _tmp18_;
				_tmp20_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp17_, _tmp19_);
				_tmp21_ = (LayoutsItemBoard*) _tmp20_;
				layouts_item_base_hide_destroy ((LayoutsItemBase*) _tmp21_);
				_g_object_unref0 (_tmp21_);
				_tmp22_ = self->items_map;
				_tmp23_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
				_tmp24_ = _tmp23_;
				gee_abstract_map_unset ((GeeAbstractMap*) _tmp22_, _tmp24_, NULL);
			}
			_tmp25_ = self->checked_items_map;
			_tmp26_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
			_tmp27_ = _tmp26_;
			if (!gee_abstract_map_has_key ((GeeAbstractMap*) _tmp25_, _tmp27_)) {
				GeeHashMap* _tmp28_;
				const gchar* _tmp29_;
				const gchar* _tmp30_;
				LayoutsItemBoard* _tmp31_;
				LayoutsItemBoard* _tmp32_;
				GtkListBox* _tmp33_;
				GeeHashMap* _tmp34_;
				const gchar* _tmp35_;
				const gchar* _tmp36_;
				gpointer _tmp37_;
				LayoutsItemBoard* _tmp38_;
				_tmp28_ = self->checked_items_map;
				_tmp29_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
				_tmp30_ = _tmp29_;
				_tmp31_ = layouts_item_board_new (item);
				g_object_ref_sink (_tmp31_);
				_tmp32_ = _tmp31_;
				gee_abstract_map_set ((GeeAbstractMap*) _tmp28_, _tmp30_, _tmp32_);
				_g_object_unref0 (_tmp32_);
				_tmp33_ = self->priv->checked_listbox;
				_tmp34_ = self->checked_items_map;
				_tmp35_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
				_tmp36_ = _tmp35_;
				_tmp37_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp34_, _tmp36_);
				_tmp38_ = (LayoutsItemBoard*) _tmp37_;
				gtk_list_box_insert (_tmp33_, (GtkWidget*) _tmp38_, 0);
				_g_object_unref0 (_tmp38_);
			}
		} else {
			GeeHashMap* _tmp39_;
			const gchar* _tmp40_;
			const gchar* _tmp41_;
			GeeHashMap* _tmp50_;
			const gchar* _tmp51_;
			const gchar* _tmp52_;
			_tmp39_ = self->checked_items_map;
			_tmp40_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
			_tmp41_ = _tmp40_;
			if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp39_, _tmp41_)) {
				GeeHashMap* _tmp42_;
				const gchar* _tmp43_;
				const gchar* _tmp44_;
				gpointer _tmp45_;
				LayoutsItemBoard* _tmp46_;
				GeeHashMap* _tmp47_;
				const gchar* _tmp48_;
				const gchar* _tmp49_;
				_tmp42_ = self->checked_items_map;
				_tmp43_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
				_tmp44_ = _tmp43_;
				_tmp45_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp42_, _tmp44_);
				_tmp46_ = (LayoutsItemBoard*) _tmp45_;
				layouts_item_base_hide_destroy ((LayoutsItemBase*) _tmp46_);
				_g_object_unref0 (_tmp46_);
				_tmp47_ = self->checked_items_map;
				_tmp48_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
				_tmp49_ = _tmp48_;
				gee_abstract_map_unset ((GeeAbstractMap*) _tmp47_, _tmp49_, NULL);
			}
			_tmp50_ = self->items_map;
			_tmp51_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
			_tmp52_ = _tmp51_;
			if (!gee_abstract_map_has_key ((GeeAbstractMap*) _tmp50_, _tmp52_)) {
				GeeHashMap* _tmp53_;
				const gchar* _tmp54_;
				const gchar* _tmp55_;
				LayoutsItemBoard* _tmp56_;
				LayoutsItemBoard* _tmp57_;
				GtkListBox* _tmp58_;
				GeeHashMap* _tmp59_;
				const gchar* _tmp60_;
				const gchar* _tmp61_;
				gpointer _tmp62_;
				LayoutsItemBoard* _tmp63_;
				_tmp53_ = self->items_map;
				_tmp54_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
				_tmp55_ = _tmp54_;
				_tmp56_ = layouts_item_board_new (item);
				g_object_ref_sink (_tmp56_);
				_tmp57_ = _tmp56_;
				gee_abstract_map_set ((GeeAbstractMap*) _tmp53_, _tmp55_, _tmp57_);
				_g_object_unref0 (_tmp57_);
				_tmp58_ = self->priv->listbox;
				_tmp59_ = self->items_map;
				_tmp60_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
				_tmp61_ = _tmp60_;
				_tmp62_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp59_, _tmp61_);
				_tmp63_ = (LayoutsItemBoard*) _tmp62_;
				gtk_list_box_append (_tmp58_, (GtkWidget*) _tmp63_);
				_g_object_unref0 (_tmp63_);
			}
		}
	}
}

static void
__layouts_section_board___lambda707__services_event_bus_checked_toggled (ServicesEventBus* _sender,
                                                                         ObjectsItem* item,
                                                                         gboolean old_checked,
                                                                         gpointer self)
{
	_layouts_section_board___lambda707_ ((LayoutsSectionBoard*) self, item, old_checked);
}

static void
_layouts_section_board___lambda708_ (LayoutsSectionBoard* self,
                                     ObjectsItem* item,
                                     const gchar* update_id)
{
	GeeHashMap* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	GeeHashMap* _tmp13_;
	const gchar* _tmp14_;
	const gchar* _tmp15_;
	g_return_if_fail (item != NULL);
	g_return_if_fail (update_id != NULL);
	_tmp0_ = self->items_map;
	_tmp1_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
	_tmp2_ = _tmp1_;
	if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp0_, _tmp2_)) {
		GeeHashMap* _tmp3_;
		const gchar* _tmp4_;
		const gchar* _tmp5_;
		gpointer _tmp6_;
		LayoutsItemBoard* _tmp7_;
		ObjectsSection* _tmp8_;
		ObjectsProject* _tmp9_;
		ObjectsProject* _tmp10_;
		SortedByType _tmp11_;
		SortedByType _tmp12_;
		_tmp3_ = self->items_map;
		_tmp4_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
		_tmp5_ = _tmp4_;
		_tmp6_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp3_, _tmp5_);
		_tmp7_ = (LayoutsItemBoard*) _tmp6_;
		layouts_item_base_update_request ((LayoutsItemBase*) _tmp7_);
		_g_object_unref0 (_tmp7_);
		_tmp8_ = self->priv->_section;
		_tmp9_ = objects_section_get_project (_tmp8_);
		_tmp10_ = _tmp9_;
		_tmp11_ = objects_project_get_sorted_by (_tmp10_);
		_tmp12_ = _tmp11_;
		if (_tmp12_ != SORTED_BY_TYPE_MANUAL) {
			layouts_section_board_update_sort (self);
		}
	}
	_tmp13_ = self->checked_items_map;
	_tmp14_ = objects_base_object_get_id_string ((ObjectsBaseObject*) item);
	_tmp15_ = _tmp14_;
	if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp13_, _tmp15_)) {
		GeeHashMap* _tmp16_;
		const gchar* _tmp17_;
		const gchar* _tmp18_;
		gpointer _tmp19_;
		LayoutsItemBoard* _tmp20_;
		_tmp16_ = self->checked_items_map;
		_tmp17_ = objects_base_object_get_id_string ((ObjectsBaseObject*) item);
		_tmp18_ = _tmp17_;
		_tmp19_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp16_, _tmp18_);
		_tmp20_ = (LayoutsItemBoard*) _tmp19_;
		layouts_item_base_update_request ((LayoutsItemBase*) _tmp20_);
		_g_object_unref0 (_tmp20_);
	}
}

static void
__layouts_section_board___lambda708__services_store_item_updated (ServicesStore* _sender,
                                                                  ObjectsItem* item,
                                                                  const gchar* update_id,
                                                                  gpointer self)
{
	_layouts_section_board___lambda708_ ((LayoutsSectionBoard*) self, item, update_id);
}

static void
_layouts_section_board___lambda709_ (LayoutsSectionBoard* self,
                                     ObjectsItem* item)
{
	gboolean _tmp0_ = FALSE;
	gboolean _tmp1_ = FALSE;
	gboolean _tmp2_ = FALSE;
	gboolean _tmp3_ = FALSE;
	gboolean _tmp4_;
	gboolean _tmp5_;
	gboolean _tmp21_ = FALSE;
	gboolean _tmp22_;
	gboolean _tmp23_;
	g_return_if_fail (item != NULL);
	_tmp4_ = objects_item_get_pinned (item);
	_tmp5_ = _tmp4_;
	if (!_tmp5_) {
		const gchar* _tmp6_;
		const gchar* _tmp7_;
		ObjectsSection* _tmp8_;
		const gchar* _tmp9_;
		const gchar* _tmp10_;
		_tmp6_ = objects_item_get_project_id (item);
		_tmp7_ = _tmp6_;
		_tmp8_ = self->priv->_section;
		_tmp9_ = objects_section_get_project_id (_tmp8_);
		_tmp10_ = _tmp9_;
		_tmp3_ = g_strcmp0 (_tmp7_, _tmp10_) == 0;
	} else {
		_tmp3_ = FALSE;
	}
	if (_tmp3_) {
		const gchar* _tmp11_;
		const gchar* _tmp12_;
		ObjectsSection* _tmp13_;
		const gchar* _tmp14_;
		const gchar* _tmp15_;
		_tmp11_ = objects_item_get_section_id (item);
		_tmp12_ = _tmp11_;
		_tmp13_ = self->priv->_section;
		_tmp14_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp13_);
		_tmp15_ = _tmp14_;
		_tmp2_ = g_strcmp0 (_tmp12_, _tmp15_) == 0;
	} else {
		_tmp2_ = FALSE;
	}
	if (_tmp2_) {
		gboolean _tmp16_;
		gboolean _tmp17_;
		_tmp16_ = objects_item_get_has_parent (item);
		_tmp17_ = _tmp16_;
		_tmp1_ = !_tmp17_;
	} else {
		_tmp1_ = FALSE;
	}
	if (_tmp1_) {
		GeeHashMap* _tmp18_;
		const gchar* _tmp19_;
		const gchar* _tmp20_;
		_tmp18_ = self->items_map;
		_tmp19_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
		_tmp20_ = _tmp19_;
		_tmp0_ = !gee_abstract_map_has_key ((GeeAbstractMap*) _tmp18_, _tmp20_);
	} else {
		_tmp0_ = FALSE;
	}
	if (_tmp0_) {
		layouts_section_board_add_item (self, item, -1);
	}
	_tmp22_ = objects_item_get_pinned (item);
	_tmp23_ = _tmp22_;
	if (_tmp23_) {
		GeeHashMap* _tmp24_;
		const gchar* _tmp25_;
		const gchar* _tmp26_;
		_tmp24_ = self->items_map;
		_tmp25_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
		_tmp26_ = _tmp25_;
		_tmp21_ = gee_abstract_map_has_key ((GeeAbstractMap*) _tmp24_, _tmp26_);
	} else {
		_tmp21_ = FALSE;
	}
	if (_tmp21_) {
		GeeHashMap* _tmp27_;
		const gchar* _tmp28_;
		const gchar* _tmp29_;
		gpointer _tmp30_;
		LayoutsItemBoard* _tmp31_;
		GeeHashMap* _tmp32_;
		const gchar* _tmp33_;
		const gchar* _tmp34_;
		_tmp27_ = self->items_map;
		_tmp28_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
		_tmp29_ = _tmp28_;
		_tmp30_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp27_, _tmp29_);
		_tmp31_ = (LayoutsItemBoard*) _tmp30_;
		layouts_item_base_hide_destroy ((LayoutsItemBase*) _tmp31_);
		_g_object_unref0 (_tmp31_);
		_tmp32_ = self->items_map;
		_tmp33_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
		_tmp34_ = _tmp33_;
		gee_abstract_map_unset ((GeeAbstractMap*) _tmp32_, _tmp34_, NULL);
	}
}

static void
__layouts_section_board___lambda709__services_store_item_pin_change (ServicesStore* _sender,
                                                                     ObjectsItem* item,
                                                                     gpointer self)
{
	_layouts_section_board___lambda709_ ((LayoutsSectionBoard*) self, item);
}

static void
_layouts_section_board___lambda710_ (LayoutsSectionBoard* self,
                                     ObjectsItem* item)
{
	GeeHashMap* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	g_return_if_fail (item != NULL);
	_tmp0_ = self->items_map;
	_tmp1_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
	_tmp2_ = _tmp1_;
	if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp0_, _tmp2_)) {
		GeeHashMap* _tmp3_;
		const gchar* _tmp4_;
		const gchar* _tmp5_;
		gpointer _tmp6_;
		LayoutsItemBoard* _tmp7_;
		GeeHashMap* _tmp8_;
		const gchar* _tmp9_;
		const gchar* _tmp10_;
		_tmp3_ = self->items_map;
		_tmp4_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
		_tmp5_ = _tmp4_;
		_tmp6_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp3_, _tmp5_);
		_tmp7_ = (LayoutsItemBoard*) _tmp6_;
		layouts_item_base_hide_destroy ((LayoutsItemBase*) _tmp7_);
		_g_object_unref0 (_tmp7_);
		_tmp8_ = self->items_map;
		_tmp9_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
		_tmp10_ = _tmp9_;
		gee_abstract_map_unset ((GeeAbstractMap*) _tmp8_, _tmp10_, NULL);
	}
}

static void
__layouts_section_board___lambda710__services_store_item_deleted (ServicesStore* _sender,
                                                                  ObjectsItem* item,
                                                                  gpointer self)
{
	_layouts_section_board___lambda710_ ((LayoutsSectionBoard*) self, item);
}

static void
_layouts_section_board___lambda711_ (LayoutsSectionBoard* self,
                                     ObjectsItem* item,
                                     const gchar* old_project_id,
                                     const gchar* old_section_id,
                                     const gchar* old_parent_id)
{
	gboolean _tmp0_ = FALSE;
	ObjectsSection* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	gboolean _tmp29_ = FALSE;
	gboolean _tmp30_ = FALSE;
	const gchar* _tmp31_;
	const gchar* _tmp32_;
	ObjectsSection* _tmp33_;
	const gchar* _tmp34_;
	const gchar* _tmp35_;
	g_return_if_fail (item != NULL);
	g_return_if_fail (old_project_id != NULL);
	g_return_if_fail (old_section_id != NULL);
	g_return_if_fail (old_parent_id != NULL);
	_tmp1_ = self->priv->_section;
	_tmp2_ = objects_section_get_project_id (_tmp1_);
	_tmp3_ = _tmp2_;
	if (g_strcmp0 (old_project_id, _tmp3_) == 0) {
		ObjectsSection* _tmp4_;
		const gchar* _tmp5_;
		const gchar* _tmp6_;
		_tmp4_ = self->priv->_section;
		_tmp5_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp4_);
		_tmp6_ = _tmp5_;
		_tmp0_ = g_strcmp0 (old_section_id, _tmp6_) == 0;
	} else {
		_tmp0_ = FALSE;
	}
	if (_tmp0_) {
		GeeHashMap* _tmp7_;
		const gchar* _tmp8_;
		const gchar* _tmp9_;
		GeeHashMap* _tmp18_;
		const gchar* _tmp19_;
		const gchar* _tmp20_;
		_tmp7_ = self->items_map;
		_tmp8_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
		_tmp9_ = _tmp8_;
		if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp7_, _tmp9_)) {
			GeeHashMap* _tmp10_;
			const gchar* _tmp11_;
			const gchar* _tmp12_;
			gpointer _tmp13_;
			LayoutsItemBoard* _tmp14_;
			GeeHashMap* _tmp15_;
			const gchar* _tmp16_;
			const gchar* _tmp17_;
			_tmp10_ = self->items_map;
			_tmp11_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
			_tmp12_ = _tmp11_;
			_tmp13_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp10_, _tmp12_);
			_tmp14_ = (LayoutsItemBoard*) _tmp13_;
			layouts_item_base_hide_destroy ((LayoutsItemBase*) _tmp14_);
			_g_object_unref0 (_tmp14_);
			_tmp15_ = self->items_map;
			_tmp16_ = objects_base_object_get_id ((ObjectsBaseObject*) item);
			_tmp17_ = _tmp16_;
			gee_abstract_map_unset ((GeeAbstractMap*) _tmp15_, _tmp17_, NULL);
		}
		_tmp18_ = self->checked_items_map;
		_tmp19_ = objects_base_object_get_id_string ((ObjectsBaseObject*) item);
		_tmp20_ = _tmp19_;
		if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp18_, _tmp20_)) {
			GeeHashMap* _tmp21_;
			const gchar* _tmp22_;
			const gchar* _tmp23_;
			gpointer _tmp24_;
			LayoutsItemBoard* _tmp25_;
			GeeHashMap* _tmp26_;
			const gchar* _tmp27_;
			const gchar* _tmp28_;
			_tmp21_ = self->checked_items_map;
			_tmp22_ = objects_base_object_get_id_string ((ObjectsBaseObject*) item);
			_tmp23_ = _tmp22_;
			_tmp24_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp21_, _tmp23_);
			_tmp25_ = (LayoutsItemBoard*) _tmp24_;
			layouts_item_base_hide_destroy ((LayoutsItemBase*) _tmp25_);
			_g_object_unref0 (_tmp25_);
			_tmp26_ = self->checked_items_map;
			_tmp27_ = objects_base_object_get_id_string ((ObjectsBaseObject*) item);
			_tmp28_ = _tmp27_;
			gee_abstract_map_unset ((GeeAbstractMap*) _tmp26_, _tmp28_, NULL);
		}
	}
	_tmp31_ = objects_item_get_project_id (item);
	_tmp32_ = _tmp31_;
	_tmp33_ = self->priv->_section;
	_tmp34_ = objects_section_get_project_id (_tmp33_);
	_tmp35_ = _tmp34_;
	if (g_strcmp0 (_tmp32_, _tmp35_) == 0) {
		const gchar* _tmp36_;
		const gchar* _tmp37_;
		ObjectsSection* _tmp38_;
		const gchar* _tmp39_;
		const gchar* _tmp40_;
		_tmp36_ = objects_item_get_section_id (item);
		_tmp37_ = _tmp36_;
		_tmp38_ = self->priv->_section;
		_tmp39_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp38_);
		_tmp40_ = _tmp39_;
		_tmp30_ = g_strcmp0 (_tmp37_, _tmp40_) == 0;
	} else {
		_tmp30_ = FALSE;
	}
	if (_tmp30_) {
		gboolean _tmp41_;
		gboolean _tmp42_;
		_tmp41_ = objects_item_get_has_parent (item);
		_tmp42_ = _tmp41_;
		_tmp29_ = !_tmp42_;
	} else {
		_tmp29_ = FALSE;
	}
	if (_tmp29_) {
		layouts_section_board_add_item (self, item, -1);
	}
}

static void
__layouts_section_board___lambda711__services_event_bus_item_moved (ServicesEventBus* _sender,
                                                                    ObjectsItem* item,
                                                                    const gchar* old_project_id,
                                                                    const gchar* old_section_id,
                                                                    const gchar* old_parent_id,
                                                                    gpointer self)
{
	_layouts_section_board___lambda711_ ((LayoutsSectionBoard*) self, item, old_project_id, old_section_id, old_parent_id);
}

static void
_layouts_section_board___lambda712_ (LayoutsSectionBoard* self)
{
	layouts_section_board_update_sort (self);
}

static void
__layouts_section_board___lambda712__objects_project_sorted_by_changed (ObjectsProject* _sender,
                                                                        gpointer self)
{
	_layouts_section_board___lambda712_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda713_ (LayoutsSectionBoard* self)
{
	layouts_section_board_update_sort (self);
}

static void
__layouts_section_board___lambda713__objects_project_sort_order_changed (ObjectsProject* _sender,
                                                                         gpointer self)
{
	_layouts_section_board___lambda713_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda714_ (LayoutsSectionBoard* self,
                                     const gchar* project_id,
                                     const gchar* section_id,
                                     gboolean value)
{
	gboolean _tmp0_ = FALSE;
	ObjectsSection* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	g_return_if_fail (project_id != NULL);
	g_return_if_fail (section_id != NULL);
	_tmp1_ = self->priv->_section;
	_tmp2_ = objects_section_get_project_id (_tmp1_);
	_tmp3_ = _tmp2_;
	if (g_strcmp0 (_tmp3_, project_id) == 0) {
		ObjectsSection* _tmp4_;
		const gchar* _tmp5_;
		const gchar* _tmp6_;
		_tmp4_ = self->priv->_section;
		_tmp5_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp4_);
		_tmp6_ = _tmp5_;
		_tmp0_ = g_strcmp0 (_tmp6_, section_id) == 0;
	} else {
		_tmp0_ = FALSE;
	}
	if (_tmp0_) {
		layouts_section_board_update_sort (self);
	}
}

static void
__layouts_section_board___lambda714__services_event_bus_update_section_sort_func (ServicesEventBus* _sender,
                                                                                  const gchar* project_id,
                                                                                  const gchar* section_id,
                                                                                  gboolean active,
                                                                                  gpointer self)
{
	_layouts_section_board___lambda714_ ((LayoutsSectionBoard*) self, project_id, section_id, active);
}

static void
_layouts_section_board___lambda715_ (LayoutsSectionBoard* self)
{
	layouts_section_board_refresh_count_label (self);
}

static void
__layouts_section_board___lambda715__objects_section_section_count_updated (ObjectsSection* _sender,
                                                                            gpointer self)
{
	_layouts_section_board___lambda715_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda716_ (LayoutsSectionBoard* self,
                                     GtkWidget* _row,
                                     const gchar* old_section_id)
{
	g_return_if_fail (_row != NULL);
	g_return_if_fail (old_section_id != NULL);
	if (LAYOUTS_IS_ITEM_BOARD (_row)) {
		LayoutsItemBoard* row = NULL;
		LayoutsItemBoard* _tmp0_;
		gboolean _tmp1_ = FALSE;
		LayoutsItemBoard* _tmp2_;
		ObjectsItem* _tmp3_;
		ObjectsItem* _tmp4_;
		const gchar* _tmp5_;
		const gchar* _tmp6_;
		ObjectsSection* _tmp7_;
		const gchar* _tmp8_;
		const gchar* _tmp9_;
		gboolean _tmp31_ = FALSE;
		gboolean _tmp32_ = FALSE;
		LayoutsItemBoard* _tmp33_;
		ObjectsItem* _tmp34_;
		ObjectsItem* _tmp35_;
		const gchar* _tmp36_;
		const gchar* _tmp37_;
		ObjectsSection* _tmp38_;
		const gchar* _tmp39_;
		const gchar* _tmp40_;
		LayoutsItemBoard* _tmp64_;
		ObjectsItem* _tmp65_;
		ObjectsItem* _tmp66_;
		const gchar* _tmp67_;
		const gchar* _tmp68_;
		ObjectsSection* _tmp82_;
		ObjectsProject* _tmp83_;
		ObjectsProject* _tmp84_;
		_tmp0_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_CAST (_row, LAYOUTS_TYPE_ITEM_BOARD, LayoutsItemBoard));
		row = _tmp0_;
		_tmp2_ = row;
		_tmp3_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp2_);
		_tmp4_ = _tmp3_;
		_tmp5_ = objects_item_get_project_id (_tmp4_);
		_tmp6_ = _tmp5_;
		_tmp7_ = self->priv->_section;
		_tmp8_ = objects_section_get_project_id (_tmp7_);
		_tmp9_ = _tmp8_;
		if (g_strcmp0 (_tmp6_, _tmp9_) == 0) {
			LayoutsItemBoard* _tmp10_;
			ObjectsItem* _tmp11_;
			ObjectsItem* _tmp12_;
			const gchar* _tmp13_;
			const gchar* _tmp14_;
			ObjectsSection* _tmp15_;
			const gchar* _tmp16_;
			const gchar* _tmp17_;
			_tmp10_ = row;
			_tmp11_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp10_);
			_tmp12_ = _tmp11_;
			_tmp13_ = objects_item_get_section_id (_tmp12_);
			_tmp14_ = _tmp13_;
			_tmp15_ = self->priv->_section;
			_tmp16_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp15_);
			_tmp17_ = _tmp16_;
			_tmp1_ = g_strcmp0 (_tmp14_, _tmp17_) == 0;
		} else {
			_tmp1_ = FALSE;
		}
		if (_tmp1_) {
			GeeHashMap* _tmp18_;
			LayoutsItemBoard* _tmp19_;
			ObjectsItem* _tmp20_;
			ObjectsItem* _tmp21_;
			const gchar* _tmp22_;
			const gchar* _tmp23_;
			_tmp18_ = self->items_map;
			_tmp19_ = row;
			_tmp20_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp19_);
			_tmp21_ = _tmp20_;
			_tmp22_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp21_);
			_tmp23_ = _tmp22_;
			if (!gee_abstract_map_has_key ((GeeAbstractMap*) _tmp18_, _tmp23_)) {
				GeeHashMap* _tmp24_;
				LayoutsItemBoard* _tmp25_;
				ObjectsItem* _tmp26_;
				ObjectsItem* _tmp27_;
				const gchar* _tmp28_;
				const gchar* _tmp29_;
				LayoutsItemBoard* _tmp30_;
				_tmp24_ = self->items_map;
				_tmp25_ = row;
				_tmp26_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp25_);
				_tmp27_ = _tmp26_;
				_tmp28_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp27_);
				_tmp29_ = _tmp28_;
				_tmp30_ = row;
				gee_abstract_map_set ((GeeAbstractMap*) _tmp24_, _tmp29_, _tmp30_);
			}
		}
		_tmp33_ = row;
		_tmp34_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp33_);
		_tmp35_ = _tmp34_;
		_tmp36_ = objects_item_get_project_id (_tmp35_);
		_tmp37_ = _tmp36_;
		_tmp38_ = self->priv->_section;
		_tmp39_ = objects_section_get_project_id (_tmp38_);
		_tmp40_ = _tmp39_;
		if (g_strcmp0 (_tmp37_, _tmp40_) == 0) {
			LayoutsItemBoard* _tmp41_;
			ObjectsItem* _tmp42_;
			ObjectsItem* _tmp43_;
			const gchar* _tmp44_;
			const gchar* _tmp45_;
			ObjectsSection* _tmp46_;
			const gchar* _tmp47_;
			const gchar* _tmp48_;
			_tmp41_ = row;
			_tmp42_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp41_);
			_tmp43_ = _tmp42_;
			_tmp44_ = objects_item_get_section_id (_tmp43_);
			_tmp45_ = _tmp44_;
			_tmp46_ = self->priv->_section;
			_tmp47_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp46_);
			_tmp48_ = _tmp47_;
			_tmp32_ = g_strcmp0 (_tmp45_, _tmp48_) != 0;
		} else {
			_tmp32_ = FALSE;
		}
		if (_tmp32_) {
			ObjectsSection* _tmp49_;
			const gchar* _tmp50_;
			const gchar* _tmp51_;
			_tmp49_ = self->priv->_section;
			_tmp50_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp49_);
			_tmp51_ = _tmp50_;
			_tmp31_ = g_strcmp0 (old_section_id, _tmp51_) == 0;
		} else {
			_tmp31_ = FALSE;
		}
		if (_tmp31_) {
			GeeHashMap* _tmp52_;
			LayoutsItemBoard* _tmp53_;
			ObjectsItem* _tmp54_;
			ObjectsItem* _tmp55_;
			const gchar* _tmp56_;
			const gchar* _tmp57_;
			_tmp52_ = self->items_map;
			_tmp53_ = row;
			_tmp54_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp53_);
			_tmp55_ = _tmp54_;
			_tmp56_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp55_);
			_tmp57_ = _tmp56_;
			if (gee_abstract_map_has_key ((GeeAbstractMap*) _tmp52_, _tmp57_)) {
				GeeHashMap* _tmp58_;
				LayoutsItemBoard* _tmp59_;
				ObjectsItem* _tmp60_;
				ObjectsItem* _tmp61_;
				const gchar* _tmp62_;
				const gchar* _tmp63_;
				_tmp58_ = self->items_map;
				_tmp59_ = row;
				_tmp60_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp59_);
				_tmp61_ = _tmp60_;
				_tmp62_ = objects_base_object_get_id ((ObjectsBaseObject*) _tmp61_);
				_tmp63_ = _tmp62_;
				gee_abstract_map_unset ((GeeAbstractMap*) _tmp58_, _tmp63_, NULL);
			}
		}
		_tmp64_ = row;
		_tmp65_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp64_);
		_tmp66_ = _tmp65_;
		_tmp67_ = objects_item_get_section_id (_tmp66_);
		_tmp68_ = _tmp67_;
		if (g_strcmp0 (old_section_id, _tmp68_) != 0) {
			ObjectsSection* source_section = NULL;
			ServicesStore* _tmp69_;
			ObjectsSection* _tmp70_;
			ObjectsSection* _tmp71_;
			ObjectsSection* target_section = NULL;
			ServicesStore* _tmp73_;
			LayoutsItemBoard* _tmp74_;
			ObjectsItem* _tmp75_;
			ObjectsItem* _tmp76_;
			const gchar* _tmp77_;
			const gchar* _tmp78_;
			ObjectsSection* _tmp79_;
			ObjectsSection* _tmp80_;
			_tmp69_ = services_store_instance ();
			_tmp70_ = services_store_get_section (_tmp69_, old_section_id);
			source_section = _tmp70_;
			_tmp71_ = source_section;
			if (_tmp71_ != NULL) {
				ObjectsSection* _tmp72_;
				_tmp72_ = source_section;
				objects_section_update_count (_tmp72_);
			}
			_tmp73_ = services_store_instance ();
			_tmp74_ = row;
			_tmp75_ = layouts_item_base_get_item ((LayoutsItemBase*) _tmp74_);
			_tmp76_ = _tmp75_;
			_tmp77_ = objects_item_get_section_id (_tmp76_);
			_tmp78_ = _tmp77_;
			_tmp79_ = services_store_get_section (_tmp73_, _tmp78_);
			target_section = _tmp79_;
			_tmp80_ = target_section;
			if (_tmp80_ != NULL) {
				ObjectsSection* _tmp81_;
				_tmp81_ = target_section;
				objects_section_update_count (_tmp81_);
			}
			_g_object_unref0 (target_section);
			_g_object_unref0 (source_section);
		}
		_tmp82_ = self->priv->_section;
		_tmp83_ = objects_section_get_project (_tmp82_);
		_tmp84_ = _tmp83_;
		objects_base_object_count_update ((ObjectsBaseObject*) _tmp84_);
		_g_object_unref0 (row);
	}
}

static void
__layouts_section_board___lambda716__services_event_bus_update_inserted_item_map (ServicesEventBus* _sender,
                                                                                  GtkWidget* row,
                                                                                  const gchar* old_section_id,
                                                                                  const gchar* old_parent_id,
                                                                                  gpointer self)
{
	_layouts_section_board___lambda716_ ((LayoutsSectionBoard*) self, row, old_section_id);
}

static void
_layouts_section_board___lambda717_ (LayoutsSectionBoard* self)
{
	layouts_section_board_update_sort (self);
}

static void
__layouts_section_board___lambda717__objects_base_object_filter_added (ObjectsBaseObject* _sender,
                                                                       ObjectsFiltersFilterItem* filters,
                                                                       gpointer self)
{
	_layouts_section_board___lambda717_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda718_ (LayoutsSectionBoard* self)
{
	layouts_section_board_update_sort (self);
}

static void
__layouts_section_board___lambda718__objects_base_object_filter_removed (ObjectsBaseObject* _sender,
                                                                         ObjectsFiltersFilterItem* filters,
                                                                         gpointer self)
{
	_layouts_section_board___lambda718_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda719_ (LayoutsSectionBoard* self)
{
	layouts_section_board_update_sort (self);
}

static void
__layouts_section_board___lambda719__objects_base_object_filter_updated (ObjectsBaseObject* _sender,
                                                                         ObjectsFiltersFilterItem* filters,
                                                                         gpointer self)
{
	_layouts_section_board___lambda719_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda720_ (LayoutsSectionBoard* self)
{
	ObjectsSection* _tmp0_;
	gboolean _tmp1_;
	gboolean _tmp2_;
	_tmp0_ = self->priv->_section;
	_tmp1_ = objects_base_object_get_sensitive ((ObjectsBaseObject*) _tmp0_);
	_tmp2_ = _tmp1_;
	gtk_widget_set_sensitive ((GtkWidget*) self, _tmp2_);
}

static void
__layouts_section_board___lambda720__objects_base_object_sensitive_change (ObjectsBaseObject* _sender,
                                                                           gpointer self)
{
	_layouts_section_board___lambda720_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda721_ (LayoutsSectionBoard* self)
{
	ObjectsSection* _tmp0_;
	gboolean _tmp1_;
	gboolean _tmp2_;
	_tmp0_ = self->priv->_section;
	_tmp1_ = objects_base_object_get_loading ((ObjectsBaseObject*) _tmp0_);
	_tmp2_ = _tmp1_;
	layouts_section_board_set_is_loading (self, _tmp2_);
}

static void
__layouts_section_board___lambda721__objects_base_object_loading_change (ObjectsBaseObject* _sender,
                                                                         gpointer self)
{
	_layouts_section_board___lambda721_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda722_ (LayoutsSectionBoard* self,
                                     gint n_press,
                                     gdouble x,
                                     gdouble y)
{
	if (n_press == 2) {
		DialogsSection* dialog = NULL;
		ObjectsSection* _tmp0_;
		DialogsSection* _tmp1_;
		DialogsSection* _tmp2_;
		Planify* _tmp3_;
		MainWindow* _tmp4_;
		_tmp0_ = self->priv->_section;
		_tmp1_ = dialogs_section_new (_tmp0_);
		g_object_ref_sink (_tmp1_);
		dialog = _tmp1_;
		_tmp2_ = dialog;
		_tmp3_ = planify__instance;
		_tmp4_ = _tmp3_->main_window;
		adw_dialog_present ((AdwDialog*) _tmp2_, (GtkWidget*) _tmp4_);
		_g_object_unref0 (dialog);
	}
}

static void
__layouts_section_board___lambda722__gtk_gesture_click_released (GtkGestureClick* _sender,
                                                                 gint n_press,
                                                                 gdouble x,
                                                                 gdouble y,
                                                                 gpointer self)
{
	_layouts_section_board___lambda722_ ((LayoutsSectionBoard*) self, n_press, x, y);
}

static void
_layouts_section_board_show_completed_changed_objects_project_show_completed_changed (ObjectsProject* _sender,
                                                                                      gpointer self)
{
	layouts_section_board_show_completed_changed ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda723_ (LayoutsSectionBoard* self)
{
	layouts_section_board_load_next_completed_page (self);
}

static void
__layouts_section_board___lambda723__gtk_button_clicked (GtkButton* _sender,
                                                         gpointer self)
{
	_layouts_section_board___lambda723_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda724_ (LayoutsSectionBoard* self)
{
	layouts_section_board_prepare_new_item (self, "", NEW_TASK_POSITION_END);
}

static void
__layouts_section_board___lambda724__gtk_button_clicked (GtkButton* _sender,
                                                         gpointer self)
{
	_layouts_section_board___lambda724_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda725_ (LayoutsSectionBoard* self)
{
	layouts_section_board_update_sort (self);
}

static void
__layouts_section_board___lambda725__objects_source_sync_finished (ObjectsSource* _sender,
                                                                   gpointer self)
{
	_layouts_section_board___lambda725_ ((LayoutsSectionBoard*) self);
}

static void
_layouts_section_board___lambda726_ (LayoutsSectionBoard* self,
                                     const gchar* project_id,
                                     gboolean active)
{
	ObjectsSection* _tmp0_;
	const gchar* _tmp1_;
	const gchar* _tmp2_;
	g_return_if_fail (project_id != NULL);
	_tmp0_ = self->priv->_section;
	_tmp1_ = objects_section_get_project_id (_tmp0_);
	_tmp2_ = _tmp1_;
	if (g_strcmp0 (_tmp2_, project_id) == 0) {
		if (active) {
			GtkListBox* _tmp3_;
			_tmp3_ = self->priv->listbox;
			gtk_list_box_set_sort_func (_tmp3_, NULL, NULL, NULL);
		}
	}
}

static void
__layouts_section_board___lambda726__services_event_bus_drag_n_drop_active (ServicesEventBus* _sender,
                                                                            const gchar* project_id,
                                                                            gboolean active,
                                                                            gpointer self)
{
	_layouts_section_board___lambda726_ ((LayoutsSectionBoard*) self, project_id, active);
}

static GObject *
layouts_section_board_constructor (GType type,
                                   guint n_construct_properties,
                                   GObjectConstructParam * construct_properties)
{
	GObject * obj;
	GObjectClass * parent_class;
	LayoutsSectionBoard * self;
	gchar* _tmp0_;
	gchar** _tmp1_;
	GtkGrid* _tmp2_ = NULL;
	ObjectsSection* _tmp3_;
	const gchar* _tmp4_;
	const gchar* _tmp5_;
	gchar* _tmp6_;
	gchar** _tmp7_;
	GtkLabel* _tmp8_ = NULL;
	gchar* _tmp9_;
	gchar* _tmp10_;
	gchar** _tmp11_;
	GtkLabel* _tmp12_ = NULL;
	GtkMenuButton* menu_button = NULL;
	gchar* _tmp13_;
	GtkPopover* _tmp14_;
	gchar* _tmp15_;
	gchar** _tmp16_;
	GtkMenuButton* _tmp17_ = NULL;
	GtkBox* header_box = NULL;
	GtkBox* _tmp18_ = NULL;
	GtkBox* _tmp19_;
	GtkGrid* _tmp20_;
	GtkBox* _tmp21_;
	GtkLabel* _tmp22_;
	GtkBox* _tmp23_;
	GtkLabel* _tmp24_;
	GtkBox* _tmp25_;
	GtkMenuButton* _tmp26_;
	ObjectsSection* _tmp27_;
	const gchar* _tmp28_;
	const gchar* _tmp29_;
	gchar* _tmp30_;
	gchar* _tmp31_;
	gchar* _tmp32_;
	gchar** _tmp33_;
	GtkLabel* _tmp34_ = NULL;
	GtkLabel* _tmp35_;
	GtkWidget* _tmp36_;
	GtkRevealer* _tmp37_ = NULL;
	gchar* _tmp38_;
	gchar* _tmp39_;
	gchar** _tmp40_;
	GtkListBox* _tmp41_ = NULL;
	GtkBox* add_button_box = NULL;
	GtkBox* _tmp42_ = NULL;
	GtkBox* _tmp43_;
	gchar* _tmp44_;
	gchar** _tmp45_;
	GtkImage* _tmp46_ = NULL;
	GtkImage* _tmp47_;
	GtkBox* _tmp48_;
	GtkLabel* _tmp49_;
	GtkLabel* _tmp50_;
	GtkButton* add_button = NULL;
	GtkBox* _tmp51_;
	GtkWidget* _tmp52_;
	GtkButton* _tmp53_ = NULL;
	GtkButton* _tmp54_;
	GtkButton* _tmp55_;
	gchar* _tmp56_;
	gchar* _tmp57_;
	gchar** _tmp58_;
	GtkListBox* _tmp59_ = NULL;
	GtkButton* _tmp60_ = NULL;
	GtkButton* _tmp61_;
	GtkButton* _tmp62_;
	GtkWidget* _tmp63_;
	GtkRevealer* _tmp64_ = NULL;
	GtkBox* checked_listbox_container = NULL;
	GtkBox* _tmp65_;
	GtkBox* _tmp66_;
	GtkListBox* _tmp67_;
	GtkBox* _tmp68_;
	GtkRevealer* _tmp69_;
	GtkBox* _tmp70_;
	GtkWidget* _tmp71_;
	GtkRevealer* _tmp72_ = NULL;
	GtkBox* _tmp73_ = NULL;
	GtkBox* _tmp74_;
	GtkListBox* _tmp75_;
	GtkBox* _tmp76_;
	GtkButton* _tmp77_;
	GtkBox* _tmp78_;
	GtkRevealer* _tmp79_;
	WidgetsScrolledWindow* items_scrolled = NULL;
	GtkBox* _tmp80_;
	WidgetsScrolledWindow* _tmp81_;
	gchar* _tmp82_;
	gchar* _tmp83_;
	gchar** _tmp84_;
	GtkBox* _tmp85_ = NULL;
	GtkBox* _tmp86_;
	GtkBox* _tmp87_;
	GtkBox* _tmp88_;
	GtkRevealer* _tmp89_;
	GtkBox* _tmp90_;
	WidgetsScrolledWindow* _tmp91_;
	GtkBox* _tmp92_;
	GtkListBox* _tmp93_;
	GeeHashMap* _tmp94_;
	GtkListBox* _tmp95_;
	gulong _tmp96_;
	GtkListBox* _tmp97_;
	GeeHashMap* _tmp98_;
	ObjectsSection* _tmp99_;
	gulong _tmp100_;
	ObjectsSection* _tmp101_;
	gboolean _tmp102_;
	gboolean _tmp103_;
	GeeHashMap* _tmp124_;
	ServicesEventBus* _tmp125_;
	ServicesEventBus* _tmp126_;
	gulong _tmp127_;
	ServicesEventBus* _tmp128_;
	ServicesEventBus* _tmp129_;
	GeeHashMap* _tmp130_;
	ServicesStore* _tmp131_;
	gulong _tmp132_;
	ServicesStore* _tmp133_;
	GeeHashMap* _tmp134_;
	ServicesStore* _tmp135_;
	gulong _tmp136_;
	ServicesStore* _tmp137_;
	GeeHashMap* _tmp138_;
	ServicesStore* _tmp139_;
	gulong _tmp140_;
	ServicesStore* _tmp141_;
	GeeHashMap* _tmp142_;
	ServicesEventBus* _tmp143_;
	ServicesEventBus* _tmp144_;
	gulong _tmp145_;
	ServicesEventBus* _tmp146_;
	ServicesEventBus* _tmp147_;
	GeeHashMap* _tmp148_;
	ObjectsSection* _tmp149_;
	ObjectsProject* _tmp150_;
	ObjectsProject* _tmp151_;
	gulong _tmp152_;
	ObjectsSection* _tmp153_;
	ObjectsProject* _tmp154_;
	ObjectsProject* _tmp155_;
	GeeHashMap* _tmp156_;
	ObjectsSection* _tmp157_;
	ObjectsProject* _tmp158_;
	ObjectsProject* _tmp159_;
	gulong _tmp160_;
	ObjectsSection* _tmp161_;
	ObjectsProject* _tmp162_;
	ObjectsProject* _tmp163_;
	GeeHashMap* _tmp164_;
	ServicesEventBus* _tmp165_;
	ServicesEventBus* _tmp166_;
	gulong _tmp167_;
	ServicesEventBus* _tmp168_;
	ServicesEventBus* _tmp169_;
	GeeHashMap* _tmp170_;
	ObjectsSection* _tmp171_;
	gulong _tmp172_;
	ObjectsSection* _tmp173_;
	GeeHashMap* _tmp174_;
	ServicesEventBus* _tmp175_;
	ServicesEventBus* _tmp176_;
	gulong _tmp177_;
	ServicesEventBus* _tmp178_;
	ServicesEventBus* _tmp179_;
	GeeHashMap* _tmp180_;
	ObjectsSection* _tmp181_;
	ObjectsProject* _tmp182_;
	ObjectsProject* _tmp183_;
	gulong _tmp184_;
	ObjectsSection* _tmp185_;
	ObjectsProject* _tmp186_;
	ObjectsProject* _tmp187_;
	GeeHashMap* _tmp188_;
	ObjectsSection* _tmp189_;
	ObjectsProject* _tmp190_;
	ObjectsProject* _tmp191_;
	gulong _tmp192_;
	ObjectsSection* _tmp193_;
	ObjectsProject* _tmp194_;
	ObjectsProject* _tmp195_;
	GeeHashMap* _tmp196_;
	ObjectsSection* _tmp197_;
	ObjectsProject* _tmp198_;
	ObjectsProject* _tmp199_;
	gulong _tmp200_;
	ObjectsSection* _tmp201_;
	ObjectsProject* _tmp202_;
	ObjectsProject* _tmp203_;
	GeeHashMap* _tmp204_;
	ObjectsSection* _tmp205_;
	gulong _tmp206_;
	ObjectsSection* _tmp207_;
	GeeHashMap* _tmp208_;
	ObjectsSection* _tmp209_;
	gulong _tmp210_;
	ObjectsSection* _tmp211_;
	GtkGestureClick* edit_gesture = NULL;
	GtkGestureClick* _tmp212_;
	GtkLabel* _tmp213_;
	GtkGestureClick* _tmp214_;
	GtkEventController* _tmp215_;
	GeeHashMap* _tmp216_;
	GtkGestureClick* _tmp217_;
	gulong _tmp218_;
	GtkGestureClick* _tmp219_;
	GeeHashMap* _tmp220_;
	ObjectsSection* _tmp221_;
	ObjectsProject* _tmp222_;
	ObjectsProject* _tmp223_;
	gulong _tmp224_;
	ObjectsSection* _tmp225_;
	ObjectsProject* _tmp226_;
	ObjectsProject* _tmp227_;
	GeeHashMap* _tmp228_;
	GtkButton* _tmp229_;
	gulong _tmp230_;
	GtkButton* _tmp231_;
	GeeHashMap* _tmp232_;
	GtkButton* _tmp233_;
	gulong _tmp234_;
	GtkButton* _tmp235_;
	GeeHashMap* _tmp236_;
	ObjectsSection* _tmp237_;
	ObjectsProject* _tmp238_;
	ObjectsProject* _tmp239_;
	ObjectsSource* _tmp240_;
	ObjectsSource* _tmp241_;
	gulong _tmp242_;
	ObjectsSection* _tmp243_;
	ObjectsProject* _tmp244_;
	ObjectsProject* _tmp245_;
	ObjectsSource* _tmp246_;
	ObjectsSource* _tmp247_;
	GeeHashMap* _tmp248_;
	ServicesEventBus* _tmp249_;
	ServicesEventBus* _tmp250_;
	gulong _tmp251_;
	ServicesEventBus* _tmp252_;
	ServicesEventBus* _tmp253_;
	parent_class = G_OBJECT_CLASS (layouts_section_board_parent_class);
	obj = parent_class->constructor (type, n_construct_properties, construct_properties);
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, LAYOUTS_TYPE_SECTION_BOARD, LayoutsSectionBoard);
	gtk_widget_add_css_class ((GtkWidget*) self, "no-selectable");
	gtk_widget_add_css_class ((GtkWidget*) self, "no-padding");
	_tmp0_ = g_strdup ("event-bar");
	_tmp1_ = g_new0 (gchar*, 1 + 1);
	_tmp1_[0] = _tmp0_;
	_tmp2_ = (GtkGrid*) gtk_grid_new ();
	gtk_widget_set_valign ((GtkWidget*) _tmp2_, GTK_ALIGN_CENTER);
	g_object_set ((GtkWidget*) _tmp2_, "height-request", 16, NULL);
	g_object_set ((GtkWidget*) _tmp2_, "width-request", 3, NULL);
	gtk_widget_set_css_classes ((GtkWidget*) _tmp2_, _tmp1_);
	_tmp1_ = (_vala_array_free (_tmp1_, 1, (GDestroyNotify) g_free), NULL);
	g_object_ref_sink (_tmp2_);
	_g_object_unref0 (self->priv->widget_color);
	self->priv->widget_color = _tmp2_;
	_tmp3_ = self->priv->_section;
	_tmp4_ = objects_base_object_get_name ((ObjectsBaseObject*) _tmp3_);
	_tmp5_ = _tmp4_;
	_tmp6_ = g_strdup ("font-bold");
	_tmp7_ = g_new0 (gchar*, 1 + 1);
	_tmp7_[0] = _tmp6_;
	_tmp8_ = (GtkLabel*) gtk_label_new (_tmp5_);
	gtk_widget_set_halign ((GtkWidget*) _tmp8_, GTK_ALIGN_START);
	gtk_widget_set_css_classes ((GtkWidget*) _tmp8_, _tmp7_);
	_tmp7_ = (_vala_array_free (_tmp7_, 1, (GDestroyNotify) g_free), NULL);
	gtk_widget_set_margin_start ((GtkWidget*) _tmp8_, 6);
	g_object_ref_sink (_tmp8_);
	_g_object_unref0 (self->priv->name_label);
	self->priv->name_label = _tmp8_;
	_tmp9_ = g_strdup ("dimmed");
	_tmp10_ = g_strdup ("caption");
	_tmp11_ = g_new0 (gchar*, 2 + 1);
	_tmp11_[0] = _tmp9_;
	_tmp11_[1] = _tmp10_;
	_tmp12_ = (GtkLabel*) gtk_label_new (NULL);
	gtk_widget_set_margin_start ((GtkWidget*) _tmp12_, 9);
	gtk_widget_set_halign ((GtkWidget*) _tmp12_, GTK_ALIGN_CENTER);
	gtk_widget_set_css_classes ((GtkWidget*) _tmp12_, _tmp11_);
	_tmp11_ = (_vala_array_free (_tmp11_, 2, (GDestroyNotify) g_free), NULL);
	g_object_ref_sink (_tmp12_);
	_g_object_unref0 (self->priv->count_label);
	self->priv->count_label = _tmp12_;
	_tmp13_ = g_strdup ("view-more-symbolic");
	_tmp14_ = layouts_section_board_build_context_menu (self);
	_tmp15_ = g_strdup ("flat");
	_tmp16_ = g_new0 (gchar*, 1 + 1);
	_tmp16_[0] = _tmp15_;
	_tmp17_ = (GtkMenuButton*) gtk_menu_button_new ();
	gtk_widget_set_hexpand ((GtkWidget*) _tmp17_, TRUE);
	gtk_widget_set_halign ((GtkWidget*) _tmp17_, GTK_ALIGN_END);
	gtk_menu_button_set_icon_name (_tmp17_, _tmp13_);
	_g_free0 (_tmp13_);
	gtk_menu_button_set_popover (_tmp17_, _tmp14_);
	_g_object_unref0 (_tmp14_);
	gtk_widget_set_css_classes ((GtkWidget*) _tmp17_, _tmp16_);
	_tmp16_ = (_vala_array_free (_tmp16_, 1, (GDestroyNotify) g_free), NULL);
	g_object_ref_sink (_tmp17_);
	menu_button = _tmp17_;
	_tmp18_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
	gtk_widget_set_margin_start ((GtkWidget*) _tmp18_, 6);
	g_object_ref_sink (_tmp18_);
	header_box = _tmp18_;
	_tmp19_ = header_box;
	_tmp20_ = self->priv->widget_color;
	gtk_box_append (_tmp19_, (GtkWidget*) _tmp20_);
	_tmp21_ = header_box;
	_tmp22_ = self->priv->name_label;
	gtk_box_append (_tmp21_, (GtkWidget*) _tmp22_);
	_tmp23_ = header_box;
	_tmp24_ = self->priv->count_label;
	gtk_box_append (_tmp23_, (GtkWidget*) _tmp24_);
	_tmp25_ = header_box;
	_tmp26_ = menu_button;
	gtk_box_append (_tmp25_, (GtkWidget*) _tmp26_);
	_tmp27_ = self->priv->_section;
	_tmp28_ = objects_section_get_description (_tmp27_);
	_tmp29_ = _tmp28_;
	_tmp30_ = string_strip (_tmp29_);
	_tmp31_ = _tmp30_;
	_tmp32_ = g_strdup ("dimmed");
	_tmp33_ = g_new0 (gchar*, 1 + 1);
	_tmp33_[0] = _tmp32_;
	_tmp34_ = (GtkLabel*) gtk_label_new (_tmp31_);
	gtk_label_set_wrap (_tmp34_, TRUE);
	gtk_label_set_selectable (_tmp34_, TRUE);
	gtk_widget_set_halign ((GtkWidget*) _tmp34_, GTK_ALIGN_START);
	gtk_widget_set_css_classes ((GtkWidget*) _tmp34_, _tmp33_);
	_tmp33_ = (_vala_array_free (_tmp33_, 1, (GDestroyNotify) g_free), NULL);
	gtk_widget_set_margin_start ((GtkWidget*) _tmp34_, 6);
	gtk_widget_set_margin_top ((GtkWidget*) _tmp34_, 6);
	gtk_widget_set_margin_bottom ((GtkWidget*) _tmp34_, 6);
	g_object_ref_sink (_tmp34_);
	_g_object_unref0 (self->priv->description_label);
	self->priv->description_label = _tmp34_;
	_g_free0 (_tmp31_);
	_tmp35_ = self->priv->description_label;
	_tmp36_ = _g_object_ref0 ((GtkWidget*) _tmp35_);
	_tmp37_ = (GtkRevealer*) gtk_revealer_new ();
	gtk_revealer_set_transition_type (_tmp37_, GTK_REVEALER_TRANSITION_TYPE_SLIDE_DOWN);
	gtk_revealer_set_child (_tmp37_, _tmp36_);
	_g_object_unref0 (_tmp36_);
	g_object_ref_sink (_tmp37_);
	_g_object_unref0 (self->priv->description_revealer);
	self->priv->description_revealer = _tmp37_;
	_tmp38_ = g_strdup ("listbox-background");
	_tmp39_ = g_strdup ("drop-target-list");
	_tmp40_ = g_new0 (gchar*, 2 + 1);
	_tmp40_[0] = _tmp38_;
	_tmp40_[1] = _tmp39_;
	_tmp41_ = (GtkListBox*) gtk_list_box_new ();
	gtk_list_box_set_selection_mode (_tmp41_, GTK_SELECTION_SINGLE);
	gtk_widget_set_css_classes ((GtkWidget*) _tmp41_, _tmp40_);
	_tmp40_ = (_vala_array_free (_tmp40_, 2, (GDestroyNotify) g_free), NULL);
	g_object_ref_sink (_tmp41_);
	_g_object_unref0 (self->priv->listbox);
	self->priv->listbox = _tmp41_;
	_tmp42_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
	gtk_widget_set_valign ((GtkWidget*) _tmp42_, GTK_ALIGN_CENTER);
	g_object_ref_sink (_tmp42_);
	add_button_box = _tmp42_;
	_tmp43_ = add_button_box;
	_tmp44_ = g_strdup ("color-primary");
	_tmp45_ = g_new0 (gchar*, 1 + 1);
	_tmp45_[0] = _tmp44_;
	_tmp46_ = (GtkImage*) gtk_image_new_from_icon_name ("plus-large-symbolic");
	gtk_widget_set_css_classes ((GtkWidget*) _tmp46_, _tmp45_);
	_tmp45_ = (_vala_array_free (_tmp45_, 1, (GDestroyNotify) g_free), NULL);
	g_object_ref_sink (_tmp46_);
	_tmp47_ = _tmp46_;
	gtk_box_append (_tmp43_, (GtkWidget*) _tmp47_);
	_g_object_unref0 (_tmp47_);
	_tmp48_ = add_button_box;
	_tmp49_ = (GtkLabel*) gtk_label_new (_ ("Add tasks"));
	g_object_ref_sink (_tmp49_);
	_tmp50_ = _tmp49_;
	gtk_box_append (_tmp48_, (GtkWidget*) _tmp50_);
	_g_object_unref0 (_tmp50_);
	_tmp51_ = add_button_box;
	_tmp52_ = _g_object_ref0 ((GtkWidget*) _tmp51_);
	_tmp53_ = (GtkButton*) gtk_button_new ();
	gtk_button_set_child (_tmp53_, _tmp52_);
	_g_object_unref0 (_tmp52_);
	gtk_widget_set_margin_top ((GtkWidget*) _tmp53_, 6);
	gtk_widget_set_margin_bottom ((GtkWidget*) _tmp53_, 6);
	gtk_widget_set_halign ((GtkWidget*) _tmp53_, GTK_ALIGN_START);
	g_object_ref_sink (_tmp53_);
	add_button = _tmp53_;
	_tmp54_ = add_button;
	gtk_widget_add_css_class ((GtkWidget*) _tmp54_, "flat");
	_tmp55_ = add_button;
	gtk_widget_add_css_class ((GtkWidget*) _tmp55_, "add-button");
	_tmp56_ = g_strdup ("listbox-background");
	_tmp57_ = g_strdup ("listbox-separator-3");
	_tmp58_ = g_new0 (gchar*, 2 + 1);
	_tmp58_[0] = _tmp56_;
	_tmp58_[1] = _tmp57_;
	_tmp59_ = (GtkListBox*) gtk_list_box_new ();
	gtk_widget_set_valign ((GtkWidget*) _tmp59_, GTK_ALIGN_START);
	gtk_list_box_set_selection_mode (_tmp59_, GTK_SELECTION_NONE);
	gtk_widget_set_hexpand ((GtkWidget*) _tmp59_, TRUE);
	gtk_widget_set_css_classes ((GtkWidget*) _tmp59_, _tmp58_);
	_tmp58_ = (_vala_array_free (_tmp58_, 2, (GDestroyNotify) g_free), NULL);
	g_object_ref_sink (_tmp59_);
	_g_object_unref0 (self->priv->checked_listbox);
	self->priv->checked_listbox = _tmp59_;
	_tmp60_ = (GtkButton*) gtk_button_new_with_label (_ ("Load more"));
	gtk_widget_set_halign ((GtkWidget*) _tmp60_, GTK_ALIGN_START);
	g_object_ref_sink (_tmp60_);
	_g_object_unref0 (self->priv->load_more_button);
	self->priv->load_more_button = _tmp60_;
	_tmp61_ = self->priv->load_more_button;
	gtk_widget_add_css_class ((GtkWidget*) _tmp61_, "flat");
	_tmp62_ = self->priv->load_more_button;
	_tmp63_ = _g_object_ref0 ((GtkWidget*) _tmp62_);
	_tmp64_ = (GtkRevealer*) gtk_revealer_new ();
	gtk_revealer_set_transition_type (_tmp64_, GTK_REVEALER_TRANSITION_TYPE_SLIDE_DOWN);
	gtk_revealer_set_reveal_child (_tmp64_, FALSE);
	gtk_revealer_set_child (_tmp64_, _tmp63_);
	_g_object_unref0 (_tmp63_);
	g_object_ref_sink (_tmp64_);
	_g_object_unref0 (self->priv->load_more_button_revealer);
	self->priv->load_more_button_revealer = _tmp64_;
	_tmp65_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 6);
	g_object_ref_sink (_tmp65_);
	checked_listbox_container = _tmp65_;
	_tmp66_ = checked_listbox_container;
	_tmp67_ = self->priv->checked_listbox;
	gtk_box_append (_tmp66_, (GtkWidget*) _tmp67_);
	_tmp68_ = checked_listbox_container;
	_tmp69_ = self->priv->load_more_button_revealer;
	gtk_box_append (_tmp68_, (GtkWidget*) _tmp69_);
	_tmp70_ = checked_listbox_container;
	_tmp71_ = _g_object_ref0 ((GtkWidget*) _tmp70_);
	_tmp72_ = (GtkRevealer*) gtk_revealer_new ();
	gtk_revealer_set_transition_type (_tmp72_, GTK_REVEALER_TRANSITION_TYPE_SLIDE_DOWN);
	gtk_revealer_set_child (_tmp72_, _tmp71_);
	_g_object_unref0 (_tmp71_);
	g_object_ref_sink (_tmp72_);
	_g_object_unref0 (self->priv->checked_revealer);
	self->priv->checked_revealer = _tmp72_;
	_tmp73_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
	gtk_widget_set_vexpand ((GtkWidget*) _tmp73_, TRUE);
	gtk_widget_set_margin_end ((GtkWidget*) _tmp73_, 6);
	gtk_widget_set_margin_bottom ((GtkWidget*) _tmp73_, 12);
	g_object_ref_sink (_tmp73_);
	_g_object_unref0 (self->priv->listbox_target);
	self->priv->listbox_target = _tmp73_;
	_tmp74_ = self->priv->listbox_target;
	_tmp75_ = self->priv->listbox;
	gtk_box_append (_tmp74_, (GtkWidget*) _tmp75_);
	_tmp76_ = self->priv->listbox_target;
	_tmp77_ = add_button;
	gtk_box_append (_tmp76_, (GtkWidget*) _tmp77_);
	_tmp78_ = self->priv->listbox_target;
	_tmp79_ = self->priv->checked_revealer;
	gtk_box_append (_tmp78_, (GtkWidget*) _tmp79_);
	_tmp80_ = self->priv->listbox_target;
	_tmp81_ = widgets_scrolled_window_new ((GtkWidget*) _tmp80_, GTK_ORIENTATION_VERTICAL);
	g_object_ref_sink (_tmp81_);
	items_scrolled = _tmp81_;
	_tmp82_ = g_strdup ("transition");
	_tmp83_ = g_strdup ("drop-target-list");
	_tmp84_ = g_new0 (gchar*, 2 + 1);
	_tmp84_[0] = _tmp82_;
	_tmp84_[1] = _tmp83_;
	_tmp85_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
	gtk_widget_set_vexpand ((GtkWidget*) _tmp85_, TRUE);
	gtk_widget_set_css_classes ((GtkWidget*) _tmp85_, _tmp84_);
	_tmp84_ = (_vala_array_free (_tmp84_, 2, (GDestroyNotify) g_free), NULL);
	g_object_ref_sink (_tmp85_);
	_g_object_unref0 (self->priv->content_box);
	self->priv->content_box = _tmp85_;
	_tmp86_ = self->priv->content_box;
	_tmp87_ = header_box;
	gtk_box_append (_tmp86_, (GtkWidget*) _tmp87_);
	_tmp88_ = self->priv->content_box;
	_tmp89_ = self->priv->description_revealer;
	gtk_box_append (_tmp88_, (GtkWidget*) _tmp89_);
	_tmp90_ = self->priv->content_box;
	_tmp91_ = items_scrolled;
	gtk_box_append (_tmp90_, (GtkWidget*) _tmp91_);
	_tmp92_ = self->priv->content_box;
	gtk_flow_box_child_set_child ((GtkFlowBoxChild*) self, (GtkWidget*) _tmp92_);
	layouts_section_board_update_request (self);
	layouts_section_board_add_items (self);
	layouts_section_board_show_completed_changed (self);
	layouts_section_board_build_drag_and_drop (self);
	layouts_section_board_refresh_count_label (self);
	_tmp93_ = self->priv->listbox;
	gtk_list_box_set_filter_func (_tmp93_, __layouts_section_board___lambda701__gtk_list_box_filter_func, g_object_ref (self), g_object_unref);
	_tmp94_ = self->priv->signals_map;
	_tmp95_ = self->priv->listbox;
	_tmp96_ = g_signal_connect_object (_tmp95_, "row-selected", (GCallback) __layouts_section_board___lambda702__gtk_list_box_row_selected, self, 0);
	_tmp97_ = self->priv->listbox;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp94_, (gpointer) ((guintptr) _tmp96_), (GObject*) _tmp97_);
	_tmp98_ = self->priv->signals_map;
	_tmp99_ = self->priv->_section;
	_tmp100_ = g_signal_connect_object ((ObjectsBaseObject*) _tmp99_, "updated", (GCallback) __layouts_section_board___lambda703__objects_base_object_updated, self, 0);
	_tmp101_ = self->priv->_section;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp98_, (gpointer) ((guintptr) _tmp100_), (GObject*) _tmp101_);
	_tmp102_ = layouts_section_board_get_is_inbox_section (self);
	_tmp103_ = _tmp102_;
	if (_tmp103_) {
		GeeHashMap* _tmp104_;
		ObjectsSection* _tmp105_;
		ObjectsProject* _tmp106_;
		ObjectsProject* _tmp107_;
		gulong _tmp108_;
		ObjectsSection* _tmp109_;
		ObjectsProject* _tmp110_;
		ObjectsProject* _tmp111_;
		GeeHashMap* _tmp112_;
		ObjectsSection* _tmp113_;
		ObjectsProject* _tmp114_;
		ObjectsProject* _tmp115_;
		gulong _tmp116_;
		ObjectsSection* _tmp117_;
		ObjectsProject* _tmp118_;
		ObjectsProject* _tmp119_;
		_tmp104_ = self->priv->signals_map;
		_tmp105_ = self->priv->_section;
		_tmp106_ = objects_section_get_project (_tmp105_);
		_tmp107_ = _tmp106_;
		_tmp108_ = g_signal_connect_object (_tmp107_, "item-added", (GCallback) __layouts_section_board____lambda704__objects_project_item_added, self, 0);
		_tmp109_ = self->priv->_section;
		_tmp110_ = objects_section_get_project (_tmp109_);
		_tmp111_ = _tmp110_;
		gee_abstract_map_set ((GeeAbstractMap*) _tmp104_, (gpointer) ((guintptr) _tmp108_), (GObject*) _tmp111_);
		_tmp112_ = self->priv->signals_map;
		_tmp113_ = self->priv->_section;
		_tmp114_ = objects_section_get_project (_tmp113_);
		_tmp115_ = _tmp114_;
		_tmp116_ = g_signal_connect_object ((ObjectsBaseObject*) _tmp115_, "count-updated", (GCallback) __layouts_section_board____lambda705__objects_base_object_count_updated, self, 0);
		_tmp117_ = self->priv->_section;
		_tmp118_ = objects_section_get_project (_tmp117_);
		_tmp119_ = _tmp118_;
		gee_abstract_map_set ((GeeAbstractMap*) _tmp112_, (gpointer) ((guintptr) _tmp116_), (GObject*) _tmp119_);
	} else {
		GeeHashMap* _tmp120_;
		ObjectsSection* _tmp121_;
		gulong _tmp122_;
		ObjectsSection* _tmp123_;
		_tmp120_ = self->priv->signals_map;
		_tmp121_ = self->priv->_section;
		_tmp122_ = g_signal_connect_object (_tmp121_, "item-added", (GCallback) __layouts_section_board____lambda706__objects_section_item_added, self, 0);
		_tmp123_ = self->priv->_section;
		gee_abstract_map_set ((GeeAbstractMap*) _tmp120_, (gpointer) ((guintptr) _tmp122_), (GObject*) _tmp123_);
	}
	_tmp124_ = self->priv->signals_map;
	_tmp125_ = services_event_bus_get_default ();
	_tmp126_ = _tmp125_;
	_tmp127_ = g_signal_connect_object (_tmp126_, "checked-toggled", (GCallback) __layouts_section_board___lambda707__services_event_bus_checked_toggled, self, 0);
	_tmp128_ = services_event_bus_get_default ();
	_tmp129_ = _tmp128_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp124_, (gpointer) ((guintptr) _tmp127_), (GObject*) _tmp129_);
	_g_object_unref0 (_tmp129_);
	_g_object_unref0 (_tmp126_);
	_tmp130_ = self->priv->signals_map;
	_tmp131_ = services_store_instance ();
	_tmp132_ = g_signal_connect_object (_tmp131_, "item-updated", (GCallback) __layouts_section_board___lambda708__services_store_item_updated, self, 0);
	_tmp133_ = services_store_instance ();
	gee_abstract_map_set ((GeeAbstractMap*) _tmp130_, (gpointer) ((guintptr) _tmp132_), (GObject*) _tmp133_);
	_tmp134_ = self->priv->signals_map;
	_tmp135_ = services_store_instance ();
	_tmp136_ = g_signal_connect_object (_tmp135_, "item-pin-change", (GCallback) __layouts_section_board___lambda709__services_store_item_pin_change, self, 0);
	_tmp137_ = services_store_instance ();
	gee_abstract_map_set ((GeeAbstractMap*) _tmp134_, (gpointer) ((guintptr) _tmp136_), (GObject*) _tmp137_);
	_tmp138_ = self->priv->signals_map;
	_tmp139_ = services_store_instance ();
	_tmp140_ = g_signal_connect_object (_tmp139_, "item-deleted", (GCallback) __layouts_section_board___lambda710__services_store_item_deleted, self, 0);
	_tmp141_ = services_store_instance ();
	gee_abstract_map_set ((GeeAbstractMap*) _tmp138_, (gpointer) ((guintptr) _tmp140_), (GObject*) _tmp141_);
	_tmp142_ = self->priv->signals_map;
	_tmp143_ = services_event_bus_get_default ();
	_tmp144_ = _tmp143_;
	_tmp145_ = g_signal_connect_object (_tmp144_, "item-moved", (GCallback) __layouts_section_board___lambda711__services_event_bus_item_moved, self, 0);
	_tmp146_ = services_event_bus_get_default ();
	_tmp147_ = _tmp146_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp142_, (gpointer) ((guintptr) _tmp145_), (GObject*) _tmp147_);
	_g_object_unref0 (_tmp147_);
	_g_object_unref0 (_tmp144_);
	_tmp148_ = self->priv->signals_map;
	_tmp149_ = self->priv->_section;
	_tmp150_ = objects_section_get_project (_tmp149_);
	_tmp151_ = _tmp150_;
	_tmp152_ = g_signal_connect_object (_tmp151_, "sorted-by-changed", (GCallback) __layouts_section_board___lambda712__objects_project_sorted_by_changed, self, 0);
	_tmp153_ = self->priv->_section;
	_tmp154_ = objects_section_get_project (_tmp153_);
	_tmp155_ = _tmp154_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp148_, (gpointer) ((guintptr) _tmp152_), (GObject*) _tmp155_);
	_tmp156_ = self->priv->signals_map;
	_tmp157_ = self->priv->_section;
	_tmp158_ = objects_section_get_project (_tmp157_);
	_tmp159_ = _tmp158_;
	_tmp160_ = g_signal_connect_object (_tmp159_, "sort-order-changed", (GCallback) __layouts_section_board___lambda713__objects_project_sort_order_changed, self, 0);
	_tmp161_ = self->priv->_section;
	_tmp162_ = objects_section_get_project (_tmp161_);
	_tmp163_ = _tmp162_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp156_, (gpointer) ((guintptr) _tmp160_), (GObject*) _tmp163_);
	_tmp164_ = self->priv->signals_map;
	_tmp165_ = services_event_bus_get_default ();
	_tmp166_ = _tmp165_;
	_tmp167_ = g_signal_connect_object (_tmp166_, "update-section-sort-func", (GCallback) __layouts_section_board___lambda714__services_event_bus_update_section_sort_func, self, 0);
	_tmp168_ = services_event_bus_get_default ();
	_tmp169_ = _tmp168_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp164_, (gpointer) ((guintptr) _tmp167_), (GObject*) _tmp169_);
	_g_object_unref0 (_tmp169_);
	_g_object_unref0 (_tmp166_);
	_tmp170_ = self->priv->signals_map;
	_tmp171_ = self->priv->_section;
	_tmp172_ = g_signal_connect_object (_tmp171_, "section-count-updated", (GCallback) __layouts_section_board___lambda715__objects_section_section_count_updated, self, 0);
	_tmp173_ = self->priv->_section;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp170_, (gpointer) ((guintptr) _tmp172_), (GObject*) _tmp173_);
	_tmp174_ = self->priv->signals_map;
	_tmp175_ = services_event_bus_get_default ();
	_tmp176_ = _tmp175_;
	_tmp177_ = g_signal_connect_object (_tmp176_, "update-inserted-item-map", (GCallback) __layouts_section_board___lambda716__services_event_bus_update_inserted_item_map, self, 0);
	_tmp178_ = services_event_bus_get_default ();
	_tmp179_ = _tmp178_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp174_, (gpointer) ((guintptr) _tmp177_), (GObject*) _tmp179_);
	_g_object_unref0 (_tmp179_);
	_g_object_unref0 (_tmp176_);
	_tmp180_ = self->priv->signals_map;
	_tmp181_ = self->priv->_section;
	_tmp182_ = objects_section_get_project (_tmp181_);
	_tmp183_ = _tmp182_;
	_tmp184_ = g_signal_connect_object ((ObjectsBaseObject*) _tmp183_, "filter-added", (GCallback) __layouts_section_board___lambda717__objects_base_object_filter_added, self, 0);
	_tmp185_ = self->priv->_section;
	_tmp186_ = objects_section_get_project (_tmp185_);
	_tmp187_ = _tmp186_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp180_, (gpointer) ((guintptr) _tmp184_), (GObject*) _tmp187_);
	_tmp188_ = self->priv->signals_map;
	_tmp189_ = self->priv->_section;
	_tmp190_ = objects_section_get_project (_tmp189_);
	_tmp191_ = _tmp190_;
	_tmp192_ = g_signal_connect_object ((ObjectsBaseObject*) _tmp191_, "filter-removed", (GCallback) __layouts_section_board___lambda718__objects_base_object_filter_removed, self, 0);
	_tmp193_ = self->priv->_section;
	_tmp194_ = objects_section_get_project (_tmp193_);
	_tmp195_ = _tmp194_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp188_, (gpointer) ((guintptr) _tmp192_), (GObject*) _tmp195_);
	_tmp196_ = self->priv->signals_map;
	_tmp197_ = self->priv->_section;
	_tmp198_ = objects_section_get_project (_tmp197_);
	_tmp199_ = _tmp198_;
	_tmp200_ = g_signal_connect_object ((ObjectsBaseObject*) _tmp199_, "filter-updated", (GCallback) __layouts_section_board___lambda719__objects_base_object_filter_updated, self, 0);
	_tmp201_ = self->priv->_section;
	_tmp202_ = objects_section_get_project (_tmp201_);
	_tmp203_ = _tmp202_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp196_, (gpointer) ((guintptr) _tmp200_), (GObject*) _tmp203_);
	_tmp204_ = self->priv->signals_map;
	_tmp205_ = self->priv->_section;
	_tmp206_ = g_signal_connect_object ((ObjectsBaseObject*) _tmp205_, "sensitive-change", (GCallback) __layouts_section_board___lambda720__objects_base_object_sensitive_change, self, 0);
	_tmp207_ = self->priv->_section;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp204_, (gpointer) ((guintptr) _tmp206_), (GObject*) _tmp207_);
	_tmp208_ = self->priv->signals_map;
	_tmp209_ = self->priv->_section;
	_tmp210_ = g_signal_connect_object ((ObjectsBaseObject*) _tmp209_, "loading-change", (GCallback) __layouts_section_board___lambda721__objects_base_object_loading_change, self, 0);
	_tmp211_ = self->priv->_section;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp208_, (gpointer) ((guintptr) _tmp210_), (GObject*) _tmp211_);
	_tmp212_ = (GtkGestureClick*) gtk_gesture_click_new ();
	edit_gesture = _tmp212_;
	_tmp213_ = self->priv->name_label;
	_tmp214_ = edit_gesture;
	_tmp215_ = _g_object_ref0 ((GtkEventController*) _tmp214_);
	gtk_widget_add_controller ((GtkWidget*) _tmp213_, _tmp215_);
	_tmp216_ = self->priv->signals_map;
	_tmp217_ = edit_gesture;
	_tmp218_ = g_signal_connect_object (_tmp217_, "released", (GCallback) __layouts_section_board___lambda722__gtk_gesture_click_released, self, 0);
	_tmp219_ = edit_gesture;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp216_, (gpointer) ((guintptr) _tmp218_), (GObject*) _tmp219_);
	_tmp220_ = self->priv->signals_map;
	_tmp221_ = self->priv->_section;
	_tmp222_ = objects_section_get_project (_tmp221_);
	_tmp223_ = _tmp222_;
	_tmp224_ = g_signal_connect_object (_tmp223_, "show-completed-changed", (GCallback) _layouts_section_board_show_completed_changed_objects_project_show_completed_changed, self, 0);
	_tmp225_ = self->priv->_section;
	_tmp226_ = objects_section_get_project (_tmp225_);
	_tmp227_ = _tmp226_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp220_, (gpointer) ((guintptr) _tmp224_), (GObject*) _tmp227_);
	_tmp228_ = self->priv->signals_map;
	_tmp229_ = self->priv->load_more_button;
	_tmp230_ = g_signal_connect_object (_tmp229_, "clicked", (GCallback) __layouts_section_board___lambda723__gtk_button_clicked, self, 0);
	_tmp231_ = self->priv->load_more_button;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp228_, (gpointer) ((guintptr) _tmp230_), (GObject*) _tmp231_);
	_tmp232_ = self->priv->signals_map;
	_tmp233_ = add_button;
	_tmp234_ = g_signal_connect_object (_tmp233_, "clicked", (GCallback) __layouts_section_board___lambda724__gtk_button_clicked, self, 0);
	_tmp235_ = add_button;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp232_, (gpointer) ((guintptr) _tmp234_), (GObject*) _tmp235_);
	_tmp236_ = self->priv->signals_map;
	_tmp237_ = self->priv->_section;
	_tmp238_ = objects_section_get_project (_tmp237_);
	_tmp239_ = _tmp238_;
	_tmp240_ = objects_project_get_source (_tmp239_);
	_tmp241_ = _tmp240_;
	_tmp242_ = g_signal_connect_object (_tmp241_, "sync-finished", (GCallback) __layouts_section_board___lambda725__objects_source_sync_finished, self, 0);
	_tmp243_ = self->priv->_section;
	_tmp244_ = objects_section_get_project (_tmp243_);
	_tmp245_ = _tmp244_;
	_tmp246_ = objects_project_get_source (_tmp245_);
	_tmp247_ = _tmp246_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp236_, (gpointer) ((guintptr) _tmp242_), (GObject*) _tmp247_);
	_tmp248_ = self->priv->signals_map;
	_tmp249_ = services_event_bus_get_default ();
	_tmp250_ = _tmp249_;
	_tmp251_ = g_signal_connect_object (_tmp250_, "drag-n-drop-active", (GCallback) __layouts_section_board___lambda726__services_event_bus_drag_n_drop_active, self, 0);
	_tmp252_ = services_event_bus_get_default ();
	_tmp253_ = _tmp252_;
	gee_abstract_map_set ((GeeAbstractMap*) _tmp248_, (gpointer) ((guintptr) _tmp251_), (GObject*) _tmp253_);
	_g_object_unref0 (_tmp253_);
	_g_object_unref0 (_tmp250_);
	_g_object_unref0 (edit_gesture);
	_g_object_unref0 (items_scrolled);
	_g_object_unref0 (checked_listbox_container);
	_g_object_unref0 (add_button);
	_g_object_unref0 (add_button_box);
	_g_object_unref0 (header_box);
	_g_object_unref0 (menu_button);
	return obj;
}

static void
layouts_section_board_class_init (LayoutsSectionBoardClass * klass,
                                  gpointer klass_data)
{
	layouts_section_board_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &LayoutsSectionBoard_private_offset);
	G_OBJECT_CLASS (klass)->get_property = _vala_layouts_section_board_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_layouts_section_board_set_property;
	G_OBJECT_CLASS (klass)->constructor = layouts_section_board_constructor;
	G_OBJECT_CLASS (klass)->finalize = layouts_section_board_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), LAYOUTS_SECTION_BOARD_SECTION_PROPERTY, layouts_section_board_properties[LAYOUTS_SECTION_BOARD_SECTION_PROPERTY] = g_param_spec_object ("section", "section", "section", OBJECTS_TYPE_SECTION, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
	g_object_class_install_property (G_OBJECT_CLASS (klass), LAYOUTS_SECTION_BOARD_IS_INBOX_SECTION_PROPERTY, layouts_section_board_properties[LAYOUTS_SECTION_BOARD_IS_INBOX_SECTION_PROPERTY] = g_param_spec_boolean ("is-inbox-section", "is-inbox-section", "is-inbox-section", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), LAYOUTS_SECTION_BOARD_IS_LOADING_PROPERTY, layouts_section_board_properties[LAYOUTS_SECTION_BOARD_IS_LOADING_PROPERTY] = g_param_spec_boolean ("is-loading", "is-loading", "is-loading", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), LAYOUTS_SECTION_BOARD_SECTION_COUNT_PROPERTY, layouts_section_board_properties[LAYOUTS_SECTION_BOARD_SECTION_COUNT_PROPERTY] = g_param_spec_int ("section-count", "section-count", "section-count", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
}

static void
layouts_section_board_instance_init (LayoutsSectionBoard * self,
                                     gpointer klass)
{
	GeeHashMap* _tmp0_;
	GeeHashMap* _tmp1_;
	GeeHashMap* _tmp2_;
	self->priv = layouts_section_board_get_instance_private (self);
	_tmp0_ = gee_hash_map_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, (GDestroyNotify) g_free, LAYOUTS_TYPE_ITEM_BOARD, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
	self->items_map = _tmp0_;
	_tmp1_ = gee_hash_map_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, (GDestroyNotify) g_free, LAYOUTS_TYPE_ITEM_BOARD, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
	self->checked_items_map = _tmp1_;
	_tmp2_ = gee_hash_map_new (G_TYPE_ULONG, NULL, NULL, G_TYPE_OBJECT, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
	self->priv->signals_map = _tmp2_;
	self->priv->completed_page_index = 0;
}

static void
layouts_section_board_finalize (GObject * obj)
{
	LayoutsSectionBoard * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, LAYOUTS_TYPE_SECTION_BOARD, LayoutsSectionBoard);
	g_debug ("SectionBoard.vala:88: Destroying - Layouts.SectionBoard\n");
	_g_object_unref0 (self->priv->_section);
	_g_object_unref0 (self->priv->widget_color);
	_g_object_unref0 (self->priv->name_label);
	_g_object_unref0 (self->priv->count_label);
	_g_object_unref0 (self->priv->description_label);
	_g_object_unref0 (self->priv->description_revealer);
	_g_object_unref0 (self->priv->listbox);
	_g_object_unref0 (self->priv->listbox_target);
	_g_object_unref0 (self->priv->checked_listbox);
	_g_object_unref0 (self->priv->load_more_button);
	_g_object_unref0 (self->priv->load_more_button_revealer);
	_g_object_unref0 (self->priv->checked_revealer);
	_g_object_unref0 (self->priv->content_box);
	_g_object_unref0 (self->items_map);
	_g_object_unref0 (self->checked_items_map);
	_g_object_unref0 (self->priv->signals_map);
	_g_object_unref0 (self->priv->completed_items_list);
	G_OBJECT_CLASS (layouts_section_board_parent_class)->finalize (obj);
}

static GType
layouts_section_board_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (LayoutsSectionBoardClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) layouts_section_board_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (LayoutsSectionBoard), 0, (GInstanceInitFunc) layouts_section_board_instance_init, NULL };
	GType layouts_section_board_type_id;
	layouts_section_board_type_id = g_type_register_static (gtk_flow_box_child_get_type (), "LayoutsSectionBoard", &g_define_type_info, 0);
	LayoutsSectionBoard_private_offset = g_type_add_instance_private (layouts_section_board_type_id, sizeof (LayoutsSectionBoardPrivate));
	return layouts_section_board_type_id;
}

GType
layouts_section_board_get_type (void)
{
	static volatile gsize layouts_section_board_type_id__once = 0;
	if (g_once_init_enter (&layouts_section_board_type_id__once)) {
		GType layouts_section_board_type_id;
		layouts_section_board_type_id = layouts_section_board_get_type_once ();
		g_once_init_leave (&layouts_section_board_type_id__once, layouts_section_board_type_id);
	}
	return layouts_section_board_type_id__once;
}

static void
_vala_layouts_section_board_get_property (GObject * object,
                                          guint property_id,
                                          GValue * value,
                                          GParamSpec * pspec)
{
	LayoutsSectionBoard * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, LAYOUTS_TYPE_SECTION_BOARD, LayoutsSectionBoard);
	switch (property_id) {
		case LAYOUTS_SECTION_BOARD_SECTION_PROPERTY:
		g_value_set_object (value, layouts_section_board_get_section (self));
		break;
		case LAYOUTS_SECTION_BOARD_IS_INBOX_SECTION_PROPERTY:
		g_value_set_boolean (value, layouts_section_board_get_is_inbox_section (self));
		break;
		case LAYOUTS_SECTION_BOARD_SECTION_COUNT_PROPERTY:
		g_value_set_int (value, layouts_section_board_get_section_count (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_layouts_section_board_set_property (GObject * object,
                                          guint property_id,
                                          const GValue * value,
                                          GParamSpec * pspec)
{
	LayoutsSectionBoard * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, LAYOUTS_TYPE_SECTION_BOARD, LayoutsSectionBoard);
	switch (property_id) {
		case LAYOUTS_SECTION_BOARD_SECTION_PROPERTY:
		layouts_section_board_set_section (self, g_value_get_object (value));
		break;
		case LAYOUTS_SECTION_BOARD_IS_LOADING_PROPERTY:
		layouts_section_board_set_is_loading (self, g_value_get_boolean (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_array_destroy (gpointer array,
                     gssize array_length,
                     GDestroyNotify destroy_func)
{
	if ((array != NULL) && (destroy_func != NULL)) {
		gssize 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,
                  gssize array_length,
                  GDestroyNotify destroy_func)
{
	_vala_array_destroy (array, array_length, destroy_func);
	g_free (array);
}

