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

#include <gtk/gtk.h>
#include <glib-object.h>
#include <gio/gio.h>
#include <glib.h>
#include <adwaita.h>
#include <stdlib.h>
#include <string.h>

#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 TUBA_VIEWS_ADMIN_TIMELINE_TYPE_PAGINATION_TIMELINE (tuba_views_admin_timeline_pagination_timeline_get_type ())
#define TUBA_VIEWS_ADMIN_TIMELINE_PAGINATION_TIMELINE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_ADMIN_TIMELINE_TYPE_PAGINATION_TIMELINE, TubaViewsAdminTimelinePaginationTimeline))
#define TUBA_VIEWS_ADMIN_TIMELINE_PAGINATION_TIMELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_ADMIN_TIMELINE_TYPE_PAGINATION_TIMELINE, TubaViewsAdminTimelinePaginationTimelineClass))
#define TUBA_VIEWS_ADMIN_TIMELINE_IS_PAGINATION_TIMELINE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_ADMIN_TIMELINE_TYPE_PAGINATION_TIMELINE))
#define TUBA_VIEWS_ADMIN_TIMELINE_IS_PAGINATION_TIMELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_ADMIN_TIMELINE_TYPE_PAGINATION_TIMELINE))
#define TUBA_VIEWS_ADMIN_TIMELINE_PAGINATION_TIMELINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_ADMIN_TIMELINE_TYPE_PAGINATION_TIMELINE, TubaViewsAdminTimelinePaginationTimelineClass))

typedef struct _TubaViewsAdminTimelinePaginationTimeline TubaViewsAdminTimelinePaginationTimeline;
typedef struct _TubaViewsAdminTimelinePaginationTimelineClass TubaViewsAdminTimelinePaginationTimelineClass;
typedef struct _TubaViewsAdminTimelinePaginationTimelinePrivate TubaViewsAdminTimelinePaginationTimelinePrivate;

#define TUBA_VIEWS_ADMIN_TIMELINE_TYPE_ACCOUNTS (tuba_views_admin_timeline_accounts_get_type ())
#define TUBA_VIEWS_ADMIN_TIMELINE_ACCOUNTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_VIEWS_ADMIN_TIMELINE_TYPE_ACCOUNTS, TubaViewsAdminTimelineAccounts))
#define TUBA_VIEWS_ADMIN_TIMELINE_ACCOUNTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_VIEWS_ADMIN_TIMELINE_TYPE_ACCOUNTS, TubaViewsAdminTimelineAccountsClass))
#define TUBA_VIEWS_ADMIN_TIMELINE_IS_ACCOUNTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_VIEWS_ADMIN_TIMELINE_TYPE_ACCOUNTS))
#define TUBA_VIEWS_ADMIN_TIMELINE_IS_ACCOUNTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_VIEWS_ADMIN_TIMELINE_TYPE_ACCOUNTS))
#define TUBA_VIEWS_ADMIN_TIMELINE_ACCOUNTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_VIEWS_ADMIN_TIMELINE_TYPE_ACCOUNTS, TubaViewsAdminTimelineAccountsClass))

typedef struct _TubaViewsAdminTimelineAccounts TubaViewsAdminTimelineAccounts;
typedef struct _TubaViewsAdminTimelineAccountsClass TubaViewsAdminTimelineAccountsClass;
typedef struct _TubaViewsAdminTimelineAccountsPrivate TubaViewsAdminTimelineAccountsPrivate;
enum  {
	TUBA_VIEWS_ADMIN_TIMELINE_ACCOUNTS_0_PROPERTY,
	TUBA_VIEWS_ADMIN_TIMELINE_ACCOUNTS_NUM_PROPERTIES
};
static GParamSpec* tuba_views_admin_timeline_accounts_properties[TUBA_VIEWS_ADMIN_TIMELINE_ACCOUNTS_NUM_PROPERTIES];

#define TUBA_WIDGETS_ADMIN_TYPE_ACCOUNT_ROW (tuba_widgets_admin_account_row_get_type ())
#define TUBA_WIDGETS_ADMIN_ACCOUNT_ROW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_WIDGETS_ADMIN_TYPE_ACCOUNT_ROW, TubaWidgetsAdminAccountRow))
#define TUBA_WIDGETS_ADMIN_ACCOUNT_ROW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_WIDGETS_ADMIN_TYPE_ACCOUNT_ROW, TubaWidgetsAdminAccountRowClass))
#define TUBA_WIDGETS_ADMIN_IS_ACCOUNT_ROW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_WIDGETS_ADMIN_TYPE_ACCOUNT_ROW))
#define TUBA_WIDGETS_ADMIN_IS_ACCOUNT_ROW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_WIDGETS_ADMIN_TYPE_ACCOUNT_ROW))
#define TUBA_WIDGETS_ADMIN_ACCOUNT_ROW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_WIDGETS_ADMIN_TYPE_ACCOUNT_ROW, TubaWidgetsAdminAccountRowClass))

