/* moonshot-warning-dialog.c generated by valac 0.34.9, the Vala compiler
 * generated from moonshot-warning-dialog.vala, do not modify */

/*
 * Copyright (c) 2011-2016, JANET(UK)
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions
 * are met:
 *
 * 1. Redistributions of source code must retain the above copyright
 *    notice, this list of conditions and the following disclaimer.
 *
 * 2. Redistributions in binary form must reproduce the above copyright
 *    notice, this list of conditions and the following disclaimer in the
 *    documentation and/or other materials provided with the distribution.
 *
 * 3. Neither the name of JANET(UK) nor the names of its contributors
 *    may be used to endorse or promote products derived from this software
 *    without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 * SUCH DAMAGE.
*/

#include <glib.h>
#include <glib-object.h>
#include <stdlib.h>
#include <string.h>
#include <gtk/gtk.h>
#include <gdk/gdk.h>
#include <glib/gi18n-lib.h>
#include <gobject/gvaluecollector.h>


#define TYPE_WARNING_DIALOG (warning_dialog_get_type ())
#define WARNING_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_WARNING_DIALOG, WarningDialog))
#define WARNING_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_WARNING_DIALOG, WarningDialogClass))
#define IS_WARNING_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_WARNING_DIALOG))
#define IS_WARNING_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_WARNING_DIALOG))
#define WARNING_DIALOG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_WARNING_DIALOG, WarningDialogClass))

typedef struct _WarningDialog WarningDialog;
typedef struct _WarningDialogClass WarningDialogClass;
typedef struct _WarningDialogPrivate WarningDialogPrivate;

#define TYPE_MOONSHOT_LOGGER (moonshot_logger_get_type ())
#define MOONSHOT_LOGGER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_MOONSHOT_LOGGER, MoonshotLogger))
#define MOONSHOT_LOGGER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_MOONSHOT_LOGGER, MoonshotLoggerClass))
#define IS_MOONSHOT_LOGGER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_MOONSHOT_LOGGER))
#define IS_MOONSHOT_LOGGER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_MOONSHOT_LOGGER))
#define MOONSHOT_LOGGER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_MOONSHOT_LOGGER, MoonshotLoggerClass))

typedef struct _MoonshotLogger MoonshotLogger;
typedef struct _MoonshotLoggerClass MoonshotLoggerClass;
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _g_free0(var) (var = (g_free (var), NULL))
typedef struct _ParamSpecWarningDialog ParamSpecWarningDialog;

struct _WarningDialog {
	GTypeInstance parent_instance;
	volatile int ref_count;
	WarningDialogPrivate * priv;
};

struct _WarningDialogClass {
	GTypeClass parent_class;
	void (*finalize) (WarningDialog *self);
};

struct _ParamSpecWarningDialog {
	GParamSpec parent_instance;
};


static gpointer warning_dialog_parent_class = NULL;
static MoonshotLogger* warning_dialog__logger;
static MoonshotLogger* warning_dialog__logger = NULL;

