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

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

#define TOOTLE_WIDGETS_TYPE_STATUS (tootle_widgets_status_get_type ())
#define TOOTLE_WIDGETS_STATUS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOOTLE_WIDGETS_TYPE_STATUS, TootleWidgetsStatus))
#define TOOTLE_WIDGETS_STATUS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOOTLE_WIDGETS_TYPE_STATUS, TootleWidgetsStatusClass))
#define TOOTLE_WIDGETS_IS_STATUS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOOTLE_WIDGETS_TYPE_STATUS))
#define TOOTLE_WIDGETS_IS_STATUS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOOTLE_WIDGETS_TYPE_STATUS))
#define TOOTLE_WIDGETS_STATUS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TOOTLE_WIDGETS_TYPE_STATUS, TootleWidgetsStatusClass))

typedef struct _TootleWidgetsStatus TootleWidgetsStatus;
typedef struct _TootleWidgetsStatusClass TootleWidgetsStatusClass;
typedef struct _TootleWidgetsStatusPrivate TootleWidgetsStatusPrivate;

#define TOOTLE_WIDGETS_TYPE_RICH_LABEL (tootle_widgets_rich_label_get_type ())
#define TOOTLE_WIDGETS_RICH_LABEL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOOTLE_WIDGETS_TYPE_RICH_LABEL, TootleWidgetsRichLabel))
#define TOOTLE_WIDGETS_RICH_LABEL_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOOTLE_WIDGETS_TYPE_RICH_LABEL, TootleWidgetsRichLabelClass))
#define TOOTLE_WIDGETS_IS_RICH_LABEL(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOOTLE_WIDGETS_TYPE_RICH_LABEL))
#define TOOTLE_WIDGETS_IS_RICH_LABEL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOOTLE_WIDGETS_TYPE_RICH_LABEL))
#define TOOTLE_WIDGETS_RICH_LABEL_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TOOTLE_WIDGETS_TYPE_RICH_LABEL, TootleWidgetsRichLabelClass))

typedef struct _TootleWidgetsRichLabel TootleWidgetsRichLabel;
typedef struct _TootleWidgetsRichLabelClass TootleWidgetsRichLabelClass;

#define TOOTLE_WIDGETS_TYPE_AVATAR (tootle_widgets_avatar_get_type ())
#define TOOTLE_WIDGETS_AVATAR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOOTLE_WIDGETS_TYPE_AVATAR, TootleWidgetsAvatar))
#define TOOTLE_WIDGETS_AVATAR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOOTLE_WIDGETS_TYPE_AVATAR, TootleWidgetsAvatarClass))
#define TOOTLE_WIDGETS_IS_AVATAR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOOTLE_WIDGETS_TYPE_AVATAR))
#define TOOTLE_WIDGETS_IS_AVATAR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOOTLE_WIDGETS_TYPE_AVATAR))
#define TOOTLE_WIDGETS_AVATAR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TOOTLE_WIDGETS_TYPE_AVATAR, TootleWidgetsAvatarClass))

typedef struct _TootleWidgetsAvatar TootleWidgetsAvatar;
typedef struct _TootleWidgetsAvatarClass TootleWidgetsAvatarClass;

#define TOOTLE_WIDGETS_TYPE_MARKUP_VIEW (tootle_widgets_markup_view_get_type ())
#define TOOTLE_WIDGETS_MARKUP_VIEW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOOTLE_WIDGETS_TYPE_MARKUP_VIEW, TootleWidgetsMarkupView))
#define TOOTLE_WIDGETS_MARKUP_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOOTLE_WIDGETS_TYPE_MARKUP_VIEW, TootleWidgetsMarkupViewClass))
#define TOOTLE_WIDGETS_IS_MARKUP_VIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOOTLE_WIDGETS_TYPE_MARKUP_VIEW))
#define TOOTLE_WIDGETS_IS_MARKUP_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOOTLE_WIDGETS_TYPE_MARKUP_VIEW))
#define TOOTLE_WIDGETS_MARKUP_VIEW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TOOTLE_WIDGETS_TYPE_MARKUP_VIEW, TootleWidgetsMarkupViewClass))

typedef struct _TootleWidgetsMarkupView TootleWidgetsMarkupView;
typedef struct _TootleWidgetsMarkupViewClass TootleWidgetsMarkupViewClass;