typedef struct _TubaWidgetsAdminAccountRow TubaWidgetsAdminAccountRow;
typedef struct _TubaWidgetsAdminAccountRowClass TubaWidgetsAdminAccountRowClass;

#define TUBA_TYPE_ENTITY (tuba_entity_get_type ())
#define TUBA_ENTITY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_ENTITY, TubaEntity))
#define TUBA_ENTITY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_ENTITY, TubaEntityClass))
#define TUBA_IS_ENTITY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_ENTITY))
#define TUBA_IS_ENTITY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_ENTITY))
#define TUBA_ENTITY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_ENTITY, TubaEntityClass))

typedef struct _TubaEntity TubaEntity;
typedef struct _TubaEntityClass TubaEntityClass;

#define TUBA_API_ADMIN_TYPE_ACCOUNT (tuba_api_admin_account_get_type ())
#define TUBA_API_ADMIN_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_ADMIN_TYPE_ACCOUNT, TubaAPIAdminAccount))
#define TUBA_API_ADMIN_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_ADMIN_TYPE_ACCOUNT, TubaAPIAdminAccountClass))
#define TUBA_API_ADMIN_IS_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_ADMIN_TYPE_ACCOUNT))
#define TUBA_API_ADMIN_IS_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_ADMIN_TYPE_ACCOUNT))
#define TUBA_API_ADMIN_ACCOUNT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_ADMIN_TYPE_ACCOUNT, TubaAPIAdminAccountClass))

typedef struct _TubaAPIAdminAccount TubaAPIAdminAccount;
typedef struct _TubaAPIAdminAccountClass TubaAPIAdminAccountClass;
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
enum  {
	TUBA_VIEWS_ADMIN_TIMELINE_ACCOUNTS_ON_OPEN_ACCOUNT_SIGNAL,
	TUBA_VIEWS_ADMIN_TIMELINE_ACCOUNTS_NUM_SIGNALS
};
static guint tuba_views_admin_timeline_accounts_signals[TUBA_VIEWS_ADMIN_TIMELINE_ACCOUNTS_NUM_SIGNALS] = {0};

struct _TubaViewsAdminTimelinePaginationTimeline {
	GtkBox parent_instance;
	TubaViewsAdminTimelinePaginationTimelinePrivate * priv;
	GtkListBox* content;
};

struct _TubaViewsAdminTimelinePaginationTimelineClass {
	GtkBoxClass parent_class;
	void (*request) (TubaViewsAdminTimelinePaginationTimeline* self, GAsyncReadyCallback _callback_, gpointer _user_data_);
	void (*request_finish) (TubaViewsAdminTimelinePaginationTimeline* self, GAsyncResult* _res_);
	GtkWidget* (*on_create_model_widget) (TubaViewsAdminTimelinePaginationTimeline* self, GObject* obj);
	void (*on_content_item_activated) (TubaViewsAdminTimelinePaginationTimeline* self, GtkListBoxRow* row);
};

struct _TubaViewsAdminTimelineAccounts {
	TubaViewsAdminTimelinePaginationTimeline parent_instance;
	TubaViewsAdminTimelineAccountsPrivate * priv;
};

struct _TubaViewsAdminTimelineAccountsClass {
	TubaViewsAdminTimelinePaginationTimelineClass parent_class;
};

static gpointer tuba_views_admin_timeline_accounts_parent_class = NULL;

VALA_EXTERN GType tuba_views_admin_timeline_pagination_timeline_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsAdminTimelinePaginationTimeline, g_object_unref)
VALA_EXTERN GType tuba_views_admin_timeline_accounts_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaViewsAdminTimelineAccounts, g_object_unref)
VALA_EXTERN GtkWidget* tuba_views_admin_timeline_pagination_timeline_on_create_model_widget (TubaViewsAdminTimelinePaginationTimeline* self,
                                                                                 GObject* obj);
static GtkWidget* tuba_views_admin_timeline_accounts_real_on_create_model_widget (TubaViewsAdminTimelinePaginationTimeline* base,
                                                                           GObject* obj);
VALA_EXTERN GType tuba_widgets_admin_account_row_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaWidgetsAdminAccountRow, g_object_unref)
VALA_EXTERN GType tuba_entity_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaEntity, g_object_unref)
VALA_EXTERN GType tuba_api_admin_account_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIAdminAccount, g_object_unref)
static void tuba_views_admin_timeline_accounts_on_account_opened (TubaViewsAdminTimelineAccounts* self,
                                                           TubaAPIAdminAccount* account);
