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

/*
 * Seahorse
 *
 * Copyright (C) 2004,2005 Stefan Walter
 * Copyright (C) 2011 Collabora Ltd.
 * Copyright (C) 2012 Stefan Walter
 *
 * This program 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.
 *
 * This program 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 this program; if not, see <http://www.gnu.org/licenses/>.
 */

#include <glib.h>
#include <glib-object.h>
#include "seahorse-common.h"
#include <stdlib.h>
#include <string.h>
#include <gio/gio.h>
#include <gtk/gtk.h>
#include <glib/gi18n-lib.h>

typedef struct _Block3Data Block3Data;
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _g_main_loop_unref0(var) ((var == NULL) ? NULL : (var = (g_main_loop_unref (var), NULL)))
#define __g_list_free__g_object_unref0_0(var) ((var == NULL) ? NULL : (var = (_g_list_free__g_object_unref0_ (var), NULL)))
#define _g_free0(var) (var = (g_free (var), NULL))
typedef struct _Block4Data Block4Data;
typedef struct _Block5Data Block5Data;
#define _g_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (g_hash_table_unref (var), NULL)))
typedef struct _Block6Data Block6Data;

struct _Block3Data {
	int _ref_count_;
	GMainLoop* loop;
	GAsyncResult* _result_;
};

struct _Block4Data {
	int _ref_count_;
	GMainLoop* loop;
	GAsyncResult* _result_;
};

struct _Block5Data {
	int _ref_count_;
	GMainLoop* loop;
	GAsyncResult* _result_;
};

struct _Block6Data {
	int _ref_count_;
	GtkFileChooserDialog* chooser;
	GHashTable* filters;
};



static Block3Data* block3_data_ref (Block3Data* _data3_);
static void block3_data_unref (void * _userdata_);
static void _g_object_unref0_ (gpointer var);
static void _g_list_free__g_object_unref0_ (GList* self);
static void ____lambda2_ (Block3Data* _data3_, GObject* obj, GAsyncResult* res);
static void _____lambda2__gasync_ready_callback (GObject* source_object, GAsyncResult* res, gpointer self);
static Block4Data* block4_data_ref (Block4Data* _data4_);
static void block4_data_unref (void * _userdata_);
static void ___lambda3_ (Block4Data* _data4_, GObject* obj, GAsyncResult* res);
static void ____lambda3__gasync_ready_callback (GObject* source_object, GAsyncResult* res, gpointer self);
static Block5Data* block5_data_ref (Block5Data* _data5_);
static void block5_data_unref (void * _userdata_);
static void ____lambda5_ (Block5Data* _data5_, GObject* obj, GAsyncResult* res);
static void _____lambda5__gasync_ready_callback (GObject* source_object, GAsyncResult* res, gpointer self);
static gchar* seahorse_exportable_calculate_basename (GFile* file, const gchar* extension);
static Block6Data* block6_data_ref (Block6Data* _data6_);
static void block6_data_unref (void * _userdata_);
static void __lambda4_ (Block6Data* _data6_, GObject* obj, GParamSpec* prop);
static void ___lambda4__g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);


GList* seahorse_exportable_create_exporters (SeahorseExportable* self, SeahorseExporterType type) {
#line 26 "/data/src/seahorse/common/exportable.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 26 "/data/src/seahorse/common/exportable.vala"
	return SEAHORSE_EXPORTABLE_GET_INTERFACE (self)->create_exporters (self, type);
#line 96 "exportable.c"
}


gboolean seahorse_exportable_can_export (GObject* object) {
	gboolean result = FALSE;
	GObject* _tmp0_ = NULL;
#line 28 "/data/src/seahorse/common/exportable.vala"
	g_return_val_if_fail (object != NULL, FALSE);
#line 29 "/data/src/seahorse/common/exportable.vala"
	_tmp0_ = object;
#line 29 "/data/src/seahorse/common/exportable.vala"
	if (G_TYPE_CHECK_INSTANCE_TYPE (_tmp0_, SEAHORSE_TYPE_EXPORTABLE)) {
#line 109 "exportable.c"
		GObject* _tmp1_ = NULL;
		gboolean _tmp2_ = FALSE;
		gboolean _tmp3_ = FALSE;
#line 30 "/data/src/seahorse/common/exportable.vala"
		_tmp1_ = object;
#line 30 "/data/src/seahorse/common/exportable.vala"
		_tmp2_ = seahorse_exportable_get_exportable (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, SEAHORSE_TYPE_EXPORTABLE, SeahorseExportable));
#line 30 "/data/src/seahorse/common/exportable.vala"
		_tmp3_ = _tmp2_;
#line 30 "/data/src/seahorse/common/exportable.vala"
		result = _tmp3_;
#line 30 "/data/src/seahorse/common/exportable.vala"
		return result;
#line 123 "exportable.c"
	}
#line 31 "/data/src/seahorse/common/exportable.vala"
	result = FALSE;
#line 31 "/data/src/seahorse/common/exportable.vala"
	return result;
#line 129 "exportable.c"
}


static Block3Data* block3_data_ref (Block3Data* _data3_) {
#line 34 "/data/src/seahorse/common/exportable.vala"
	g_atomic_int_inc (&_data3_->_ref_count_);
#line 34 "/data/src/seahorse/common/exportable.vala"
	return _data3_;
#line 138 "exportable.c"
}


static void block3_data_unref (void * _userdata_) {
	Block3Data* _data3_;
	_data3_ = (Block3Data*) _userdata_;
#line 34 "/data/src/seahorse/common/exportable.vala"
	if (g_atomic_int_dec_and_test (&_data3_->_ref_count_)) {
#line 34 "/data/src/seahorse/common/exportable.vala"
		_g_object_unref0 (_data3_->_result_);
#line 34 "/data/src/seahorse/common/exportable.vala"
		_g_main_loop_unref0 (_data3_->loop);
#line 34 "/data/src/seahorse/common/exportable.vala"
		g_slice_free (Block3Data, _data3_);
#line 153 "exportable.c"
	}
}


static gpointer _g_object_ref0 (gpointer self) {
#line 40 "/data/src/seahorse/common/exportable.vala"
	return self ? g_object_ref (self) : NULL;
#line 161 "exportable.c"
}


static void _g_object_unref0_ (gpointer var) {
#line 46 "/data/src/seahorse/common/exportable.vala"
	(var == NULL) ? NULL : (var = (g_object_unref (var), NULL));
#line 168 "exportable.c"
}


static void _g_list_free__g_object_unref0_ (GList* self) {
#line 46 "/data/src/seahorse/common/exportable.vala"
	g_list_foreach (self, (GFunc) _g_object_unref0_, NULL);
#line 46 "/data/src/seahorse/common/exportable.vala"
	g_list_free (self);
#line 177 "exportable.c"
}


static void ____lambda2_ (Block3Data* _data3_, GObject* obj, GAsyncResult* res) {
	GAsyncResult* _tmp0_ = NULL;
	GAsyncResult* _tmp1_ = NULL;
	GMainLoop* _tmp2_ = NULL;
#line 52 "/data/src/seahorse/common/exportable.vala"
	g_return_if_fail (res != NULL);
#line 53 "/data/src/seahorse/common/exportable.vala"
	_tmp0_ = res;
#line 53 "/data/src/seahorse/common/exportable.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 53 "/data/src/seahorse/common/exportable.vala"
	_g_object_unref0 (_data3_->_result_);
#line 53 "/data/src/seahorse/common/exportable.vala"
	_data3_->_result_ = _tmp1_;
#line 54 "/data/src/seahorse/common/exportable.vala"
	_tmp2_ = _data3_->loop;
#line 54 "/data/src/seahorse/common/exportable.vala"
	g_main_loop_quit (_tmp2_);
#line 199 "exportable.c"
}


static void _____lambda2__gasync_ready_callback (GObject* source_object, GAsyncResult* res, gpointer self) {
#line 52 "/data/src/seahorse/common/exportable.vala"
	____lambda2_ (self, source_object, res);
#line 52 "/data/src/seahorse/common/exportable.vala"
	block3_data_unref (self);
#line 208 "exportable.c"
}


