/* gitg-history-command-line.c generated by valac 0.32.1, the Vala compiler
 * generated from gitg-history-command-line.vala, do not modify */

/*
 * This file is part of gitg
 *
 * Copyright (C) 2015 - Jesse van den Kieboom
 *
 * gitg is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * gitg is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with gitg. If not, see <http://www.gnu.org/licenses/>.
 */

#include <glib.h>
#include <glib-object.h>
#include "libgitg-ext/libgitg-ext.h"
#include <stdlib.h>
#include <string.h>
#include <config.h>
#include <gtk/gtk.h>
#include "libgitg/libgitg.h"
#include <stdio.h>


#define GITG_HISTORY_TYPE_COMMAND_LINE (gitg_history_command_line_get_type ())
#define GITG_HISTORY_COMMAND_LINE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GITG_HISTORY_TYPE_COMMAND_LINE, GitgHistoryCommandLine))
#define GITG_HISTORY_COMMAND_LINE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GITG_HISTORY_TYPE_COMMAND_LINE, GitgHistoryCommandLineClass))
#define GITG_HISTORY_IS_COMMAND_LINE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GITG_HISTORY_TYPE_COMMAND_LINE))
#define GITG_HISTORY_IS_COMMAND_LINE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GITG_HISTORY_TYPE_COMMAND_LINE))
#define GITG_HISTORY_COMMAND_LINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GITG_HISTORY_TYPE_COMMAND_LINE, GitgHistoryCommandLineClass))

typedef struct _GitgHistoryCommandLine GitgHistoryCommandLine;
typedef struct _GitgHistoryCommandLineClass GitgHistoryCommandLineClass;
typedef struct _GitgHistoryCommandLinePrivate GitgHistoryCommandLinePrivate;
#define _g_free0(var) (var = (g_free (var), NULL))
#define _g_option_group_free0(var) ((var == NULL) ? NULL : (var = (g_option_group_free (var), NULL)))

#define GITG_HISTORY_TYPE_ACTIVITY (gitg_history_activity_get_type ())
#define GITG_HISTORY_ACTIVITY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GITG_HISTORY_TYPE_ACTIVITY, GitgHistoryActivity))
#define GITG_HISTORY_ACTIVITY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GITG_HISTORY_TYPE_ACTIVITY, GitgHistoryActivityClass))
#define GITG_HISTORY_IS_ACTIVITY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GITG_HISTORY_TYPE_ACTIVITY))
#define GITG_HISTORY_IS_ACTIVITY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GITG_HISTORY_TYPE_ACTIVITY))
#define GITG_HISTORY_ACTIVITY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GITG_HISTORY_TYPE_ACTIVITY, GitgHistoryActivityClass))

typedef struct _GitgHistoryActivity GitgHistoryActivity;
typedef struct _GitgHistoryActivityClass GitgHistoryActivityClass;
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))

#define GITG_HISTORY_TYPE_REFS_LIST (gitg_history_refs_list_get_type ())
#define GITG_HISTORY_REFS_LIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GITG_HISTORY_TYPE_REFS_LIST, GitgHistoryRefsList))
#define GITG_HISTORY_REFS_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GITG_HISTORY_TYPE_REFS_LIST, GitgHistoryRefsListClass))
#define GITG_HISTORY_IS_REFS_LIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GITG_HISTORY_TYPE_REFS_LIST))
#define GITG_HISTORY_IS_REFS_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GITG_HISTORY_TYPE_REFS_LIST))
#define GITG_HISTORY_REFS_LIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GITG_HISTORY_TYPE_REFS_LIST, GitgHistoryRefsListClass))

typedef struct _GitgHistoryRefsList GitgHistoryRefsList;
typedef struct _GitgHistoryRefsListClass GitgHistoryRefsListClass;
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))

struct _GitgHistoryCommandLine {
	GObject parent_instance;
	GitgHistoryCommandLinePrivate * priv;
};

struct _GitgHistoryCommandLineClass {
	GObjectClass parent_class;
};

struct _GitgHistoryCommandLinePrivate {
	gchar* d_select_reference;
	gboolean d_all_commits;
	gboolean d_all_branches;
	gboolean d_all_remotes;
	gboolean d_all_tags;
};