#define TOOTLE_WIDGETS_ATTACHMENT_TYPE_BOX (tootle_widgets_attachment_box_get_type ())
#define TOOTLE_WIDGETS_ATTACHMENT_BOX(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOOTLE_WIDGETS_ATTACHMENT_TYPE_BOX, TootleWidgetsAttachmentBox))
#define TOOTLE_WIDGETS_ATTACHMENT_BOX_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOOTLE_WIDGETS_ATTACHMENT_TYPE_BOX, TootleWidgetsAttachmentBoxClass))
#define TOOTLE_WIDGETS_ATTACHMENT_IS_BOX(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOOTLE_WIDGETS_ATTACHMENT_TYPE_BOX))
#define TOOTLE_WIDGETS_ATTACHMENT_IS_BOX_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOOTLE_WIDGETS_ATTACHMENT_TYPE_BOX))
#define TOOTLE_WIDGETS_ATTACHMENT_BOX_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TOOTLE_WIDGETS_ATTACHMENT_TYPE_BOX, TootleWidgetsAttachmentBoxClass))

typedef struct _TootleWidgetsAttachmentBox TootleWidgetsAttachmentBox;
typedef struct _TootleWidgetsAttachmentBoxClass TootleWidgetsAttachmentBoxClass;

#define TOOTLE_WIDGETS_TYPE_NOTIFICATION (tootle_widgets_notification_get_type ())
#define TOOTLE_WIDGETS_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOOTLE_WIDGETS_TYPE_NOTIFICATION, TootleWidgetsNotification))
#define TOOTLE_WIDGETS_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOOTLE_WIDGETS_TYPE_NOTIFICATION, TootleWidgetsNotificationClass))
#define TOOTLE_WIDGETS_IS_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOOTLE_WIDGETS_TYPE_NOTIFICATION))
#define TOOTLE_WIDGETS_IS_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOOTLE_WIDGETS_TYPE_NOTIFICATION))
#define TOOTLE_WIDGETS_NOTIFICATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TOOTLE_WIDGETS_TYPE_NOTIFICATION, TootleWidgetsNotificationClass))

typedef struct _TootleWidgetsNotification TootleWidgetsNotification;
typedef struct _TootleWidgetsNotificationClass TootleWidgetsNotificationClass;
typedef struct _TootleWidgetsNotificationPrivate TootleWidgetsNotificationPrivate;

#define TOOTLE_TYPE_ENTITY (tootle_entity_get_type ())
#define TOOTLE_ENTITY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOOTLE_TYPE_ENTITY, TootleEntity))
#define TOOTLE_ENTITY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOOTLE_TYPE_ENTITY, TootleEntityClass))
#define TOOTLE_IS_ENTITY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOOTLE_TYPE_ENTITY))
#define TOOTLE_IS_ENTITY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOOTLE_TYPE_ENTITY))
#define TOOTLE_ENTITY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TOOTLE_TYPE_ENTITY, TootleEntityClass))

typedef struct _TootleEntity TootleEntity;
typedef struct _TootleEntityClass TootleEntityClass;

#define TOOTLE_API_TYPE_NOTIFICATION (tootle_api_notification_get_type ())
#define TOOTLE_API_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOOTLE_API_TYPE_NOTIFICATION, TootleAPINotification))
#define TOOTLE_API_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOOTLE_API_TYPE_NOTIFICATION, TootleAPINotificationClass))
#define TOOTLE_API_IS_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOOTLE_API_TYPE_NOTIFICATION))
#define TOOTLE_API_IS_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOOTLE_API_TYPE_NOTIFICATION))
#define TOOTLE_API_NOTIFICATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TOOTLE_API_TYPE_NOTIFICATION, TootleAPINotificationClass))

typedef struct _TootleAPINotification TootleAPINotification;
typedef struct _TootleAPINotificationClass TootleAPINotificationClass;
enum  {
	TOOTLE_WIDGETS_NOTIFICATION_0_PROPERTY,
	TOOTLE_WIDGETS_NOTIFICATION_NOTIFICATION_PROPERTY,
	TOOTLE_WIDGETS_NOTIFICATION_NUM_PROPERTIES
};
static GParamSpec* tootle_widgets_notification_properties[TOOTLE_WIDGETS_NOTIFICATION_NUM_PROPERTIES];
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))