#define GROUP_NAME "WarningDialogs"
gpointer warning_dialog_ref (gpointer instance);
void warning_dialog_unref (gpointer instance);
GParamSpec* param_spec_warning_dialog (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_warning_dialog (GValue* value, gpointer v_object);
void value_take_warning_dialog (GValue* value, gpointer v_object);
gpointer value_get_warning_dialog (const GValue* value);
GType warning_dialog_get_type (void) G_GNUC_CONST;
enum  {
	WARNING_DIALOG_DUMMY_PROPERTY
};
GType moonshot_logger_get_type (void) G_GNUC_CONST;
static MoonshotLogger* warning_dialog_logger (void);
MoonshotLogger* get_logger (const gchar* name);
gboolean warning_dialog_confirm (GtkWindow* parent, const gchar* message, const gchar* dialog_name);
gboolean get_bool_setting (const gchar* group_name, const gchar* key_name, gboolean _default_, GKeyFile* key_file);
void moonshot_logger_trace (MoonshotLogger* self, const gchar* message, GError* e);
void make_color (guint16 red, guint16 green, guint16 blue, GdkColor* result);
void set_bg_color (GtkWidget* w);
void set_bool_setting (const gchar* group_name, const gchar* key_name, gboolean value, GKeyFile* key_file);
WarningDialog* warning_dialog_new (void);
WarningDialog* warning_dialog_construct (GType object_type);
static void warning_dialog_finalize (WarningDialog* obj);


static gpointer _g_object_ref0 (gpointer self) {
#line 46 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	return self ? g_object_ref (self) : NULL;
#line 119 "moonshot-warning-dialog.c"
}


static MoonshotLogger* warning_dialog_logger (void) {
	MoonshotLogger* result = NULL;
	MoonshotLogger* _tmp0_ = NULL;
	MoonshotLogger* _tmp2_ = NULL;
	MoonshotLogger* _tmp3_ = NULL;
#line 43 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp0_ = warning_dialog__logger;
#line 43 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (_tmp0_ == NULL) {
#line 132 "moonshot-warning-dialog.c"
		MoonshotLogger* _tmp1_ = NULL;
#line 44 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp1_ = get_logger ("WarningDialog");
#line 44 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_g_object_unref0 (warning_dialog__logger);
#line 44 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		warning_dialog__logger = _tmp1_;
#line 140 "moonshot-warning-dialog.c"
	}
#line 46 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp2_ = warning_dialog__logger;
#line 46 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp3_ = _g_object_ref0 (_tmp2_);
#line 46 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	result = _tmp3_;
#line 46 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	return result;
#line 150 "moonshot-warning-dialog.c"
}


static const gchar* string_to_string (const gchar* self) {
	const gchar* result = NULL;
#line 1420 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, NULL);
#line 1421 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	result = self;
#line 1421 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	return result;
#line 162 "moonshot-warning-dialog.c"
}


gboolean warning_dialog_confirm (GtkWindow* parent, const gchar* message, const gchar* dialog_name) {
	gboolean result = FALSE;
	const gchar* _tmp0_ = NULL;
	gboolean _tmp1_ = FALSE;
	GdkColor white = {0};
	GdkColor _tmp9_ = {0};
	GtkMessageDialog* dialog = NULL;
	GtkWindow* _tmp10_ = NULL;
	GtkMessageDialog* _tmp11_ = NULL;
	GtkWidget* content_area = NULL;
	GtkMessageDialog* _tmp12_ = NULL;
	GtkWidget* _tmp13_ = NULL;
	GtkWidget* _tmp14_ = NULL;
	GtkCheckButton* remember_checkbutton = NULL;
	gboolean _tmp15_ = FALSE;
	const gchar* _tmp16_ = NULL;
	GtkMessageDialog* _tmp34_ = NULL;
	const gchar* _tmp35_ = NULL;
	GtkMessageDialog* _tmp36_ = NULL;
	GtkWidget* _tmp37_ = NULL;
	GtkWidget* _tmp38_ = NULL;
	GtkMessageDialog* _tmp39_ = NULL;
	const gchar* _tmp40_ = NULL;
	gint ret = 0;
	GtkMessageDialog* _tmp41_ = NULL;
	gint _tmp42_ = 0;
	gboolean _tmp43_ = FALSE;
	gboolean _tmp44_ = FALSE;
	gint _tmp45_ = 0;
	GtkMessageDialog* _tmp51_ = NULL;
	gint _tmp52_ = 0;
#line 49 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	g_return_val_if_fail (parent != NULL, FALSE);
#line 49 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	g_return_val_if_fail (message != NULL, FALSE);
#line 49 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	g_return_val_if_fail (dialog_name != NULL, FALSE);
#line 52 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp0_ = dialog_name;
#line 52 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp1_ = get_bool_setting (GROUP_NAME, _tmp0_, FALSE, NULL);
#line 52 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (_tmp1_) {
#line 209 "moonshot-warning-dialog.c"
		MoonshotLogger* _tmp2_ = NULL;
		MoonshotLogger* _tmp3_ = NULL;
		const gchar* _tmp4_ = NULL;
		const gchar* _tmp5_ = NULL;
		const gchar* _tmp6_ = NULL;
		gchar* _tmp7_ = NULL;
		gchar* _tmp8_ = NULL;
#line 54 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp2_ = warning_dialog_logger ();
#line 54 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp3_ = _tmp2_;
#line 54 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp4_ = string_to_string (GROUP_NAME);
#line 54 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp5_ = dialog_name;
#line 54 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp6_ = string_to_string (_tmp5_);
#line 54 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp7_ = g_strconcat ("confirm: Settings group ", _tmp4_, " has 'true' for key ", _tmp6_, "; skipping dialog and returning true.", NULL);
#line 54 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp8_ = _tmp7_;
#line 54 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		moonshot_logger_trace (_tmp3_, _tmp8_, NULL);
#line 54 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_g_free0 (_tmp8_);
#line 54 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_g_object_unref0 (_tmp3_);
#line 55 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		result = TRUE;
#line 55 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		return result;
#line 241 "moonshot-warning-dialog.c"
	}