gint seahorse_exportable_export_to_directory_wait (GList* objects, const gchar* directory, GError** error) {
	gint result = 0;
	Block3Data* _data3_;
	GMainLoop* _tmp0_ = NULL;
	gint count = 0;
	GList* _tmp1_ = NULL;
	GError * _inner_error_ = NULL;
#line 34 "/data/src/seahorse/common/exportable.vala"
	g_return_val_if_fail (directory != NULL, 0);
#line 34 "/data/src/seahorse/common/exportable.vala"
	_data3_ = g_slice_new0 (Block3Data);
#line 34 "/data/src/seahorse/common/exportable.vala"
	_data3_->_ref_count_ = 1;
#line 36 "/data/src/seahorse/common/exportable.vala"
	_tmp0_ = g_main_loop_new (NULL, FALSE);
#line 36 "/data/src/seahorse/common/exportable.vala"
	_data3_->loop = _tmp0_;
#line 37 "/data/src/seahorse/common/exportable.vala"
	_data3_->_result_ = NULL;
#line 38 "/data/src/seahorse/common/exportable.vala"
	count = 0;
#line 40 "/data/src/seahorse/common/exportable.vala"
	_tmp1_ = objects;
#line 235 "exportable.c"
	{
		GList* object_collection = NULL;
		GList* object_it = NULL;
#line 40 "/data/src/seahorse/common/exportable.vala"
		object_collection = _tmp1_;
#line 40 "/data/src/seahorse/common/exportable.vala"
		for (object_it = object_collection; object_it != NULL; object_it = object_it->next) {
#line 243 "exportable.c"
			GObject* _tmp2_ = NULL;
			GObject* object = NULL;
#line 40 "/data/src/seahorse/common/exportable.vala"
			_tmp2_ = _g_object_ref0 ((GObject*) object_it->data);
#line 40 "/data/src/seahorse/common/exportable.vala"
			object = _tmp2_;
#line 250 "exportable.c"
			{
				GObject* _tmp3_ = NULL;
				gboolean _tmp4_ = FALSE;
				GList* exporters = NULL;
				GObject* _tmp5_ = NULL;
				GList* _tmp6_ = NULL;
				GList* _tmp7_ = NULL;
				SeahorseExporter* exporter = NULL;
				GList* _tmp8_ = NULL;
				gconstpointer _tmp9_ = NULL;
				SeahorseExporter* _tmp10_ = NULL;
				gchar* filename = NULL;
				const gchar* _tmp11_ = NULL;
				SeahorseExporter* _tmp12_ = NULL;
				gchar* _tmp13_ = NULL;
				gchar* _tmp14_ = NULL;
				gchar* _tmp15_ = NULL;
				gchar* _tmp16_ = NULL;
				gchar* _tmp17_ = NULL;
				GFile* file = NULL;
				const gchar* _tmp18_ = NULL;
				GFile* _tmp19_ = NULL;
				SeahorseExporter* _tmp20_ = NULL;
				GFile* _tmp21_ = NULL;
				GMainLoop* _tmp22_ = NULL;
				SeahorseExporter* _tmp23_ = NULL;
				GAsyncResult* _tmp24_ = NULL;
				gint _tmp25_ = 0;
#line 41 "/data/src/seahorse/common/exportable.vala"
				_tmp3_ = object;
#line 41 "/data/src/seahorse/common/exportable.vala"
				_tmp4_ = seahorse_exportable_can_export (_tmp3_);
#line 41 "/data/src/seahorse/common/exportable.vala"
				if (!_tmp4_) {
#line 42 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (object);
#line 42 "/data/src/seahorse/common/exportable.vala"
					continue;
#line 289 "exportable.c"
				}
#line 44 "/data/src/seahorse/common/exportable.vala"
				_tmp5_ = object;
#line 44 "/data/src/seahorse/common/exportable.vala"
				_tmp6_ = seahorse_exportable_create_exporters (G_TYPE_CHECK_INSTANCE_CAST (_tmp5_, SEAHORSE_TYPE_EXPORTABLE, SeahorseExportable), SEAHORSE_EXPORTER_TYPE_ANY);
#line 44 "/data/src/seahorse/common/exportable.vala"
				exporters = _tmp6_;
#line 45 "/data/src/seahorse/common/exportable.vala"
				_tmp7_ = exporters;
#line 45 "/data/src/seahorse/common/exportable.vala"
				if (_tmp7_ == NULL) {
#line 46 "/data/src/seahorse/common/exportable.vala"
					__g_list_free__g_object_unref0_0 (exporters);
#line 46 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (object);
#line 46 "/data/src/seahorse/common/exportable.vala"
					continue;
#line 307 "exportable.c"
				}
#line 48 "/data/src/seahorse/common/exportable.vala"
				_tmp8_ = exporters;
#line 48 "/data/src/seahorse/common/exportable.vala"
				_tmp9_ = _tmp8_->data;
#line 48 "/data/src/seahorse/common/exportable.vala"
				_tmp10_ = _g_object_ref0 ((SeahorseExporter*) _tmp9_);
#line 48 "/data/src/seahorse/common/exportable.vala"
				exporter = _tmp10_;
#line 49 "/data/src/seahorse/common/exportable.vala"
				_tmp11_ = directory;
#line 49 "/data/src/seahorse/common/exportable.vala"
				_tmp12_ = exporter;
#line 49 "/data/src/seahorse/common/exportable.vala"
				_tmp13_ = seahorse_exporter_get_filename (_tmp12_);
#line 49 "/data/src/seahorse/common/exportable.vala"
				_tmp14_ = _tmp13_;
#line 49 "/data/src/seahorse/common/exportable.vala"
				_tmp15_ = _tmp14_;
#line 49 "/data/src/seahorse/common/exportable.vala"
				_tmp16_ = g_build_filename (_tmp11_, _tmp15_, NULL, NULL);
#line 49 "/data/src/seahorse/common/exportable.vala"
				_tmp17_ = _tmp16_;
#line 49 "/data/src/seahorse/common/exportable.vala"
				_g_free0 (_tmp15_);
#line 49 "/data/src/seahorse/common/exportable.vala"
				filename = _tmp17_;
#line 50 "/data/src/seahorse/common/exportable.vala"
				_tmp18_ = filename;
#line 50 "/data/src/seahorse/common/exportable.vala"
				_tmp19_ = g_file_new_for_uri (_tmp18_);
#line 50 "/data/src/seahorse/common/exportable.vala"
				file = _tmp19_;
#line 52 "/data/src/seahorse/common/exportable.vala"
				_tmp20_ = exporter;
#line 52 "/data/src/seahorse/common/exportable.vala"
				_tmp21_ = file;
#line 52 "/data/src/seahorse/common/exportable.vala"
				seahorse_exporter_export_to_file (_tmp20_, _tmp21_, FALSE, NULL, _____lambda2__gasync_ready_callback, block3_data_ref (_data3_));
#line 57 "/data/src/seahorse/common/exportable.vala"
				_tmp22_ = _data3_->loop;
#line 57 "/data/src/seahorse/common/exportable.vala"
				g_main_loop_run (_tmp22_);
#line 59 "/data/src/seahorse/common/exportable.vala"
				_tmp23_ = exporter;
#line 59 "/data/src/seahorse/common/exportable.vala"
				_tmp24_ = _data3_->_result_;
#line 59 "/data/src/seahorse/common/exportable.vala"
				seahorse_exporter_export_to_file_finish (_tmp23_, _tmp24_, &_inner_error_);
#line 59 "/data/src/seahorse/common/exportable.vala"
				if (_inner_error_ != NULL) {
#line 59 "/data/src/seahorse/common/exportable.vala"
					g_propagate_error (error, _inner_error_);
#line 59 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (file);
#line 59 "/data/src/seahorse/common/exportable.vala"
					_g_free0 (filename);
#line 59 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (exporter);
#line 59 "/data/src/seahorse/common/exportable.vala"
					__g_list_free__g_object_unref0_0 (exporters);
#line 59 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (object);
#line 59 "/data/src/seahorse/common/exportable.vala"
					block3_data_unref (_data3_);
#line 59 "/data/src/seahorse/common/exportable.vala"
					_data3_ = NULL;
#line 59 "/data/src/seahorse/common/exportable.vala"
					return 0;
#line 377 "exportable.c"
				}
#line 61 "/data/src/seahorse/common/exportable.vala"
				_tmp25_ = count;
#line 61 "/data/src/seahorse/common/exportable.vala"
				count = _tmp25_ + 1;
#line 40 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (file);
#line 40 "/data/src/seahorse/common/exportable.vala"
				_g_free0 (filename);
#line 40 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (exporter);
#line 40 "/data/src/seahorse/common/exportable.vala"
				__g_list_free__g_object_unref0_0 (exporters);
#line 40 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (object);
#line 393 "exportable.c"
			}
		}
	}
#line 64 "/data/src/seahorse/common/exportable.vala"
	result = count;
#line 64 "/data/src/seahorse/common/exportable.vala"
	block3_data_unref (_data3_);
#line 64 "/data/src/seahorse/common/exportable.vala"
	_data3_ = NULL;
#line 64 "/data/src/seahorse/common/exportable.vala"
	return result;
#line 405 "exportable.c"
}


static Block4Data* block4_data_ref (Block4Data* _data4_) {
#line 97 "/data/src/seahorse/common/exportable.vala"
	g_atomic_int_inc (&_data4_->_ref_count_);
#line 97 "/data/src/seahorse/common/exportable.vala"
	return _data4_;
#line 414 "exportable.c"
}


static void block4_data_unref (void * _userdata_) {
	Block4Data* _data4_;
	_data4_ = (Block4Data*) _userdata_;
#line 97 "/data/src/seahorse/common/exportable.vala"
	if (g_atomic_int_dec_and_test (&_data4_->_ref_count_)) {
#line 97 "/data/src/seahorse/common/exportable.vala"
		_g_object_unref0 (_data4_->_result_);
#line 97 "/data/src/seahorse/common/exportable.vala"
		_g_main_loop_unref0 (_data4_->loop);
#line 97 "/data/src/seahorse/common/exportable.vala"
		g_slice_free (Block4Data, _data4_);
#line 429 "exportable.c"
	}
}


static void ___lambda3_ (Block4Data* _data4_, GObject* obj, GAsyncResult* res) {
	GAsyncResult* _tmp0_ = NULL;
	GAsyncResult* _tmp1_ = NULL;
	GMainLoop* _tmp2_ = NULL;
#line 101 "/data/src/seahorse/common/exportable.vala"
	g_return_if_fail (res != NULL);
#line 102 "/data/src/seahorse/common/exportable.vala"
	_tmp0_ = res;
#line 102 "/data/src/seahorse/common/exportable.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 102 "/data/src/seahorse/common/exportable.vala"
	_g_object_unref0 (_data4_->_result_);
#line 102 "/data/src/seahorse/common/exportable.vala"
	_data4_->_result_ = _tmp1_;
#line 103 "/data/src/seahorse/common/exportable.vala"
	_tmp2_ = _data4_->loop;
#line 103 "/data/src/seahorse/common/exportable.vala"
	g_main_loop_quit (_tmp2_);
#line 452 "exportable.c"
}


static void ____lambda3__gasync_ready_callback (GObject* source_object, GAsyncResult* res, gpointer self) {
#line 101 "/data/src/seahorse/common/exportable.vala"
	___lambda3_ (self, source_object, res);
#line 101 "/data/src/seahorse/common/exportable.vala"
	block4_data_unref (self);
#line 461 "exportable.c"
}


