/* auth-notification.c generated by valac 0.39.5, the Vala compiler
 * generated from auth-notification.vala, do not modify */

/* This file is part of GNOME Boxes. License: LGPLv2+*/

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


#define BOXES_TYPE_AUTH_NOTIFICATION (boxes_auth_notification_get_type ())
#define BOXES_AUTH_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), BOXES_TYPE_AUTH_NOTIFICATION, BoxesAuthNotification))
#define BOXES_AUTH_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), BOXES_TYPE_AUTH_NOTIFICATION, BoxesAuthNotificationClass))
#define BOXES_IS_AUTH_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), BOXES_TYPE_AUTH_NOTIFICATION))
#define BOXES_IS_AUTH_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), BOXES_TYPE_AUTH_NOTIFICATION))
#define BOXES_AUTH_NOTIFICATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), BOXES_TYPE_AUTH_NOTIFICATION, BoxesAuthNotificationClass))

typedef struct _BoxesAuthNotification BoxesAuthNotification;
typedef struct _BoxesAuthNotificationClass BoxesAuthNotificationClass;
typedef struct _BoxesAuthNotificationPrivate BoxesAuthNotificationPrivate;

#define BOXES_TYPE_SEARCHBAR (boxes_searchbar_get_type ())
#define BOXES_SEARCHBAR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), BOXES_TYPE_SEARCHBAR, BoxesSearchbar))
#define BOXES_SEARCHBAR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), BOXES_TYPE_SEARCHBAR, BoxesSearchbarClass))
#define BOXES_IS_SEARCHBAR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), BOXES_TYPE_SEARCHBAR))
#define BOXES_IS_SEARCHBAR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), BOXES_TYPE_SEARCHBAR))
#define BOXES_SEARCHBAR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), BOXES_TYPE_SEARCHBAR, BoxesSearchbarClass))

typedef struct _BoxesSearchbar BoxesSearchbar;
typedef struct _BoxesSearchbarClass BoxesSearchbarClass;
enum  {
	BOXES_AUTH_NOTIFICATION_0_PROPERTY,
	BOXES_AUTH_NOTIFICATION_NUM_PROPERTIES
};
static GParamSpec* boxes_auth_notification_properties[BOXES_AUTH_NOTIFICATION_NUM_PROPERTIES];
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
typedef struct _Block18Data Block18Data;
enum  {
	BOXES_AUTH_NOTIFICATION_DISMISSED_SIGNAL,
	BOXES_AUTH_NOTIFICATION_NUM_SIGNALS
};
static guint boxes_auth_notification_signals[BOXES_AUTH_NOTIFICATION_NUM_SIGNALS] = {0};

struct _BoxesAuthNotification {
	GtkRevealer parent_instance;
	BoxesAuthNotificationPrivate * priv;
};

struct _BoxesAuthNotificationClass {
	GtkRevealerClass parent_class;
};

typedef void (*BoxesAuthNotificationAuthFunc) (const gchar* username, const gchar* password, void* user_data);
struct _BoxesAuthNotificationPrivate {
	GtkLabel* title_label;
	GtkLabel* username_label;
	GtkEntry* username_entry;
	GtkEntry* password_entry;
	GtkButton* auth_button;
	BoxesAuthNotificationAuthFunc auth_func;
	gpointer auth_func_target;
	GDestroyNotify auth_func_target_destroy_notify;
	gboolean auth_pressed;
	BoxesSearchbar* searchbar;
};

typedef void (*BoxesNotificationDismissFunc) (void* user_data);
struct _Block18Data {
	int _ref_count_;
	BoxesAuthNotification* self;
	BoxesNotificationDismissFunc dismiss_func;
	gpointer dismiss_func_target;
	GDestroyNotify dismiss_func_target_destroy_notify;
};


static gpointer boxes_auth_notification_parent_class = NULL;