#define TOOTLE_API_TYPE_STATUS (tootle_api_status_get_type ())
#define TOOTLE_API_STATUS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOOTLE_API_TYPE_STATUS, TootleAPIStatus))
#define TOOTLE_API_STATUS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOOTLE_API_TYPE_STATUS, TootleAPIStatusClass))
#define TOOTLE_API_IS_STATUS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOOTLE_API_TYPE_STATUS))
#define TOOTLE_API_IS_STATUS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOOTLE_API_TYPE_STATUS))
#define TOOTLE_API_STATUS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TOOTLE_API_TYPE_STATUS, TootleAPIStatusClass))

typedef struct _TootleAPIStatus TootleAPIStatus;
typedef struct _TootleAPIStatusClass TootleAPIStatusClass;

#define TOOTLE_API_TYPE_ACCOUNT (tootle_api_account_get_type ())
#define TOOTLE_API_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOOTLE_API_TYPE_ACCOUNT, TootleAPIAccount))
#define TOOTLE_API_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOOTLE_API_TYPE_ACCOUNT, TootleAPIAccountClass))
#define TOOTLE_API_IS_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOOTLE_API_TYPE_ACCOUNT))
#define TOOTLE_API_IS_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOOTLE_API_TYPE_ACCOUNT))
#define TOOTLE_API_ACCOUNT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TOOTLE_API_TYPE_ACCOUNT, TootleAPIAccountClass))

typedef struct _TootleAPIAccount TootleAPIAccount;
typedef struct _TootleAPIAccountClass TootleAPIAccountClass;
typedef enum  {
	TOOTLE_API_NOTIFICATION_TYPE_MENTION,
	TOOTLE_API_NOTIFICATION_TYPE_REBLOG,
	TOOTLE_API_NOTIFICATION_TYPE_REBLOG_REMOTE_USER,
	TOOTLE_API_NOTIFICATION_TYPE_FAVOURITE,
	TOOTLE_API_NOTIFICATION_TYPE_FOLLOW,
	TOOTLE_API_NOTIFICATION_TYPE_FOLLOW_REQUEST,
	TOOTLE_API_NOTIFICATION_TYPE_WATCHLIST
} TootleAPINotificationType;

#define TOOTLE_API_TYPE_NOTIFICATION_TYPE (tootle_api_notification_type_get_type ())
#define _g_free0(var) (var = (g_free (var), NULL))

struct _TootleWidgetsStatus {
	GtkListBoxRow parent_instance;
	TootleWidgetsStatusPrivate * priv;
	GtkGrid* grid;
	GtkImage* header_icon;
	TootleWidgetsRichLabel* header_label;
	GtkImage* thread_line;
	TootleWidgetsAvatar* avatar;
	TootleWidgetsRichLabel* name_label;
	GtkLabel* handle_label;
	GtkBox* indicators;
	GtkLabel* date_label;
	GtkImage* pin_indicator;
	GtkImage* indicator;
	GtkBox* content_column;
	GtkStack* spoiler_stack;
	GtkBox* content_box;
	TootleWidgetsMarkupView* content;
	TootleWidgetsAttachmentBox* attachments;
	GtkButton* spoiler_button;
	TootleWidgetsRichLabel* spoiler_label;
	GtkBox* actions;
	GtkButton* reply_button;
	GtkImage* reply_button_icon;
	GtkToggleButton* reblog_button;
	GtkImage* reblog_icon;
	GtkToggleButton* favorite_button;
	GtkToggleButton* bookmark_button;
	GtkButton* menu_button;
};

struct _TootleWidgetsStatusClass {
	GtkListBoxRowClass parent_class;
	void (*on_open) (TootleWidgetsStatus* self);
	void (*on_kind_changed) (TootleWidgetsStatus* self);
};

struct _TootleWidgetsNotification {
	TootleWidgetsStatus parent_instance;
	TootleWidgetsNotificationPrivate * priv;
};

struct _TootleWidgetsNotificationClass {
	TootleWidgetsStatusClass parent_class;
};

struct _TootleWidgetsNotificationPrivate {
	TootleAPINotification* _notification;
};

static gint TootleWidgetsNotification_private_offset;
static gpointer tootle_widgets_notification_parent_class = NULL;