guint seahorse_exportable_export_to_text_wait (GList* objects, guint8** output, size_t* output_length1, GError** error) {
	guint8* _vala_output = NULL;
	int _vala_output_length1 = 0;
	guint result = 0U;
	GList* exporters = NULL;
	GList* _tmp0_ = NULL;
	SeahorseExporter* chosen = NULL;
	guint total = 0U;
	GList* _tmp11_ = NULL;
	SeahorseExporter* _tmp21_ = NULL;
	guint8* _tmp30_ = NULL;
	GError * _inner_error_ = NULL;
#line 69 "/data/src/seahorse/common/exportable.vala"
	exporters = NULL;
#line 71 "/data/src/seahorse/common/exportable.vala"
	_tmp0_ = objects;
#line 481 "exportable.c"
	{
		GList* object_collection = NULL;
		GList* object_it = NULL;
#line 71 "/data/src/seahorse/common/exportable.vala"
		object_collection = _tmp0_;
#line 71 "/data/src/seahorse/common/exportable.vala"
		for (object_it = object_collection; object_it != NULL; object_it = object_it->next) {
#line 489 "exportable.c"
			GObject* _tmp1_ = NULL;
			GObject* object = NULL;
#line 71 "/data/src/seahorse/common/exportable.vala"
			_tmp1_ = _g_object_ref0 ((GObject*) object_it->data);
#line 71 "/data/src/seahorse/common/exportable.vala"
			object = _tmp1_;
#line 496 "exportable.c"
			{
				GObject* _tmp2_ = NULL;
				gboolean _tmp3_ = FALSE;
				GList* _tmp4_ = NULL;
#line 72 "/data/src/seahorse/common/exportable.vala"
				_tmp2_ = object;
#line 72 "/data/src/seahorse/common/exportable.vala"
				_tmp3_ = seahorse_exportable_can_export (_tmp2_);
#line 72 "/data/src/seahorse/common/exportable.vala"
				if (!_tmp3_) {
#line 73 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (object);
#line 73 "/data/src/seahorse/common/exportable.vala"
					continue;
#line 511 "exportable.c"
				}
#line 76 "/data/src/seahorse/common/exportable.vala"
				_tmp4_ = exporters;
#line 76 "/data/src/seahorse/common/exportable.vala"
				if (_tmp4_ != NULL) {
#line 517 "exportable.c"
					GList* _tmp5_ = NULL;
#line 77 "/data/src/seahorse/common/exportable.vala"
					_tmp5_ = exporters;
#line 521 "exportable.c"
					{
						GList* exporter_collection = NULL;
						GList* exporter_it = NULL;
#line 77 "/data/src/seahorse/common/exportable.vala"
						exporter_collection = _tmp5_;
#line 77 "/data/src/seahorse/common/exportable.vala"
						for (exporter_it = exporter_collection; exporter_it != NULL; exporter_it = exporter_it->next) {
#line 529 "exportable.c"
							SeahorseExporter* _tmp6_ = NULL;
							SeahorseExporter* exporter = NULL;
#line 77 "/data/src/seahorse/common/exportable.vala"
							_tmp6_ = _g_object_ref0 ((SeahorseExporter*) exporter_it->data);
#line 77 "/data/src/seahorse/common/exportable.vala"
							exporter = _tmp6_;
#line 536 "exportable.c"
							{
								SeahorseExporter* _tmp7_ = NULL;
								GObject* _tmp8_ = NULL;
#line 78 "/data/src/seahorse/common/exportable.vala"
								_tmp7_ = exporter;
#line 78 "/data/src/seahorse/common/exportable.vala"
								_tmp8_ = object;
#line 78 "/data/src/seahorse/common/exportable.vala"
								seahorse_exporter_add_object (_tmp7_, _tmp8_);
#line 77 "/data/src/seahorse/common/exportable.vala"
								_g_object_unref0 (exporter);
#line 548 "exportable.c"
							}
						}
					}
				} else {
					GObject* _tmp9_ = NULL;
					GList* _tmp10_ = NULL;
#line 82 "/data/src/seahorse/common/exportable.vala"
					_tmp9_ = object;
#line 82 "/data/src/seahorse/common/exportable.vala"
					_tmp10_ = seahorse_exportable_create_exporters (G_TYPE_CHECK_INSTANCE_CAST (_tmp9_, SEAHORSE_TYPE_EXPORTABLE, SeahorseExportable), SEAHORSE_EXPORTER_TYPE_TEXTUAL);
#line 82 "/data/src/seahorse/common/exportable.vala"
					__g_list_free__g_object_unref0_0 (exporters);
#line 82 "/data/src/seahorse/common/exportable.vala"
					exporters = _tmp10_;
#line 563 "exportable.c"
				}
#line 71 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (object);
#line 567 "exportable.c"
			}
		}
	}
#line 87 "/data/src/seahorse/common/exportable.vala"
	chosen = NULL;
#line 88 "/data/src/seahorse/common/exportable.vala"
	total = (guint) 0;
#line 89 "/data/src/seahorse/common/exportable.vala"
	_tmp11_ = exporters;
#line 577 "exportable.c"
	{
		GList* exporter_collection = NULL;
		GList* exporter_it = NULL;
#line 89 "/data/src/seahorse/common/exportable.vala"
		exporter_collection = _tmp11_;
#line 89 "/data/src/seahorse/common/exportable.vala"
		for (exporter_it = exporter_collection; exporter_it != NULL; exporter_it = exporter_it->next) {
#line 585 "exportable.c"
			SeahorseExporter* _tmp12_ = NULL;
			SeahorseExporter* exporter = NULL;
#line 89 "/data/src/seahorse/common/exportable.vala"
			_tmp12_ = _g_object_ref0 ((SeahorseExporter*) exporter_it->data);
#line 89 "/data/src/seahorse/common/exportable.vala"
			exporter = _tmp12_;
#line 592 "exportable.c"
			{
				guint count = 0U;
				SeahorseExporter* _tmp13_ = NULL;
				GList* _tmp14_ = NULL;
				guint _tmp15_ = 0U;
				guint _tmp16_ = 0U;
				guint _tmp17_ = 0U;
#line 90 "/data/src/seahorse/common/exportable.vala"
				_tmp13_ = exporter;
#line 90 "/data/src/seahorse/common/exportable.vala"
				_tmp14_ = seahorse_exporter_get_objects (_tmp13_);
#line 90 "/data/src/seahorse/common/exportable.vala"
				_tmp15_ = g_list_length (_tmp14_);
#line 90 "/data/src/seahorse/common/exportable.vala"
				count = _tmp15_;
#line 91 "/data/src/seahorse/common/exportable.vala"
				_tmp16_ = count;
#line 91 "/data/src/seahorse/common/exportable.vala"
				_tmp17_ = total;
#line 91 "/data/src/seahorse/common/exportable.vala"
				if (_tmp16_ > _tmp17_) {
#line 614 "exportable.c"
					guint _tmp18_ = 0U;
					SeahorseExporter* _tmp19_ = NULL;
					SeahorseExporter* _tmp20_ = NULL;
#line 92 "/data/src/seahorse/common/exportable.vala"
					_tmp18_ = count;
#line 92 "/data/src/seahorse/common/exportable.vala"
					total = _tmp18_;
#line 93 "/data/src/seahorse/common/exportable.vala"
					_tmp19_ = exporter;
#line 93 "/data/src/seahorse/common/exportable.vala"
					_tmp20_ = _g_object_ref0 (_tmp19_);
#line 93 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (chosen);
#line 93 "/data/src/seahorse/common/exportable.vala"
					chosen = _tmp20_;
#line 630 "exportable.c"
				}
#line 89 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (exporter);
#line 634 "exportable.c"
			}
		}
	}
#line 97 "/data/src/seahorse/common/exportable.vala"
	_tmp21_ = chosen;
#line 97 "/data/src/seahorse/common/exportable.vala"
	if (_tmp21_ != NULL) {
#line 642 "exportable.c"
		Block4Data* _data4_;
		GMainLoop* _tmp22_ = NULL;
		SeahorseExporter* _tmp23_ = NULL;
		GMainLoop* _tmp24_ = NULL;
		guint8* _tmp25_ = NULL;
		SeahorseExporter* _tmp26_ = NULL;
		GAsyncResult* _tmp27_ = NULL;
		size_t _tmp28_;
		guint8* _tmp29_ = NULL;
		gint _tmp25__length1 = 0;
		gint __tmp25__size_ = 0;
#line 97 "/data/src/seahorse/common/exportable.vala"
		_data4_ = g_slice_new0 (Block4Data);
#line 97 "/data/src/seahorse/common/exportable.vala"
		_data4_->_ref_count_ = 1;
#line 98 "/data/src/seahorse/common/exportable.vala"
		_tmp22_ = g_main_loop_new (NULL, FALSE);
#line 98 "/data/src/seahorse/common/exportable.vala"
		_data4_->loop = _tmp22_;
#line 99 "/data/src/seahorse/common/exportable.vala"
		_data4_->_result_ = NULL;
#line 101 "/data/src/seahorse/common/exportable.vala"
		_tmp23_ = chosen;
#line 101 "/data/src/seahorse/common/exportable.vala"
		seahorse_exporter_export (_tmp23_, NULL, ____lambda3__gasync_ready_callback, block4_data_ref (_data4_));
#line 106 "/data/src/seahorse/common/exportable.vala"
		_tmp24_ = _data4_->loop;
#line 106 "/data/src/seahorse/common/exportable.vala"
		g_main_loop_run (_tmp24_);
#line 108 "/data/src/seahorse/common/exportable.vala"
		_tmp26_ = chosen;
#line 108 "/data/src/seahorse/common/exportable.vala"
		_tmp27_ = _data4_->_result_;
#line 108 "/data/src/seahorse/common/exportable.vala"
		_tmp29_ = seahorse_exporter_export_finish (_tmp26_, _tmp27_, &_tmp28_, &_inner_error_);
#line 108 "/data/src/seahorse/common/exportable.vala"
		_tmp25_ = _tmp29_;
#line 108 "/data/src/seahorse/common/exportable.vala"
		_tmp25__length1 = _tmp28_;
#line 108 "/data/src/seahorse/common/exportable.vala"
		__tmp25__size_ = _tmp25__length1;
#line 108 "/data/src/seahorse/common/exportable.vala"
		if (_inner_error_ != NULL) {
#line 108 "/data/src/seahorse/common/exportable.vala"
			g_propagate_error (error, _inner_error_);
#line 108 "/data/src/seahorse/common/exportable.vala"
			block4_data_unref (_data4_);
#line 108 "/data/src/seahorse/common/exportable.vala"
			_data4_ = NULL;
#line 108 "/data/src/seahorse/common/exportable.vala"
			_g_object_unref0 (chosen);
#line 108 "/data/src/seahorse/common/exportable.vala"
			__g_list_free__g_object_unref0_0 (exporters);
#line 108 "/data/src/seahorse/common/exportable.vala"
			return 0U;
#line 698 "exportable.c"
		}
#line 108 "/data/src/seahorse/common/exportable.vala"
		_vala_output = (g_free (_vala_output), NULL);
#line 108 "/data/src/seahorse/common/exportable.vala"
		_vala_output = _tmp25_;
#line 108 "/data/src/seahorse/common/exportable.vala"
		_vala_output_length1 = _tmp25__length1;
#line 109 "/data/src/seahorse/common/exportable.vala"
		result = total;
#line 109 "/data/src/seahorse/common/exportable.vala"
		block4_data_unref (_data4_);
#line 109 "/data/src/seahorse/common/exportable.vala"
		_data4_ = NULL;
#line 109 "/data/src/seahorse/common/exportable.vala"
		_g_object_unref0 (chosen);
#line 109 "/data/src/seahorse/common/exportable.vala"
		__g_list_free__g_object_unref0_0 (exporters);
#line 109 "/data/src/seahorse/common/exportable.vala"
		if (output) {
#line 109 "/data/src/seahorse/common/exportable.vala"
			*output = _vala_output;
#line 720 "exportable.c"
		} else {
#line 109 "/data/src/seahorse/common/exportable.vala"
			_vala_output = (g_free (_vala_output), NULL);
#line 724 "exportable.c"
		}
#line 109 "/data/src/seahorse/common/exportable.vala"
		if (output_length1) {
#line 109 "/data/src/seahorse/common/exportable.vala"
			*output_length1 = _vala_output_length1;
#line 730 "exportable.c"
		}
#line 109 "/data/src/seahorse/common/exportable.vala"
		return result;
#line 734 "exportable.c"
	}
#line 112 "/data/src/seahorse/common/exportable.vala"
	_tmp30_ = g_new0 (guint8, 0);
#line 112 "/data/src/seahorse/common/exportable.vala"
	_vala_output = (g_free (_vala_output), NULL);
#line 112 "/data/src/seahorse/common/exportable.vala"
	_vala_output = _tmp30_;
#line 112 "/data/src/seahorse/common/exportable.vala"
	_vala_output_length1 = 0;
#line 113 "/data/src/seahorse/common/exportable.vala"
	result = (guint) 0;
#line 113 "/data/src/seahorse/common/exportable.vala"
	_g_object_unref0 (chosen);
#line 113 "/data/src/seahorse/common/exportable.vala"
	__g_list_free__g_object_unref0_0 (exporters);
#line 113 "/data/src/seahorse/common/exportable.vala"
	if (output) {
#line 113 "/data/src/seahorse/common/exportable.vala"
		*output = _vala_output;
#line 754 "exportable.c"
	} else {
#line 113 "/data/src/seahorse/common/exportable.vala"
		_vala_output = (g_free (_vala_output), NULL);
#line 758 "exportable.c"
	}
#line 113 "/data/src/seahorse/common/exportable.vala"
	if (output_length1) {
#line 113 "/data/src/seahorse/common/exportable.vala"
		*output_length1 = _vala_output_length1;
#line 764 "exportable.c"
	}
#line 113 "/data/src/seahorse/common/exportable.vala"
	return result;
#line 768 "exportable.c"
}