GType boxes_auth_notification_get_type (void) G_GNUC_CONST;
GType boxes_searchbar_get_type (void) G_GNUC_CONST;
#define BOXES_AUTH_NOTIFICATION_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), BOXES_TYPE_AUTH_NOTIFICATION, BoxesAuthNotificationPrivate))
BoxesAuthNotification* boxes_auth_notification_new (const gchar* auth_string,
                                                    BoxesAuthNotificationAuthFunc auth_func,
                                                    void* auth_func_target,
                                                    GDestroyNotify auth_func_target_destroy_notify,
                                                    BoxesNotificationDismissFunc dismiss_func,
                                                    void* dismiss_func_target,
                                                    GDestroyNotify dismiss_func_target_destroy_notify,
                                                    gboolean need_username,
                                                    BoxesSearchbar* searchbar);
BoxesAuthNotification* boxes_auth_notification_construct (GType object_type,
                                                          const gchar* auth_string,
                                                          BoxesAuthNotificationAuthFunc auth_func,
                                                          void* auth_func_target,
                                                          GDestroyNotify auth_func_target_destroy_notify,
                                                          BoxesNotificationDismissFunc dismiss_func,
                                                          void* dismiss_func_target,
                                                          GDestroyNotify dismiss_func_target_destroy_notify,
                                                          gboolean need_username,
                                                          BoxesSearchbar* searchbar);
static Block18Data* block18_data_ref (Block18Data* _data18_);
static void block18_data_unref (void * _userdata_);
static void __lambda49_ (Block18Data* _data18_);
static void ___lambda49__boxes_auth_notification_dismissed (BoxesAuthNotification* _sender,
                                                     gpointer self);
static gboolean boxes_auth_notification_on_entry_focus_in_event (BoxesAuthNotification* self);
void boxes_searchbar_set_enable_key_handler (BoxesSearchbar* self,
                                             gboolean value);
static gboolean _boxes_auth_notification_on_entry_focus_in_event_gtk_widget_focus_in_event (GtkWidget* _sender,
                                                                                     GdkEventFocus* event,
                                                                                     gpointer self);
static gboolean boxes_auth_notification_on_entry_focus_out_event (BoxesAuthNotification* self);
static gboolean _boxes_auth_notification_on_entry_focus_out_event_gtk_widget_focus_out_event (GtkWidget* _sender,
                                                                                       GdkEventFocus* event,
                                                                                       gpointer self);
static void boxes_auth_notification_on_username_entry_map (BoxesAuthNotification* self);
static void _boxes_auth_notification_on_username_entry_map_gtk_widget_map (GtkWidget* _sender,
                                                                    gpointer self);
static void boxes_auth_notification_on_username_entry_activated (BoxesAuthNotification* self);
static void _boxes_auth_notification_on_username_entry_activated_gtk_entry_activate (GtkEntry* _sender,
                                                                              gpointer self);
static void boxes_auth_notification_on_password_entry_activated (BoxesAuthNotification* self);
static void _boxes_auth_notification_on_password_entry_activated_gtk_entry_activate (GtkEntry* _sender,
                                                                              gpointer self);
static void boxes_auth_notification_on_auth_button_clicked (BoxesAuthNotification* self);
void boxes_auth_notification_dismiss (BoxesAuthNotification* self);
static void _boxes_auth_notification_on_auth_button_clicked_gtk_button_clicked (GtkButton* _sender,
                                                                         gpointer self);
static void boxes_auth_notification_finalize (GObject * obj);


static Block18Data*
block18_data_ref (Block18Data* _data18_)
{
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_atomic_int_inc (&_data18_->_ref_count_);
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	return _data18_;
#line 143 "auth-notification.c"
}


static void
block18_data_unref (void * _userdata_)
{
	Block18Data* _data18_;
	_data18_ = (Block18Data*) _userdata_;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	if (g_atomic_int_dec_and_test (&_data18_->_ref_count_)) {
#line 154 "auth-notification.c"
		BoxesAuthNotification* self;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		self = _data18_->self;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		(_data18_->dismiss_func_target_destroy_notify == NULL) ? NULL : (_data18_->dismiss_func_target_destroy_notify (_data18_->dismiss_func_target), NULL);
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_data18_->dismiss_func = NULL;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_data18_->dismiss_func_target = NULL;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_data18_->dismiss_func_target_destroy_notify = NULL;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_g_object_unref0 (self);
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		g_slice_free (Block18Data, _data18_);
#line 170 "auth-notification.c"
	}
}