static gpointer gitg_history_command_line_parent_class = NULL;
static gchar* gitg_history_command_line_s_select_reference;
static gchar* gitg_history_command_line_s_select_reference = NULL;
static gboolean gitg_history_command_line_s_all_commits;
static gboolean gitg_history_command_line_s_all_commits = FALSE;
static gboolean gitg_history_command_line_s_all_branches;
static gboolean gitg_history_command_line_s_all_branches = FALSE;
static gboolean gitg_history_command_line_s_all_remotes;
static gboolean gitg_history_command_line_s_all_remotes = FALSE;
static gboolean gitg_history_command_line_s_all_tags;
static gboolean gitg_history_command_line_s_all_tags = FALSE;
static GitgExtCommandLineIface* gitg_history_command_line_gitg_ext_command_line_parent_iface = NULL;

GType gitg_history_command_line_get_type (void) G_GNUC_CONST;
#define GITG_HISTORY_COMMAND_LINE_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), GITG_HISTORY_TYPE_COMMAND_LINE, GitgHistoryCommandLinePrivate))
enum  {
	GITG_HISTORY_COMMAND_LINE_DUMMY_PROPERTY
};
#define GITG_HISTORY_COMMAND_LINE_version VERSION
static GOptionGroup* gitg_history_command_line_real_get_option_group (GitgExtCommandLine* base);
static void gitg_history_command_line_real_parse_finished (GitgExtCommandLine* base);
static void gitg_history_command_line_real_apply (GitgExtCommandLine* base, GitgExtApplication* application);
GType gitg_history_activity_get_type (void) G_GNUC_CONST;
GType gitg_history_refs_list_get_type (void) G_GNUC_CONST;
GitgHistoryRefsList* gitg_history_activity_get_refs_list (GitgHistoryActivity* self);
gboolean gitg_history_refs_list_select_all_commits (GitgHistoryRefsList* self);
gboolean gitg_history_refs_list_select_all_branches (GitgHistoryRefsList* self);
gboolean gitg_history_refs_list_select_all_remotes (GitgHistoryRefsList* self);
gboolean gitg_history_refs_list_select_all_tags (GitgHistoryRefsList* self);
gboolean gitg_history_refs_list_select_ref (GitgHistoryRefsList* self, GitgRef* reference);
GitgHistoryCommandLine* gitg_history_command_line_new (void);
GitgHistoryCommandLine* gitg_history_command_line_construct (GType object_type);
static void gitg_history_command_line_finalize (GObject* obj);

static const GOptionEntry GITG_HISTORY_COMMAND_LINE_s_entries[6] = {{"all", 'a', (gint) G_OPTION_FLAG_IN_MAIN, G_OPTION_ARG_NONE, &gitg_history_command_line_s_all_commits, "Select all commits by default in the history activity", NULL}, {"branches", 'b', (gint) G_OPTION_FLAG_IN_MAIN, G_OPTION_ARG_NONE, &gitg_history_command_line_s_all_branches, "Select all branches by default in the history activity", NULL}, {"remotes", 'r', (gint) G_OPTION_FLAG_IN_MAIN, G_OPTION_ARG_NONE, &gitg_history_command_line_s_all_remotes, "Select all remotes by default in the history activity", NULL}, {"tags", 't', (gint) G_OPTION_FLAG_IN_MAIN, G_OPTION_ARG_NONE, &gitg_history_command_line_s_all_tags, "Select all tags by default in the history activity", NULL}, {"select-reference", 's', (gint) G_OPTION_FLAG_IN_MAIN, G_OPTION_ARG_STRING, &gitg_history_command_line_s_select_reference, "Select the specified reference by default in the history activity", "REFERENCE"}, {NULL}};

static GOptionGroup* gitg_history_command_line_real_get_option_group (GitgExtCommandLine* base) {
	GitgHistoryCommandLine * self;
	GOptionGroup* result = NULL;
	GOptionGroup* group = NULL;
	GOptionGroup* _tmp0_ = NULL;
#line 55 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	self = (GitgHistoryCommandLine*) base;
#line 57 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp0_ = g_option_group_new ("", "", "", NULL, NULL);
#line 57 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	group = _tmp0_;
#line 58 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	g_option_group_add_entries (group, GITG_HISTORY_COMMAND_LINE_s_entries);
#line 60 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	result = group;
#line 60 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	return result;
#line 141 "gitg-history-command-line.c"
}