static Block5Data* block5_data_ref (Block5Data* _data5_) {
#line 124 "/data/src/seahorse/common/exportable.vala"
	g_atomic_int_inc (&_data5_->_ref_count_);
#line 124 "/data/src/seahorse/common/exportable.vala"
	return _data5_;
#line 777 "exportable.c"
}


static void block5_data_unref (void * _userdata_) {
	Block5Data* _data5_;
	_data5_ = (Block5Data*) _userdata_;
#line 124 "/data/src/seahorse/common/exportable.vala"
	if (g_atomic_int_dec_and_test (&_data5_->_ref_count_)) {
#line 124 "/data/src/seahorse/common/exportable.vala"
		_g_object_unref0 (_data5_->_result_);
#line 124 "/data/src/seahorse/common/exportable.vala"
		_g_main_loop_unref0 (_data5_->loop);
#line 124 "/data/src/seahorse/common/exportable.vala"
		g_slice_free (Block5Data, _data5_);
#line 792 "exportable.c"
	}
}


static void ____lambda5_ (Block5Data* _data5_, GObject* obj, GAsyncResult* res) {
	GAsyncResult* _tmp0_ = NULL;
	GAsyncResult* _tmp1_ = NULL;
	GMainLoop* _tmp2_ = NULL;
#line 159 "/data/src/seahorse/common/exportable.vala"
	g_return_if_fail (res != NULL);
#line 160 "/data/src/seahorse/common/exportable.vala"
	_tmp0_ = res;
#line 160 "/data/src/seahorse/common/exportable.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 160 "/data/src/seahorse/common/exportable.vala"
	_g_object_unref0 (_data5_->_result_);
#line 160 "/data/src/seahorse/common/exportable.vala"
	_data5_->_result_ = _tmp1_;
#line 161 "/data/src/seahorse/common/exportable.vala"
	_tmp2_ = _data5_->loop;
#line 161 "/data/src/seahorse/common/exportable.vala"
	g_main_loop_quit (_tmp2_);
#line 815 "exportable.c"
}


static void _____lambda5__gasync_ready_callback (GObject* source_object, GAsyncResult* res, gpointer self) {
#line 159 "/data/src/seahorse/common/exportable.vala"
	____lambda5_ (self, source_object, res);
#line 159 "/data/src/seahorse/common/exportable.vala"
	block5_data_unref (self);
#line 824 "exportable.c"
}