static void
__lambda49_ (Block18Data* _data18_)
{
	BoxesAuthNotification* self;
	gboolean _tmp0_ = FALSE;
	gboolean _tmp1_;
#line 39 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self = _data18_->self;
#line 40 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp1_ = self->priv->auth_pressed;
#line 40 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	if (!_tmp1_) {
#line 40 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_tmp0_ = _data18_->dismiss_func != NULL;
#line 189 "auth-notification.c"
	} else {
#line 40 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_tmp0_ = FALSE;
#line 193 "auth-notification.c"
	}
#line 40 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	if (_tmp0_) {
#line 41 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_data18_->dismiss_func (_data18_->dismiss_func_target);
#line 199 "auth-notification.c"
	}
}


static void
___lambda49__boxes_auth_notification_dismissed (BoxesAuthNotification* _sender,
                                                gpointer self)
{
#line 39 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	__lambda49_ (self);
#line 210 "auth-notification.c"
}


static gpointer
_g_object_ref0 (gpointer self)
{
#line 49 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	return self ? g_object_ref (self) : NULL;
#line 219 "auth-notification.c"
}


BoxesAuthNotification*
boxes_auth_notification_construct (GType object_type,
                                   const gchar* auth_string,
                                   BoxesAuthNotificationAuthFunc auth_func,
                                   void* auth_func_target,
                                   GDestroyNotify auth_func_target_destroy_notify,
                                   BoxesNotificationDismissFunc dismiss_func,
                                   void* dismiss_func_target,
                                   GDestroyNotify dismiss_func_target_destroy_notify,
                                   gboolean need_username,
                                   BoxesSearchbar* searchbar)
{
	BoxesAuthNotification * self = NULL;
	Block18Data* _data18_;
	GtkLabel* _tmp0_;
	GtkLabel* _tmp1_;
	GtkEntry* _tmp2_;
	BoxesAuthNotificationAuthFunc _tmp3_;
	void* _tmp3__target;
	GDestroyNotify _tmp3__target_destroy_notify;
	BoxesSearchbar* _tmp4_;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_return_val_if_fail (auth_string != NULL, NULL);
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_return_val_if_fail (searchbar != NULL, NULL);
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_data18_ = g_slice_new0 (Block18Data);
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_data18_->_ref_count_ = 1;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	(_data18_->dismiss_func_target_destroy_notify == NULL) ? NULL : (_data18_->dismiss_func_target_destroy_notify (_data18_->dismiss_func_target), NULL);
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_data18_->dismiss_func = NULL;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_data18_->dismiss_func_target = NULL;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_data18_->dismiss_func_target_destroy_notify = NULL;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_data18_->dismiss_func = dismiss_func;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_data18_->dismiss_func_target = dismiss_func_target;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_data18_->dismiss_func_target_destroy_notify = dismiss_func_target_destroy_notify;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self = (BoxesAuthNotification*) g_object_new (object_type, NULL);
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_data18_->self = g_object_ref (self);
#line 35 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_revealer_set_reveal_child ((GtkRevealer*) self, TRUE);
#line 37 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp0_ = self->priv->title_label;
#line 37 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_label_set_label (_tmp0_, auth_string);
#line 39 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_signal_connect_data (self, "dismissed", (GCallback) ___lambda49__boxes_auth_notification_dismissed, block18_data_ref (_data18_), (GClosureNotify) block18_data_unref, 0);
#line 44 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp1_ = self->priv->username_label;
#line 44 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_set_visible ((GtkWidget*) _tmp1_, need_username);
#line 45 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp2_ = self->priv->username_entry;
#line 45 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_set_visible ((GtkWidget*) _tmp2_, need_username);
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp3_ = auth_func;
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp3__target = auth_func_target;
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp3__target_destroy_notify = auth_func_target_destroy_notify;
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	auth_func = NULL;
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	auth_func_target = NULL;
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	auth_func_target_destroy_notify = NULL;
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	(self->priv->auth_func_target_destroy_notify == NULL) ? NULL : (self->priv->auth_func_target_destroy_notify (self->priv->auth_func_target), NULL);
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv->auth_func = NULL;
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv->auth_func_target = NULL;
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv->auth_func_target_destroy_notify = NULL;
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv->auth_func = _tmp3_;
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv->auth_func_target = _tmp3__target;
#line 47 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv->auth_func_target_destroy_notify = _tmp3__target_destroy_notify;
#line 49 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp4_ = _g_object_ref0 (searchbar);
#line 49 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_g_object_unref0 (self->priv->searchbar);
#line 49 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv->searchbar = _tmp4_;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	(auth_func_target_destroy_notify == NULL) ? NULL : (auth_func_target_destroy_notify (auth_func_target), NULL);
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	auth_func = NULL;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	auth_func_target = NULL;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	auth_func_target_destroy_notify = NULL;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	block18_data_unref (_data18_);
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_data18_ = NULL;
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	return self;
#line 332 "auth-notification.c"
}