GType tootle_widgets_status_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TootleWidgetsStatus, g_object_unref)
GType tootle_widgets_rich_label_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TootleWidgetsRichLabel, g_object_unref)
GType tootle_widgets_avatar_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TootleWidgetsAvatar, g_object_unref)
GType tootle_widgets_markup_view_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TootleWidgetsMarkupView, g_object_unref)
GType tootle_widgets_attachment_box_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TootleWidgetsAttachmentBox, g_object_unref)
GType tootle_widgets_notification_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TootleWidgetsNotification, g_object_unref)
GType tootle_entity_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TootleEntity, g_object_unref)
GType tootle_api_notification_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TootleAPINotification, g_object_unref)
void tootle_widgets_status_on_kind_changed (TootleWidgetsStatus* self);
TootleWidgetsNotification* tootle_widgets_notification_new (TootleAPINotification* obj);
TootleWidgetsNotification* tootle_widgets_notification_construct (GType object_type,
                                                                  TootleAPINotification* obj);
GType tootle_api_status_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TootleAPIStatus, g_object_unref)
TootleAPIStatus* tootle_api_notification_get_status (TootleAPINotification* self);
GType tootle_api_account_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TootleAPIAccount, g_object_unref)
TootleAPIAccount* tootle_api_notification_get_account (TootleAPINotification* self);
TootleAPIStatus* tootle_api_status_new_from_account (TootleAPIAccount* account);
TootleAPIStatus* tootle_api_status_construct_from_account (GType object_type,
                                                           TootleAPIAccount* account);
GType tootle_api_notification_type_get_type (void) G_GNUC_CONST ;
TootleAPINotificationType tootle_api_notification_get_kind (TootleAPINotification* self);
void tootle_widgets_status_set_kind (TootleWidgetsStatus* self,
                                     TootleAPINotificationType* value);
static void tootle_widgets_notification_real_on_kind_changed (TootleWidgetsStatus* base);
TootleAPINotificationType* tootle_widgets_status_get_kind (TootleWidgetsStatus* self);
gchar* tootle_api_notification_type_get_icon (TootleAPINotificationType self);
gchar* tootle_api_notification_type_get_desc (TootleAPINotificationType self,
                                              TootleAPIAccount* account);
TootleAPINotification* tootle_widgets_notification_get_notification (TootleWidgetsNotification* self);
void tootle_widgets_notification_set_notification (TootleWidgetsNotification* self,
                                                   TootleAPINotification* value);
static void tootle_widgets_notification_finalize (GObject * obj);
static GType tootle_widgets_notification_get_type_once (void);
static void _vala_tootle_widgets_notification_get_property (GObject * object,
                                                     guint property_id,
                                                     GValue * value,
                                                     GParamSpec * pspec);
static void _vala_tootle_widgets_notification_set_property (GObject * object,
                                                     guint property_id,
                                                     const GValue * value,
                                                     GParamSpec * pspec);
static inline gpointer _vala_memdup2 (gconstpointer mem,
                        gsize byte_size);

static inline gpointer
tootle_widgets_notification_get_instance_private (TootleWidgetsNotification* self)
{
	return G_STRUCT_MEMBER_P (self, TootleWidgetsNotification_private_offset);
}

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

TootleWidgetsNotification*
tootle_widgets_notification_construct (GType object_type,
                                       TootleAPINotification* obj)
{
	TootleWidgetsNotification * self = NULL;
	TootleAPIStatus* status = NULL;
	TootleAPIStatus* _tmp0_;
	TootleAPIStatus* _tmp1_;
	TootleAPIStatus* _tmp8_;
	TootleAPINotificationType _tmp9_;
	TootleAPINotificationType _tmp10_;
	g_return_val_if_fail (obj != NULL, NULL);
	_tmp0_ = tootle_api_notification_get_status (obj);
	_tmp1_ = _tmp0_;
	if (_tmp1_ != NULL) {
		TootleAPIStatus* _tmp2_;
		TootleAPIStatus* _tmp3_;
		TootleAPIStatus* _tmp4_;
		_tmp2_ = tootle_api_notification_get_status (obj);
		_tmp3_ = _tmp2_;
		_tmp4_ = _g_object_ref0 (_tmp3_);
		_g_object_unref0 (status);
		status = _tmp4_;
	} else {
		TootleAPIAccount* _tmp5_;
		TootleAPIAccount* _tmp6_;
		TootleAPIStatus* _tmp7_;
		_tmp5_ = tootle_api_notification_get_account (obj);
		_tmp6_ = _tmp5_;
		_tmp7_ = tootle_api_status_new_from_account (_tmp6_);
		_g_object_unref0 (status);
		status = _tmp7_;
	}
	_tmp8_ = status;
	self = (TootleWidgetsNotification*) g_object_new (object_type, "notification", obj, "status", _tmp8_, NULL);
	_tmp9_ = tootle_api_notification_get_kind (obj);
	_tmp10_ = _tmp9_;
	tootle_widgets_status_set_kind ((TootleWidgetsStatus*) self, &_tmp10_);
	_g_object_unref0 (status);
	return self;
}