gint seahorse_exportable_export_to_prompt_wait (GList* objects, GtkWindow* parent, GError** error) {
	gint result = 0;
	gint count = 0;
	GHashTable* pending = NULL;
	GHashFunc _tmp0_ = NULL;
	GEqualFunc _tmp1_ = NULL;
	GHashTable* _tmp2_ = NULL;
	GList* _tmp3_ = NULL;
	GList* _tmp7_ = NULL;
	GError * _inner_error_ = NULL;
#line 118 "/data/src/seahorse/common/exportable.vala"
	count = 0;
#line 120 "/data/src/seahorse/common/exportable.vala"
	_tmp0_ = g_direct_hash;
#line 120 "/data/src/seahorse/common/exportable.vala"
	_tmp1_ = g_direct_equal;
#line 120 "/data/src/seahorse/common/exportable.vala"
	_tmp2_ = g_hash_table_new_full (_tmp0_, _tmp1_, NULL, NULL);
#line 120 "/data/src/seahorse/common/exportable.vala"
	pending = _tmp2_;
#line 121 "/data/src/seahorse/common/exportable.vala"
	_tmp3_ = objects;
#line 850 "exportable.c"
	{
		GList* object_collection = NULL;
		GList* object_it = NULL;
#line 121 "/data/src/seahorse/common/exportable.vala"
		object_collection = _tmp3_;
#line 121 "/data/src/seahorse/common/exportable.vala"
		for (object_it = object_collection; object_it != NULL; object_it = object_it->next) {
#line 858 "exportable.c"
			GObject* _tmp4_ = NULL;
			GObject* object = NULL;
#line 121 "/data/src/seahorse/common/exportable.vala"
			_tmp4_ = _g_object_ref0 ((GObject*) object_it->data);
#line 121 "/data/src/seahorse/common/exportable.vala"
			object = _tmp4_;
#line 865 "exportable.c"
			{
				GHashTable* _tmp5_ = NULL;
				GObject* _tmp6_ = NULL;
#line 122 "/data/src/seahorse/common/exportable.vala"
				_tmp5_ = pending;
#line 122 "/data/src/seahorse/common/exportable.vala"
				_tmp6_ = object;
#line 122 "/data/src/seahorse/common/exportable.vala"
				g_hash_table_add (_tmp5_, _tmp6_);
#line 121 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (object);
#line 877 "exportable.c"
			}
		}
	}
#line 124 "/data/src/seahorse/common/exportable.vala"
	_tmp7_ = objects;
#line 883 "exportable.c"
	{
		GList* object_collection = NULL;
		GList* object_it = NULL;
#line 124 "/data/src/seahorse/common/exportable.vala"
		object_collection = _tmp7_;
#line 124 "/data/src/seahorse/common/exportable.vala"
		for (object_it = object_collection; object_it != NULL; object_it = object_it->next) {
#line 891 "exportable.c"
			GObject* _tmp8_ = NULL;
			GObject* object = NULL;
#line 124 "/data/src/seahorse/common/exportable.vala"
			_tmp8_ = _g_object_ref0 ((GObject*) object_it->data);
#line 124 "/data/src/seahorse/common/exportable.vala"
			object = _tmp8_;
#line 898 "exportable.c"
			{
				Block5Data* _data5_;
				GHashTable* _tmp9_ = NULL;
				GObject* _tmp10_ = NULL;
				gconstpointer _tmp11_ = NULL;
				GObject* _tmp12_ = NULL;
				gboolean _tmp13_ = FALSE;
				GList* exporters = NULL;
				GObject* _tmp16_ = NULL;
				GList* _tmp17_ = NULL;
				GList* _tmp18_ = NULL;
				GList* _tmp19_ = NULL;
				gchar* directory = NULL;
				GFile* file = NULL;
				SeahorseExporter* exporter = NULL;
				gboolean ret = FALSE;
				GList* _tmp30_ = NULL;
				GtkWindow* _tmp31_ = NULL;
				GFile* _tmp32_ = NULL;
				SeahorseExporter* _tmp33_ = NULL;
				gboolean _tmp34_ = FALSE;
				gboolean _tmp35_ = FALSE;
				GMainLoop* _tmp36_ = NULL;
				SeahorseExporter* _tmp37_ = NULL;
				GFile* _tmp38_ = NULL;
				GMainLoop* _tmp39_ = NULL;
				SeahorseExporter* _tmp40_ = NULL;
				GAsyncResult* _tmp41_ = NULL;
				SeahorseExporter* _tmp42_ = NULL;
				GList* _tmp43_ = NULL;
#line 124 "/data/src/seahorse/common/exportable.vala"
				_data5_ = g_slice_new0 (Block5Data);
#line 124 "/data/src/seahorse/common/exportable.vala"
				_data5_->_ref_count_ = 1;
#line 125 "/data/src/seahorse/common/exportable.vala"
				_tmp9_ = pending;
#line 125 "/data/src/seahorse/common/exportable.vala"
				_tmp10_ = object;
#line 125 "/data/src/seahorse/common/exportable.vala"
				_tmp11_ = g_hash_table_lookup (_tmp9_, _tmp10_);
#line 125 "/data/src/seahorse/common/exportable.vala"
				if (((GObject*) _tmp11_) == NULL) {
#line 126 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (object);
#line 126 "/data/src/seahorse/common/exportable.vala"
					block5_data_unref (_data5_);
#line 126 "/data/src/seahorse/common/exportable.vala"
					_data5_ = NULL;
#line 126 "/data/src/seahorse/common/exportable.vala"
					continue;
#line 949 "exportable.c"
				}
#line 128 "/data/src/seahorse/common/exportable.vala"
				_tmp12_ = object;
#line 128 "/data/src/seahorse/common/exportable.vala"
				_tmp13_ = seahorse_exportable_can_export (_tmp12_);
#line 128 "/data/src/seahorse/common/exportable.vala"
				if (!_tmp13_) {
#line 957 "exportable.c"
					GHashTable* _tmp14_ = NULL;
					GObject* _tmp15_ = NULL;
#line 129 "/data/src/seahorse/common/exportable.vala"
					_tmp14_ = pending;
#line 129 "/data/src/seahorse/common/exportable.vala"
					_tmp15_ = object;
#line 129 "/data/src/seahorse/common/exportable.vala"
					g_hash_table_remove (_tmp14_, _tmp15_);
#line 130 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (object);
#line 130 "/data/src/seahorse/common/exportable.vala"
					block5_data_unref (_data5_);
#line 130 "/data/src/seahorse/common/exportable.vala"
					_data5_ = NULL;
#line 130 "/data/src/seahorse/common/exportable.vala"
					continue;
#line 974 "exportable.c"
				}
#line 133 "/data/src/seahorse/common/exportable.vala"
				_tmp16_ = object;
#line 133 "/data/src/seahorse/common/exportable.vala"
				_tmp17_ = seahorse_exportable_create_exporters (G_TYPE_CHECK_INSTANCE_CAST (_tmp16_, SEAHORSE_TYPE_EXPORTABLE, SeahorseExportable), SEAHORSE_EXPORTER_TYPE_ANY);
#line 133 "/data/src/seahorse/common/exportable.vala"
				exporters = _tmp17_;
#line 134 "/data/src/seahorse/common/exportable.vala"
				_tmp18_ = exporters;
#line 134 "/data/src/seahorse/common/exportable.vala"
				if (_tmp18_ == NULL) {
#line 135 "/data/src/seahorse/common/exportable.vala"
					__g_list_free__g_object_unref0_0 (exporters);
#line 135 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (object);
#line 135 "/data/src/seahorse/common/exportable.vala"
					block5_data_unref (_data5_);
#line 135 "/data/src/seahorse/common/exportable.vala"
					_data5_ = NULL;
#line 135 "/data/src/seahorse/common/exportable.vala"
					continue;
#line 996 "exportable.c"
				}
#line 137 "/data/src/seahorse/common/exportable.vala"
				_tmp19_ = objects;
#line 1000 "exportable.c"
				{
					GList* x_collection = NULL;
					GList* x_it = NULL;
#line 137 "/data/src/seahorse/common/exportable.vala"
					x_collection = _tmp19_;
#line 137 "/data/src/seahorse/common/exportable.vala"
					for (x_it = x_collection; x_it != NULL; x_it = x_it->next) {
#line 1008 "exportable.c"
						GObject* _tmp20_ = NULL;
						GObject* x = NULL;
#line 137 "/data/src/seahorse/common/exportable.vala"
						_tmp20_ = _g_object_ref0 ((GObject*) x_it->data);
#line 137 "/data/src/seahorse/common/exportable.vala"
						x = _tmp20_;
#line 1015 "exportable.c"
						{
							GObject* _tmp21_ = NULL;
							GObject* _tmp22_ = NULL;
							GHashTable* _tmp23_ = NULL;
							GObject* _tmp24_ = NULL;
							gconstpointer _tmp25_ = NULL;
#line 138 "/data/src/seahorse/common/exportable.vala"
							_tmp21_ = x;
#line 138 "/data/src/seahorse/common/exportable.vala"
							_tmp22_ = object;
#line 138 "/data/src/seahorse/common/exportable.vala"
							if (_tmp21_ == _tmp22_) {
#line 139 "/data/src/seahorse/common/exportable.vala"
								_g_object_unref0 (x);
#line 139 "/data/src/seahorse/common/exportable.vala"
								continue;
#line 1032 "exportable.c"
							}
#line 140 "/data/src/seahorse/common/exportable.vala"
							_tmp23_ = pending;
#line 140 "/data/src/seahorse/common/exportable.vala"
							_tmp24_ = x;
#line 140 "/data/src/seahorse/common/exportable.vala"
							_tmp25_ = g_hash_table_lookup (_tmp23_, _tmp24_);
#line 140 "/data/src/seahorse/common/exportable.vala"
							if (((GObject*) _tmp25_) != NULL) {
#line 1042 "exportable.c"
								GList* _tmp26_ = NULL;
#line 141 "/data/src/seahorse/common/exportable.vala"
								_tmp26_ = exporters;
#line 1046 "exportable.c"
								{
									GList* exporter_collection = NULL;
									GList* exporter_it = NULL;
#line 141 "/data/src/seahorse/common/exportable.vala"
									exporter_collection = _tmp26_;
#line 141 "/data/src/seahorse/common/exportable.vala"
									for (exporter_it = exporter_collection; exporter_it != NULL; exporter_it = exporter_it->next) {
#line 1054 "exportable.c"
										SeahorseExporter* _tmp27_ = NULL;
										SeahorseExporter* exporter = NULL;
#line 141 "/data/src/seahorse/common/exportable.vala"
										_tmp27_ = _g_object_ref0 ((SeahorseExporter*) exporter_it->data);
#line 141 "/data/src/seahorse/common/exportable.vala"
										exporter = _tmp27_;
#line 1061 "exportable.c"
										{
											SeahorseExporter* _tmp28_ = NULL;
											GObject* _tmp29_ = NULL;
#line 142 "/data/src/seahorse/common/exportable.vala"
											_tmp28_ = exporter;
#line 142 "/data/src/seahorse/common/exportable.vala"
											_tmp29_ = x;
#line 142 "/data/src/seahorse/common/exportable.vala"
											seahorse_exporter_add_object (_tmp28_, _tmp29_);
#line 141 "/data/src/seahorse/common/exportable.vala"
											_g_object_unref0 (exporter);
#line 1073 "exportable.c"
										}
									}
								}
							}
#line 137 "/data/src/seahorse/common/exportable.vala"
							_g_object_unref0 (x);
#line 1080 "exportable.c"
						}
					}
				}
#line 146 "/data/src/seahorse/common/exportable.vala"
				directory = NULL;
#line 151 "/data/src/seahorse/common/exportable.vala"
				_tmp30_ = exporters;
#line 151 "/data/src/seahorse/common/exportable.vala"
				_tmp31_ = parent;
#line 151 "/data/src/seahorse/common/exportable.vala"
				_tmp34_ = seahorse_exportable_prompt (_tmp30_, _tmp31_, &directory, &_tmp32_, &_tmp33_);
#line 151 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (file);
#line 151 "/data/src/seahorse/common/exportable.vala"
				file = _tmp32_;
#line 151 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (exporter);
#line 151 "/data/src/seahorse/common/exportable.vala"
				exporter = _tmp33_;
#line 151 "/data/src/seahorse/common/exportable.vala"
				ret = _tmp34_;
#line 153 "/data/src/seahorse/common/exportable.vala"
				_tmp35_ = ret;
#line 153 "/data/src/seahorse/common/exportable.vala"
				if (!_tmp35_) {
#line 154 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (exporter);
#line 154 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (file);
#line 154 "/data/src/seahorse/common/exportable.vala"
					_g_free0 (directory);
#line 154 "/data/src/seahorse/common/exportable.vala"
					__g_list_free__g_object_unref0_0 (exporters);
#line 154 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (object);
#line 154 "/data/src/seahorse/common/exportable.vala"
					block5_data_unref (_data5_);
#line 154 "/data/src/seahorse/common/exportable.vala"
					_data5_ = NULL;
#line 154 "/data/src/seahorse/common/exportable.vala"
					break;
#line 1122 "exportable.c"
				}
#line 156 "/data/src/seahorse/common/exportable.vala"
				_tmp36_ = g_main_loop_new (NULL, FALSE);
#line 156 "/data/src/seahorse/common/exportable.vala"
				_data5_->loop = _tmp36_;
#line 157 "/data/src/seahorse/common/exportable.vala"
				_data5_->_result_ = NULL;
#line 159 "/data/src/seahorse/common/exportable.vala"
				_tmp37_ = exporter;
#line 159 "/data/src/seahorse/common/exportable.vala"
				_tmp38_ = file;
#line 159 "/data/src/seahorse/common/exportable.vala"
				seahorse_exporter_export_to_file (_tmp37_, _tmp38_, TRUE, NULL, _____lambda5__gasync_ready_callback, block5_data_ref (_data5_));
#line 164 "/data/src/seahorse/common/exportable.vala"
				_tmp39_ = _data5_->loop;
#line 164 "/data/src/seahorse/common/exportable.vala"
				g_main_loop_run (_tmp39_);
#line 166 "/data/src/seahorse/common/exportable.vala"
				_tmp40_ = exporter;
#line 166 "/data/src/seahorse/common/exportable.vala"
				_tmp41_ = _data5_->_result_;
#line 166 "/data/src/seahorse/common/exportable.vala"
				seahorse_exporter_export_to_file_finish (_tmp40_, _tmp41_, &_inner_error_);
#line 166 "/data/src/seahorse/common/exportable.vala"
				if (_inner_error_ != NULL) {
#line 166 "/data/src/seahorse/common/exportable.vala"
					g_propagate_error (error, _inner_error_);
#line 166 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (exporter);
#line 166 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (file);
#line 166 "/data/src/seahorse/common/exportable.vala"
					_g_free0 (directory);
#line 166 "/data/src/seahorse/common/exportable.vala"
					__g_list_free__g_object_unref0_0 (exporters);
#line 166 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (object);
#line 166 "/data/src/seahorse/common/exportable.vala"
					block5_data_unref (_data5_);
#line 166 "/data/src/seahorse/common/exportable.vala"
					_data5_ = NULL;
#line 166 "/data/src/seahorse/common/exportable.vala"
					_g_hash_table_unref0 (pending);
#line 166 "/data/src/seahorse/common/exportable.vala"
					return 0;
#line 1168 "exportable.c"
				}
#line 167 "/data/src/seahorse/common/exportable.vala"
				_tmp42_ = exporter;
#line 167 "/data/src/seahorse/common/exportable.vala"
				_tmp43_ = seahorse_exporter_get_objects (_tmp42_);
#line 1174 "exportable.c"
				{
					GList* e_collection = NULL;
					GList* e_it = NULL;
#line 167 "/data/src/seahorse/common/exportable.vala"
					e_collection = _tmp43_;
#line 167 "/data/src/seahorse/common/exportable.vala"
					for (e_it = e_collection; e_it != NULL; e_it = e_it->next) {
#line 1182 "exportable.c"
						GObject* e = NULL;
#line 167 "/data/src/seahorse/common/exportable.vala"
						e = (GObject*) e_it->data;
#line 1186 "exportable.c"
						{
							GHashTable* _tmp44_ = NULL;
							GObject* _tmp45_ = NULL;
							gint _tmp46_ = 0;
#line 168 "/data/src/seahorse/common/exportable.vala"
							_tmp44_ = pending;
#line 168 "/data/src/seahorse/common/exportable.vala"
							_tmp45_ = e;
#line 168 "/data/src/seahorse/common/exportable.vala"
							g_hash_table_remove (_tmp44_, _tmp45_);
#line 169 "/data/src/seahorse/common/exportable.vala"
							_tmp46_ = count;
#line 169 "/data/src/seahorse/common/exportable.vala"
							count = _tmp46_ + 1;
#line 1201 "exportable.c"
						}
					}
				}
#line 124 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (exporter);
#line 124 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (file);
#line 124 "/data/src/seahorse/common/exportable.vala"
				_g_free0 (directory);
#line 124 "/data/src/seahorse/common/exportable.vala"
				__g_list_free__g_object_unref0_0 (exporters);
#line 124 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (object);
#line 124 "/data/src/seahorse/common/exportable.vala"
				block5_data_unref (_data5_);
#line 124 "/data/src/seahorse/common/exportable.vala"
				_data5_ = NULL;
#line 1219 "exportable.c"
			}
		}
	}
#line 173 "/data/src/seahorse/common/exportable.vala"
	result = count;
#line 173 "/data/src/seahorse/common/exportable.vala"
	_g_hash_table_unref0 (pending);
#line 173 "/data/src/seahorse/common/exportable.vala"
	return result;
#line 1229 "exportable.c"
}


static gint string_last_index_of_char (const gchar* self, gunichar c, gint start_index) {
	gint result = 0;
	gchar* _result_ = NULL;
	gint _tmp0_ = 0;
	gunichar _tmp1_ = 0U;
	gchar* _tmp2_ = NULL;
	gchar* _tmp3_ = NULL;
#line 928 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, 0);
#line 929 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp0_ = start_index;
#line 929 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp1_ = c;
#line 929 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp2_ = g_utf8_strrchr (((gchar*) self) + _tmp0_, (gssize) (-1), _tmp1_);
#line 929 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_result_ = _tmp2_;
#line 931 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp3_ = _result_;
#line 931 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	if (_tmp3_ != NULL) {
#line 1254 "exportable.c"
		gchar* _tmp4_ = NULL;
#line 932 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp4_ = _result_;
#line 932 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		result = (gint) (_tmp4_ - ((gchar*) self));
#line 932 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		return result;
#line 1262 "exportable.c"
	} else {
#line 934 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		result = -1;
#line 934 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		return result;
#line 1268 "exportable.c"
	}
}


static glong string_strnlen (gchar* str, glong maxlen) {
	glong result = 0L;
	gchar* end = NULL;
	gchar* _tmp0_ = NULL;
	glong _tmp1_ = 0L;
	gchar* _tmp2_ = NULL;
	gchar* _tmp3_ = NULL;
#line 1156 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp0_ = str;
#line 1156 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp1_ = maxlen;
#line 1156 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp2_ = memchr (_tmp0_, 0, (gsize) _tmp1_);
#line 1156 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	end = _tmp2_;
#line 1157 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp3_ = end;
#line 1157 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	if (_tmp3_ == NULL) {
#line 1292 "exportable.c"
		glong _tmp4_ = 0L;
#line 1158 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp4_ = maxlen;
#line 1158 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		result = _tmp4_;
#line 1158 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		return result;
#line 1300 "exportable.c"
	} else {
		gchar* _tmp5_ = NULL;
		gchar* _tmp6_ = NULL;
#line 1160 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp5_ = end;
#line 1160 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp6_ = str;
#line 1160 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		result = (glong) (_tmp5_ - _tmp6_);
#line 1160 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		return result;
#line 1312 "exportable.c"
	}
}