#line 58 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	make_color ((guint16) 65535, (guint16) 65535, (guint16) 65535, &_tmp9_);
#line 58 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	white = _tmp9_;
#line 60 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp10_ = parent;
#line 60 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp11_ = (GtkMessageDialog*) gtk_message_dialog_new (_tmp10_, GTK_DIALOG_DESTROY_WITH_PARENT, GTK_MESSAGE_WARNING, GTK_BUTTONS_YES_NO, "%s", "");
#line 60 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	g_object_ref_sink (_tmp11_);
#line 60 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	dialog = _tmp11_;
#line 66 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp12_ = dialog;
#line 66 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp13_ = gtk_dialog_get_content_area ((GtkDialog*) _tmp12_);
#line 66 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp14_ = _g_object_ref0 (_tmp13_);
#line 66 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	content_area = _tmp14_;
#line 67 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	remember_checkbutton = NULL;
#line 69 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp16_ = dialog_name;
#line 69 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (_tmp16_ != NULL) {
#line 269 "moonshot-warning-dialog.c"
		const gchar* _tmp17_ = NULL;
#line 69 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp17_ = dialog_name;
#line 69 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp15_ = g_strcmp0 (_tmp17_, "") != 0;
#line 275 "moonshot-warning-dialog.c"
	} else {
#line 69 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp15_ = FALSE;
#line 279 "moonshot-warning-dialog.c"
	}
#line 69 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (_tmp15_) {
#line 283 "moonshot-warning-dialog.c"
		const gchar* _tmp18_ = NULL;
		GtkCheckButton* _tmp19_ = NULL;
		GtkCheckButton* _tmp20_ = NULL;
		GtkContainer* action_area = NULL;
		GtkMessageDialog* _tmp21_ = NULL;
		GtkWidget* _tmp22_ = NULL;
		GtkContainer* _tmp23_ = NULL;
		GtkButton* yes_button = NULL;
		GtkMessageDialog* _tmp24_ = NULL;
		GtkWidget* _tmp25_ = NULL;
		GtkButton* _tmp26_ = NULL;
		GtkButton* _tmp27_ = NULL;
		GtkButton* _tmp28_ = NULL;
		GtkWidget* message_area = NULL;
		GtkMessageDialog* _tmp29_ = NULL;
		GtkWidget* _tmp30_ = NULL;
		GtkWidget* _tmp31_ = NULL;
		GtkWidget* _tmp32_ = NULL;
		GtkCheckButton* _tmp33_ = NULL;