static void _tuba_views_admin_timeline_accounts_on_account_opened_tuba_widgets_admin_account_row_account_opened (TubaWidgetsAdminAccountRow* _sender,
                                                                                                          TubaAPIAdminAccount* account_obj,
                                                                                                          gpointer self);
VALA_EXTERN TubaViewsAdminTimelineAccounts* tuba_views_admin_timeline_accounts_new (void);
VALA_EXTERN TubaViewsAdminTimelineAccounts* tuba_views_admin_timeline_accounts_construct (GType object_type);
VALA_EXTERN TubaViewsAdminTimelinePaginationTimeline* tuba_views_admin_timeline_pagination_timeline_new (void);
VALA_EXTERN TubaViewsAdminTimelinePaginationTimeline* tuba_views_admin_timeline_pagination_timeline_construct (GType object_type);
static GObject * tuba_views_admin_timeline_accounts_constructor (GType type,
                                                          guint n_construct_properties,
                                                          GObjectConstructParam * construct_properties);
VALA_EXTERN void tuba_views_admin_timeline_pagination_timeline_set_url (TubaViewsAdminTimelinePaginationTimeline* self,
                                                            const gchar* value);
VALA_EXTERN void tuba_views_admin_timeline_pagination_timeline_set_accepts (TubaViewsAdminTimelinePaginationTimeline* self,
                                                                GType value);
static void tuba_views_admin_timeline_accounts_finalize (GObject * obj);
static GType tuba_views_admin_timeline_accounts_get_type_once (void);

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

static void
_tuba_views_admin_timeline_accounts_on_account_opened_tuba_widgets_admin_account_row_account_opened (TubaWidgetsAdminAccountRow* _sender,
                                                                                                     TubaAPIAdminAccount* account_obj,
                                                                                                     gpointer self)
{
	tuba_views_admin_timeline_accounts_on_account_opened ((TubaViewsAdminTimelineAccounts*) self, account_obj);
}

static GtkWidget*
tuba_views_admin_timeline_accounts_real_on_create_model_widget (TubaViewsAdminTimelinePaginationTimeline* base,
                                                                GObject* obj)
{
	TubaViewsAdminTimelineAccounts * self;
	GtkWidget* widget = NULL;
	GtkWidget* _tmp0_;
	TubaWidgetsAdminAccountRow* action_row = NULL;
	GtkWidget* _tmp1_;
	TubaWidgetsAdminAccountRow* _tmp2_;
	TubaWidgetsAdminAccountRow* _tmp3_;
	GtkWidget* result;
	self = (TubaViewsAdminTimelineAccounts*) base;
	g_return_val_if_fail (obj != NULL, NULL);
	_tmp0_ = TUBA_VIEWS_ADMIN_TIMELINE_PAGINATION_TIMELINE_CLASS (tuba_views_admin_timeline_accounts_parent_class)->on_create_model_widget (G_TYPE_CHECK_INSTANCE_CAST (self, TUBA_VIEWS_ADMIN_TIMELINE_TYPE_PAGINATION_TIMELINE, TubaViewsAdminTimelinePaginationTimeline), obj);
	widget = _tmp0_;
	_tmp1_ = widget;
	_tmp2_ = _g_object_ref0 (TUBA_WIDGETS_ADMIN_IS_ACCOUNT_ROW (_tmp1_) ? ((TubaWidgetsAdminAccountRow*) _tmp1_) : NULL);
	action_row = _tmp2_;
	_tmp3_ = action_row;
	if (_tmp3_ != NULL) {
		TubaWidgetsAdminAccountRow* _tmp4_;
		_tmp4_ = action_row;
		g_signal_connect_object (_tmp4_, "account-opened", (GCallback) _tuba_views_admin_timeline_accounts_on_account_opened_tuba_widgets_admin_account_row_account_opened, self, 0);
	}
	result = widget;
	_g_object_unref0 (action_row);
	return result;
}

static void
tuba_views_admin_timeline_accounts_on_account_opened (TubaViewsAdminTimelineAccounts* self,
                                                      TubaAPIAdminAccount* account)
{
	g_return_if_fail (self != NULL);
	g_return_if_fail (account != NULL);
	g_signal_emit (self, tuba_views_admin_timeline_accounts_signals[TUBA_VIEWS_ADMIN_TIMELINE_ACCOUNTS_ON_OPEN_ACCOUNT_SIGNAL], 0, account);
}

TubaViewsAdminTimelineAccounts*
tuba_views_admin_timeline_accounts_construct (GType object_type)
{
	TubaViewsAdminTimelineAccounts * self = NULL;
	self = (TubaViewsAdminTimelineAccounts*) tuba_views_admin_timeline_pagination_timeline_construct (object_type);
	return self;
}