BoxesAuthNotification*
boxes_auth_notification_new (const gchar* auth_string,
                             BoxesAuthNotificationAuthFunc auth_func,
                             void* auth_func_target,
                             GDestroyNotify auth_func_target_destroy_notify,
                             BoxesNotificationDismissFunc dismiss_func,
                             void* dismiss_func_target,
                             GDestroyNotify dismiss_func_target_destroy_notify,
                             gboolean need_username,
                             BoxesSearchbar* searchbar)
{
#line 26 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	return boxes_auth_notification_construct (BOXES_TYPE_AUTH_NOTIFICATION, auth_string, auth_func, auth_func_target, auth_func_target_destroy_notify, dismiss_func, dismiss_func_target, dismiss_func_target_destroy_notify, need_username, searchbar);
#line 349 "auth-notification.c"
}


static gboolean
boxes_auth_notification_on_entry_focus_in_event (BoxesAuthNotification* self)
{
	gboolean result = FALSE;
	BoxesSearchbar* _tmp0_;
#line 53 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 54 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp0_ = self->priv->searchbar;
#line 54 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	boxes_searchbar_set_enable_key_handler (_tmp0_, FALSE);
#line 56 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	result = FALSE;
#line 56 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	return result;
#line 368 "auth-notification.c"
}


static gboolean
_boxes_auth_notification_on_entry_focus_in_event_gtk_widget_focus_in_event (GtkWidget* _sender,
                                                                            GdkEventFocus* event,
                                                                            gpointer self)
{
	gboolean result;
	result = boxes_auth_notification_on_entry_focus_in_event ((BoxesAuthNotification*) self);
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	return result;
#line 381 "auth-notification.c"
}


static gboolean
boxes_auth_notification_on_entry_focus_out_event (BoxesAuthNotification* self)
{
	gboolean result = FALSE;
	BoxesSearchbar* _tmp0_;
#line 60 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 61 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp0_ = self->priv->searchbar;
#line 61 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	boxes_searchbar_set_enable_key_handler (_tmp0_, TRUE);
#line 63 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	result = FALSE;
#line 63 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	return result;
#line 400 "auth-notification.c"
}


static gboolean
_boxes_auth_notification_on_entry_focus_out_event_gtk_widget_focus_out_event (GtkWidget* _sender,
                                                                              GdkEventFocus* event,
                                                                              gpointer self)
{
	gboolean result;
	result = boxes_auth_notification_on_entry_focus_out_event ((BoxesAuthNotification*) self);
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	return result;
#line 413 "auth-notification.c"
}


static void
boxes_auth_notification_on_username_entry_map (BoxesAuthNotification* self)
{
	GtkEntry* _tmp0_;
#line 67 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_return_if_fail (self != NULL);
#line 68 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp0_ = self->priv->username_entry;
#line 68 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_grab_focus ((GtkWidget*) _tmp0_);
#line 427 "auth-notification.c"
}


static void
_boxes_auth_notification_on_username_entry_map_gtk_widget_map (GtkWidget* _sender,
                                                               gpointer self)
{
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	boxes_auth_notification_on_username_entry_map ((BoxesAuthNotification*) self);
#line 437 "auth-notification.c"
}