static void gitg_history_command_line_real_parse_finished (GitgExtCommandLine* base) {
	GitgHistoryCommandLine * self;
	const gchar* _tmp0_ = NULL;
	gchar* _tmp1_ = NULL;
	gboolean _tmp2_ = FALSE;
	gboolean _tmp3_ = FALSE;
	gboolean _tmp4_ = FALSE;
	gboolean _tmp5_ = FALSE;
#line 63 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	self = (GitgHistoryCommandLine*) base;
#line 65 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp0_ = gitg_history_command_line_s_select_reference;
#line 65 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp1_ = g_strdup (_tmp0_);
#line 65 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_g_free0 (self->priv->d_select_reference);
#line 65 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	self->priv->d_select_reference = _tmp1_;
#line 66 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp2_ = gitg_history_command_line_s_all_commits;
#line 66 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	self->priv->d_all_commits = _tmp2_;
#line 67 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp3_ = gitg_history_command_line_s_all_branches;
#line 67 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	self->priv->d_all_branches = _tmp3_;
#line 68 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp4_ = gitg_history_command_line_s_all_remotes;
#line 68 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	self->priv->d_all_remotes = _tmp4_;
#line 69 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp5_ = gitg_history_command_line_s_all_tags;
#line 69 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	self->priv->d_all_tags = _tmp5_;
#line 179 "gitg-history-command-line.c"
}


static void gitg_history_command_line_real_apply (GitgExtCommandLine* base, GitgExtApplication* application) {
	GitgHistoryCommandLine * self;
	GitgHistoryActivity* history = NULL;
	GitgExtApplication* _tmp0_ = NULL;
	GitgExtActivity* _tmp1_ = NULL;
	GitgHistoryActivity* _tmp2_ = NULL;
	GitgHistoryActivity* _tmp3_ = NULL;
	gboolean _tmp4_ = FALSE;
	GError * _inner_error_ = NULL;
#line 72 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	self = (GitgHistoryCommandLine*) base;
#line 72 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	g_return_if_fail (application != NULL);
#line 74 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp0_ = application;
#line 74 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp1_ = gitg_ext_application_get_activity_by_id (_tmp0_, "/org/gnome/gitg/Activities/History");
#line 74 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp2_ = G_TYPE_CHECK_INSTANCE_TYPE (_tmp1_, GITG_HISTORY_TYPE_ACTIVITY) ? ((GitgHistoryActivity*) _tmp1_) : NULL;
#line 74 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	if (_tmp2_ == NULL) {
#line 74 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
		_g_object_unref0 (_tmp1_);
#line 206 "gitg-history-command-line.c"
	}
#line 74 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	history = _tmp2_;
#line 76 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp3_ = history;
#line 76 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	if (_tmp3_ == NULL) {
#line 78 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
		_g_object_unref0 (history);
#line 78 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
		return;
#line 218 "gitg-history-command-line.c"
	}
#line 81 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_tmp4_ = self->priv->d_all_commits;
#line 81 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	if (_tmp4_) {
#line 224 "gitg-history-command-line.c"
		GitgHistoryActivity* _tmp5_ = NULL;
		GitgHistoryRefsList* _tmp6_ = NULL;
		GitgHistoryRefsList* _tmp7_ = NULL;
#line 83 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
		_tmp5_ = history;
#line 83 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
		_tmp6_ = gitg_history_activity_get_refs_list (_tmp5_);
#line 83 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
		_tmp7_ = _tmp6_;
#line 83 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
		gitg_history_refs_list_select_all_commits (_tmp7_);