static gchar* string_substring (const gchar* self, glong offset, glong len) {
	gchar* result = NULL;
	glong string_length = 0L;
	gboolean _tmp0_ = FALSE;
	glong _tmp1_ = 0L;
	gboolean _tmp3_ = FALSE;
	glong _tmp9_ = 0L;
	glong _tmp15_ = 0L;
	glong _tmp18_ = 0L;
	glong _tmp19_ = 0L;
	glong _tmp20_ = 0L;
	glong _tmp21_ = 0L;
	glong _tmp22_ = 0L;
	gchar* _tmp23_ = NULL;
#line 1167 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, NULL);
#line 1169 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp1_ = offset;
#line 1169 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	if (_tmp1_ >= ((glong) 0)) {
#line 1337 "exportable.c"
		glong _tmp2_ = 0L;
#line 1169 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp2_ = len;
#line 1169 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp0_ = _tmp2_ >= ((glong) 0);
#line 1343 "exportable.c"
	} else {
#line 1169 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp0_ = FALSE;
#line 1347 "exportable.c"
	}
#line 1169 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp3_ = _tmp0_;
#line 1169 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	if (_tmp3_) {
#line 1353 "exportable.c"
		glong _tmp4_ = 0L;
		glong _tmp5_ = 0L;
		glong _tmp6_ = 0L;
#line 1171 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp4_ = offset;
#line 1171 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp5_ = len;
#line 1171 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp6_ = string_strnlen ((gchar*) self, _tmp4_ + _tmp5_);
#line 1171 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		string_length = _tmp6_;
#line 1365 "exportable.c"
	} else {
		gint _tmp7_ = 0;
		gint _tmp8_ = 0;
#line 1173 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp7_ = strlen (self);
#line 1173 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp8_ = _tmp7_;
#line 1173 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		string_length = (glong) _tmp8_;
#line 1375 "exportable.c"
	}
#line 1176 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp9_ = offset;
#line 1176 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	if (_tmp9_ < ((glong) 0)) {
#line 1381 "exportable.c"
		glong _tmp10_ = 0L;
		glong _tmp11_ = 0L;
		glong _tmp12_ = 0L;
#line 1177 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp10_ = string_length;
#line 1177 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp11_ = offset;
#line 1177 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		offset = _tmp10_ + _tmp11_;
#line 1178 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp12_ = offset;
#line 1178 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		g_return_val_if_fail (_tmp12_ >= ((glong) 0), NULL);
#line 1395 "exportable.c"
	} else {
		glong _tmp13_ = 0L;
		glong _tmp14_ = 0L;
#line 1180 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp13_ = offset;
#line 1180 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp14_ = string_length;
#line 1180 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		g_return_val_if_fail (_tmp13_ <= _tmp14_, NULL);
#line 1405 "exportable.c"
	}
#line 1182 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp15_ = len;
#line 1182 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	if (_tmp15_ < ((glong) 0)) {
#line 1411 "exportable.c"
		glong _tmp16_ = 0L;
		glong _tmp17_ = 0L;
#line 1183 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp16_ = string_length;
#line 1183 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		_tmp17_ = offset;
#line 1183 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
		len = _tmp16_ - _tmp17_;
#line 1420 "exportable.c"
	}
#line 1185 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp18_ = offset;
#line 1185 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp19_ = len;
#line 1185 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp20_ = string_length;
#line 1185 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	g_return_val_if_fail ((_tmp18_ + _tmp19_) <= _tmp20_, NULL);
#line 1186 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp21_ = offset;
#line 1186 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp22_ = len;
#line 1186 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	_tmp23_ = g_strndup (((gchar*) self) + _tmp21_, (gsize) _tmp22_);
#line 1186 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	result = _tmp23_;
#line 1186 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
	return result;
#line 1440 "exportable.c"
}


static gchar* seahorse_exportable_calculate_basename (GFile* file, const gchar* extension) {
	gchar* result = NULL;
	gchar* basename = NULL;
	GFile* _tmp0_ = NULL;
	gchar* _tmp1_ = NULL;
	gint dot = 0;
	const gchar* _tmp2_ = NULL;
	gint _tmp3_ = 0;
	gint _tmp4_ = 0;
	const gchar* _tmp8_ = NULL;
	const gchar* _tmp9_ = NULL;
	gchar* _tmp10_ = NULL;
#line 176 "/data/src/seahorse/common/exportable.vala"
	g_return_val_if_fail (file != NULL, NULL);
#line 176 "/data/src/seahorse/common/exportable.vala"
	g_return_val_if_fail (extension != NULL, NULL);
#line 178 "/data/src/seahorse/common/exportable.vala"
	_tmp0_ = file;
#line 178 "/data/src/seahorse/common/exportable.vala"
	_tmp1_ = g_file_get_basename (_tmp0_);
#line 178 "/data/src/seahorse/common/exportable.vala"
	basename = _tmp1_;
#line 179 "/data/src/seahorse/common/exportable.vala"
	_tmp2_ = basename;
#line 179 "/data/src/seahorse/common/exportable.vala"
	_tmp3_ = string_last_index_of_char (_tmp2_, (gunichar) '.', 0);
#line 179 "/data/src/seahorse/common/exportable.vala"
	dot = _tmp3_;
#line 180 "/data/src/seahorse/common/exportable.vala"
	_tmp4_ = dot;
#line 180 "/data/src/seahorse/common/exportable.vala"
	if (_tmp4_ != (-1)) {
#line 1476 "exportable.c"
		const gchar* _tmp5_ = NULL;
		gint _tmp6_ = 0;
		gchar* _tmp7_ = NULL;
#line 181 "/data/src/seahorse/common/exportable.vala"
		_tmp5_ = basename;
#line 181 "/data/src/seahorse/common/exportable.vala"
		_tmp6_ = dot;
#line 181 "/data/src/seahorse/common/exportable.vala"
		_tmp7_ = string_substring (_tmp5_, (glong) 0, (glong) _tmp6_);
#line 181 "/data/src/seahorse/common/exportable.vala"
		_g_free0 (basename);
#line 181 "/data/src/seahorse/common/exportable.vala"
		basename = _tmp7_;
#line 1490 "exportable.c"
	}
#line 182 "/data/src/seahorse/common/exportable.vala"
	_tmp8_ = basename;
#line 182 "/data/src/seahorse/common/exportable.vala"
	_tmp9_ = extension;
#line 182 "/data/src/seahorse/common/exportable.vala"
	_tmp10_ = g_strdup_printf ("%s%s", _tmp8_, _tmp9_);
#line 182 "/data/src/seahorse/common/exportable.vala"
	result = _tmp10_;
#line 182 "/data/src/seahorse/common/exportable.vala"
	_g_free0 (basename);
#line 182 "/data/src/seahorse/common/exportable.vala"
	return result;
#line 1504 "exportable.c"
}


static Block6Data* block6_data_ref (Block6Data* _data6_) {
#line 185 "/data/src/seahorse/common/exportable.vala"
	g_atomic_int_inc (&_data6_->_ref_count_);
#line 185 "/data/src/seahorse/common/exportable.vala"
	return _data6_;
#line 1513 "exportable.c"
}


static void block6_data_unref (void * _userdata_) {
	Block6Data* _data6_;
	_data6_ = (Block6Data*) _userdata_;
#line 185 "/data/src/seahorse/common/exportable.vala"
	if (g_atomic_int_dec_and_test (&_data6_->_ref_count_)) {
#line 185 "/data/src/seahorse/common/exportable.vala"
		_g_hash_table_unref0 (_data6_->filters);
#line 185 "/data/src/seahorse/common/exportable.vala"
		_g_object_unref0 (_data6_->chooser);
#line 185 "/data/src/seahorse/common/exportable.vala"
		g_slice_free (Block6Data, _data6_);
#line 1528 "exportable.c"
	}
}