#line 71 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp18_ = _ ("Do not show this message again");
#line 71 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp19_ = (GtkCheckButton*) gtk_check_button_new_with_label (_tmp18_);
#line 71 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		g_object_ref_sink (_tmp19_);
#line 71 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_g_object_unref0 (remember_checkbutton);
#line 71 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		remember_checkbutton = _tmp19_;
#line 75 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp20_ = remember_checkbutton;
#line 75 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		gtk_widget_set_receives_default ((GtkWidget*) _tmp20_, FALSE);
#line 76 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp21_ = dialog;
#line 76 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp22_ = gtk_dialog_get_action_area ((GtkDialog*) _tmp21_);
#line 76 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp23_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_CAST (_tmp22_, GTK_TYPE_CONTAINER, GtkContainer));
#line 76 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		action_area = _tmp23_;
#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp24_ = dialog;
#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp25_ = gtk_dialog_get_widget_for_response ((GtkDialog*) _tmp24_, (gint) GTK_RESPONSE_YES);
#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp26_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_CAST (_tmp25_, GTK_TYPE_BUTTON, GtkButton));
#line 78 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		yes_button = _tmp26_;
#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp27_ = yes_button;
#line 79 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		gtk_widget_grab_default ((GtkWidget*) _tmp27_);
#line 80 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp28_ = yes_button;
#line 80 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		gtk_widget_grab_focus ((GtkWidget*) _tmp28_);
#line 84 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp29_ = dialog;
#line 84 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp30_ = gtk_message_dialog_get_message_area (_tmp29_);
#line 84 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp31_ = _g_object_ref0 (_tmp30_);
#line 84 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		message_area = _tmp31_;
#line 85 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp32_ = message_area;
#line 85 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp33_ = remember_checkbutton;
#line 85 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		gtk_box_pack_start (G_TYPE_CHECK_INSTANCE_CAST (_tmp32_, GTK_TYPE_BOX, GtkBox), (GtkWidget*) _tmp33_, FALSE, FALSE, (guint) 12);
#line 69 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_g_object_unref0 (message_area);
#line 69 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_g_object_unref0 (yes_button);
#line 69 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_g_object_unref0 (action_area);
#line 361 "moonshot-warning-dialog.c"
	}
#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp34_ = dialog;
#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp35_ = _ ("Warning");
#line 95 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	gtk_window_set_title ((GtkWindow*) _tmp34_, _tmp35_);
#line 96 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp36_ = dialog;
#line 96 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	set_bg_color ((GtkWidget*) _tmp36_);
#line 99 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp37_ = content_area;
#line 99 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	set_bg_color (_tmp37_);
#line 101 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp38_ = content_area;
#line 101 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	gtk_widget_show_all (_tmp38_);
#line 103 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp39_ = dialog;
#line 103 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp40_ = message;
#line 103 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	gtk_message_dialog_set_markup (_tmp39_, _tmp40_);
#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp41_ = dialog;
#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp42_ = gtk_dialog_run ((GtkDialog*) _tmp41_);
#line 105 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	ret = _tmp42_;
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp45_ = ret;
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (_tmp45_ == ((gint) GTK_RESPONSE_YES)) {
#line 397 "moonshot-warning-dialog.c"
		GtkCheckButton* _tmp46_ = NULL;
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp46_ = remember_checkbutton;
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp44_ = _tmp46_ != NULL;
#line 403 "moonshot-warning-dialog.c"
	} else {
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp44_ = FALSE;
#line 407 "moonshot-warning-dialog.c"
	}
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (_tmp44_) {
#line 411 "moonshot-warning-dialog.c"
		GtkCheckButton* _tmp47_ = NULL;
		gboolean _tmp48_ = FALSE;
		gboolean _tmp49_ = FALSE;
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp47_ = remember_checkbutton;
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp48_ = gtk_toggle_button_get_active ((GtkToggleButton*) _tmp47_);
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp49_ = _tmp48_;
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp43_ = _tmp49_;
#line 423 "moonshot-warning-dialog.c"
	} else {
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp43_ = FALSE;
#line 427 "moonshot-warning-dialog.c"
	}