#line 236 "gitg-history-command-line.c"
	} else {
		gboolean _tmp8_ = FALSE;
#line 85 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
		_tmp8_ = self->priv->d_all_branches;
#line 85 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
		if (_tmp8_) {
#line 243 "gitg-history-command-line.c"
			GitgHistoryActivity* _tmp9_ = NULL;
			GitgHistoryRefsList* _tmp10_ = NULL;
			GitgHistoryRefsList* _tmp11_ = NULL;
#line 87 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
			_tmp9_ = history;
#line 87 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
			_tmp10_ = gitg_history_activity_get_refs_list (_tmp9_);
#line 87 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
			_tmp11_ = _tmp10_;
#line 87 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
			gitg_history_refs_list_select_all_branches (_tmp11_);
#line 255 "gitg-history-command-line.c"
		} else {
			gboolean _tmp12_ = FALSE;
#line 89 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
			_tmp12_ = self->priv->d_all_remotes;
#line 89 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
			if (_tmp12_) {
#line 262 "gitg-history-command-line.c"
				GitgHistoryActivity* _tmp13_ = NULL;
				GitgHistoryRefsList* _tmp14_ = NULL;
				GitgHistoryRefsList* _tmp15_ = NULL;
#line 91 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
				_tmp13_ = history;
#line 91 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
				_tmp14_ = gitg_history_activity_get_refs_list (_tmp13_);
#line 91 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
				_tmp15_ = _tmp14_;
#line 91 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
				gitg_history_refs_list_select_all_remotes (_tmp15_);
#line 274 "gitg-history-command-line.c"
			} else {
				gboolean _tmp16_ = FALSE;
#line 93 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
				_tmp16_ = self->priv->d_all_tags;
#line 93 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
				if (_tmp16_) {
#line 281 "gitg-history-command-line.c"
					GitgHistoryActivity* _tmp17_ = NULL;
					GitgHistoryRefsList* _tmp18_ = NULL;
					GitgHistoryRefsList* _tmp19_ = NULL;
#line 95 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
					_tmp17_ = history;
#line 95 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
					_tmp18_ = gitg_history_activity_get_refs_list (_tmp17_);
#line 95 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
					_tmp19_ = _tmp18_;
#line 95 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
					gitg_history_refs_list_select_all_tags (_tmp19_);
#line 293 "gitg-history-command-line.c"
				} else {
					const gchar* _tmp20_ = NULL;
#line 97 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
					_tmp20_ = self->priv->d_select_reference;
#line 97 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
					if (_tmp20_ != NULL) {
#line 300 "gitg-history-command-line.c"
						{
							GitgRef* _tmp21_ = NULL;
							GitgExtApplication* _tmp22_ = NULL;
							GitgRepository* _tmp23_ = NULL;
							GitgRepository* _tmp24_ = NULL;
							GitgRepository* _tmp25_ = NULL;
							const gchar* _tmp26_ = NULL;
							GitgRef* _tmp27_ = NULL;
							GitgRef* _tmp28_ = NULL;
							GitgHistoryActivity* _tmp29_ = NULL;
							GitgHistoryRefsList* _tmp30_ = NULL;
							GitgHistoryRefsList* _tmp31_ = NULL;
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp22_ = application;
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp23_ = gitg_ext_application_get_repository (_tmp22_);
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp24_ = _tmp23_;
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp25_ = _tmp24_;
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp26_ = self->priv->d_select_reference;
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp27_ = gitg_repository_lookup_reference_dwim (_tmp25_, _tmp26_, &_inner_error_);
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp28_ = _tmp27_;
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_g_object_unref0 (_tmp25_);
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp21_ = _tmp28_;
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 333 "gitg-history-command-line.c"
								goto __catch116_g_error;
							}
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp29_ = history;
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp30_ = gitg_history_activity_get_refs_list (_tmp29_);
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp31_ = _tmp30_;
#line 101 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							gitg_history_refs_list_select_ref (_tmp31_, _tmp21_);
#line 99 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_g_object_unref0 (_tmp21_);
#line 346 "gitg-history-command-line.c"
						}
						goto __finally116;
						__catch116_g_error:
						{
							GError* e = NULL;
							FILE* _tmp32_ = NULL;
							const gchar* _tmp33_ = NULL;
							GError* _tmp34_ = NULL;
							const gchar* _tmp35_ = NULL;
#line 99 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							e = _inner_error_;
#line 99 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_inner_error_ = NULL;
#line 105 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp32_ = stderr;
#line 105 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp33_ = self->priv->d_select_reference;
#line 105 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp34_ = e;
#line 105 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_tmp35_ = _tmp34_->message;
#line 105 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							fprintf (_tmp32_, "Failed to lookup reference %s: %s\n", _tmp33_, _tmp35_);
#line 99 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_g_error_free0 (e);
#line 372 "gitg-history-command-line.c"
						}
						__finally116:
#line 99 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
						if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 99 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							_g_object_unref0 (history);
#line 99 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 99 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							g_clear_error (&_inner_error_);
#line 99 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
							return;
#line 385 "gitg-history-command-line.c"
						}
					}
				}
			}
		}
	}