static void __lambda4_ (Block6Data* _data6_, GObject* obj, GParamSpec* prop) {
	SeahorseExporter* exporter = NULL;
	GHashTable* _tmp0_ = NULL;
	GtkFileChooserDialog* _tmp1_ = NULL;
	GtkFileFilter* _tmp2_ = NULL;
	gconstpointer _tmp3_ = NULL;
	SeahorseExporter* _tmp4_ = NULL;
	gchar* name = NULL;
	SeahorseExporter* _tmp5_ = NULL;
	gchar* _tmp6_ = NULL;
	gchar* _tmp7_ = NULL;
	gint dot = 0;
	const gchar* _tmp8_ = NULL;
	gint _tmp9_ = 0;
	gint _tmp10_ = 0;
#line 212 "/data/src/seahorse/common/exportable.vala"
	g_return_if_fail (obj != NULL);
#line 212 "/data/src/seahorse/common/exportable.vala"
	g_return_if_fail (prop != NULL);
#line 213 "/data/src/seahorse/common/exportable.vala"
	_tmp0_ = _data6_->filters;
#line 213 "/data/src/seahorse/common/exportable.vala"
	_tmp1_ = _data6_->chooser;
#line 213 "/data/src/seahorse/common/exportable.vala"
	_tmp2_ = gtk_file_chooser_get_filter ((GtkFileChooser*) _tmp1_);
#line 213 "/data/src/seahorse/common/exportable.vala"
	_tmp3_ = g_hash_table_lookup (_tmp0_, _tmp2_);
#line 213 "/data/src/seahorse/common/exportable.vala"
	_tmp4_ = _g_object_ref0 ((SeahorseExporter*) _tmp3_);
#line 213 "/data/src/seahorse/common/exportable.vala"
	exporter = _tmp4_;
#line 214 "/data/src/seahorse/common/exportable.vala"
	_tmp5_ = exporter;
#line 214 "/data/src/seahorse/common/exportable.vala"
	_tmp6_ = seahorse_exporter_get_filename (_tmp5_);
#line 214 "/data/src/seahorse/common/exportable.vala"
	_tmp7_ = _tmp6_;
#line 214 "/data/src/seahorse/common/exportable.vala"
	name = _tmp7_;
#line 215 "/data/src/seahorse/common/exportable.vala"
	_tmp8_ = name;
#line 215 "/data/src/seahorse/common/exportable.vala"
	_tmp9_ = string_last_index_of_char (_tmp8_, (gunichar) '.', 0);
#line 215 "/data/src/seahorse/common/exportable.vala"
	dot = _tmp9_;
#line 216 "/data/src/seahorse/common/exportable.vala"
	_tmp10_ = dot;
#line 216 "/data/src/seahorse/common/exportable.vala"
	if (_tmp10_ != (-1)) {
#line 1582 "exportable.c"
		GFile* file = NULL;
		GtkFileChooserDialog* _tmp11_ = NULL;
		GFile* _tmp12_ = NULL;
		GFile* _tmp13_ = NULL;
		GFile* _tmp14_ = NULL;
#line 217 "/data/src/seahorse/common/exportable.vala"
		_tmp11_ = _data6_->chooser;
#line 217 "/data/src/seahorse/common/exportable.vala"
		_tmp12_ = gtk_file_chooser_get_file ((GtkFileChooser*) _tmp11_);
#line 217 "/data/src/seahorse/common/exportable.vala"
		_tmp13_ = _g_object_ref0 (_tmp12_);
#line 217 "/data/src/seahorse/common/exportable.vala"
		file = _tmp13_;
#line 218 "/data/src/seahorse/common/exportable.vala"
		_tmp14_ = file;
#line 218 "/data/src/seahorse/common/exportable.vala"
		if (_tmp14_ != NULL) {
#line 1600 "exportable.c"
			gchar* basename = NULL;
			GFile* _tmp15_ = NULL;
			const gchar* _tmp16_ = NULL;
			gint _tmp17_ = 0;
			gchar* _tmp18_ = NULL;
			gchar* _tmp19_ = NULL;
			gchar* _tmp20_ = NULL;
			gchar* _tmp21_ = NULL;
			GtkFileChooserDialog* _tmp22_ = NULL;
			const gchar* _tmp23_ = NULL;
#line 219 "/data/src/seahorse/common/exportable.vala"
			_tmp15_ = file;
#line 219 "/data/src/seahorse/common/exportable.vala"
			_tmp16_ = name;
#line 219 "/data/src/seahorse/common/exportable.vala"
			_tmp17_ = dot;
#line 219 "/data/src/seahorse/common/exportable.vala"
			_tmp18_ = string_substring (_tmp16_, (glong) _tmp17_, (glong) (-1));
#line 219 "/data/src/seahorse/common/exportable.vala"
			_tmp19_ = _tmp18_;
#line 219 "/data/src/seahorse/common/exportable.vala"
			_tmp20_ = seahorse_exportable_calculate_basename (_tmp15_, _tmp19_);
#line 219 "/data/src/seahorse/common/exportable.vala"
			_tmp21_ = _tmp20_;
#line 219 "/data/src/seahorse/common/exportable.vala"
			_g_free0 (_tmp19_);
#line 219 "/data/src/seahorse/common/exportable.vala"
			basename = _tmp21_;
#line 220 "/data/src/seahorse/common/exportable.vala"
			_tmp22_ = _data6_->chooser;
#line 220 "/data/src/seahorse/common/exportable.vala"
			_tmp23_ = basename;
#line 220 "/data/src/seahorse/common/exportable.vala"
			gtk_file_chooser_set_current_name ((GtkFileChooser*) _tmp22_, _tmp23_);
#line 218 "/data/src/seahorse/common/exportable.vala"
			_g_free0 (basename);
#line 1637 "exportable.c"
		} else {
			GtkFileChooserDialog* _tmp24_ = NULL;
			const gchar* _tmp25_ = NULL;
#line 222 "/data/src/seahorse/common/exportable.vala"
			_tmp24_ = _data6_->chooser;
#line 222 "/data/src/seahorse/common/exportable.vala"
			_tmp25_ = name;
#line 222 "/data/src/seahorse/common/exportable.vala"
			gtk_file_chooser_set_current_name ((GtkFileChooser*) _tmp24_, _tmp25_);
#line 1647 "exportable.c"
		}
#line 216 "/data/src/seahorse/common/exportable.vala"
		_g_object_unref0 (file);
#line 1651 "exportable.c"
	}
#line 212 "/data/src/seahorse/common/exportable.vala"
	_g_free0 (name);
#line 212 "/data/src/seahorse/common/exportable.vala"
	_g_object_unref0 (exporter);
#line 1657 "exportable.c"
}


static void ___lambda4__g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
#line 212 "/data/src/seahorse/common/exportable.vala"
	__lambda4_ (self, _sender, pspec);
#line 1664 "exportable.c"
}