#line 107 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (_tmp43_) {
#line 431 "moonshot-warning-dialog.c"
		const gchar* _tmp50_ = NULL;
#line 109 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		_tmp50_ = dialog_name;
#line 109 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		set_bool_setting (GROUP_NAME, _tmp50_, TRUE, NULL);
#line 437 "moonshot-warning-dialog.c"
	}
#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp51_ = dialog;
#line 112 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	gtk_object_destroy ((GtkObject*) _tmp51_);
#line 113 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_tmp52_ = ret;
#line 113 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	result = _tmp52_ == ((gint) GTK_RESPONSE_YES);
#line 113 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_g_object_unref0 (remember_checkbutton);
#line 113 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_g_object_unref0 (content_area);
#line 113 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	_g_object_unref0 (dialog);
#line 113 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	return result;
#line 455 "moonshot-warning-dialog.c"
}


WarningDialog* warning_dialog_construct (GType object_type) {
	WarningDialog* self = NULL;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	self = (WarningDialog*) g_type_create_instance (object_type);
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	return self;
#line 465 "moonshot-warning-dialog.c"
}


WarningDialog* warning_dialog_new (void) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	return warning_dialog_construct (TYPE_WARNING_DIALOG);
#line 472 "moonshot-warning-dialog.c"
}


static void value_warning_dialog_init (GValue* value) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	value->data[0].v_pointer = NULL;
#line 479 "moonshot-warning-dialog.c"
}


static void value_warning_dialog_free_value (GValue* value) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (value->data[0].v_pointer) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		warning_dialog_unref (value->data[0].v_pointer);
#line 488 "moonshot-warning-dialog.c"
	}
}


static void value_warning_dialog_copy_value (const GValue* src_value, GValue* dest_value) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (src_value->data[0].v_pointer) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		dest_value->data[0].v_pointer = warning_dialog_ref (src_value->data[0].v_pointer);
#line 498 "moonshot-warning-dialog.c"
	} else {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		dest_value->data[0].v_pointer = NULL;
#line 502 "moonshot-warning-dialog.c"
	}
}


static gpointer value_warning_dialog_peek_pointer (const GValue* value) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	return value->data[0].v_pointer;
#line 510 "moonshot-warning-dialog.c"
}


static gchar* value_warning_dialog_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (collect_values[0].v_pointer) {
#line 517 "moonshot-warning-dialog.c"
		WarningDialog* object;
		object = collect_values[0].v_pointer;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		if (object->parent_instance.g_class == NULL) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
			return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 524 "moonshot-warning-dialog.c"
		} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
			return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 528 "moonshot-warning-dialog.c"
		}
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		value->data[0].v_pointer = warning_dialog_ref (object);
#line 532 "moonshot-warning-dialog.c"
	} else {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		value->data[0].v_pointer = NULL;
#line 536 "moonshot-warning-dialog.c"
	}
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	return NULL;
#line 540 "moonshot-warning-dialog.c"
}


static gchar* value_warning_dialog_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
	WarningDialog** object_p;
	object_p = collect_values[0].v_pointer;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (!object_p) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
#line 551 "moonshot-warning-dialog.c"
	}
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (!value->data[0].v_pointer) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		*object_p = NULL;
#line 557 "moonshot-warning-dialog.c"
	} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		*object_p = value->data[0].v_pointer;
#line 561 "moonshot-warning-dialog.c"
	} else {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		*object_p = warning_dialog_ref (value->data[0].v_pointer);
#line 565 "moonshot-warning-dialog.c"
	}
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	return NULL;
#line 569 "moonshot-warning-dialog.c"
}


GParamSpec* param_spec_warning_dialog (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) {
	ParamSpecWarningDialog* spec;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	g_return_val_if_fail (g_type_is_a (object_type, TYPE_WARNING_DIALOG), NULL);
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags);
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	G_PARAM_SPEC (spec)->value_type = object_type;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	return G_PARAM_SPEC (spec);
#line 583 "moonshot-warning-dialog.c"
}