TootleWidgetsNotification*
tootle_widgets_notification_new (TootleAPINotification* obj)
{
	return tootle_widgets_notification_construct (TOOTLE_WIDGETS_TYPE_NOTIFICATION, obj);
}

static void
tootle_widgets_notification_real_on_kind_changed (TootleWidgetsStatus* base)
{
	TootleWidgetsNotification * self;
	TootleAPINotificationType* _tmp0_;
	TootleAPINotificationType* _tmp1_;
	GtkImage* _tmp2_;
	TootleWidgetsRichLabel* _tmp3_;
	GtkImage* _tmp4_;
	TootleAPINotificationType* _tmp5_;
	TootleAPINotificationType* _tmp6_;
	gchar* _tmp7_;
	gchar* _tmp8_;
	TootleWidgetsRichLabel* _tmp9_;
	TootleAPINotificationType* _tmp10_;
	TootleAPINotificationType* _tmp11_;
	TootleAPINotification* _tmp12_;
	TootleAPIAccount* _tmp13_;
	TootleAPIAccount* _tmp14_;
	gchar* _tmp15_;
	gchar* _tmp16_;
	self = (TootleWidgetsNotification*) base;
	_tmp0_ = tootle_widgets_status_get_kind ((TootleWidgetsStatus*) self);
	_tmp1_ = _tmp0_;
	if (_tmp1_ == NULL) {
		return;
	}
	_tmp2_ = ((TootleWidgetsStatus*) self)->header_icon;
	_tmp3_ = ((TootleWidgetsStatus*) self)->header_label;
	gtk_widget_set_visible ((GtkWidget*) _tmp3_, TRUE);
	gtk_widget_set_visible ((GtkWidget*) _tmp2_, TRUE);
	_tmp4_ = ((TootleWidgetsStatus*) self)->header_icon;
	_tmp5_ = tootle_widgets_status_get_kind ((TootleWidgetsStatus*) self);
	_tmp6_ = _tmp5_;
	_tmp7_ = tootle_api_notification_type_get_icon (*_tmp6_);
	_tmp8_ = _tmp7_;
	g_object_set (_tmp4_, "icon-name", _tmp8_, NULL);
	_g_free0 (_tmp8_);
	_tmp9_ = ((TootleWidgetsStatus*) self)->header_label;
	_tmp10_ = tootle_widgets_status_get_kind ((TootleWidgetsStatus*) self);
	_tmp11_ = _tmp10_;
	_tmp12_ = self->priv->_notification;
	_tmp13_ = tootle_api_notification_get_account (_tmp12_);
	_tmp14_ = _tmp13_;
	_tmp15_ = tootle_api_notification_type_get_desc (*_tmp11_, _tmp14_);
	_tmp16_ = _tmp15_;
	gtk_label_set_label ((GtkLabel*) _tmp9_, _tmp16_);
	_g_free0 (_tmp16_);
}

TootleAPINotification*
tootle_widgets_notification_get_notification (TootleWidgetsNotification* self)
{
	TootleAPINotification* result;
	TootleAPINotification* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_notification;
	result = _tmp0_;
	return result;
}

void
tootle_widgets_notification_set_notification (TootleWidgetsNotification* self,
                                              TootleAPINotification* value)
{
	TootleAPINotification* old_value;
	g_return_if_fail (self != NULL);
	old_value = tootle_widgets_notification_get_notification (self);
	if (old_value != value) {
		TootleAPINotification* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_notification);
		self->priv->_notification = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tootle_widgets_notification_properties[TOOTLE_WIDGETS_NOTIFICATION_NOTIFICATION_PROPERTY]);
	}
}