gboolean seahorse_exportable_prompt (GList* exporters, GtkWindow* parent, gchar** directory, GFile** chosen_file, SeahorseExporter** chosen_exporter) {
	GFile* _vala_chosen_file = NULL;
	SeahorseExporter* _vala_chosen_exporter = NULL;
	gboolean result = FALSE;
	Block6Data* _data6_;
	GtkWindow* _tmp0_ = NULL;
	const gchar* _tmp1_ = NULL;
	GtkFileChooserDialog* _tmp2_ = NULL;
	GtkFileChooserDialog* _tmp3_ = NULL;
	GtkFileChooserDialog* _tmp4_ = NULL;
	GtkFileChooserDialog* _tmp5_ = NULL;
	const gchar* _tmp6_ = NULL;
	GtkFileFilter* first = NULL;
	GHashFunc _tmp9_ = NULL;
	GEqualFunc _tmp10_ = NULL;
	GHashTable* _tmp11_ = NULL;
	GList* _tmp12_ = NULL;
	GtkFileChooserDialog* _tmp28_ = NULL;
	GtkFileChooserDialog* _tmp29_ = NULL;
	GtkFileFilter* _tmp30_ = NULL;
	GtkFileChooserDialog* _tmp31_ = NULL;
	gint _tmp32_ = 0;
	GtkFileChooserDialog* _tmp44_ = NULL;
#line 185 "/data/src/seahorse/common/exportable.vala"
	_data6_ = g_slice_new0 (Block6Data);
#line 185 "/data/src/seahorse/common/exportable.vala"
	_data6_->_ref_count_ = 1;
#line 190 "/data/src/seahorse/common/exportable.vala"
	_tmp0_ = parent;
#line 190 "/data/src/seahorse/common/exportable.vala"
	_tmp1_ = _ ("Export");
#line 190 "/data/src/seahorse/common/exportable.vala"
	_tmp2_ = (GtkFileChooserDialog*) gtk_file_chooser_dialog_new (NULL, _tmp0_, GTK_FILE_CHOOSER_ACTION_SAVE, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, _tmp1_, GTK_RESPONSE_ACCEPT, NULL, NULL);
#line 190 "/data/src/seahorse/common/exportable.vala"
	g_object_ref_sink (_tmp2_);
#line 190 "/data/src/seahorse/common/exportable.vala"
	_data6_->chooser = _tmp2_;
#line 195 "/data/src/seahorse/common/exportable.vala"
	_tmp3_ = _data6_->chooser;
#line 195 "/data/src/seahorse/common/exportable.vala"
	gtk_dialog_set_default_response ((GtkDialog*) _tmp3_, (gint) GTK_RESPONSE_ACCEPT);
#line 196 "/data/src/seahorse/common/exportable.vala"
	_tmp4_ = _data6_->chooser;
#line 196 "/data/src/seahorse/common/exportable.vala"
	gtk_file_chooser_set_local_only ((GtkFileChooser*) _tmp4_, FALSE);
#line 197 "/data/src/seahorse/common/exportable.vala"
	_tmp5_ = _data6_->chooser;
#line 197 "/data/src/seahorse/common/exportable.vala"
	gtk_file_chooser_set_do_overwrite_confirmation ((GtkFileChooser*) _tmp5_, TRUE);
#line 199 "/data/src/seahorse/common/exportable.vala"
	_tmp6_ = *directory;
#line 199 "/data/src/seahorse/common/exportable.vala"
	if (_tmp6_ != NULL) {
#line 1721 "exportable.c"
		GtkFileChooserDialog* _tmp7_ = NULL;
		const gchar* _tmp8_ = NULL;
#line 200 "/data/src/seahorse/common/exportable.vala"
		_tmp7_ = _data6_->chooser;
#line 200 "/data/src/seahorse/common/exportable.vala"
		_tmp8_ = *directory;
#line 200 "/data/src/seahorse/common/exportable.vala"
		gtk_file_chooser_set_current_folder ((GtkFileChooser*) _tmp7_, _tmp8_);
#line 1730 "exportable.c"
	}
#line 202 "/data/src/seahorse/common/exportable.vala"
	first = NULL;
#line 203 "/data/src/seahorse/common/exportable.vala"
	_tmp9_ = g_direct_hash;
#line 203 "/data/src/seahorse/common/exportable.vala"
	_tmp10_ = g_direct_equal;
#line 203 "/data/src/seahorse/common/exportable.vala"
	_tmp11_ = g_hash_table_new_full (_tmp9_, _tmp10_, _g_object_unref0_, _g_object_unref0_);
#line 203 "/data/src/seahorse/common/exportable.vala"
	_data6_->filters = _tmp11_;
#line 204 "/data/src/seahorse/common/exportable.vala"
	_tmp12_ = exporters;
#line 1744 "exportable.c"
	{
		GList* exporter_collection = NULL;
		GList* exporter_it = NULL;
#line 204 "/data/src/seahorse/common/exportable.vala"
		exporter_collection = _tmp12_;
#line 204 "/data/src/seahorse/common/exportable.vala"
		for (exporter_it = exporter_collection; exporter_it != NULL; exporter_it = exporter_it->next) {
#line 1752 "exportable.c"
			SeahorseExporter* _tmp13_ = NULL;
			SeahorseExporter* exporter = NULL;
#line 204 "/data/src/seahorse/common/exportable.vala"
			_tmp13_ = _g_object_ref0 ((SeahorseExporter*) exporter_it->data);
#line 204 "/data/src/seahorse/common/exportable.vala"
			exporter = _tmp13_;
#line 1759 "exportable.c"
			{
				GtkFileFilter* filter = NULL;
				SeahorseExporter* _tmp14_ = NULL;
				GtkFileFilter* _tmp15_ = NULL;
				GtkFileFilter* _tmp16_ = NULL;
				GHashTable* _tmp17_ = NULL;
				GtkFileFilter* _tmp18_ = NULL;
				GtkFileFilter* _tmp19_ = NULL;
				SeahorseExporter* _tmp20_ = NULL;
				SeahorseExporter* _tmp21_ = NULL;
				GtkFileChooserDialog* _tmp22_ = NULL;
				GtkFileFilter* _tmp23_ = NULL;
				GtkFileFilter* _tmp24_ = NULL;
				GtkFileFilter* _tmp25_ = NULL;
#line 205 "/data/src/seahorse/common/exportable.vala"
				_tmp14_ = exporter;
#line 205 "/data/src/seahorse/common/exportable.vala"
				_tmp15_ = seahorse_exporter_get_file_filter (_tmp14_);
#line 205 "/data/src/seahorse/common/exportable.vala"
				_tmp16_ = _tmp15_;
#line 205 "/data/src/seahorse/common/exportable.vala"
				filter = _tmp16_;
#line 206 "/data/src/seahorse/common/exportable.vala"
				_tmp17_ = _data6_->filters;
#line 206 "/data/src/seahorse/common/exportable.vala"
				_tmp18_ = filter;
#line 206 "/data/src/seahorse/common/exportable.vala"
				_tmp19_ = _g_object_ref0 (_tmp18_);
#line 206 "/data/src/seahorse/common/exportable.vala"
				_tmp20_ = exporter;
#line 206 "/data/src/seahorse/common/exportable.vala"
				_tmp21_ = _g_object_ref0 (_tmp20_);
#line 206 "/data/src/seahorse/common/exportable.vala"
				g_hash_table_replace (_tmp17_, _tmp19_, _tmp21_);
#line 207 "/data/src/seahorse/common/exportable.vala"
				_tmp22_ = _data6_->chooser;
#line 207 "/data/src/seahorse/common/exportable.vala"
				_tmp23_ = filter;
#line 207 "/data/src/seahorse/common/exportable.vala"
				_tmp24_ = _g_object_ref0 (_tmp23_);
#line 207 "/data/src/seahorse/common/exportable.vala"
				gtk_file_chooser_add_filter ((GtkFileChooser*) _tmp22_, _tmp24_);
#line 208 "/data/src/seahorse/common/exportable.vala"
				_tmp25_ = first;
#line 208 "/data/src/seahorse/common/exportable.vala"
				if (_tmp25_ == NULL) {
#line 1806 "exportable.c"
					GtkFileFilter* _tmp26_ = NULL;
					GtkFileFilter* _tmp27_ = NULL;
#line 209 "/data/src/seahorse/common/exportable.vala"
					_tmp26_ = filter;
#line 209 "/data/src/seahorse/common/exportable.vala"
					_tmp27_ = _g_object_ref0 (_tmp26_);
#line 209 "/data/src/seahorse/common/exportable.vala"
					_g_object_unref0 (first);
#line 209 "/data/src/seahorse/common/exportable.vala"
					first = _tmp27_;
#line 1817 "exportable.c"
				}
#line 204 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (filter);
#line 204 "/data/src/seahorse/common/exportable.vala"
				_g_object_unref0 (exporter);
#line 1823 "exportable.c"
			}
		}
	}
#line 212 "/data/src/seahorse/common/exportable.vala"
	_tmp28_ = _data6_->chooser;
#line 212 "/data/src/seahorse/common/exportable.vala"
	g_signal_connect_data ((GObject*) _tmp28_, "notify", (GCallback) ___lambda4__g_object_notify, block6_data_ref (_data6_), (GClosureNotify) block6_data_unref, 0);
#line 227 "/data/src/seahorse/common/exportable.vala"
	_tmp29_ = _data6_->chooser;
#line 227 "/data/src/seahorse/common/exportable.vala"
	_tmp30_ = first;
#line 227 "/data/src/seahorse/common/exportable.vala"
	gtk_file_chooser_set_filter ((GtkFileChooser*) _tmp29_, _tmp30_);
#line 229 "/data/src/seahorse/common/exportable.vala"
	_tmp31_ = _data6_->chooser;
#line 229 "/data/src/seahorse/common/exportable.vala"
	_tmp32_ = gtk_dialog_run ((GtkDialog*) _tmp31_);
#line 229 "/data/src/seahorse/common/exportable.vala"
	if (_tmp32_ == ((gint) GTK_RESPONSE_ACCEPT)) {
#line 1843 "exportable.c"
		GtkFileChooserDialog* _tmp33_ = NULL;
		GFile* _tmp34_ = NULL;
		GFile* _tmp35_ = NULL;
		GHashTable* _tmp36_ = NULL;
		GtkFileChooserDialog* _tmp37_ = NULL;
		GtkFileFilter* _tmp38_ = NULL;
		gconstpointer _tmp39_ = NULL;
		SeahorseExporter* _tmp40_ = NULL;
		GtkFileChooserDialog* _tmp41_ = NULL;
		gchar* _tmp42_ = NULL;
		GtkFileChooserDialog* _tmp43_ = NULL;
#line 230 "/data/src/seahorse/common/exportable.vala"
		_tmp33_ = _data6_->chooser;
#line 230 "/data/src/seahorse/common/exportable.vala"
		_tmp34_ = gtk_file_chooser_get_file ((GtkFileChooser*) _tmp33_);
#line 230 "/data/src/seahorse/common/exportable.vala"
		_tmp35_ = _g_object_ref0 (_tmp34_);
#line 230 "/data/src/seahorse/common/exportable.vala"
		_g_object_unref0 (_vala_chosen_file);
#line 230 "/data/src/seahorse/common/exportable.vala"
		_vala_chosen_file = _tmp35_;
#line 231 "/data/src/seahorse/common/exportable.vala"
		_tmp36_ = _data6_->filters;
#line 231 "/data/src/seahorse/common/exportable.vala"
		_tmp37_ = _data6_->chooser;
#line 231 "/data/src/seahorse/common/exportable.vala"
		_tmp38_ = gtk_file_chooser_get_filter ((GtkFileChooser*) _tmp37_);
#line 231 "/data/src/seahorse/common/exportable.vala"
		_tmp39_ = g_hash_table_lookup (_tmp36_, _tmp38_);
#line 231 "/data/src/seahorse/common/exportable.vala"
		_tmp40_ = _g_object_ref0 ((SeahorseExporter*) _tmp39_);
#line 231 "/data/src/seahorse/common/exportable.vala"
		_g_object_unref0 (_vala_chosen_exporter);
#line 231 "/data/src/seahorse/common/exportable.vala"
		_vala_chosen_exporter = _tmp40_;
#line 232 "/data/src/seahorse/common/exportable.vala"
		_tmp41_ = _data6_->chooser;
#line 232 "/data/src/seahorse/common/exportable.vala"
		_tmp42_ = gtk_file_chooser_get_current_folder ((GtkFileChooser*) _tmp41_);
#line 232 "/data/src/seahorse/common/exportable.vala"
		_g_free0 (*directory);
#line 232 "/data/src/seahorse/common/exportable.vala"
		*directory = _tmp42_;
#line 233 "/data/src/seahorse/common/exportable.vala"
		_tmp43_ = _data6_->chooser;
#line 233 "/data/src/seahorse/common/exportable.vala"
		gtk_widget_destroy ((GtkWidget*) _tmp43_);
#line 234 "/data/src/seahorse/common/exportable.vala"
		result = TRUE;
#line 234 "/data/src/seahorse/common/exportable.vala"
		_g_object_unref0 (first);
#line 234 "/data/src/seahorse/common/exportable.vala"
		block6_data_unref (_data6_);
#line 234 "/data/src/seahorse/common/exportable.vala"
		_data6_ = NULL;
#line 234 "/data/src/seahorse/common/exportable.vala"
		if (chosen_file) {
#line 234 "/data/src/seahorse/common/exportable.vala"
			*chosen_file = _vala_chosen_file;
#line 1903 "exportable.c"
		} else {
#line 234 "/data/src/seahorse/common/exportable.vala"
			_g_object_unref0 (_vala_chosen_file);
#line 1907 "exportable.c"
		}
#line 234 "/data/src/seahorse/common/exportable.vala"
		if (chosen_exporter) {
#line 234 "/data/src/seahorse/common/exportable.vala"
			*chosen_exporter = _vala_chosen_exporter;
#line 1913 "exportable.c"
		} else {
#line 234 "/data/src/seahorse/common/exportable.vala"
			_g_object_unref0 (_vala_chosen_exporter);
#line 1917 "exportable.c"
		}
#line 234 "/data/src/seahorse/common/exportable.vala"
		return result;
#line 1921 "exportable.c"
	}
#line 237 "/data/src/seahorse/common/exportable.vala"
	_g_object_unref0 (_vala_chosen_file);
#line 237 "/data/src/seahorse/common/exportable.vala"
	_vala_chosen_file = NULL;
#line 238 "/data/src/seahorse/common/exportable.vala"
	_g_object_unref0 (_vala_chosen_exporter);
#line 238 "/data/src/seahorse/common/exportable.vala"
	_vala_chosen_exporter = NULL;
#line 239 "/data/src/seahorse/common/exportable.vala"
	_tmp44_ = _data6_->chooser;
#line 239 "/data/src/seahorse/common/exportable.vala"
	gtk_widget_destroy ((GtkWidget*) _tmp44_);
#line 240 "/data/src/seahorse/common/exportable.vala"
	result = FALSE;
#line 240 "/data/src/seahorse/common/exportable.vala"
	_g_object_unref0 (first);
#line 240 "/data/src/seahorse/common/exportable.vala"
	block6_data_unref (_data6_);
#line 240 "/data/src/seahorse/common/exportable.vala"
	_data6_ = NULL;
#line 240 "/data/src/seahorse/common/exportable.vala"
	if (chosen_file) {
#line 240 "/data/src/seahorse/common/exportable.vala"
		*chosen_file = _vala_chosen_file;
#line 1947 "exportable.c"
	} else {
#line 240 "/data/src/seahorse/common/exportable.vala"
		_g_object_unref0 (_vala_chosen_file);
#line 1951 "exportable.c"
	}
#line 240 "/data/src/seahorse/common/exportable.vala"
	if (chosen_exporter) {
#line 240 "/data/src/seahorse/common/exportable.vala"
		*chosen_exporter = _vala_chosen_exporter;
#line 1957 "exportable.c"
	} else {
#line 240 "/data/src/seahorse/common/exportable.vala"
		_g_object_unref0 (_vala_chosen_exporter);
#line 1961 "exportable.c"
	}
#line 240 "/data/src/seahorse/common/exportable.vala"
	return result;
#line 1965 "exportable.c"
}


gboolean seahorse_exportable_get_exportable (SeahorseExportable* self) {
#line 24 "/data/src/seahorse/common/exportable.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 24 "/data/src/seahorse/common/exportable.vala"
	return SEAHORSE_EXPORTABLE_GET_INTERFACE (self)->get_exportable (self);
#line 1974 "exportable.c"
}


static void seahorse_exportable_base_init (SeahorseExportableIface * iface) {
#line 23 "/data/src/seahorse/common/exportable.vala"
	static gboolean initialized = FALSE;
#line 23 "/data/src/seahorse/common/exportable.vala"
	if (!initialized) {
#line 23 "/data/src/seahorse/common/exportable.vala"
		initialized = TRUE;
#line 23 "/data/src/seahorse/common/exportable.vala"
		g_object_interface_install_property (iface, g_param_spec_boolean ("exportable", "exportable", "exportable", FALSE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE));
#line 1987 "exportable.c"
	}
}


GType seahorse_exportable_get_type (void) {
	static volatile gsize seahorse_exportable_type_id__volatile = 0;
	if (g_once_init_enter (&seahorse_exportable_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (SeahorseExportableIface), (GBaseInitFunc) seahorse_exportable_base_init, (GBaseFinalizeFunc) NULL, (GClassInitFunc) NULL, (GClassFinalizeFunc) NULL, NULL, 0, 0, (GInstanceInitFunc) NULL, NULL };
		GType seahorse_exportable_type_id;
		seahorse_exportable_type_id = g_type_register_static (G_TYPE_INTERFACE, "SeahorseExportable", &g_define_type_info, 0);
		g_type_interface_add_prerequisite (seahorse_exportable_type_id, G_TYPE_OBJECT);
		g_once_init_leave (&seahorse_exportable_type_id__volatile, seahorse_exportable_type_id);
	}
	return seahorse_exportable_type_id__volatile;
}