#line 72 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_g_object_unref0 (history);
#line 394 "gitg-history-command-line.c"
}


GitgHistoryCommandLine* gitg_history_command_line_construct (GType object_type) {
	GitgHistoryCommandLine * self = NULL;
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	self = (GitgHistoryCommandLine*) g_object_new (object_type, NULL);
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	return self;
#line 404 "gitg-history-command-line.c"
}


GitgHistoryCommandLine* gitg_history_command_line_new (void) {
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	return gitg_history_command_line_construct (GITG_HISTORY_TYPE_COMMAND_LINE);
#line 411 "gitg-history-command-line.c"
}


static void gitg_history_command_line_class_init (GitgHistoryCommandLineClass * klass) {
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	gitg_history_command_line_parent_class = g_type_class_peek_parent (klass);
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	g_type_class_add_private (klass, sizeof (GitgHistoryCommandLinePrivate));
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	G_OBJECT_CLASS (klass)->finalize = gitg_history_command_line_finalize;
#line 422 "gitg-history-command-line.c"
}


static void gitg_history_command_line_gitg_ext_command_line_interface_init (GitgExtCommandLineIface * iface) {
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	gitg_history_command_line_gitg_ext_command_line_parent_iface = g_type_interface_peek_parent (iface);
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	iface->get_option_group = (GOptionGroup* (*)(GitgExtCommandLine*)) gitg_history_command_line_real_get_option_group;
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	iface->parse_finished = (void (*)(GitgExtCommandLine*)) gitg_history_command_line_real_parse_finished;
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	iface->apply = (void (*)(GitgExtCommandLine*, GitgExtApplication*)) gitg_history_command_line_real_apply;
#line 435 "gitg-history-command-line.c"
}


static void gitg_history_command_line_instance_init (GitgHistoryCommandLine * self) {
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	self->priv = GITG_HISTORY_COMMAND_LINE_GET_PRIVATE (self);
#line 442 "gitg-history-command-line.c"
}


static void gitg_history_command_line_finalize (GObject* obj) {
	GitgHistoryCommandLine * self;
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, GITG_HISTORY_TYPE_COMMAND_LINE, GitgHistoryCommandLine);
#line 34 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	_g_free0 (self->priv->d_select_reference);
#line 23 "/home/jesse/dev/gitg/gitg/history/gitg-history-command-line.vala"
	G_OBJECT_CLASS (gitg_history_command_line_parent_class)->finalize (obj);
#line 454 "gitg-history-command-line.c"
}


GType gitg_history_command_line_get_type (void) {
	static volatile gsize gitg_history_command_line_type_id__volatile = 0;
	if (g_once_init_enter (&gitg_history_command_line_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (GitgHistoryCommandLineClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) gitg_history_command_line_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (GitgHistoryCommandLine), 0, (GInstanceInitFunc) gitg_history_command_line_instance_init, NULL };
		static const GInterfaceInfo gitg_ext_command_line_info = { (GInterfaceInitFunc) gitg_history_command_line_gitg_ext_command_line_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
		GType gitg_history_command_line_type_id;
		gitg_history_command_line_type_id = g_type_register_static (G_TYPE_OBJECT, "GitgHistoryCommandLine", &g_define_type_info, 0);
		g_type_add_interface_static (gitg_history_command_line_type_id, GITG_EXT_TYPE_COMMAND_LINE, &gitg_ext_command_line_info);
		g_once_init_leave (&gitg_history_command_line_type_id__volatile, gitg_history_command_line_type_id);
	}
	return gitg_history_command_line_type_id__volatile;
}