static void
boxes_auth_notification_on_username_entry_activated (BoxesAuthNotification* self)
{
	GtkEntry* _tmp0_;
#line 72 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_return_if_fail (self != NULL);
#line 73 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp0_ = self->priv->password_entry;
#line 73 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_grab_focus ((GtkWidget*) _tmp0_);
#line 451 "auth-notification.c"
}


static void
_boxes_auth_notification_on_username_entry_activated_gtk_entry_activate (GtkEntry* _sender,
                                                                         gpointer self)
{
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	boxes_auth_notification_on_username_entry_activated ((BoxesAuthNotification*) self);
#line 461 "auth-notification.c"
}


static void
boxes_auth_notification_on_password_entry_activated (BoxesAuthNotification* self)
{
	GtkButton* _tmp0_;
#line 77 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_return_if_fail (self != NULL);
#line 78 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp0_ = self->priv->auth_button;
#line 78 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_signal_emit_by_name (_tmp0_, "activate");
#line 475 "auth-notification.c"
}


static void
_boxes_auth_notification_on_password_entry_activated_gtk_entry_activate (GtkEntry* _sender,
                                                                         gpointer self)
{
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	boxes_auth_notification_on_password_entry_activated ((BoxesAuthNotification*) self);
#line 485 "auth-notification.c"
}


static void
boxes_auth_notification_on_auth_button_clicked (BoxesAuthNotification* self)
{
	BoxesAuthNotificationAuthFunc _tmp0_;
	void* _tmp0__target;
#line 82 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_return_if_fail (self != NULL);
#line 83 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp0_ = self->priv->auth_func;
#line 83 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_tmp0__target = self->priv->auth_func_target;
#line 83 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	if (_tmp0_ != NULL) {
#line 502 "auth-notification.c"
		BoxesAuthNotificationAuthFunc _tmp1_;
		void* _tmp1__target;
		GtkEntry* _tmp2_;
		const gchar* _tmp3_;
		GtkEntry* _tmp4_;
		const gchar* _tmp5_;
#line 84 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_tmp1_ = self->priv->auth_func;
#line 84 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_tmp1__target = self->priv->auth_func_target;
#line 84 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_tmp2_ = self->priv->username_entry;
#line 84 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_tmp3_ = gtk_entry_get_text (_tmp2_);
#line 84 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_tmp4_ = self->priv->password_entry;
#line 84 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_tmp5_ = gtk_entry_get_text (_tmp4_);
#line 84 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
		_tmp1_ (_tmp3_, _tmp5_, _tmp1__target);
#line 523 "auth-notification.c"
	}
#line 85 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv->auth_pressed = TRUE;
#line 87 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	boxes_auth_notification_dismiss (self);
#line 529 "auth-notification.c"
}


static void
_boxes_auth_notification_on_auth_button_clicked_gtk_button_clicked (GtkButton* _sender,
                                                                    gpointer self)
{
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	boxes_auth_notification_on_auth_button_clicked ((BoxesAuthNotification*) self);
#line 539 "auth-notification.c"
}


void
boxes_auth_notification_dismiss (BoxesAuthNotification* self)
{
#line 90 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_return_if_fail (self != NULL);
#line 91 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_revealer_set_reveal_child ((GtkRevealer*) self, FALSE);
#line 92 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_signal_emit (self, boxes_auth_notification_signals[BOXES_AUTH_NOTIFICATION_DISMISSED_SIGNAL], 0);
#line 552 "auth-notification.c"
}