static void
tootle_widgets_notification_class_init (TootleWidgetsNotificationClass * klass,
                                        gpointer klass_data)
{
	tootle_widgets_notification_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &TootleWidgetsNotification_private_offset);
	((TootleWidgetsStatusClass *) klass)->on_kind_changed = (void (*) (TootleWidgetsStatus*)) tootle_widgets_notification_real_on_kind_changed;
	G_OBJECT_CLASS (klass)->get_property = _vala_tootle_widgets_notification_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_tootle_widgets_notification_set_property;
	G_OBJECT_CLASS (klass)->finalize = tootle_widgets_notification_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), TOOTLE_WIDGETS_NOTIFICATION_NOTIFICATION_PROPERTY, tootle_widgets_notification_properties[TOOTLE_WIDGETS_NOTIFICATION_NOTIFICATION_PROPERTY] = g_param_spec_object ("notification", "notification", "notification", TOOTLE_API_TYPE_NOTIFICATION, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
}

static void
tootle_widgets_notification_instance_init (TootleWidgetsNotification * self,
                                           gpointer klass)
{
	self->priv = tootle_widgets_notification_get_instance_private (self);
}

static void
tootle_widgets_notification_finalize (GObject * obj)
{
	TootleWidgetsNotification * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TOOTLE_WIDGETS_TYPE_NOTIFICATION, TootleWidgetsNotification);
	_g_object_unref0 (self->priv->_notification);
	G_OBJECT_CLASS (tootle_widgets_notification_parent_class)->finalize (obj);
}

static GType
tootle_widgets_notification_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (TootleWidgetsNotificationClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) tootle_widgets_notification_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TootleWidgetsNotification), 0, (GInstanceInitFunc) tootle_widgets_notification_instance_init, NULL };
	GType tootle_widgets_notification_type_id;
	tootle_widgets_notification_type_id = g_type_register_static (TOOTLE_WIDGETS_TYPE_STATUS, "TootleWidgetsNotification", &g_define_type_info, 0);
	TootleWidgetsNotification_private_offset = g_type_add_instance_private (tootle_widgets_notification_type_id, sizeof (TootleWidgetsNotificationPrivate));
	return tootle_widgets_notification_type_id;
}

GType
tootle_widgets_notification_get_type (void)
{
	static volatile gsize tootle_widgets_notification_type_id__volatile = 0;
	if (g_once_init_enter (&tootle_widgets_notification_type_id__volatile)) {
		GType tootle_widgets_notification_type_id;
		tootle_widgets_notification_type_id = tootle_widgets_notification_get_type_once ();
		g_once_init_leave (&tootle_widgets_notification_type_id__volatile, tootle_widgets_notification_type_id);
	}
	return tootle_widgets_notification_type_id__volatile;
}

static void
_vala_tootle_widgets_notification_get_property (GObject * object,
                                                guint property_id,
                                                GValue * value,
                                                GParamSpec * pspec)
{
	TootleWidgetsNotification * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TOOTLE_WIDGETS_TYPE_NOTIFICATION, TootleWidgetsNotification);
	switch (property_id) {
		case TOOTLE_WIDGETS_NOTIFICATION_NOTIFICATION_PROPERTY:
		g_value_set_object (value, tootle_widgets_notification_get_notification (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_tootle_widgets_notification_set_property (GObject * object,
                                                guint property_id,
                                                const GValue * value,
                                                GParamSpec * pspec)
{
	TootleWidgetsNotification * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TOOTLE_WIDGETS_TYPE_NOTIFICATION, TootleWidgetsNotification);
	switch (property_id) {
		case TOOTLE_WIDGETS_NOTIFICATION_NOTIFICATION_PROPERTY:
		tootle_widgets_notification_set_notification (self, g_value_get_object (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static inline gpointer
_vala_memdup2 (gconstpointer mem,
               gsize byte_size)
{
	gpointer new_mem;
	if (mem && byte_size != 0) {
		new_mem = g_malloc (byte_size);
		memcpy (new_mem, mem, byte_size);
	} else {
		new_mem = NULL;
	}
	return new_mem;
}