TubaViewsAdminTimelineAccounts*
tuba_views_admin_timeline_accounts_new (void)
{
	return tuba_views_admin_timeline_accounts_construct (TUBA_VIEWS_ADMIN_TIMELINE_TYPE_ACCOUNTS);
}

static GObject *
tuba_views_admin_timeline_accounts_constructor (GType type,
                                                guint n_construct_properties,
                                                GObjectConstructParam * construct_properties)
{
	GObject * obj;
	GObjectClass * parent_class;
	TubaViewsAdminTimelineAccounts * self;
	parent_class = G_OBJECT_CLASS (tuba_views_admin_timeline_accounts_parent_class);
	obj = parent_class->constructor (type, n_construct_properties, construct_properties);
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_VIEWS_ADMIN_TIMELINE_TYPE_ACCOUNTS, TubaViewsAdminTimelineAccounts);
	tuba_views_admin_timeline_pagination_timeline_set_url ((TubaViewsAdminTimelinePaginationTimeline*) self, "/api/v1/admin/accounts");
	tuba_views_admin_timeline_pagination_timeline_set_accepts ((TubaViewsAdminTimelinePaginationTimeline*) self, TUBA_API_ADMIN_TYPE_ACCOUNT);
	return obj;
}

static void
tuba_views_admin_timeline_accounts_class_init (TubaViewsAdminTimelineAccountsClass * klass,
                                               gpointer klass_data)
{
	tuba_views_admin_timeline_accounts_parent_class = g_type_class_peek_parent (klass);
	((TubaViewsAdminTimelinePaginationTimelineClass *) klass)->on_create_model_widget = (GtkWidget* (*) (TubaViewsAdminTimelinePaginationTimeline*, GObject*)) tuba_views_admin_timeline_accounts_real_on_create_model_widget;
	G_OBJECT_CLASS (klass)->constructor = tuba_views_admin_timeline_accounts_constructor;
	G_OBJECT_CLASS (klass)->finalize = tuba_views_admin_timeline_accounts_finalize;
	tuba_views_admin_timeline_accounts_signals[TUBA_VIEWS_ADMIN_TIMELINE_ACCOUNTS_ON_OPEN_ACCOUNT_SIGNAL] = g_signal_new ("on-open-account", TUBA_VIEWS_ADMIN_TIMELINE_TYPE_ACCOUNTS, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__OBJECT, G_TYPE_NONE, 1, TUBA_API_ADMIN_TYPE_ACCOUNT);
}

static void
tuba_views_admin_timeline_accounts_instance_init (TubaViewsAdminTimelineAccounts * self,
                                                  gpointer klass)
{
}

static void
tuba_views_admin_timeline_accounts_finalize (GObject * obj)
{
	TubaViewsAdminTimelineAccounts * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_VIEWS_ADMIN_TIMELINE_TYPE_ACCOUNTS, TubaViewsAdminTimelineAccounts);
	g_debug ("Accounts.vala:5: Destroying Accounts");
	G_OBJECT_CLASS (tuba_views_admin_timeline_accounts_parent_class)->finalize (obj);
}

 G_GNUC_NO_INLINE static GType
tuba_views_admin_timeline_accounts_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (TubaViewsAdminTimelineAccountsClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) tuba_views_admin_timeline_accounts_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TubaViewsAdminTimelineAccounts), 0, (GInstanceInitFunc) tuba_views_admin_timeline_accounts_instance_init, NULL };
	GType tuba_views_admin_timeline_accounts_type_id;
	tuba_views_admin_timeline_accounts_type_id = g_type_register_static (TUBA_VIEWS_ADMIN_TIMELINE_TYPE_PAGINATION_TIMELINE, "TubaViewsAdminTimelineAccounts", &g_define_type_info, G_TYPE_FLAG_NONE);
	return tuba_views_admin_timeline_accounts_type_id;
}

GType
tuba_views_admin_timeline_accounts_get_type (void)
{
	static GType tuba_views_admin_timeline_accounts_type_id__once = 0;
	if (g_once_init_enter_pointer (&tuba_views_admin_timeline_accounts_type_id__once)) {
		GType tuba_views_admin_timeline_accounts_type_id;
		tuba_views_admin_timeline_accounts_type_id = tuba_views_admin_timeline_accounts_get_type_once ();
		g_once_init_leave_pointer (&tuba_views_admin_timeline_accounts_type_id__once, tuba_views_admin_timeline_accounts_type_id);
	}
	return tuba_views_admin_timeline_accounts_type_id__once;
}