static void
boxes_auth_notification_class_init (BoxesAuthNotificationClass * klass)
{
	gint BoxesAuthNotification_private_offset;
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	boxes_auth_notification_parent_class = g_type_class_peek_parent (klass);
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	g_type_class_add_private (klass, sizeof (BoxesAuthNotificationPrivate));
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	G_OBJECT_CLASS (klass)->finalize = boxes_auth_notification_finalize;
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	BoxesAuthNotification_private_offset = g_type_class_get_instance_private_offset (klass);
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (klass), "/org/gnome/Boxes/ui/auth-notification.ui");
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	boxes_auth_notification_signals[BOXES_AUTH_NOTIFICATION_DISMISSED_SIGNAL] = g_signal_new ("dismissed", BOXES_TYPE_AUTH_NOTIFICATION, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "title_label", FALSE, BoxesAuthNotification_private_offset + G_STRUCT_OFFSET (BoxesAuthNotificationPrivate, title_label));
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "username_label", FALSE, BoxesAuthNotification_private_offset + G_STRUCT_OFFSET (BoxesAuthNotificationPrivate, username_label));
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "username_entry", FALSE, BoxesAuthNotification_private_offset + G_STRUCT_OFFSET (BoxesAuthNotificationPrivate, username_entry));
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "password_entry", FALSE, BoxesAuthNotification_private_offset + G_STRUCT_OFFSET (BoxesAuthNotificationPrivate, password_entry));
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "auth_button", FALSE, BoxesAuthNotification_private_offset + G_STRUCT_OFFSET (BoxesAuthNotificationPrivate, auth_button));
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "on_entry_focus_in_event", G_CALLBACK(_boxes_auth_notification_on_entry_focus_in_event_gtk_widget_focus_in_event));
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "on_entry_focus_out_event", G_CALLBACK(_boxes_auth_notification_on_entry_focus_out_event_gtk_widget_focus_out_event));
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "on_username_entry_map", G_CALLBACK(_boxes_auth_notification_on_username_entry_map_gtk_widget_map));
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "on_username_entry_activated", G_CALLBACK(_boxes_auth_notification_on_username_entry_activated_gtk_entry_activate));
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "on_password_entry_activated", G_CALLBACK(_boxes_auth_notification_on_password_entry_activated_gtk_entry_activate));
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "on_auth_button_clicked", G_CALLBACK(_boxes_auth_notification_on_auth_button_clicked_gtk_button_clicked));
#line 594 "auth-notification.c"
}


static void
boxes_auth_notification_instance_init (BoxesAuthNotification * self)
{
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv = BOXES_AUTH_NOTIFICATION_GET_PRIVATE (self);
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	gtk_widget_init_template (GTK_WIDGET (self));
#line 605 "auth-notification.c"
}


static void
boxes_auth_notification_finalize (GObject * obj)
{
	BoxesAuthNotification * self;
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, BOXES_TYPE_AUTH_NOTIFICATION, BoxesAuthNotification);
#line 11 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_g_object_unref0 (self->priv->title_label);
#line 13 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_g_object_unref0 (self->priv->username_label);
#line 15 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_g_object_unref0 (self->priv->username_entry);
#line 17 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_g_object_unref0 (self->priv->password_entry);
#line 19 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_g_object_unref0 (self->priv->auth_button);
#line 21 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	(self->priv->auth_func_target_destroy_notify == NULL) ? NULL : (self->priv->auth_func_target_destroy_notify (self->priv->auth_func_target), NULL);
#line 21 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv->auth_func = NULL;
#line 21 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv->auth_func_target = NULL;
#line 21 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	self->priv->auth_func_target_destroy_notify = NULL;
#line 24 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	_g_object_unref0 (self->priv->searchbar);
#line 5 "/home/fborges/checkout/gnome-boxes/src/auth-notification.vala"
	G_OBJECT_CLASS (boxes_auth_notification_parent_class)->finalize (obj);
#line 637 "auth-notification.c"
}


GType
boxes_auth_notification_get_type (void)
{
	static volatile gsize boxes_auth_notification_type_id__volatile = 0;
	if (g_once_init_enter (&boxes_auth_notification_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (BoxesAuthNotificationClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) boxes_auth_notification_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (BoxesAuthNotification), 0, (GInstanceInitFunc) boxes_auth_notification_instance_init, NULL };
		GType boxes_auth_notification_type_id;
		boxes_auth_notification_type_id = g_type_register_static (gtk_revealer_get_type (), "BoxesAuthNotification", &g_define_type_info, 0);
		g_once_init_leave (&boxes_auth_notification_type_id__volatile, boxes_auth_notification_type_id);
	}
	return boxes_auth_notification_type_id__volatile;
}