gpointer value_get_warning_dialog (const GValue* value) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_WARNING_DIALOG), NULL);
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	return value->data[0].v_pointer;
#line 592 "moonshot-warning-dialog.c"
}


void value_set_warning_dialog (GValue* value, gpointer v_object) {
	WarningDialog* old;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_WARNING_DIALOG));
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	old = value->data[0].v_pointer;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (v_object) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_WARNING_DIALOG));
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		value->data[0].v_pointer = v_object;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		warning_dialog_ref (value->data[0].v_pointer);
#line 612 "moonshot-warning-dialog.c"
	} else {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		value->data[0].v_pointer = NULL;
#line 616 "moonshot-warning-dialog.c"
	}
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (old) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		warning_dialog_unref (old);
#line 622 "moonshot-warning-dialog.c"
	}
}


void value_take_warning_dialog (GValue* value, gpointer v_object) {
	WarningDialog* old;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_WARNING_DIALOG));
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	old = value->data[0].v_pointer;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (v_object) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_WARNING_DIALOG));
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		value->data[0].v_pointer = v_object;
#line 641 "moonshot-warning-dialog.c"
	} else {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		value->data[0].v_pointer = NULL;
#line 645 "moonshot-warning-dialog.c"
	}
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (old) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		warning_dialog_unref (old);
#line 651 "moonshot-warning-dialog.c"
	}
}


static void warning_dialog_class_init (WarningDialogClass * klass) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	warning_dialog_parent_class = g_type_class_peek_parent (klass);
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	((WarningDialogClass *) klass)->finalize = warning_dialog_finalize;
#line 661 "moonshot-warning-dialog.c"
}


static void warning_dialog_instance_init (WarningDialog * self) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	self->ref_count = 1;
#line 668 "moonshot-warning-dialog.c"
}


static void warning_dialog_finalize (WarningDialog* obj) {
	WarningDialog * self;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_WARNING_DIALOG, WarningDialog);
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	g_signal_handlers_destroy (self);
#line 678 "moonshot-warning-dialog.c"
}


GType warning_dialog_get_type (void) {
	static volatile gsize warning_dialog_type_id__volatile = 0;
	if (g_once_init_enter (&warning_dialog_type_id__volatile)) {
		static const GTypeValueTable g_define_type_value_table = { value_warning_dialog_init, value_warning_dialog_free_value, value_warning_dialog_copy_value, value_warning_dialog_peek_pointer, "p", value_warning_dialog_collect_value, "p", value_warning_dialog_lcopy_value };
		static const GTypeInfo g_define_type_info = { sizeof (WarningDialogClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) warning_dialog_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (WarningDialog), 0, (GInstanceInitFunc) warning_dialog_instance_init, &g_define_type_value_table };
		static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) };
		GType warning_dialog_type_id;
		warning_dialog_type_id = g_type_register_fundamental (g_type_fundamental_next (), "WarningDialog", &g_define_type_info, &g_define_type_fundamental_info, 0);
		g_once_init_leave (&warning_dialog_type_id__volatile, warning_dialog_type_id);
	}
	return warning_dialog_type_id__volatile;
}


gpointer warning_dialog_ref (gpointer instance) {
	WarningDialog* self;
	self = instance;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	g_atomic_int_inc (&self->ref_count);
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	return instance;
#line 703 "moonshot-warning-dialog.c"
}


void warning_dialog_unref (gpointer instance) {
	WarningDialog* self;
	self = instance;
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
	if (g_atomic_int_dec_and_test (&self->ref_count)) {
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		WARNING_DIALOG_GET_CLASS (self)->finalize (self);
#line 38 "/home/hartmans/moonshot/moonshot/ui/src/moonshot-warning-dialog.vala"
		g_type_free_instance ((GTypeInstance *) self);
#line 716 "moonshot-warning-dialog.c"
	}
}



