/* unified-privacy.c generated by valac 0.20.1, the Vala compiler
 * generated from unified-privacy.vala, do not modify */

/* -*- Mode: vala; tab-width: 4; intend-tabs-mode: t -*- */
/* alm
 * Copyright (C) 2012 Stefano Candori <scandori@gnome.org>
 *               2013 Manish Sinha <manishsinha@ubuntu.com>
 *
 * alm is free software: you can redistribute it and/or modify it
 * under the terms of the GNU Lesser General Public License as published
 * by the Free Software Foundation, either version 2 of the License, or
 * (at your option) any later version.
 * 
 * alm 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 Lesser General Public License for more details.
 * 
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.";
 */

#include <glib.h>
#include <glib-object.h>
#include <gtk/gtk.h>
#include <gee.h>
#include <stdlib.h>
#include <string.h>
#include <gdk-pixbuf/gdk-pixbuf.h>
#include <gio/gio.h>
#include <zeitgeist-datamodel.h>
#include <glib/gi18n-lib.h>
#include <pango/pango.h>
#include <float.h>
#include <math.h>
#include <gio/gdesktopappinfo.h>
#include <gdk/gdk.h>
#include <cairo.h>
#include <zeitgeist.h>


#define ALM_TYPE_ITEM_TYPE (alm_item_type_get_type ())

#define ALM_TYPE_PRIVACY_WIDGET (alm_privacy_widget_get_type ())
#define ALM_PRIVACY_WIDGET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ALM_TYPE_PRIVACY_WIDGET, AlmPrivacyWidget))
#define ALM_PRIVACY_WIDGET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ALM_TYPE_PRIVACY_WIDGET, AlmPrivacyWidgetClass))
#define ALM_IS_PRIVACY_WIDGET(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ALM_TYPE_PRIVACY_WIDGET))
#define ALM_IS_PRIVACY_WIDGET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ALM_TYPE_PRIVACY_WIDGET))
#define ALM_PRIVACY_WIDGET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ALM_TYPE_PRIVACY_WIDGET, AlmPrivacyWidgetClass))

typedef struct _AlmPrivacyWidget AlmPrivacyWidget;
typedef struct _AlmPrivacyWidgetClass AlmPrivacyWidgetClass;
typedef struct _AlmPrivacyWidgetPrivate AlmPrivacyWidgetPrivate;

#define ALM_TYPE_BLACKLIST (alm_blacklist_get_type ())
#define ALM_BLACKLIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ALM_TYPE_BLACKLIST, AlmBlacklist))
#define ALM_BLACKLIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ALM_TYPE_BLACKLIST, AlmBlacklistClass))
#define ALM_IS_BLACKLIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ALM_TYPE_BLACKLIST))
#define ALM_IS_BLACKLIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ALM_TYPE_BLACKLIST))
#define ALM_BLACKLIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ALM_TYPE_BLACKLIST, AlmBlacklistClass))

typedef struct _AlmBlacklist AlmBlacklist;
typedef struct _AlmBlacklistClass AlmBlacklistClass;

#define ALM_TYPE_FILE_TYPE_BLACKLIST (alm_file_type_blacklist_get_type ())
#define ALM_FILE_TYPE_BLACKLIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ALM_TYPE_FILE_TYPE_BLACKLIST, AlmFileTypeBlacklist))
#define ALM_FILE_TYPE_BLACKLIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ALM_TYPE_FILE_TYPE_BLACKLIST, AlmFileTypeBlacklistClass))
#define ALM_IS_FILE_TYPE_BLACKLIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ALM_TYPE_FILE_TYPE_BLACKLIST))
#define ALM_IS_FILE_TYPE_BLACKLIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ALM_TYPE_FILE_TYPE_BLACKLIST))
#define ALM_FILE_TYPE_BLACKLIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ALM_TYPE_FILE_TYPE_BLACKLIST, AlmFileTypeBlacklistClass))

typedef struct _AlmFileTypeBlacklist AlmFileTypeBlacklist;
typedef struct _AlmFileTypeBlacklistClass AlmFileTypeBlacklistClass;

#define ALM_TYPE_PATH_BLACKLIST (alm_path_blacklist_get_type ())
#define ALM_PATH_BLACKLIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ALM_TYPE_PATH_BLACKLIST, AlmPathBlacklist))
#define ALM_PATH_BLACKLIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ALM_TYPE_PATH_BLACKLIST, AlmPathBlacklistClass))
#define ALM_IS_PATH_BLACKLIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ALM_TYPE_PATH_BLACKLIST))
#define ALM_IS_PATH_BLACKLIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ALM_TYPE_PATH_BLACKLIST))
#define ALM_PATH_BLACKLIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ALM_TYPE_PATH_BLACKLIST, AlmPathBlacklistClass))

typedef struct _AlmPathBlacklist AlmPathBlacklist;
typedef struct _AlmPathBlacklistClass AlmPathBlacklistClass;

#define ALM_TYPE_APPLICATION_BLACKLIST (alm_application_blacklist_get_type ())
#define ALM_APPLICATION_BLACKLIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ALM_TYPE_APPLICATION_BLACKLIST, AlmApplicationBlacklist))
#define ALM_APPLICATION_BLACKLIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ALM_TYPE_APPLICATION_BLACKLIST, AlmApplicationBlacklistClass))
#define ALM_IS_APPLICATION_BLACKLIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ALM_TYPE_APPLICATION_BLACKLIST))
#define ALM_IS_APPLICATION_BLACKLIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ALM_TYPE_APPLICATION_BLACKLIST))
#define ALM_APPLICATION_BLACKLIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ALM_TYPE_APPLICATION_BLACKLIST, AlmApplicationBlacklistClass))

typedef struct _AlmApplicationBlacklist AlmApplicationBlacklist;
typedef struct _AlmApplicationBlacklistClass AlmApplicationBlacklistClass;

#define ALM_TYPE_APPLICATIONS_CHOOSER_DIALOG (alm_applications_chooser_dialog_get_type ())
#define ALM_APPLICATIONS_CHOOSER_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ALM_TYPE_APPLICATIONS_CHOOSER_DIALOG, AlmApplicationsChooserDialog))
#define ALM_APPLICATIONS_CHOOSER_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ALM_TYPE_APPLICATIONS_CHOOSER_DIALOG, AlmApplicationsChooserDialogClass))
#define ALM_IS_APPLICATIONS_CHOOSER_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ALM_TYPE_APPLICATIONS_CHOOSER_DIALOG))
#define ALM_IS_APPLICATIONS_CHOOSER_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ALM_TYPE_APPLICATIONS_CHOOSER_DIALOG))
#define ALM_APPLICATIONS_CHOOSER_DIALOG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ALM_TYPE_APPLICATIONS_CHOOSER_DIALOG, AlmApplicationsChooserDialogClass))

typedef struct _AlmApplicationsChooserDialog AlmApplicationsChooserDialog;
typedef struct _AlmApplicationsChooserDialogClass AlmApplicationsChooserDialogClass;

#define ALM_TYPE_APPLICATIONS_TREE_VIEW (alm_applications_tree_view_get_type ())
#define ALM_APPLICATIONS_TREE_VIEW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ALM_TYPE_APPLICATIONS_TREE_VIEW, AlmApplicationsTreeView))
#define ALM_APPLICATIONS_TREE_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ALM_TYPE_APPLICATIONS_TREE_VIEW, AlmApplicationsTreeViewClass))
#define ALM_IS_APPLICATIONS_TREE_VIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ALM_TYPE_APPLICATIONS_TREE_VIEW))
#define ALM_IS_APPLICATIONS_TREE_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ALM_TYPE_APPLICATIONS_TREE_VIEW))
#define ALM_APPLICATIONS_TREE_VIEW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ALM_TYPE_APPLICATIONS_TREE_VIEW, AlmApplicationsTreeViewClass))

typedef struct _AlmApplicationsTreeView AlmApplicationsTreeView;
typedef struct _AlmApplicationsTreeViewClass AlmApplicationsTreeViewClass;

#define ALM_TYPE_APP_CHOOSE_INFO (alm_app_choose_info_get_type ())
#define ALM_APP_CHOOSE_INFO(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ALM_TYPE_APP_CHOOSE_INFO, AlmAppChooseInfo))
#define ALM_APP_CHOOSE_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ALM_TYPE_APP_CHOOSE_INFO, AlmAppChooseInfoClass))
#define ALM_IS_APP_CHOOSE_INFO(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ALM_TYPE_APP_CHOOSE_INFO))
#define ALM_IS_APP_CHOOSE_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ALM_TYPE_APP_CHOOSE_INFO))
#define ALM_APP_CHOOSE_INFO_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ALM_TYPE_APP_CHOOSE_INFO, AlmAppChooseInfoClass))

typedef struct _AlmAppChooseInfo AlmAppChooseInfo;
typedef struct _AlmAppChooseInfoClass AlmAppChooseInfoClass;

#define ALM_TYPE_DELETE_HISTORY_DIALOG (alm_delete_history_dialog_get_type ())
#define ALM_DELETE_HISTORY_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ALM_TYPE_DELETE_HISTORY_DIALOG, AlmDeleteHistoryDialog))
#define ALM_DELETE_HISTORY_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ALM_TYPE_DELETE_HISTORY_DIALOG, AlmDeleteHistoryDialogClass))
#define ALM_IS_DELETE_HISTORY_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ALM_TYPE_DELETE_HISTORY_DIALOG))
#define ALM_IS_DELETE_HISTORY_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ALM_TYPE_DELETE_HISTORY_DIALOG))
#define ALM_DELETE_HISTORY_DIALOG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ALM_TYPE_DELETE_HISTORY_DIALOG, AlmDeleteHistoryDialogClass))

typedef struct _AlmDeleteHistoryDialog AlmDeleteHistoryDialog;
typedef struct _AlmDeleteHistoryDialogClass AlmDeleteHistoryDialogClass;
#define _alm_blacklist_unref0(var) ((var == NULL) ? NULL : (var = (alm_blacklist_unref (var), NULL)))
#define _alm_file_type_blacklist_unref0(var) ((var == NULL) ? NULL : (var = (alm_file_type_blacklist_unref (var), NULL)))
#define _alm_path_blacklist_unref0(var) ((var == NULL) ? NULL : (var = (alm_path_blacklist_unref (var), NULL)))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _alm_application_blacklist_unref0(var) ((var == NULL) ? NULL : (var = (alm_application_blacklist_unref (var), NULL)))
#define _g_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (g_hash_table_unref (var), NULL)))
#define _g_free0(var) (var = (g_free (var), NULL))
typedef struct _Block4Data Block4Data;

#define ALM_TYPE_EXCEPTION_CELL_RENDERER (alm_exception_cell_renderer_get_type ())
#define ALM_EXCEPTION_CELL_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ALM_TYPE_EXCEPTION_CELL_RENDERER, AlmExceptionCellRenderer))
#define ALM_EXCEPTION_CELL_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ALM_TYPE_EXCEPTION_CELL_RENDERER, AlmExceptionCellRendererClass))
#define ALM_IS_EXCEPTION_CELL_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ALM_TYPE_EXCEPTION_CELL_RENDERER))
#define ALM_IS_EXCEPTION_CELL_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ALM_TYPE_EXCEPTION_CELL_RENDERER))
#define ALM_EXCEPTION_CELL_RENDERER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ALM_TYPE_EXCEPTION_CELL_RENDERER, AlmExceptionCellRendererClass))

typedef struct _AlmExceptionCellRenderer AlmExceptionCellRenderer;
typedef struct _AlmExceptionCellRendererClass AlmExceptionCellRendererClass;
#define _alm_app_choose_info_unref0(var) ((var == NULL) ? NULL : (var = (alm_app_choose_info_unref (var), NULL)))
typedef struct _AlmExceptionCellRendererPrivate AlmExceptionCellRendererPrivate;
#define _pango_attribute_destroy0(var) ((var == NULL) ? NULL : (var = (pango_attribute_destroy (var), NULL)))
#define __vala_PangoFontDescription_free0(var) ((var == NULL) ? NULL : (var = (_vala_PangoFontDescription_free (var), NULL)))
#define __vala_PangoAttrList_free0(var) ((var == NULL) ? NULL : (var = (_vala_PangoAttrList_free (var), NULL)))
typedef struct _AlmDeleteHistoryDialogPrivate AlmDeleteHistoryDialogPrivate;

#define ALM_TYPE_CALENDAR_WIDGET (alm_calendar_widget_get_type ())
#define ALM_CALENDAR_WIDGET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ALM_TYPE_CALENDAR_WIDGET, AlmCalendarWidget))
#define ALM_CALENDAR_WIDGET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ALM_TYPE_CALENDAR_WIDGET, AlmCalendarWidgetClass))
#define ALM_IS_CALENDAR_WIDGET(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ALM_TYPE_CALENDAR_WIDGET))
#define ALM_IS_CALENDAR_WIDGET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ALM_TYPE_CALENDAR_WIDGET))
#define ALM_CALENDAR_WIDGET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ALM_TYPE_CALENDAR_WIDGET, AlmCalendarWidgetClass))

typedef struct _AlmCalendarWidget AlmCalendarWidget;
typedef struct _AlmCalendarWidgetClass AlmCalendarWidgetClass;
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))
#define _g_array_unref0(var) ((var == NULL) ? NULL : (var = (g_array_unref (var), NULL)))
#define _g_ptr_array_unref0(var) ((var == NULL) ? NULL : (var = (g_ptr_array_unref (var), NULL)))
typedef struct _AlmDeleteHistoryDialogGetHistoryData AlmDeleteHistoryDialogGetHistoryData;
typedef struct _AlmDeleteHistoryDialogDeleteHistoryData AlmDeleteHistoryDialogDeleteHistoryData;

typedef enum  {
	ALM_ITEM_TYPE_FILE,
	ALM_ITEM_TYPE_APPLICATION
} AlmItemType;

struct _AlmPrivacyWidget {
	GtkBox parent_instance;
	AlmPrivacyWidgetPrivate * priv;
};

struct _AlmPrivacyWidgetClass {
	GtkBoxClass parent_class;
};

struct _AlmPrivacyWidgetPrivate {
	AlmBlacklist* blacklist;
	gboolean file_type_fire_signal;
	AlmFileTypeBlacklist* files_type_blacklist;
	AlmPathBlacklist* path_blacklist;
	GeeHashMap* mime_dict;
	GeeHashMap* checkboxes;
	GeeHashSet* button_list;
	GeeHashMap* defined_dirs;
	AlmApplicationBlacklist* app_blacklist;
	AlmApplicationsChooserDialog* app_dialog;
	AlmApplicationsTreeView* app_treeview;
	GtkBox* container_box;
	GHashTable* blocked_list;
	GHashTable* unblocked_list;
	gboolean app_change_recursive;
	GtkTreeView* exception_list;
	GtkListStore* exception_list_store;
	GtkSwitch* record_button;
	GtkButton* del_button;
	AlmDeleteHistoryDialog* delete_dialog;
	GdkPixbuf* stock_folder_icon;
	GtkMenu* exception_menu;
	GSettings* privacy_settings;
};

struct _Block4Data {
	int _ref_count_;
	AlmPrivacyWidget * self;
	GtkCheckButton* check_button;
};

struct _AlmExceptionCellRenderer {
	GtkCellRenderer parent_instance;
	AlmExceptionCellRendererPrivate * priv;
};

struct _AlmExceptionCellRendererClass {
	GtkCellRendererClass parent_class;
};

struct _AlmExceptionCellRendererPrivate {
	GtkWidget* current_widget;
	GdkPixbuf* pixbuf_;
	gchar* text_;
};

struct _AlmDeleteHistoryDialog {
	GtkDialog parent_instance;
	AlmDeleteHistoryDialogPrivate * priv;
};

struct _AlmDeleteHistoryDialogClass {
	GtkDialogClass parent_class;
};

struct _AlmDeleteHistoryDialogPrivate {
	GtkRadioButton* r_hour;
	GtkRadioButton* r_day;
	GtkRadioButton* r_week;
	GtkRadioButton* r_calendar;
	GtkRadioButton* r_ever;
	ZeitgeistLog* zg_log;
	AlmCalendarWidget* calendar_box;
};

struct _AlmDeleteHistoryDialogGetHistoryData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	AlmDeleteHistoryDialog* self;
	ZeitgeistTimeRange* tr;
	GtkDialog* _tmp0_;
	GtkDialog* dialog;
	GtkDialog* _tmp1_;
	GtkDialog* _tmp2_;
	GtkDialog* _tmp3_;
	const gchar* _tmp4_;
	GtkLabel* _tmp5_;
	GtkLabel* label;
	GtkLabel* _tmp6_;
	GtkLabel* _tmp7_;
	GtkLabel* _tmp8_;
	GtkDialog* _tmp9_;
	GtkBox* _tmp10_;
	GtkLabel* _tmp11_;
	GtkDialog* _tmp12_;
	GtkWidget* _tmp13_;
	GtkDialog* _tmp14_;
	GtkDialog* _tmp15_;
	GtkDialog* _tmp16_;
	gint _tmp17_;
	gint res;
	GtkDialog* _tmp18_;
	gint _tmp19_;
	GPtrArray* _tmp20_;
	GPtrArray* events;
	GPtrArray* _tmp21_;
	ZeitgeistEvent* _tmp22_;
	ZeitgeistLog* _tmp23_;
	ZeitgeistTimeRange* _tmp24_;
	GPtrArray* _tmp25_;
	gint _tmp26_;
	guint32* _tmp27_;
	guint32* ids;
	gint ids_length1;
	gint _ids_size_;
	GArray* _tmp28_;
	GArray* del_ids;
	GArray* _tmp29_;
	guint32* _tmp30_;
	gint _tmp30__length1;
	guint32* _tmp31_;
	gint _tmp31__length1;
	GArray* _tmp32_;
	GError* err;
	GError* _tmp33_;
	const gchar* _tmp34_;
	GError * _inner_error_;
};

struct _AlmDeleteHistoryDialogDeleteHistoryData {
	int _state_;
	GObject* _source_object_;
	GAsyncResult* _res_;
	GSimpleAsyncResult* _async_result;
	AlmDeleteHistoryDialog* self;
	GArray* ids;
	ZeitgeistLog* _tmp0_;
	GArray* _tmp1_;
	ZeitgeistTimeRange* _tmp2_;
	ZeitgeistTimeRange* rs;
	GError* err;
	GError* _tmp3_;
	const gchar* _tmp4_;
	GError * _inner_error_;
};


static gpointer alm_privacy_widget_parent_class = NULL;
extern gchar* alm_file_type_blacklist_interpretation_prefix;
static gpointer alm_exception_cell_renderer_parent_class = NULL;
static gpointer alm_delete_history_dialog_parent_class = NULL;

GType alm_item_type_get_type (void) G_GNUC_CONST;
GType alm_privacy_widget_get_type (void) G_GNUC_CONST;
gpointer alm_blacklist_ref (gpointer instance);
void alm_blacklist_unref (gpointer instance);
GParamSpec* alm_param_spec_blacklist (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void alm_value_set_blacklist (GValue* value, gpointer v_object);
void alm_value_take_blacklist (GValue* value, gpointer v_object);
gpointer alm_value_get_blacklist (const GValue* value);
GType alm_blacklist_get_type (void) G_GNUC_CONST;
gpointer alm_file_type_blacklist_ref (gpointer instance);
void alm_file_type_blacklist_unref (gpointer instance);
GParamSpec* alm_param_spec_file_type_blacklist (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void alm_value_set_file_type_blacklist (GValue* value, gpointer v_object);
void alm_value_take_file_type_blacklist (GValue* value, gpointer v_object);
gpointer alm_value_get_file_type_blacklist (const GValue* value);
GType alm_file_type_blacklist_get_type (void) G_GNUC_CONST;
gpointer alm_path_blacklist_ref (gpointer instance);
void alm_path_blacklist_unref (gpointer instance);
GParamSpec* alm_param_spec_path_blacklist (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void alm_value_set_path_blacklist (GValue* value, gpointer v_object);
void alm_value_take_path_blacklist (GValue* value, gpointer v_object);
gpointer alm_value_get_path_blacklist (const GValue* value);
GType alm_path_blacklist_get_type (void) G_GNUC_CONST;
gpointer alm_application_blacklist_ref (gpointer instance);
void alm_application_blacklist_unref (gpointer instance);
GParamSpec* alm_param_spec_application_blacklist (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void alm_value_set_application_blacklist (GValue* value, gpointer v_object);
void alm_value_take_application_blacklist (GValue* value, gpointer v_object);
gpointer alm_value_get_application_blacklist (const GValue* value);
GType alm_application_blacklist_get_type (void) G_GNUC_CONST;
GType alm_applications_chooser_dialog_get_type (void) G_GNUC_CONST;
GType alm_applications_tree_view_get_type (void) G_GNUC_CONST;
gpointer alm_app_choose_info_ref (gpointer instance);
void alm_app_choose_info_unref (gpointer instance);
GParamSpec* alm_param_spec_app_choose_info (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void alm_value_set_app_choose_info (GValue* value, gpointer v_object);
void alm_value_take_app_choose_info (GValue* value, gpointer v_object);
gpointer alm_value_get_app_choose_info (const GValue* value);
GType alm_app_choose_info_get_type (void) G_GNUC_CONST;
GType alm_delete_history_dialog_get_type (void) G_GNUC_CONST;
#define ALM_PRIVACY_WIDGET_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), ALM_TYPE_PRIVACY_WIDGET, AlmPrivacyWidgetPrivate))
enum  {
	ALM_PRIVACY_WIDGET_DUMMY_PROPERTY
};
AlmPrivacyWidget* alm_privacy_widget_new (AlmBlacklist* blacklist_interface);
AlmPrivacyWidget* alm_privacy_widget_construct (GType object_type, AlmBlacklist* blacklist_interface);
AlmFileTypeBlacklist* alm_file_type_blacklist_new (AlmBlacklist* blacklist_inter, GeeHashMap* all_checkboxes);
AlmFileTypeBlacklist* alm_file_type_blacklist_construct (GType object_type, AlmBlacklist* blacklist_inter, GeeHashMap* all_checkboxes);
AlmPathBlacklist* alm_path_blacklist_new (AlmBlacklist* blacklist_inter);
AlmPathBlacklist* alm_path_blacklist_construct (GType object_type, AlmBlacklist* blacklist_inter);
static void __lambda10_ (AlmPrivacyWidget* self, const gchar* blacklist_id, ZeitgeistEvent* blacklist_template);
static void ___lambda10__alm_blacklist_template_added (AlmBlacklist* _sender, const gchar* blacklist_id, ZeitgeistEvent* blacklist_template, gpointer self);
static void __lambda11_ (AlmPrivacyWidget* self, const gchar* blacklist_id, ZeitgeistEvent* blacklist_template);
static void ___lambda11__alm_blacklist_template_removed (AlmBlacklist* _sender, const gchar* blacklist_id, ZeitgeistEvent* blacklist_template, gpointer self);
static void __lambda12_ (AlmPrivacyWidget* self, const gchar* folder);
gboolean alm_path_blacklist_is_duplicate (AlmPathBlacklist* self, const gchar* path);
static void alm_privacy_widget_add_folder_to_view (AlmPrivacyWidget* self, const gchar* folder);
static void ___lambda12__alm_path_blacklist_folder_added (AlmPathBlacklist* _sender, const gchar* path, gpointer self);
static void __lambda13_ (AlmPrivacyWidget* self, const gchar* folder);
static gboolean alm_privacy_widget_remove_folder_from_view (AlmPrivacyWidget* self, const gchar* folder);
static void ___lambda13__alm_path_blacklist_folder_removed (AlmPathBlacklist* _sender, const gchar* path, gpointer self);
static void _g_free0_ (gpointer var);
static void _alm_app_choose_info_unref0_ (gpointer var);
AlmApplicationBlacklist* alm_application_blacklist_new (AlmBlacklist* blacklist);
AlmApplicationBlacklist* alm_application_blacklist_construct (GType object_type, AlmBlacklist* blacklist);
AlmApplicationsTreeView* alm_applications_tree_view_new (AlmApplicationBlacklist* app_blacklist, GHashTable* blocked, GHashTable* unblocked);
AlmApplicationsTreeView* alm_applications_tree_view_construct (GType object_type, AlmApplicationBlacklist* app_blacklist, GHashTable* blocked, GHashTable* unblocked);
static void __lambda14_ (AlmPrivacyWidget* self, const gchar* app, ZeitgeistEvent* event);
static void alm_privacy_widget_remove_app_from_view (AlmPrivacyWidget* self, const gchar* app);
static void ___lambda14__alm_application_blacklist_application_removed (AlmApplicationBlacklist* _sender, const gchar* app, ZeitgeistEvent* ev, gpointer self);
static void __lambda15_ (AlmPrivacyWidget* self, const gchar* app, ZeitgeistEvent* event);
static void alm_privacy_widget_add_app_to_view (AlmPrivacyWidget* self, const gchar* app);
static void ___lambda15__alm_application_blacklist_application_added (AlmApplicationBlacklist* _sender, const gchar* app, ZeitgeistEvent* ev, gpointer self);
static void alm_privacy_widget_setup_ui (AlmPrivacyWidget* self);
gboolean alm_blacklist_get_incognito (AlmBlacklist* self);
static void __lambda16_ (AlmPrivacyWidget* self, gboolean status);
static void ___lambda16__alm_blacklist_incognito_toggled (AlmBlacklist* _sender, gboolean status, gpointer self);
static void __lambda17_ (AlmPrivacyWidget* self);
void alm_blacklist_set_incognito (AlmBlacklist* self, gboolean status);
static void ___lambda17__g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self);
static void __lambda18_ (AlmPrivacyWidget* self);
void alm_delete_history_dialog_on_delete_history (AlmDeleteHistoryDialog* self);
static void ___lambda18__gtk_button_clicked (GtkButton* _sender, gpointer self);
static gint __lambda19_ (const gchar* s1, const gchar* s2);
static gint ___lambda19__gcompare_func (gconstpointer a, gconstpointer b);
void alm_file_type_blacklist_populate_file_types (AlmFileTypeBlacklist* self);
static Block4Data* block4_data_ref (Block4Data* _data4_);
static void block4_data_unref (void * _userdata_);
static void ____lambda20_ (Block4Data* _data4_);
void alm_file_type_blacklist_unblock (AlmFileTypeBlacklist* self, const gchar* interpretation);
void alm_file_type_blacklist_block (AlmFileTypeBlacklist* self, const gchar* interpretation);
static void _____lambda20__gtk_toggle_button_toggled (GtkToggleButton* _sender, gpointer self);
AlmExceptionCellRenderer* alm_exception_cell_renderer_new (void);
AlmExceptionCellRenderer* alm_exception_cell_renderer_construct (GType object_type);
GType alm_exception_cell_renderer_get_type (void) G_GNUC_CONST;
static void alm_privacy_widget_on_remove_exception (AlmPrivacyWidget* self);
static void _alm_privacy_widget_on_remove_exception_gtk_tool_button_clicked (GtkToolButton* _sender, gpointer self);
static void alm_privacy_widget_on_add_folder (AlmPrivacyWidget* self);
static void _alm_privacy_widget_on_add_folder_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self);
static void alm_privacy_widget_on_add_application (AlmPrivacyWidget* self);
static void _alm_privacy_widget_on_add_application_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self);
AlmApplicationsChooserDialog* alm_applications_chooser_dialog_new (AlmApplicationBlacklist* app_blacklist, GHashTable* blocked_list, GHashTable* unblocked_list);
AlmApplicationsChooserDialog* alm_applications_chooser_dialog_construct (GType object_type, AlmApplicationBlacklist* app_blacklist, GHashTable* blocked_list, GHashTable* unblocked_list);
AlmDeleteHistoryDialog* alm_delete_history_dialog_new (GtkButton* del_button);
AlmDeleteHistoryDialog* alm_delete_history_dialog_construct (GType object_type, GtkButton* del_button);
static void alm_privacy_widget_folders_populate (AlmPrivacyWidget* self);
static void alm_privacy_widget_app_populate (AlmPrivacyWidget* self);
gint alm_privacy_widget_compare_mimes (AlmPrivacyWidget* self, const gchar* s1, const gchar* s2);
GeeHashSet* alm_path_blacklist_get_all_folders (AlmPathBlacklist* self);
GeeHashSet* alm_application_blacklist_get_all_apps (AlmApplicationBlacklist* self);
void alm_path_blacklist_unblock (AlmPathBlacklist* self, const gchar* folder);
void alm_application_blacklist_unblock (AlmApplicationBlacklist* self, const gchar* application);
void alm_path_blacklist_block (AlmPathBlacklist* self, const gchar* folder);
static void alm_privacy_widget_on_add_file (AlmPrivacyWidget* self);
GtkTreeView* alm_applications_chooser_dialog_get_tree (AlmApplicationsChooserDialog* self);
GtkListStore* alm_applications_chooser_dialog_get_liststore (AlmApplicationsChooserDialog* self);
void alm_application_blacklist_block (AlmApplicationBlacklist* self, const gchar* application);
const gchar* g_user_directory_to_string (GUserDirectory self);
static const char* _g_user_directory_to_string (GUserDirectory value);
GdkPixbuf* alm_applications_tree_view_get_pixbuf_from_gio_icon (GIcon* icon, gint size);
gchar* alm_applications_tree_view_markup_for_app (GDesktopAppInfo* app_info);
AlmAppChooseInfo* alm_app_choose_info_new (const gchar* id, const gchar* app_name, GdkPixbuf* app_icon, const gchar* last_accessed_time_s, gint64 last_accessed_time_i, guint usage_rating);
AlmAppChooseInfo* alm_app_choose_info_construct (GType object_type, const gchar* id, const gchar* app_name, GdkPixbuf* app_icon, const gchar* last_accessed_time_s, gint64 last_accessed_time_i, guint usage_rating);
static void alm_privacy_widget_finalize (GObject* obj);
#define ALM_EXCEPTION_CELL_RENDERER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), ALM_TYPE_EXCEPTION_CELL_RENDERER, AlmExceptionCellRendererPrivate))
enum  {
	ALM_EXCEPTION_CELL_RENDERER_DUMMY_PROPERTY,
	ALM_EXCEPTION_CELL_RENDERER_PIXBUF,
	ALM_EXCEPTION_CELL_RENDERER_TEXT
};
#define ALM_EXCEPTION_CELL_RENDERER_PIXBUF_SIZE 24
#define ALM_EXCEPTION_CELL_RENDERER_xspacing 3
#define ALM_EXCEPTION_CELL_RENDERER_default_width 60
#define ALM_EXCEPTION_CELL_RENDERER_renderer_height 30
static PangoLayout* alm_exception_cell_renderer_get_text_layout (AlmExceptionCellRenderer* self, GtkWidget* widget, GdkRectangle* cell_area, GtkCellRendererState flags, const gchar* text, gboolean bold, gint size);
static void _vala_PangoFontDescription_free (PangoFontDescription* self);
static PangoAttrList* _vala_PangoAttrList_copy (PangoAttrList* self);
static void _vala_PangoAttrList_free (PangoAttrList* self);
static void alm_exception_cell_renderer_real_get_size (GtkCellRenderer* base, GtkWidget* widget, GdkRectangle* cell_area, gint* x_offset, gint* y_offset, gint* width, gint* height);
static void alm_exception_cell_renderer_do_get_size (AlmExceptionCellRenderer* self, GtkWidget* widget, GdkRectangle* cell_area, PangoLayout* layout, gint* x_offset, gint* y_offset);
static void alm_exception_cell_renderer_real_render (GtkCellRenderer* base, cairo_t* cr, GtkWidget* widget, GdkRectangle* background_area, GdkRectangle* cell_area, GtkCellRendererState flags);
const gchar* alm_exception_cell_renderer_get_text (AlmExceptionCellRenderer* self);
GdkPixbuf* alm_exception_cell_renderer_get_pixbuf (AlmExceptionCellRenderer* self);
static void alm_exception_cell_renderer_real_get_preferred_width (GtkCellRenderer* base, GtkWidget* widget, gint* min_width, gint* nat_width);
static void alm_exception_cell_renderer_real_get_preferred_height_for_width (GtkCellRenderer* base, GtkWidget* widget, gint width, gint* minimum_height, gint* natural_height);
static void alm_exception_cell_renderer_real_get_preferred_height (GtkCellRenderer* base, GtkWidget* widget, gint* minimum_size, gint* natural_size);
void alm_exception_cell_renderer_set_pixbuf (AlmExceptionCellRenderer* self, GdkPixbuf* value);
void alm_exception_cell_renderer_set_text (AlmExceptionCellRenderer* self, const gchar* value);
static void alm_exception_cell_renderer_finalize (GObject* obj);
static void _vala_alm_exception_cell_renderer_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec);
static void _vala_alm_exception_cell_renderer_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec);
GType alm_calendar_widget_get_type (void) G_GNUC_CONST;
#define ALM_DELETE_HISTORY_DIALOG_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), ALM_TYPE_DELETE_HISTORY_DIALOG, AlmDeleteHistoryDialogPrivate))
enum  {
	ALM_DELETE_HISTORY_DIALOG_DUMMY_PROPERTY
};
AlmCalendarWidget* alm_calendar_widget_new (GtkButton* button);
AlmCalendarWidget* alm_calendar_widget_construct (GType object_type, GtkButton* button);
static void alm_delete_history_dialog_set_up_ui (AlmDeleteHistoryDialog* self);
gint alm_delete_history_dialog_get_active_radio_button (AlmDeleteHistoryDialog* self);
static void alm_delete_history_dialog_get_history (AlmDeleteHistoryDialog* self, ZeitgeistTimeRange* tr, GAsyncReadyCallback _callback_, gpointer _user_data_);
static void alm_delete_history_dialog_get_history_finish (AlmDeleteHistoryDialog* self, GAsyncResult* _res_);
ZeitgeistTimeRange* alm_calendar_widget_get_range (AlmCalendarWidget* self);
static void alm_delete_history_dialog_get_history_data_free (gpointer _data);
static gboolean alm_delete_history_dialog_get_history_co (AlmDeleteHistoryDialogGetHistoryData* _data_);
static gboolean _alm_delete_history_dialog_get_history_co_gsource_func (gpointer self);
static void _g_object_unref0_ (gpointer var);
static void alm_delete_history_dialog_get_history_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static void alm_delete_history_dialog_delete_history (AlmDeleteHistoryDialog* self, GArray* ids, GAsyncReadyCallback _callback_, gpointer _user_data_);
static void alm_delete_history_dialog_delete_history_finish (AlmDeleteHistoryDialog* self, GAsyncResult* _res_);
static void alm_delete_history_dialog_delete_history_data_free (gpointer _data);
static gboolean alm_delete_history_dialog_delete_history_co (AlmDeleteHistoryDialogDeleteHistoryData* _data_);
static gboolean _alm_delete_history_dialog_delete_history_co_gsource_func (gpointer self);
static void alm_delete_history_dialog_delete_history_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_);
static void alm_delete_history_dialog_finalize (GObject* obj);


GType alm_item_type_get_type (void) {
	static volatile gsize alm_item_type_type_id__volatile = 0;
	if (g_once_init_enter (&alm_item_type_type_id__volatile)) {
		static const GEnumValue values[] = {{ALM_ITEM_TYPE_FILE, "ALM_ITEM_TYPE_FILE", "file"}, {ALM_ITEM_TYPE_APPLICATION, "ALM_ITEM_TYPE_APPLICATION", "application"}, {0, NULL, NULL}};
		GType alm_item_type_type_id;
		alm_item_type_type_id = g_enum_register_static ("AlmItemType", values);
		g_once_init_leave (&alm_item_type_type_id__volatile, alm_item_type_type_id);
	}
	return alm_item_type_type_id__volatile;
}


static gpointer _alm_blacklist_ref0 (gpointer self) {
	return self ? alm_blacklist_ref (self) : NULL;
}


static void __lambda10_ (AlmPrivacyWidget* self, const gchar* blacklist_id, ZeitgeistEvent* blacklist_template) {
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	gboolean _tmp2_ = FALSE;
	g_return_if_fail (blacklist_id != NULL);
	g_return_if_fail (blacklist_template != NULL);
	_tmp0_ = blacklist_id;
	_tmp1_ = alm_file_type_blacklist_interpretation_prefix;
	_tmp2_ = g_str_has_prefix (_tmp0_, _tmp1_);
	if (_tmp2_) {
		ZeitgeistEvent* _tmp3_;
		ZeitgeistSubject* _tmp4_ = NULL;
		ZeitgeistSubject* _tmp5_;
		const gchar* _tmp6_;
		const gchar* _tmp7_;
		gchar* _tmp8_;
		gchar* _tmp9_;
		gchar* inter;
		GeeHashMap* _tmp10_;
		const gchar* _tmp11_;
		gboolean _tmp12_ = FALSE;
		self->priv->file_type_fire_signal = FALSE;
		_tmp3_ = blacklist_template;
		_tmp4_ = zeitgeist_event_get_subject (_tmp3_, 0);
		_tmp5_ = _tmp4_;
		_tmp6_ = zeitgeist_subject_get_interpretation (_tmp5_);
		_tmp7_ = _tmp6_;
		_tmp8_ = g_strdup (_tmp7_);
		_tmp9_ = _tmp8_;
		_g_object_unref0 (_tmp5_);
		inter = _tmp9_;
		_tmp10_ = self->priv->checkboxes;
		_tmp11_ = inter;
		_tmp12_ = gee_abstract_map_has_key ((GeeAbstractMap*) _tmp10_, _tmp11_);
		if (_tmp12_) {
			GeeHashMap* _tmp13_;
			const gchar* _tmp14_;
			gpointer _tmp15_ = NULL;
			GtkCheckButton* _tmp16_;
			_tmp13_ = self->priv->checkboxes;
			_tmp14_ = inter;
			_tmp15_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp13_, _tmp14_);
			_tmp16_ = (GtkCheckButton*) _tmp15_;
			gtk_toggle_button_set_active ((GtkToggleButton*) _tmp16_, FALSE);
			_g_object_unref0 (_tmp16_);
		}
		self->priv->file_type_fire_signal = TRUE;
		_g_free0 (inter);
	}
}


static void ___lambda10__alm_blacklist_template_added (AlmBlacklist* _sender, const gchar* blacklist_id, ZeitgeistEvent* blacklist_template, gpointer self) {
	__lambda10_ (self, blacklist_id, blacklist_template);
}


static void __lambda11_ (AlmPrivacyWidget* self, const gchar* blacklist_id, ZeitgeistEvent* blacklist_template) {
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	gboolean _tmp2_ = FALSE;
	g_return_if_fail (blacklist_id != NULL);
	g_return_if_fail (blacklist_template != NULL);
	_tmp0_ = blacklist_id;
	_tmp1_ = alm_file_type_blacklist_interpretation_prefix;
	_tmp2_ = g_str_has_prefix (_tmp0_, _tmp1_);
	if (_tmp2_) {
		ZeitgeistEvent* _tmp3_;
		ZeitgeistSubject* _tmp4_ = NULL;
		ZeitgeistSubject* _tmp5_;
		const gchar* _tmp6_;
		const gchar* _tmp7_;
		gchar* _tmp8_;
		gchar* _tmp9_;
		gchar* inter;
		GeeHashMap* _tmp10_;
		const gchar* _tmp11_;
		gboolean _tmp12_ = FALSE;
		self->priv->file_type_fire_signal = FALSE;
		_tmp3_ = blacklist_template;
		_tmp4_ = zeitgeist_event_get_subject (_tmp3_, 0);
		_tmp5_ = _tmp4_;
		_tmp6_ = zeitgeist_subject_get_interpretation (_tmp5_);
		_tmp7_ = _tmp6_;
		_tmp8_ = g_strdup (_tmp7_);
		_tmp9_ = _tmp8_;
		_g_object_unref0 (_tmp5_);
		inter = _tmp9_;
		_tmp10_ = self->priv->checkboxes;
		_tmp11_ = inter;
		_tmp12_ = gee_abstract_map_has_key ((GeeAbstractMap*) _tmp10_, _tmp11_);
		if (_tmp12_) {
			GeeHashMap* _tmp13_;
			const gchar* _tmp14_;
			gpointer _tmp15_ = NULL;
			GtkCheckButton* _tmp16_;
			_tmp13_ = self->priv->checkboxes;
			_tmp14_ = inter;
			_tmp15_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp13_, _tmp14_);
			_tmp16_ = (GtkCheckButton*) _tmp15_;
			gtk_toggle_button_set_active ((GtkToggleButton*) _tmp16_, TRUE);
			_g_object_unref0 (_tmp16_);
		}
		self->priv->file_type_fire_signal = TRUE;
		_g_free0 (inter);
	}
}


static void ___lambda11__alm_blacklist_template_removed (AlmBlacklist* _sender, const gchar* blacklist_id, ZeitgeistEvent* blacklist_template, gpointer self) {
	__lambda11_ (self, blacklist_id, blacklist_template);
}


static void __lambda12_ (AlmPrivacyWidget* self, const gchar* folder) {
	AlmPathBlacklist* _tmp0_;
	const gchar* _tmp1_;
	gboolean _tmp2_ = FALSE;
	g_return_if_fail (folder != NULL);
	_tmp0_ = self->priv->path_blacklist;
	_tmp1_ = folder;
	_tmp2_ = alm_path_blacklist_is_duplicate (_tmp0_, _tmp1_);
	if (!_tmp2_) {
		const gchar* _tmp3_;
		_tmp3_ = folder;
		alm_privacy_widget_add_folder_to_view (self, _tmp3_);
	}
}


static void ___lambda12__alm_path_blacklist_folder_added (AlmPathBlacklist* _sender, const gchar* path, gpointer self) {
	__lambda12_ (self, path);
}


static void __lambda13_ (AlmPrivacyWidget* self, const gchar* folder) {
	const gchar* _tmp0_;
	g_return_if_fail (folder != NULL);
	_tmp0_ = folder;
	alm_privacy_widget_remove_folder_from_view (self, _tmp0_);
}


static void ___lambda13__alm_path_blacklist_folder_removed (AlmPathBlacklist* _sender, const gchar* path, gpointer self) {
	__lambda13_ (self, path);
}


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


static void _g_free0_ (gpointer var) {
	var = (g_free (var), NULL);
}


static void _alm_app_choose_info_unref0_ (gpointer var) {
	(var == NULL) ? NULL : (var = (alm_app_choose_info_unref (var), NULL));
}


static void __lambda14_ (AlmPrivacyWidget* self, const gchar* app, ZeitgeistEvent* event) {
	gboolean _tmp0_;
	g_return_if_fail (app != NULL);
	g_return_if_fail (event != NULL);
	_tmp0_ = self->priv->app_change_recursive;
	if (!_tmp0_) {
		const gchar* _tmp1_;
		_tmp1_ = app;
		alm_privacy_widget_remove_app_from_view (self, _tmp1_);
	}
	self->priv->app_change_recursive = FALSE;
}


static void ___lambda14__alm_application_blacklist_application_removed (AlmApplicationBlacklist* _sender, const gchar* app, ZeitgeistEvent* ev, gpointer self) {
	__lambda14_ (self, app, ev);
}


static void __lambda15_ (AlmPrivacyWidget* self, const gchar* app, ZeitgeistEvent* event) {
	gboolean _tmp0_;
	g_return_if_fail (app != NULL);
	g_return_if_fail (event != NULL);
	_tmp0_ = self->priv->app_change_recursive;
	if (!_tmp0_) {
		const gchar* _tmp1_;
		_tmp1_ = app;
		alm_privacy_widget_add_app_to_view (self, _tmp1_);
	}
	self->priv->app_change_recursive = FALSE;
}


static void ___lambda15__alm_application_blacklist_application_added (AlmApplicationBlacklist* _sender, const gchar* app, ZeitgeistEvent* ev, gpointer self) {
	__lambda15_ (self, app, ev);
}


AlmPrivacyWidget* alm_privacy_widget_construct (GType object_type, AlmBlacklist* blacklist_interface) {
	AlmPrivacyWidget * self = NULL;
	GSettings* _tmp0_;
	AlmBlacklist* _tmp1_;
	AlmBlacklist* _tmp2_;
	GeeHashMap* _tmp3_;
	GeeHashSet* _tmp4_;
	AlmBlacklist* _tmp5_;
	GeeHashMap* _tmp6_;
	AlmFileTypeBlacklist* _tmp7_;
	AlmBlacklist* _tmp8_;
	AlmPathBlacklist* _tmp9_;
	AlmBlacklist* _tmp10_;
	AlmBlacklist* _tmp11_;
	AlmPathBlacklist* _tmp12_;
	AlmPathBlacklist* _tmp13_;
	GHashFunc _tmp14_;
	GEqualFunc _tmp15_;
	GeeHashMap* _tmp16_;
	GeeHashMap* _tmp17_;
	const gchar* _tmp18_ = NULL;
	GeeHashMap* _tmp19_;
	const gchar* _tmp20_ = NULL;
	GeeHashMap* _tmp21_;
	const gchar* _tmp22_ = NULL;
	GeeHashMap* _tmp23_;
	const gchar* _tmp24_ = NULL;
	GeeHashMap* _tmp25_;
	const gchar* _tmp26_ = NULL;
	GeeHashMap* _tmp27_;
	const gchar* _tmp28_ = NULL;
	GeeHashMap* _tmp29_;
	const gchar* _tmp30_ = NULL;
	GeeHashMap* _tmp31_;
	const gchar* _tmp32_ = NULL;
	GeeHashMap* _tmp33_;
	const gchar* _tmp34_ = NULL;
	GUserDirectory* _tmp35_ = NULL;
	GUserDirectory* special_dirs;
	gint special_dirs_length1;
	gint _special_dirs_size_;
	GdkPixbuf* _tmp52_ = NULL;
	GdkPixbuf* _tmp53_;
	GHashFunc _tmp54_;
	GEqualFunc _tmp55_;
	GHashTable* _tmp56_;
	GHashFunc _tmp57_;
	GEqualFunc _tmp58_;
	GHashTable* _tmp59_;
	AlmBlacklist* _tmp60_;
	AlmApplicationBlacklist* _tmp61_;
	AlmApplicationBlacklist* _tmp62_;
	GHashTable* _tmp63_;
	GHashTable* _tmp64_;
	AlmApplicationsTreeView* _tmp65_;
	AlmApplicationBlacklist* _tmp66_;
	AlmApplicationBlacklist* _tmp67_;
	g_return_val_if_fail (blacklist_interface != NULL, NULL);
	self = (AlmPrivacyWidget*) g_object_new (object_type, "orientation", GTK_ORIENTATION_VERTICAL, "spacing", 10, NULL);
	_tmp0_ = g_settings_new ("org.gnome.desktop.privacy");
	_g_object_unref0 (self->priv->privacy_settings);
	self->priv->privacy_settings = _tmp0_;
	_tmp1_ = blacklist_interface;
	_tmp2_ = _alm_blacklist_ref0 (_tmp1_);
	_alm_blacklist_unref0 (self->priv->blacklist);
	self->priv->blacklist = _tmp2_;
	_tmp3_ = gee_hash_map_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, GTK_TYPE_CHECK_BUTTON, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL, NULL, NULL);
	_g_object_unref0 (self->priv->checkboxes);
	self->priv->checkboxes = _tmp3_;
	_tmp4_ = gee_hash_set_new (GTK_TYPE_CHECK_BUTTON, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL, NULL);
	_g_object_unref0 (self->priv->button_list);
	self->priv->button_list = _tmp4_;
	_tmp5_ = blacklist_interface;
	_tmp6_ = self->priv->checkboxes;
	_tmp7_ = alm_file_type_blacklist_new (_tmp5_, _tmp6_);
	_alm_file_type_blacklist_unref0 (self->priv->files_type_blacklist);
	self->priv->files_type_blacklist = _tmp7_;
	_tmp8_ = blacklist_interface;
	_tmp9_ = alm_path_blacklist_new (_tmp8_);
	_alm_path_blacklist_unref0 (self->priv->path_blacklist);
	self->priv->path_blacklist = _tmp9_;
	_tmp10_ = blacklist_interface;
	g_signal_connect_object (_tmp10_, "template-added", (GCallback) ___lambda10__alm_blacklist_template_added, self, 0);
	_tmp11_ = blacklist_interface;
	g_signal_connect_object (_tmp11_, "template-removed", (GCallback) ___lambda11__alm_blacklist_template_removed, self, 0);
	_tmp12_ = self->priv->path_blacklist;
	g_signal_connect_object (_tmp12_, "folder-added", (GCallback) ___lambda12__alm_path_blacklist_folder_added, self, 0);
	_tmp13_ = self->priv->path_blacklist;
	g_signal_connect_object (_tmp13_, "folder-removed", (GCallback) ___lambda13__alm_path_blacklist_folder_removed, self, 0);
	_tmp14_ = g_str_hash;
	_tmp15_ = g_str_equal;
	_tmp16_ = gee_hash_map_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, _tmp14_, _tmp15_, NULL);
	_g_object_unref0 (self->priv->mime_dict);
	self->priv->mime_dict = _tmp16_;
	_tmp17_ = self->priv->mime_dict;
	_tmp18_ = _ ("Music");
	gee_abstract_map_set ((GeeAbstractMap*) _tmp17_, _tmp18_, ZEITGEIST_NFO_AUDIO);
	_tmp19_ = self->priv->mime_dict;
	_tmp20_ = _ ("Videos");
	gee_abstract_map_set ((GeeAbstractMap*) _tmp19_, _tmp20_, ZEITGEIST_NFO_VIDEO);
	_tmp21_ = self->priv->mime_dict;
	_tmp22_ = _ ("Pictures");
	gee_abstract_map_set ((GeeAbstractMap*) _tmp21_, _tmp22_, ZEITGEIST_NFO_IMAGE);
	_tmp23_ = self->priv->mime_dict;
	_tmp24_ = _ ("Documents");
	gee_abstract_map_set ((GeeAbstractMap*) _tmp23_, _tmp24_, ZEITGEIST_NFO_DOCUMENT);
	_tmp25_ = self->priv->mime_dict;
	_tmp26_ = _ ("Presentations");
	gee_abstract_map_set ((GeeAbstractMap*) _tmp25_, _tmp26_, ZEITGEIST_NFO_PRESENTATION);
	_tmp27_ = self->priv->mime_dict;
	_tmp28_ = _ ("Spreadsheets");
	gee_abstract_map_set ((GeeAbstractMap*) _tmp27_, _tmp28_, ZEITGEIST_NFO_SPREADSHEET);
	_tmp29_ = self->priv->mime_dict;
	_tmp30_ = _ ("Chat Logs");
	gee_abstract_map_set ((GeeAbstractMap*) _tmp29_, _tmp30_, ZEITGEIST_NMO_IMMESSAGE);
	_tmp31_ = self->priv->mime_dict;
	_tmp32_ = _ ("Emails");
	gee_abstract_map_set ((GeeAbstractMap*) _tmp31_, _tmp32_, ZEITGEIST_NMO_EMAIL);
	_tmp33_ = self->priv->mime_dict;
	_tmp34_ = _ ("Websites");
	gee_abstract_map_set ((GeeAbstractMap*) _tmp33_, _tmp34_, ZEITGEIST_NFO_WEBSITE);
	_tmp35_ = g_new0 (GUserDirectory, 8);
	_tmp35_[0] = G_USER_DIRECTORY_DESKTOP;
	_tmp35_[1] = G_USER_DIRECTORY_DOCUMENTS;
	_tmp35_[2] = G_USER_DIRECTORY_DOWNLOAD;
	_tmp35_[3] = G_USER_DIRECTORY_MUSIC;
	_tmp35_[4] = G_USER_DIRECTORY_PICTURES;
	_tmp35_[5] = G_USER_DIRECTORY_PUBLIC_SHARE;
	_tmp35_[6] = G_USER_DIRECTORY_TEMPLATES;
	_tmp35_[7] = G_USER_DIRECTORY_VIDEOS;
	special_dirs = _tmp35_;
	special_dirs_length1 = 8;
	_special_dirs_size_ = special_dirs_length1;
	{
		gint i;
		i = 0;
		{
			gboolean _tmp36_;
			_tmp36_ = TRUE;
			while (TRUE) {
				gboolean _tmp37_;
				gint _tmp39_;
				GUserDirectory* _tmp40_;
				gint _tmp40__length1;
				GUserDirectory* _tmp41_;
				gint _tmp41__length1;
				gint _tmp42_;
				GUserDirectory _tmp43_;
				const gchar* _tmp44_ = NULL;
				gchar* _tmp45_;
				gchar* dir_path;
				const gchar* _tmp46_;
				_tmp37_ = _tmp36_;
				if (!_tmp37_) {
					gint _tmp38_;
					_tmp38_ = i;
					i = _tmp38_ + 1;
				}
				_tmp36_ = FALSE;
				_tmp39_ = i;
				_tmp40_ = special_dirs;
				_tmp40__length1 = special_dirs_length1;
				if (!(_tmp39_ < _tmp40__length1)) {
					break;
				}
				_tmp41_ = special_dirs;
				_tmp41__length1 = special_dirs_length1;
				_tmp42_ = i;
				_tmp43_ = _tmp41_[_tmp42_];
				_tmp44_ = g_get_user_special_dir (_tmp43_);
				_tmp45_ = g_strdup (_tmp44_);
				dir_path = _tmp45_;
				_tmp46_ = dir_path;
				if (_tmp46_ != NULL) {
					GeeHashMap* _tmp47_;
					const gchar* _tmp48_;
					GUserDirectory* _tmp49_;
					gint _tmp49__length1;
					gint _tmp50_;
					GUserDirectory _tmp51_;
					_tmp47_ = self->priv->defined_dirs;
					_tmp48_ = dir_path;
					_tmp49_ = special_dirs;
					_tmp49__length1 = special_dirs_length1;
					_tmp50_ = i;
					_tmp51_ = _tmp49_[_tmp50_];
					gee_abstract_map_set ((GeeAbstractMap*) _tmp47_, _tmp48_, (gpointer) ((gintptr) _tmp51_));
				}
				_g_free0 (dir_path);
			}
		}
	}
	_tmp52_ = gtk_widget_render_icon_pixbuf ((GtkWidget*) self, GTK_STOCK_DIRECTORY, GTK_ICON_SIZE_LARGE_TOOLBAR);
	_tmp53_ = _g_object_ref0 (_tmp52_);
	_g_object_unref0 (self->priv->stock_folder_icon);
	self->priv->stock_folder_icon = _tmp53_;
	_tmp54_ = g_str_hash;
	_tmp55_ = g_str_equal;
	_tmp56_ = g_hash_table_new_full (_tmp54_, _tmp55_, _g_free0_, _alm_app_choose_info_unref0_);
	_g_hash_table_unref0 (self->priv->blocked_list);
	self->priv->blocked_list = _tmp56_;
	_tmp57_ = g_str_hash;
	_tmp58_ = g_str_equal;
	_tmp59_ = g_hash_table_new_full (_tmp57_, _tmp58_, _g_free0_, _alm_app_choose_info_unref0_);
	_g_hash_table_unref0 (self->priv->unblocked_list);
	self->priv->unblocked_list = _tmp59_;
	_tmp60_ = blacklist_interface;
	_tmp61_ = alm_application_blacklist_new (_tmp60_);
	_alm_application_blacklist_unref0 (self->priv->app_blacklist);
	self->priv->app_blacklist = _tmp61_;
	_tmp62_ = self->priv->app_blacklist;
	_tmp63_ = self->priv->blocked_list;
	_tmp64_ = self->priv->unblocked_list;
	_tmp65_ = alm_applications_tree_view_new (_tmp62_, _tmp63_, _tmp64_);
	g_object_ref_sink (_tmp65_);
	_g_object_unref0 (self->priv->app_treeview);
	self->priv->app_treeview = _tmp65_;
	_tmp66_ = self->priv->app_blacklist;
	g_signal_connect_object (_tmp66_, "application-removed", (GCallback) ___lambda14__alm_application_blacklist_application_removed, self, 0);
	_tmp67_ = self->priv->app_blacklist;
	g_signal_connect_object (_tmp67_, "application-added", (GCallback) ___lambda15__alm_application_blacklist_application_added, self, 0);
	alm_privacy_widget_setup_ui (self);
	special_dirs = (g_free (special_dirs), NULL);
	return self;
}


AlmPrivacyWidget* alm_privacy_widget_new (AlmBlacklist* blacklist_interface) {
	return alm_privacy_widget_construct (ALM_TYPE_PRIVACY_WIDGET, blacklist_interface);
}


static void __lambda16_ (AlmPrivacyWidget* self, gboolean status) {
	GtkSwitch* _tmp0_;
	gboolean _tmp1_;
	_tmp0_ = self->priv->record_button;
	_tmp1_ = status;
	gtk_switch_set_active (_tmp0_, !_tmp1_);
}


static void ___lambda16__alm_blacklist_incognito_toggled (AlmBlacklist* _sender, gboolean status, gpointer self) {
	__lambda16_ (self, status);
}


static void __lambda17_ (AlmPrivacyWidget* self) {
	AlmBlacklist* _tmp0_;
	gboolean _tmp1_ = FALSE;
	gboolean recording;
	GtkSwitch* _tmp2_;
	gboolean _tmp3_;
	gboolean _tmp4_;
	gboolean _tmp5_;
	_tmp0_ = self->priv->blacklist;
	_tmp1_ = alm_blacklist_get_incognito (_tmp0_);
	recording = !_tmp1_;
	_tmp2_ = self->priv->record_button;
	_tmp3_ = gtk_switch_get_active (_tmp2_);
	_tmp4_ = _tmp3_;
	_tmp5_ = recording;
	if (_tmp4_ != _tmp5_) {
		AlmBlacklist* _tmp6_;
		gboolean _tmp7_;
		GSettings* _tmp8_;
		GtkSwitch* _tmp9_;
		gboolean _tmp10_;
		gboolean _tmp11_;
		_tmp6_ = self->priv->blacklist;
		_tmp7_ = recording;
		alm_blacklist_set_incognito (_tmp6_, _tmp7_);
		_tmp8_ = self->priv->privacy_settings;
		_tmp9_ = self->priv->record_button;
		_tmp10_ = gtk_switch_get_active (_tmp9_);
		_tmp11_ = _tmp10_;
		g_settings_set_boolean (_tmp8_, "remember-recent-files", _tmp11_);
	}
}


static void ___lambda17__g_object_notify (GObject* _sender, GParamSpec* pspec, gpointer self) {
	__lambda17_ (self);
}


static void __lambda18_ (AlmPrivacyWidget* self) {
	AlmDeleteHistoryDialog* _tmp0_;
	_tmp0_ = self->priv->delete_dialog;
	alm_delete_history_dialog_on_delete_history (_tmp0_);
}


static void ___lambda18__gtk_button_clicked (GtkButton* _sender, gpointer self) {
	__lambda18_ (self);
}


static gint __lambda19_ (const gchar* s1, const gchar* s2) {
	gint result = 0;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	gint _tmp2_ = 0;
	g_return_val_if_fail (s1 != NULL, 0);
	g_return_val_if_fail (s2 != NULL, 0);
	_tmp0_ = s1;
	_tmp1_ = s2;
	_tmp2_ = g_utf8_collate (_tmp0_, _tmp1_);
	result = _tmp2_;
	return result;
}


static gint ___lambda19__gcompare_func (gconstpointer a, gconstpointer b) {
	gint result;
	result = __lambda19_ (a, b);
	return result;
}


static Block4Data* block4_data_ref (Block4Data* _data4_) {
	g_atomic_int_inc (&_data4_->_ref_count_);
	return _data4_;
}


static void block4_data_unref (void * _userdata_) {
	Block4Data* _data4_;
	_data4_ = (Block4Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data4_->_ref_count_)) {
		AlmPrivacyWidget * self;
		self = _data4_->self;
		_g_object_unref0 (_data4_->check_button);
		_g_object_unref0 (self);
		g_slice_free (Block4Data, _data4_);
	}
}


static void ____lambda20_ (Block4Data* _data4_) {
	AlmPrivacyWidget * self;
	gboolean _tmp0_;
	self = _data4_->self;
	_tmp0_ = self->priv->file_type_fire_signal;
	if (_tmp0_) {
		GtkCheckButton* _tmp1_;
		gboolean _tmp2_;
		gboolean _tmp3_;
		self->priv->file_type_fire_signal = FALSE;
		_tmp1_ = _data4_->check_button;
		_tmp2_ = gtk_toggle_button_get_active ((GtkToggleButton*) _tmp1_);
		_tmp3_ = _tmp2_;
		if (_tmp3_) {
			AlmFileTypeBlacklist* _tmp4_;
			GeeHashMap* _tmp5_;
			GtkCheckButton* _tmp6_;
			const gchar* _tmp7_;
			const gchar* _tmp8_;
			gpointer _tmp9_ = NULL;
			gchar* _tmp10_;
			_tmp4_ = self->priv->files_type_blacklist;
			_tmp5_ = self->priv->mime_dict;
			_tmp6_ = _data4_->check_button;
			_tmp7_ = gtk_button_get_label ((GtkButton*) _tmp6_);
			_tmp8_ = _tmp7_;
			_tmp9_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp5_, _tmp8_);
			_tmp10_ = (gchar*) _tmp9_;
			alm_file_type_blacklist_unblock (_tmp4_, _tmp10_);
			_g_free0 (_tmp10_);
		} else {
			AlmFileTypeBlacklist* _tmp11_;
			GeeHashMap* _tmp12_;
			GtkCheckButton* _tmp13_;
			const gchar* _tmp14_;
			const gchar* _tmp15_;
			gpointer _tmp16_ = NULL;
			gchar* _tmp17_;
			_tmp11_ = self->priv->files_type_blacklist;
			_tmp12_ = self->priv->mime_dict;
			_tmp13_ = _data4_->check_button;
			_tmp14_ = gtk_button_get_label ((GtkButton*) _tmp13_);
			_tmp15_ = _tmp14_;
			_tmp16_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp12_, _tmp15_);
			_tmp17_ = (gchar*) _tmp16_;
			alm_file_type_blacklist_block (_tmp11_, _tmp17_);
			_g_free0 (_tmp17_);
		}
		self->priv->file_type_fire_signal = TRUE;
	}
}


static void _____lambda20__gtk_toggle_button_toggled (GtkToggleButton* _sender, gpointer self) {
	____lambda20_ (self);
}


static void _alm_privacy_widget_on_remove_exception_gtk_tool_button_clicked (GtkToolButton* _sender, gpointer self) {
	alm_privacy_widget_on_remove_exception (self);
}


static void _alm_privacy_widget_on_add_folder_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) {
	alm_privacy_widget_on_add_folder (self);
}


static void _alm_privacy_widget_on_add_application_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) {
	alm_privacy_widget_on_add_application (self);
}


static void alm_privacy_widget_setup_ui (AlmPrivacyWidget* self) {
	const gchar* _tmp0_ = NULL;
	gchar* _tmp1_;
	gchar* text;
	GtkLabel* _tmp2_;
	GtkLabel* label;
	GtkLabel* _tmp3_;
	const gchar* _tmp4_;
	gchar* _tmp5_ = NULL;
	gchar* _tmp6_;
	GtkLabel* _tmp7_;
	GtkLabel* _tmp8_;
	GtkLabel* _tmp9_;
	GtkLabel* _tmp10_;
	GtkSwitch* _tmp11_;
	const gchar* _tmp12_ = NULL;
	GtkLabel* _tmp13_;
	GtkLabel* record_label;
	GtkSwitch* _tmp14_;
	AlmBlacklist* _tmp15_;
	gboolean _tmp16_ = FALSE;
	AlmBlacklist* _tmp17_;
	GtkSwitch* _tmp18_;
	GtkButton* _tmp19_;
	GtkButton* _tmp20_;
	const gchar* _tmp21_ = NULL;
	GtkButton* _tmp22_;
	GtkBox* _tmp23_;
	GtkBox* hbox;
	GtkBox* _tmp24_;
	GtkSwitch* _tmp25_;
	GtkBox* _tmp26_;
	GtkLabel* _tmp27_;
	GtkBox* _tmp28_;
	GtkLabel* _tmp29_;
	GtkLabel* _tmp30_;
	GtkBox* _tmp31_;
	GtkButton* _tmp32_;
	GtkBox* _tmp33_;
	GtkBox* _tmp34_;
	GtkBox* checkbox_hbox;
	GCompareFunc mime_compare;
	GeeArrayList* _tmp35_;
	GeeArrayList* keys;
	GeeArrayList* _tmp36_;
	GeeHashMap* _tmp37_;
	GeeSet* _tmp38_;
	GeeSet* _tmp39_;
	GeeSet* _tmp40_;
	GeeArrayList* _tmp41_;
	GCompareFunc _tmp42_;
	AlmFileTypeBlacklist* _tmp67_;
	const gchar* _tmp75_ = NULL;
	GtkLabel* _tmp76_;
	GtkLabel* checkbox_label;
	GtkAlignment* _tmp77_;
	GtkAlignment* al;
	GtkBox* _tmp78_;
	GtkBox* checkbox_vbox;
	GtkBox* _tmp79_;
	GtkBox* _tmp80_;
	GtkBox* exception_vbox;
	const gchar* _tmp81_ = NULL;
	GtkLabel* _tmp82_;
	GtkLabel* exception_label;
	GtkAlignment* _tmp83_;
	GtkAlignment* al2;
	GtkListStore* _tmp84_;
	GtkListStore* _tmp85_;
	GtkTreeView* _tmp86_;
	GtkTreeView* _tmp87_;
	GtkTreeView* _tmp88_;
	GtkTreeViewColumn* _tmp89_;
	GtkTreeViewColumn* column_pix_name;
	const gchar* _tmp90_ = NULL;
	GtkTreeView* _tmp91_;
	AlmExceptionCellRenderer* _tmp92_;
	AlmExceptionCellRenderer* pix_rend;
	GtkScrolledWindow* _tmp93_;
	GtkScrolledWindow* scroll;
	GtkTreeView* _tmp94_;
	GtkToolbar* _tmp95_;
	GtkToolbar* exception_toolbar;
	GtkStyleContext* _tmp96_ = NULL;
	GtkStyleContext* _tmp97_ = NULL;
	GtkStyleContext* _tmp98_ = NULL;
	GtkToolItem* _tmp99_;
	GtkToolItem* container_add;
	GtkMenuButton* _tmp100_;
	GtkMenuButton* exception_add;
	GtkImage* _tmp101_;
	GtkImage* icon;
	const gchar* _tmp102_ = NULL;
	GtkToolButton* _tmp103_;
	GtkToolButton* exception_remove;
	GtkMenu* _tmp104_;
	GtkMenuItem* _tmp105_;
	GtkMenuItem* folder_menu;
	GtkMenuItem* _tmp106_;
	GtkMenuItem* app_menu;
	GtkMenu* _tmp107_;
	GtkMenu* _tmp108_;
	GtkMenu* _tmp109_;
	GtkMenu* _tmp110_;
	GtkBox* _tmp111_;
	GtkBox* general_hbox;
	AlmApplicationBlacklist* _tmp112_;
	GHashTable* _tmp113_;
	GHashTable* _tmp114_;
	AlmApplicationsChooserDialog* _tmp115_;
	GtkButton* _tmp116_;
	AlmDeleteHistoryDialog* _tmp117_;
	g_return_if_fail (self != NULL);
	gtk_container_set_border_width ((GtkContainer*) self, (guint) 12);
	_tmp0_ = _ ("This Operating System keeps track of Files and Applications you've use" \
"d to provide extra functionality. If other people can see or access yo" \
"ur user account, you may wish to limit which items are recorded.");
	_tmp1_ = g_strdup (_tmp0_);
	text = _tmp1_;
	_tmp2_ = (GtkLabel*) gtk_label_new ("");
	g_object_ref_sink (_tmp2_);
	label = _tmp2_;
	_tmp3_ = label;
	_tmp4_ = text;
	_tmp5_ = g_strdup_printf ("%s", _tmp4_);
	_tmp6_ = _tmp5_;
	gtk_label_set_markup (_tmp3_, _tmp6_);
	_g_free0 (_tmp6_);
	_tmp7_ = label;
	gtk_label_set_line_wrap (_tmp7_, TRUE);
	_tmp8_ = label;
	gtk_label_set_line_wrap_mode (_tmp8_, PANGO_WRAP_WORD);
	_tmp9_ = label;
	gtk_misc_set_alignment ((GtkMisc*) _tmp9_, (gfloat) 0, 0.5f);
	_tmp10_ = label;
	gtk_box_pack_start ((GtkBox*) self, (GtkWidget*) _tmp10_, FALSE, TRUE, (guint) 0);
	_tmp11_ = (GtkSwitch*) gtk_switch_new ();
	g_object_ref_sink (_tmp11_);
	_g_object_unref0 (self->priv->record_button);
	self->priv->record_button = _tmp11_;
	_tmp12_ = _ ("Record file and application usage");
	_tmp13_ = (GtkLabel*) gtk_label_new (_tmp12_);
	g_object_ref_sink (_tmp13_);
	record_label = _tmp13_;
	_tmp14_ = self->priv->record_button;
	_tmp15_ = self->priv->blacklist;
	_tmp16_ = alm_blacklist_get_incognito (_tmp15_);
	gtk_switch_set_active (_tmp14_, !_tmp16_);
	_tmp17_ = self->priv->blacklist;
	g_signal_connect_object (_tmp17_, "incognito-toggled", (GCallback) ___lambda16__alm_blacklist_incognito_toggled, self, 0);
	_tmp18_ = self->priv->record_button;
	g_signal_connect_object ((GObject*) _tmp18_, "notify::active", (GCallback) ___lambda17__g_object_notify, self, 0);
	_tmp19_ = (GtkButton*) gtk_button_new_from_stock (GTK_STOCK_DELETE);
	g_object_ref_sink (_tmp19_);
	_g_object_unref0 (self->priv->del_button);
	self->priv->del_button = _tmp19_;
	_tmp20_ = self->priv->del_button;
	_tmp21_ = _ ("Clear Usage Data…");
	gtk_button_set_label (_tmp20_, _tmp21_);
	_tmp22_ = self->priv->del_button;
	g_signal_connect_object (_tmp22_, "clicked", (GCallback) ___lambda18__gtk_button_clicked, self, 0);
	_tmp23_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 3);
	g_object_ref_sink (_tmp23_);
	hbox = _tmp23_;
	_tmp24_ = hbox;
	_tmp25_ = self->priv->record_button;
	gtk_box_pack_start (_tmp24_, (GtkWidget*) _tmp25_, FALSE, FALSE, (guint) 3);
	_tmp26_ = hbox;
	_tmp27_ = record_label;
	gtk_box_pack_start (_tmp26_, (GtkWidget*) _tmp27_, FALSE, FALSE, (guint) 3);
	_tmp28_ = hbox;
	_tmp29_ = (GtkLabel*) gtk_label_new ("");
	g_object_ref_sink (_tmp29_);
	_tmp30_ = _tmp29_;
	gtk_box_pack_start (_tmp28_, (GtkWidget*) _tmp30_, TRUE, TRUE, (guint) 3);
	_g_object_unref0 (_tmp30_);
	_tmp31_ = hbox;
	_tmp32_ = self->priv->del_button;
	gtk_box_pack_start (_tmp31_, (GtkWidget*) _tmp32_, FALSE, FALSE, (guint) 3);
	_tmp33_ = hbox;
	gtk_box_pack_start ((GtkBox*) self, (GtkWidget*) _tmp33_, FALSE, TRUE, (guint) 0);
	_tmp34_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
	g_object_ref_sink (_tmp34_);
	checkbox_hbox = _tmp34_;
	mime_compare = ___lambda19__gcompare_func;
	_tmp35_ = gee_array_list_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, NULL);
	keys = _tmp35_;
	_tmp36_ = keys;
	_tmp37_ = self->priv->mime_dict;
	_tmp38_ = gee_abstract_map_get_keys ((GeeMap*) _tmp37_);
	_tmp39_ = _tmp38_;
	_tmp40_ = _tmp39_;
	gee_abstract_collection_add_all ((GeeAbstractCollection*) _tmp36_, (GeeCollection*) _tmp40_);
	_g_object_unref0 (_tmp40_);
	_tmp41_ = keys;
	_tmp42_ = mime_compare;
	gee_list_sort ((GeeList*) _tmp41_, _tmp42_);
	{
		GeeArrayList* _tmp43_;
		GeeArrayList* _tmp44_;
		GeeArrayList* _key_list;
		GeeArrayList* _tmp45_;
		gint _tmp46_;
		gint _tmp47_;
		gint _key_size;
		gint _key_index;
		_tmp43_ = keys;
		_tmp44_ = _g_object_ref0 (_tmp43_);
		_key_list = _tmp44_;
		_tmp45_ = _key_list;
		_tmp46_ = gee_abstract_collection_get_size ((GeeCollection*) _tmp45_);
		_tmp47_ = _tmp46_;
		_key_size = _tmp47_;
		_key_index = -1;
		while (TRUE) {
			gint _tmp48_;
			gint _tmp49_;
			gint _tmp50_;
			GeeArrayList* _tmp51_;
			gint _tmp52_;
			gpointer _tmp53_ = NULL;
			gchar* key;
			const gchar* _tmp54_;
			GtkCheckButton* _tmp55_;
			GtkCheckButton* check_button;
			GtkCheckButton* _tmp56_;
			GeeHashSet* _tmp57_;
			GtkCheckButton* _tmp58_;
			GeeHashMap* _tmp59_;
			GeeHashMap* _tmp60_;
			const gchar* _tmp61_;
			gpointer _tmp62_ = NULL;
			gchar* _tmp63_;
			GtkCheckButton* _tmp64_;
			GtkBox* _tmp65_;
			GtkCheckButton* _tmp66_;
			_tmp48_ = _key_index;
			_key_index = _tmp48_ + 1;
			_tmp49_ = _key_index;
			_tmp50_ = _key_size;
			if (!(_tmp49_ < _tmp50_)) {
				break;
			}
			_tmp51_ = _key_list;
			_tmp52_ = _key_index;
			_tmp53_ = gee_abstract_list_get ((GeeAbstractList*) _tmp51_, _tmp52_);
			key = (gchar*) _tmp53_;
			_tmp54_ = key;
			_tmp55_ = (GtkCheckButton*) gtk_check_button_new_with_label (_tmp54_);
			g_object_ref_sink (_tmp55_);
			check_button = _tmp55_;
			_tmp56_ = check_button;
			gtk_toggle_button_set_active ((GtkToggleButton*) _tmp56_, TRUE);
			_tmp57_ = self->priv->button_list;
			_tmp58_ = check_button;
			gee_abstract_collection_add ((GeeAbstractCollection*) _tmp57_, _tmp58_);
			_tmp59_ = self->priv->checkboxes;
			_tmp60_ = self->priv->mime_dict;
			_tmp61_ = key;
			_tmp62_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp60_, _tmp61_);
			_tmp63_ = (gchar*) _tmp62_;
			_tmp64_ = check_button;
			gee_abstract_map_set ((GeeAbstractMap*) _tmp59_, _tmp63_, _tmp64_);
			_g_free0 (_tmp63_);
			_tmp65_ = checkbox_hbox;
			_tmp66_ = check_button;
			gtk_box_pack_start (_tmp65_, (GtkWidget*) _tmp66_, FALSE, FALSE, (guint) 0);
			_g_object_unref0 (check_button);
			_g_free0 (key);
		}
		_g_object_unref0 (_key_list);
	}
	_tmp67_ = self->priv->files_type_blacklist;
	alm_file_type_blacklist_populate_file_types (_tmp67_);
	{
		GeeHashSet* _tmp68_;
		GeeIterator* _tmp69_ = NULL;
		GeeIterator* _check_button_it;
		_tmp68_ = self->priv->button_list;
		_tmp69_ = gee_abstract_collection_iterator ((GeeAbstractCollection*) _tmp68_);
		_check_button_it = _tmp69_;
		while (TRUE) {
			Block4Data* _data4_;
			GeeIterator* _tmp70_;
			gboolean _tmp71_ = FALSE;
			GeeIterator* _tmp72_;
			gpointer _tmp73_ = NULL;
			GtkCheckButton* _tmp74_;
			_data4_ = g_slice_new0 (Block4Data);
			_data4_->_ref_count_ = 1;
			_data4_->self = g_object_ref (self);
			_tmp70_ = _check_button_it;
			_tmp71_ = gee_iterator_next (_tmp70_);
			if (!_tmp71_) {
				block4_data_unref (_data4_);
				_data4_ = NULL;
				break;
			}
			_tmp72_ = _check_button_it;
			_tmp73_ = gee_iterator_get (_tmp72_);
			_data4_->check_button = (GtkCheckButton*) _tmp73_;
			_tmp74_ = _data4_->check_button;
			g_signal_connect_data ((GtkToggleButton*) _tmp74_, "toggled", (GCallback) _____lambda20__gtk_toggle_button_toggled, block4_data_ref (_data4_), (GClosureNotify) block4_data_unref, 0);
			block4_data_unref (_data4_);
			_data4_ = NULL;
		}
		_g_object_unref0 (_check_button_it);
	}
	_tmp75_ = _ ("Include:");
	_tmp76_ = (GtkLabel*) gtk_label_new (_tmp75_);
	g_object_ref_sink (_tmp76_);
	checkbox_label = _tmp76_;
	_tmp77_ = (GtkAlignment*) gtk_alignment_new ((gfloat) 0, 0.5f, (gfloat) 0, (gfloat) 0);
	g_object_ref_sink (_tmp77_);
	al = _tmp77_;
	gtk_container_add ((GtkContainer*) al, (GtkWidget*) checkbox_label);
	_tmp78_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
	g_object_ref_sink (_tmp78_);
	checkbox_vbox = _tmp78_;
	gtk_box_pack_start (checkbox_vbox, (GtkWidget*) al, FALSE, TRUE, (guint) 0);
	_tmp79_ = checkbox_hbox;
	gtk_box_pack_start (checkbox_vbox, (GtkWidget*) _tmp79_, TRUE, TRUE, (guint) 0);
	_tmp80_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
	g_object_ref_sink (_tmp80_);
	exception_vbox = _tmp80_;
	_tmp81_ = _ ("Exclude:");
	_tmp82_ = (GtkLabel*) gtk_label_new (_tmp81_);
	g_object_ref_sink (_tmp82_);
	exception_label = _tmp82_;
	_tmp83_ = (GtkAlignment*) gtk_alignment_new ((gfloat) 0, 0.5f, (gfloat) 0, (gfloat) 0);
	g_object_ref_sink (_tmp83_);
	al2 = _tmp83_;
	gtk_container_add ((GtkContainer*) al2, (GtkWidget*) exception_label);
	gtk_box_pack_start (exception_vbox, (GtkWidget*) al2, FALSE, FALSE, (guint) 5);
	_tmp84_ = gtk_list_store_new (4, G_TYPE_STRING, GDK_TYPE_PIXBUF, G_TYPE_STRING, ALM_TYPE_ITEM_TYPE);
	_g_object_unref0 (self->priv->exception_list_store);
	self->priv->exception_list_store = _tmp84_;
	_tmp85_ = self->priv->exception_list_store;
	_tmp86_ = (GtkTreeView*) gtk_tree_view_new_with_model ((GtkTreeModel*) _tmp85_);
	g_object_ref_sink (_tmp86_);
	_g_object_unref0 (self->priv->exception_list);
	self->priv->exception_list = _tmp86_;
	_tmp87_ = self->priv->exception_list;
	gtk_tree_view_set_headers_visible (_tmp87_, FALSE);
	_tmp88_ = self->priv->exception_list;
	gtk_tree_view_set_rules_hint (_tmp88_, TRUE);
	_tmp89_ = gtk_tree_view_column_new ();
	g_object_ref_sink (_tmp89_);
	column_pix_name = _tmp89_;
	_tmp90_ = _ ("Name");
	gtk_tree_view_column_set_title (column_pix_name, _tmp90_);
	_tmp91_ = self->priv->exception_list;
	gtk_tree_view_append_column (_tmp91_, column_pix_name);
	_tmp92_ = alm_exception_cell_renderer_new ();
	g_object_ref_sink (_tmp92_);
	pix_rend = _tmp92_;
	gtk_cell_layout_pack_start ((GtkCellLayout*) column_pix_name, (GtkCellRenderer*) pix_rend, FALSE);
	gtk_cell_layout_add_attribute ((GtkCellLayout*) column_pix_name, (GtkCellRenderer*) pix_rend, "pixbuf", 1);
	gtk_cell_layout_add_attribute ((GtkCellLayout*) column_pix_name, (GtkCellRenderer*) pix_rend, "text", 2);
	_tmp93_ = (GtkScrolledWindow*) gtk_scrolled_window_new (NULL, NULL);
	g_object_ref_sink (_tmp93_);
	scroll = _tmp93_;
	_tmp94_ = self->priv->exception_list;
	gtk_container_add ((GtkContainer*) scroll, (GtkWidget*) _tmp94_);
	gtk_scrolled_window_set_policy (scroll, GTK_POLICY_NEVER, GTK_POLICY_AUTOMATIC);
	gtk_scrolled_window_set_shadow_type (scroll, GTK_SHADOW_IN);
	gtk_container_set_border_width ((GtkContainer*) scroll, (guint) 1);
	gtk_box_pack_start (exception_vbox, (GtkWidget*) scroll, TRUE, TRUE, (guint) 0);
	_tmp95_ = (GtkToolbar*) gtk_toolbar_new ();
	g_object_ref_sink (_tmp95_);
	exception_toolbar = _tmp95_;
	g_object_set (exception_toolbar, "toolbar-style", GTK_TOOLBAR_ICONS, NULL);
	gtk_toolbar_set_icon_size (exception_toolbar, 1);
	g_object_set (exception_toolbar, "icon-size-set", TRUE, NULL);
	gtk_widget_set_visible ((GtkWidget*) exception_toolbar, TRUE);
	_tmp96_ = gtk_widget_get_style_context ((GtkWidget*) scroll);
	gtk_style_context_set_junction_sides (_tmp96_, GTK_JUNCTION_BOTTOM);
	_tmp97_ = gtk_widget_get_style_context ((GtkWidget*) exception_toolbar);
	gtk_style_context_add_class (_tmp97_, GTK_STYLE_CLASS_INLINE_TOOLBAR);
	_tmp98_ = gtk_widget_get_style_context ((GtkWidget*) exception_toolbar);
	gtk_style_context_set_junction_sides (_tmp98_, GTK_JUNCTION_TOP);
	_tmp99_ = gtk_tool_item_new ();
	g_object_ref_sink (_tmp99_);
	container_add = _tmp99_;
	_tmp100_ = (GtkMenuButton*) gtk_menu_button_new ();
	g_object_ref_sink (_tmp100_);
	exception_add = _tmp100_;
	_tmp101_ = (GtkImage*) gtk_image_new_from_icon_name ("list-add-symbolic", GTK_ICON_SIZE_MENU);
	g_object_ref_sink (_tmp101_);
	icon = _tmp101_;
	gtk_button_set_image ((GtkButton*) exception_add, G_TYPE_CHECK_INSTANCE_CAST (icon, GTK_TYPE_WIDGET, GtkWidget));
	_tmp102_ = _ ("Remove Item");
	_tmp103_ = (GtkToolButton*) gtk_tool_button_new (NULL, _tmp102_);
	g_object_ref_sink (_tmp103_);
	exception_remove = _tmp103_;
	gtk_tool_button_set_icon_name (exception_remove, "list-remove-symbolic");
	g_signal_connect_object (exception_remove, "clicked", (GCallback) _alm_privacy_widget_on_remove_exception_gtk_tool_button_clicked, self, 0);
	gtk_container_add ((GtkContainer*) container_add, (GtkWidget*) exception_add);
	gtk_widget_show_all ((GtkWidget*) container_add);
	gtk_toolbar_insert (exception_toolbar, container_add, 0);
	gtk_toolbar_insert (exception_toolbar, (GtkToolItem*) exception_remove, 1);
	_tmp104_ = (GtkMenu*) gtk_menu_new ();
	g_object_ref_sink (_tmp104_);
	_g_object_unref0 (self->priv->exception_menu);
	self->priv->exception_menu = _tmp104_;
	_tmp105_ = (GtkMenuItem*) gtk_menu_item_new_with_label ("Add Folder…");
	g_object_ref_sink (_tmp105_);
	folder_menu = _tmp105_;
	g_signal_connect_object (folder_menu, "activate", (GCallback) _alm_privacy_widget_on_add_folder_gtk_menu_item_activate, self, 0);
	_tmp106_ = (GtkMenuItem*) gtk_menu_item_new_with_label ("Add Application…");
	g_object_ref_sink (_tmp106_);
	app_menu = _tmp106_;
	g_signal_connect_object (app_menu, "activate", (GCallback) _alm_privacy_widget_on_add_application_gtk_menu_item_activate, self, 0);
	_tmp107_ = self->priv->exception_menu;
	gtk_menu_shell_append ((GtkMenuShell*) _tmp107_, (GtkWidget*) folder_menu);
	_tmp108_ = self->priv->exception_menu;
	gtk_menu_shell_append ((GtkMenuShell*) _tmp108_, (GtkWidget*) app_menu);
	_tmp109_ = self->priv->exception_menu;
	gtk_widget_show_all ((GtkWidget*) _tmp109_);
	_tmp110_ = self->priv->exception_menu;
	gtk_menu_button_set_popup (exception_add, (GtkWidget*) _tmp110_);
	gtk_box_pack_start (exception_vbox, (GtkWidget*) exception_toolbar, FALSE, FALSE, (guint) 0);
	_tmp111_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
	g_object_ref_sink (_tmp111_);
	general_hbox = _tmp111_;
	gtk_box_pack_start (general_hbox, (GtkWidget*) checkbox_vbox, TRUE, TRUE, (guint) 0);
	gtk_box_pack_start (general_hbox, (GtkWidget*) exception_vbox, TRUE, TRUE, (guint) 0);
	gtk_box_pack_start ((GtkBox*) self, (GtkWidget*) general_hbox, FALSE, TRUE, (guint) 0);
	_tmp112_ = self->priv->app_blacklist;
	_tmp113_ = self->priv->blocked_list;
	_tmp114_ = self->priv->unblocked_list;
	_tmp115_ = alm_applications_chooser_dialog_new (_tmp112_, _tmp113_, _tmp114_);
	g_object_ref_sink (_tmp115_);
	_g_object_unref0 (self->priv->app_dialog);
	self->priv->app_dialog = _tmp115_;
	_tmp116_ = self->priv->del_button;
	_tmp117_ = alm_delete_history_dialog_new (_tmp116_);
	g_object_ref_sink (_tmp117_);
	_g_object_unref0 (self->priv->delete_dialog);
	self->priv->delete_dialog = _tmp117_;
	alm_privacy_widget_folders_populate (self);
	alm_privacy_widget_app_populate (self);
	_g_object_unref0 (general_hbox);
	_g_object_unref0 (app_menu);
	_g_object_unref0 (folder_menu);
	_g_object_unref0 (exception_remove);
	_g_object_unref0 (icon);
	_g_object_unref0 (exception_add);
	_g_object_unref0 (container_add);
	_g_object_unref0 (exception_toolbar);
	_g_object_unref0 (scroll);
	_g_object_unref0 (pix_rend);
	_g_object_unref0 (column_pix_name);
	_g_object_unref0 (al2);
	_g_object_unref0 (exception_label);
	_g_object_unref0 (exception_vbox);
	_g_object_unref0 (checkbox_vbox);
	_g_object_unref0 (al);
	_g_object_unref0 (checkbox_label);
	_g_object_unref0 (keys);
	_g_object_unref0 (checkbox_hbox);
	_g_object_unref0 (hbox);
	_g_object_unref0 (record_label);
	_g_object_unref0 (label);
	_g_free0 (text);
}


gint alm_privacy_widget_compare_mimes (AlmPrivacyWidget* self, const gchar* s1, const gchar* s2) {
	gint result = 0;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	gint _tmp2_ = 0;
	g_return_val_if_fail (self != NULL, 0);
	g_return_val_if_fail (s1 != NULL, 0);
	g_return_val_if_fail (s2 != NULL, 0);
	_tmp0_ = s1;
	_tmp1_ = s2;
	_tmp2_ = g_utf8_collate (_tmp0_, _tmp1_);
	result = _tmp2_;
	return result;
}


static void alm_privacy_widget_folders_populate (AlmPrivacyWidget* self) {
	g_return_if_fail (self != NULL);
	{
		AlmPathBlacklist* _tmp0_;
		GeeHashSet* _tmp1_;
		GeeHashSet* _tmp2_;
		GeeIterator* _tmp3_ = NULL;
		GeeIterator* _folder_it;
		_tmp0_ = self->priv->path_blacklist;
		_tmp1_ = alm_path_blacklist_get_all_folders (_tmp0_);
		_tmp2_ = _tmp1_;
		_tmp3_ = gee_abstract_collection_iterator ((GeeAbstractCollection*) _tmp2_);
		_folder_it = _tmp3_;
		while (TRUE) {
			GeeIterator* _tmp4_;
			gboolean _tmp5_ = FALSE;
			GeeIterator* _tmp6_;
			gpointer _tmp7_ = NULL;
			gchar* folder;
			const gchar* _tmp8_;
			_tmp4_ = _folder_it;
			_tmp5_ = gee_iterator_next (_tmp4_);
			if (!_tmp5_) {
				break;
			}
			_tmp6_ = _folder_it;
			_tmp7_ = gee_iterator_get (_tmp6_);
			folder = (gchar*) _tmp7_;
			_tmp8_ = folder;
			alm_privacy_widget_add_folder_to_view (self, _tmp8_);
			_g_free0 (folder);
		}
		_g_object_unref0 (_folder_it);
	}
}


static void alm_privacy_widget_app_populate (AlmPrivacyWidget* self) {
	g_return_if_fail (self != NULL);
	{
		AlmApplicationBlacklist* _tmp0_;
		GeeHashSet* _tmp1_;
		GeeHashSet* _tmp2_;
		GeeIterator* _tmp3_ = NULL;
		GeeIterator* _app_it;
		_tmp0_ = self->priv->app_blacklist;
		_tmp1_ = alm_application_blacklist_get_all_apps (_tmp0_);
		_tmp2_ = _tmp1_;
		_tmp3_ = gee_abstract_collection_iterator ((GeeAbstractCollection*) _tmp2_);
		_app_it = _tmp3_;
		while (TRUE) {
			GeeIterator* _tmp4_;
			gboolean _tmp5_ = FALSE;
			GeeIterator* _tmp6_;
			gpointer _tmp7_ = NULL;
			gchar* app;
			const gchar* _tmp8_;
			_tmp4_ = _app_it;
			_tmp5_ = gee_iterator_next (_tmp4_);
			if (!_tmp5_) {
				break;
			}
			_tmp6_ = _app_it;
			_tmp7_ = gee_iterator_get (_tmp6_);
			app = (gchar*) _tmp7_;
			_tmp8_ = app;
			alm_privacy_widget_add_app_to_view (self, _tmp8_);
			_g_free0 (app);
		}
		_g_object_unref0 (_app_it);
	}
}


static void alm_privacy_widget_on_remove_exception (AlmPrivacyWidget* self) {
	GtkTreeView* _tmp0_;
	GtkTreeSelection* _tmp1_ = NULL;
	GtkTreeSelection* _tmp2_;
	GtkTreeSelection* sel;
	GtkTreeSelection* _tmp3_;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->priv->exception_list;
	_tmp1_ = gtk_tree_view_get_selection (_tmp0_);
	_tmp2_ = _g_object_ref0 (_tmp1_);
	sel = _tmp2_;
	_tmp3_ = sel;
	if (_tmp3_ != NULL) {
		GtkTreeModel* model = NULL;
		GtkTreeIter iter = {0};
		GtkTreeSelection* _tmp4_;
		GtkTreeModel* _tmp5_ = NULL;
		GtkTreeIter _tmp6_ = {0};
		gboolean _tmp7_ = FALSE;
		GtkTreeModel* _tmp8_;
		_tmp4_ = sel;
		_tmp7_ = gtk_tree_selection_get_selected (_tmp4_, &_tmp5_, &_tmp6_);
		_g_object_unref0 (model);
		_tmp8_ = _g_object_ref0 (_tmp5_);
		model = _tmp8_;
		iter = _tmp6_;
		if (_tmp7_) {
			gchar* name = NULL;
			AlmItemType type = 0;
			GtkTreeModel* _tmp9_;
			GtkTreeIter _tmp10_;
			const gchar* _tmp11_;
			_tmp9_ = model;
			_tmp10_ = iter;
			gtk_tree_model_get (_tmp9_, &_tmp10_, 0, &name, 3, &type, -1);
			_tmp11_ = name;
			if (_tmp11_ != NULL) {
				GtkListStore* _tmp12_;
				GtkTreeIter _tmp13_;
				AlmItemType _tmp14_;
				_tmp12_ = self->priv->exception_list_store;
				_tmp13_ = iter;
				gtk_list_store_remove (_tmp12_, &_tmp13_);
				_tmp14_ = type;
				if (_tmp14_ == ALM_ITEM_TYPE_FILE) {
					AlmPathBlacklist* _tmp15_;
					const gchar* _tmp16_;
					_tmp15_ = self->priv->path_blacklist;
					_tmp16_ = name;
					alm_path_blacklist_unblock (_tmp15_, _tmp16_);
				} else {
					AlmApplicationBlacklist* _tmp17_;
					const gchar* _tmp18_;
					_tmp17_ = self->priv->app_blacklist;
					_tmp18_ = name;
					alm_application_blacklist_unblock (_tmp17_, _tmp18_);
				}
			}
			_g_free0 (name);
		}
		_g_object_unref0 (model);
	}
	_g_object_unref0 (sel);
}


static void alm_privacy_widget_on_add_folder (AlmPrivacyWidget* self) {
	const gchar* _tmp0_ = NULL;
	GtkFileChooserDialog* _tmp1_;
	GtkFileChooserDialog* chooser;
	GtkFileChooserDialog* _tmp2_;
	GtkFileChooserDialog* _tmp3_;
	gint _tmp4_ = 0;
	gint res;
	GtkFileChooserDialog* _tmp5_;
	gint _tmp6_;
	g_return_if_fail (self != NULL);
	_tmp0_ = _ ("Select a folder to blacklist");
	_tmp1_ = (GtkFileChooserDialog*) gtk_file_chooser_dialog_new (_tmp0_, NULL, GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER, NULL);
	g_object_ref_sink (_tmp1_);
	chooser = _tmp1_;
	_tmp2_ = chooser;
	gtk_dialog_add_buttons ((GtkDialog*) _tmp2_, GTK_STOCK_OK, GTK_RESPONSE_OK, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, NULL);
	_tmp3_ = chooser;
	_tmp4_ = gtk_dialog_run ((GtkDialog*) _tmp3_);
	res = _tmp4_;
	_tmp5_ = chooser;
	gtk_widget_hide ((GtkWidget*) _tmp5_);
	_tmp6_ = res;
	if (_tmp6_ == ((gint) GTK_RESPONSE_OK)) {
		GtkFileChooserDialog* _tmp7_;
		gchar* _tmp8_ = NULL;
		gchar* folder;
		AlmPathBlacklist* _tmp9_;
		const gchar* _tmp10_;
		gboolean _tmp11_ = FALSE;
		_tmp7_ = chooser;
		_tmp8_ = gtk_file_chooser_get_filename ((GtkFileChooser*) _tmp7_);
		folder = _tmp8_;
		_tmp9_ = self->priv->path_blacklist;
		_tmp10_ = folder;
		_tmp11_ = alm_path_blacklist_is_duplicate (_tmp9_, _tmp10_);
		if (!_tmp11_) {
			const gchar* _tmp12_;
			AlmPathBlacklist* _tmp13_;
			const gchar* _tmp14_;
			_tmp12_ = folder;
			alm_privacy_widget_add_folder_to_view (self, _tmp12_);
			_tmp13_ = self->priv->path_blacklist;
			_tmp14_ = folder;
			alm_path_blacklist_block (_tmp13_, _tmp14_);
		}
		_g_free0 (folder);
	}
	_g_object_unref0 (chooser);
}


static void alm_privacy_widget_on_add_file (AlmPrivacyWidget* self) {
	const gchar* _tmp0_ = NULL;
	GtkFileChooserDialog* _tmp1_;
	GtkFileChooserDialog* chooser;
	GtkFileChooserDialog* _tmp2_;
	GtkFileChooserDialog* _tmp3_;
	gint _tmp4_ = 0;
	gint res;
	GtkFileChooserDialog* _tmp5_;
	gint _tmp6_;
	g_return_if_fail (self != NULL);
	_tmp0_ = _ ("Select a file to blacklist");
	_tmp1_ = (GtkFileChooserDialog*) gtk_file_chooser_dialog_new (_tmp0_, NULL, GTK_FILE_CHOOSER_ACTION_OPEN, NULL);
	g_object_ref_sink (_tmp1_);
	chooser = _tmp1_;
	_tmp2_ = chooser;
	gtk_dialog_add_buttons ((GtkDialog*) _tmp2_, GTK_STOCK_OK, GTK_RESPONSE_OK, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, NULL);
	_tmp3_ = chooser;
	_tmp4_ = gtk_dialog_run ((GtkDialog*) _tmp3_);
	res = _tmp4_;
	_tmp5_ = chooser;
	gtk_widget_hide ((GtkWidget*) _tmp5_);
	_tmp6_ = res;
	if (_tmp6_ == ((gint) GTK_RESPONSE_OK)) {
		GtkFileChooserDialog* _tmp7_;
		gchar* _tmp8_ = NULL;
		gchar* filename;
		AlmPathBlacklist* _tmp9_;
		const gchar* _tmp10_;
		gboolean _tmp11_ = FALSE;
		_tmp7_ = chooser;
		_tmp8_ = gtk_file_chooser_get_filename ((GtkFileChooser*) _tmp7_);
		filename = _tmp8_;
		_tmp9_ = self->priv->path_blacklist;
		_tmp10_ = filename;
		_tmp11_ = alm_path_blacklist_is_duplicate (_tmp9_, _tmp10_);
		if (!_tmp11_) {
			const gchar* _tmp12_;
			AlmPathBlacklist* _tmp13_;
			const gchar* _tmp14_;
			_tmp12_ = filename;
			alm_privacy_widget_add_folder_to_view (self, _tmp12_);
			_tmp13_ = self->priv->path_blacklist;
			_tmp14_ = filename;
			alm_path_blacklist_block (_tmp13_, _tmp14_);
		}
		_g_free0 (filename);
	}
	_g_object_unref0 (chooser);
}


static gpointer _alm_app_choose_info_ref0 (gpointer self) {
	return self ? alm_app_choose_info_ref (self) : NULL;
}


static void alm_privacy_widget_on_add_application (AlmPrivacyWidget* self) {
	AlmApplicationsChooserDialog* _tmp0_;
	GtkWidget* _tmp1_ = NULL;
	GtkWidget* _tmp2_ = NULL;
	AlmApplicationsChooserDialog* _tmp3_;
	AlmApplicationsChooserDialog* _tmp4_;
	const gchar* _tmp5_ = NULL;
	AlmApplicationsChooserDialog* _tmp6_;
	gint _tmp7_ = 0;
	gint res;
	GtkWidget* _tmp8_ = NULL;
	gint _tmp9_;
	AlmApplicationsChooserDialog* _tmp48_;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->priv->app_dialog;
	_tmp1_ = gtk_widget_get_toplevel ((GtkWidget*) self);
	gtk_window_set_transient_for ((GtkWindow*) _tmp0_, G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, GTK_TYPE_WINDOW, GtkWindow));
	_tmp2_ = gtk_widget_get_toplevel ((GtkWidget*) self);
	gtk_widget_set_sensitive (_tmp2_, FALSE);
	_tmp3_ = self->priv->app_dialog;
	gtk_window_set_modal ((GtkWindow*) _tmp3_, TRUE);
	_tmp4_ = self->priv->app_dialog;
	_tmp5_ = _ ("Select Application");
	gtk_window_set_title ((GtkWindow*) _tmp4_, _tmp5_);
	_tmp6_ = self->priv->app_dialog;
	_tmp7_ = gtk_dialog_run ((GtkDialog*) _tmp6_);
	res = _tmp7_;
	_tmp8_ = gtk_widget_get_toplevel ((GtkWidget*) self);
	gtk_widget_set_sensitive (_tmp8_, TRUE);
	_tmp9_ = res;
	if (_tmp9_ == ((gint) GTK_RESPONSE_OK)) {
		AlmApplicationsChooserDialog* _tmp10_;
		GtkTreeView* _tmp11_;
		GtkTreeView* _tmp12_;
		GtkTreeSelection* _tmp13_ = NULL;
		GtkTreeSelection* _tmp14_;
		GtkTreeSelection* sel;
		GtkTreeModel* model = NULL;
		GtkTreeIter iter = {0};
		GtkTreeSelection* _tmp15_;
		GtkTreeModel* _tmp16_ = NULL;
		GtkTreeIter _tmp17_ = {0};
		GtkTreeModel* _tmp18_;
		gchar* app = NULL;
		GtkTreeModel* _tmp19_;
		GtkTreeIter _tmp20_;
		AlmApplicationsChooserDialog* _tmp21_;
		GtkListStore* _tmp22_;
		GtkListStore* _tmp23_;
		GtkTreeIter _tmp24_;
		const gchar* _tmp25_;
		AlmApplicationBlacklist* _tmp26_;
		const gchar* _tmp27_;
		GHashTable* _tmp28_;
		const gchar* _tmp29_;
		gconstpointer _tmp30_ = NULL;
		AlmAppChooseInfo* _tmp31_;
		AlmAppChooseInfo* info;
		AlmAppChooseInfo* _tmp32_;
		_tmp10_ = self->priv->app_dialog;
		_tmp11_ = alm_applications_chooser_dialog_get_tree (_tmp10_);
		_tmp12_ = _tmp11_;
		_tmp13_ = gtk_tree_view_get_selection (_tmp12_);
		_tmp14_ = _g_object_ref0 (_tmp13_);
		sel = _tmp14_;
		_tmp15_ = sel;
		gtk_tree_selection_get_selected (_tmp15_, &_tmp16_, &_tmp17_);
		_g_object_unref0 (model);
		_tmp18_ = _g_object_ref0 (_tmp16_);
		model = _tmp18_;
		iter = _tmp17_;
		_tmp19_ = model;
		_tmp20_ = iter;
		gtk_tree_model_get (_tmp19_, &_tmp20_, 2, &app, -1);
		_tmp21_ = self->priv->app_dialog;
		_tmp22_ = alm_applications_chooser_dialog_get_liststore (_tmp21_);
		_tmp23_ = _tmp22_;
		_tmp24_ = iter;
		gtk_list_store_remove (_tmp23_, &_tmp24_);
		self->priv->app_change_recursive = TRUE;
		_tmp25_ = app;
		alm_privacy_widget_add_app_to_view (self, _tmp25_);
		_tmp26_ = self->priv->app_blacklist;
		_tmp27_ = app;
		alm_application_blacklist_block (_tmp26_, _tmp27_);
		_tmp28_ = self->priv->unblocked_list;
		_tmp29_ = app;
		_tmp30_ = g_hash_table_lookup (_tmp28_, _tmp29_);
		_tmp31_ = _alm_app_choose_info_ref0 ((AlmAppChooseInfo*) _tmp30_);
		info = _tmp31_;
		_tmp32_ = info;
		if (_tmp32_ != NULL) {
			GHashTable* _tmp33_;
			const gchar* _tmp34_;
			GHashTable* _tmp35_;
			const gchar* _tmp36_;
			gconstpointer _tmp37_ = NULL;
			_tmp33_ = self->priv->unblocked_list;
			_tmp34_ = app;
			g_hash_table_remove (_tmp33_, _tmp34_);
			_tmp35_ = self->priv->blocked_list;
			_tmp36_ = app;
			_tmp37_ = g_hash_table_lookup (_tmp35_, _tmp36_);
			if (((AlmAppChooseInfo*) _tmp37_) == NULL) {
				GHashTable* _tmp38_;
				const gchar* _tmp39_;
				gchar* _tmp40_;
				AlmAppChooseInfo* _tmp41_;
				AlmAppChooseInfo* _tmp42_;
				_tmp38_ = self->priv->blocked_list;
				_tmp39_ = app;
				_tmp40_ = g_strdup (_tmp39_);
				_tmp41_ = info;
				_tmp42_ = _alm_app_choose_info_ref0 (_tmp41_);
				g_hash_table_insert (_tmp38_, _tmp40_, _tmp42_);
			} else {
				GHashTable* _tmp43_;
				const gchar* _tmp44_;
				gchar* _tmp45_;
				AlmAppChooseInfo* _tmp46_;
				AlmAppChooseInfo* _tmp47_;
				_tmp43_ = self->priv->blocked_list;
				_tmp44_ = app;
				_tmp45_ = g_strdup (_tmp44_);
				_tmp46_ = info;
				_tmp47_ = _alm_app_choose_info_ref0 (_tmp46_);
				g_hash_table_replace (_tmp43_, _tmp45_, _tmp47_);
			}
		}
		_alm_app_choose_info_unref0 (info);
		_g_free0 (app);
		_g_object_unref0 (model);
		_g_object_unref0 (sel);
	}
	_tmp48_ = self->priv->app_dialog;
	gtk_widget_hide ((GtkWidget*) _tmp48_);
}


static const char* _g_user_directory_to_string (GUserDirectory value) {
	switch (value) {
		case G_USER_DIRECTORY_DESKTOP:
		return "G_USER_DIRECTORY_DESKTOP";
		case G_USER_DIRECTORY_DOCUMENTS:
		return "G_USER_DIRECTORY_DOCUMENTS";
		case G_USER_DIRECTORY_DOWNLOAD:
		return "G_USER_DIRECTORY_DOWNLOAD";
		case G_USER_DIRECTORY_MUSIC:
		return "G_USER_DIRECTORY_MUSIC";
		case G_USER_DIRECTORY_PICTURES:
		return "G_USER_DIRECTORY_PICTURES";
		case G_USER_DIRECTORY_PUBLIC_SHARE:
		return "G_USER_DIRECTORY_PUBLIC_SHARE";
		case G_USER_DIRECTORY_TEMPLATES:
		return "G_USER_DIRECTORY_TEMPLATES";
		case G_USER_DIRECTORY_VIDEOS:
		return "G_USER_DIRECTORY_VIDEOS";
		case G_USER_N_DIRECTORIES:
		return "G_USER_N_DIRECTORIES";
	}
	return NULL;
}


static gchar* string_strip (const gchar* self) {
	gchar* result = NULL;
	gchar* _tmp0_ = NULL;
	gchar* _result_;
	const gchar* _tmp1_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = g_strdup (self);
	_result_ = _tmp0_;
	_tmp1_ = _result_;
	g_strstrip (_tmp1_);
	result = _result_;
	return result;
}


static void alm_privacy_widget_add_folder_to_view (AlmPrivacyWidget* self, const gchar* folder) {
	GdkPixbuf* _tmp0_;
	GdkPixbuf* _tmp1_;
	GdkPixbuf* icon;
	GThemedIcon* nautilus_icon;
	GeeHashMap* _tmp2_;
	const gchar* _tmp3_;
	gboolean _tmp4_ = FALSE;
	const gchar* _tmp38_;
	gchar* _tmp39_ = NULL;
	gchar* _tmp40_;
	gchar* _tmp41_ = NULL;
	gchar* _tmp42_;
	gchar* name;
	GtkTreeIter iter = {0};
	GtkListStore* _tmp43_;
	GtkTreeIter _tmp44_ = {0};
	GtkListStore* _tmp45_;
	GtkTreeIter _tmp46_;
	const gchar* _tmp47_;
	GdkPixbuf* _tmp48_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (folder != NULL);
	_tmp0_ = self->priv->stock_folder_icon;
	_tmp1_ = _g_object_ref0 (_tmp0_);
	icon = _tmp1_;
	nautilus_icon = NULL;
	_tmp2_ = self->priv->defined_dirs;
	_tmp3_ = folder;
	_tmp4_ = gee_abstract_map_has_key ((GeeAbstractMap*) _tmp2_, _tmp3_);
	if (_tmp4_) {
		GeeHashMap* _tmp5_;
		const gchar* _tmp6_;
		gpointer _tmp7_ = NULL;
		GUserDirectory dir;
		GUserDirectory _tmp8_;
		const gchar* _tmp9_ = NULL;
		GThemedIcon* _tmp32_;
		_tmp5_ = self->priv->defined_dirs;
		_tmp6_ = folder;
		_tmp7_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp5_, _tmp6_);
		dir = (GUserDirectory) ((gintptr) _tmp7_);
		_tmp8_ = dir;
		_tmp9_ = _g_user_directory_to_string (_tmp8_);
		if (g_strcmp0 (_tmp9_, "G_USER_DIRECTORY_DOCUMENTS") == 0) {
			GThemedIcon* _tmp10_;
			_tmp10_ = (GThemedIcon*) g_themed_icon_new ("folder-documents");
			_g_object_unref0 (nautilus_icon);
			nautilus_icon = _tmp10_;
		} else {
			GUserDirectory _tmp11_;
			const gchar* _tmp12_ = NULL;
			_tmp11_ = dir;
			_tmp12_ = _g_user_directory_to_string (_tmp11_);
			if (g_strcmp0 (_tmp12_, "G_USER_DIRECTORY_DOWNLOAD") == 0) {
				GThemedIcon* _tmp13_;
				_tmp13_ = (GThemedIcon*) g_themed_icon_new ("folder-download");
				_g_object_unref0 (nautilus_icon);
				nautilus_icon = _tmp13_;
			} else {
				GUserDirectory _tmp14_;
				const gchar* _tmp15_ = NULL;
				_tmp14_ = dir;
				_tmp15_ = _g_user_directory_to_string (_tmp14_);
				if (g_strcmp0 (_tmp15_, "G_USER_DIRECTORY_MUSIC") == 0) {
					GThemedIcon* _tmp16_;
					_tmp16_ = (GThemedIcon*) g_themed_icon_new ("folder-music");
					_g_object_unref0 (nautilus_icon);
					nautilus_icon = _tmp16_;
				} else {
					GUserDirectory _tmp17_;
					const gchar* _tmp18_ = NULL;
					_tmp17_ = dir;
					_tmp18_ = _g_user_directory_to_string (_tmp17_);
					if (g_strcmp0 (_tmp18_, "G_USER_DIRECTORY_DESKTOP") == 0) {
						GThemedIcon* _tmp19_;
						_tmp19_ = (GThemedIcon*) g_themed_icon_new ("user-desktop");
						_g_object_unref0 (nautilus_icon);
						nautilus_icon = _tmp19_;
					} else {
						GUserDirectory _tmp20_;
						const gchar* _tmp21_ = NULL;
						_tmp20_ = dir;
						_tmp21_ = _g_user_directory_to_string (_tmp20_);
						if (g_strcmp0 (_tmp21_, "G_USER_DIRECTORY_PICTURES") == 0) {
							GThemedIcon* _tmp22_;
							_tmp22_ = (GThemedIcon*) g_themed_icon_new ("folder-pictures");
							_g_object_unref0 (nautilus_icon);
							nautilus_icon = _tmp22_;
						} else {
							GUserDirectory _tmp23_;
							const gchar* _tmp24_ = NULL;
							_tmp23_ = dir;
							_tmp24_ = _g_user_directory_to_string (_tmp23_);
							if (g_strcmp0 (_tmp24_, "G_USER_DIRECTORY_VIDEOS") == 0) {
								GThemedIcon* _tmp25_;
								_tmp25_ = (GThemedIcon*) g_themed_icon_new ("folder-videos");
								_g_object_unref0 (nautilus_icon);
								nautilus_icon = _tmp25_;
							} else {
								GUserDirectory _tmp26_;
								const gchar* _tmp27_ = NULL;
								_tmp26_ = dir;
								_tmp27_ = _g_user_directory_to_string (_tmp26_);
								if (g_strcmp0 (_tmp27_, "G_USER_DIRECTORY_TEMPLATES") == 0) {
									GThemedIcon* _tmp28_;
									_tmp28_ = (GThemedIcon*) g_themed_icon_new ("folder-templates");
									_g_object_unref0 (nautilus_icon);
									nautilus_icon = _tmp28_;
								} else {
									GUserDirectory _tmp29_;
									const gchar* _tmp30_ = NULL;
									_tmp29_ = dir;
									_tmp30_ = _g_user_directory_to_string (_tmp29_);
									if (g_strcmp0 (_tmp30_, "G_USER_DIRECTORY_PUBLIC_SHARE") == 0) {
										GThemedIcon* _tmp31_;
										_tmp31_ = (GThemedIcon*) g_themed_icon_new ("folder-publicshare");
										_g_object_unref0 (nautilus_icon);
										nautilus_icon = _tmp31_;
									}
								}
							}
						}
					}
				}
			}
		}
		_tmp32_ = nautilus_icon;
		if (_tmp32_ != NULL) {
			GThemedIcon* _tmp33_;
			GdkPixbuf* _tmp34_ = NULL;
			GdkPixbuf* pixbuf;
			GdkPixbuf* _tmp35_;
			_tmp33_ = nautilus_icon;
			_tmp34_ = alm_applications_tree_view_get_pixbuf_from_gio_icon ((GIcon*) _tmp33_, 24);
			pixbuf = _tmp34_;
			_tmp35_ = pixbuf;
			if (_tmp35_ != NULL) {
				GdkPixbuf* _tmp36_;
				GdkPixbuf* _tmp37_;
				_tmp36_ = pixbuf;
				_tmp37_ = _g_object_ref0 (_tmp36_);
				_g_object_unref0 (icon);
				icon = _tmp37_;
			}
			_g_object_unref0 (pixbuf);
		}
	}
	_tmp38_ = folder;
	_tmp39_ = string_strip (_tmp38_);
	_tmp40_ = _tmp39_;
	_tmp41_ = g_path_get_basename (_tmp40_);
	_tmp42_ = _tmp41_;
	_g_free0 (_tmp40_);
	name = _tmp42_;
	_tmp43_ = self->priv->exception_list_store;
	gtk_list_store_append (_tmp43_, &_tmp44_);
	iter = _tmp44_;
	_tmp45_ = self->priv->exception_list_store;
	_tmp46_ = iter;
	_tmp47_ = folder;
	_tmp48_ = icon;
	gtk_list_store_set (_tmp45_, &_tmp46_, 0, _tmp47_, 1, _tmp48_, 2, name, 3, ALM_ITEM_TYPE_FILE, -1, -1);
	_g_free0 (name);
	_g_object_unref0 (nautilus_icon);
	_g_object_unref0 (icon);
}


static gboolean alm_privacy_widget_remove_folder_from_view (AlmPrivacyWidget* self, const gchar* folder) {
	gboolean result = FALSE;
	GtkTreeView* _tmp0_;
	GtkTreeModel* _tmp1_ = NULL;
	GtkTreeModel* _tmp2_;
	GtkTreeModel* model;
	GtkTreeIter iter = {0};
	GtkTreeModel* _tmp3_;
	GtkTreeIter _tmp4_ = {0};
	g_return_val_if_fail (self != NULL, FALSE);
	g_return_val_if_fail (folder != NULL, FALSE);
	_tmp0_ = self->priv->exception_list;
	_tmp1_ = gtk_tree_view_get_model (_tmp0_);
	_tmp2_ = _g_object_ref0 (_tmp1_);
	model = _tmp2_;
	_tmp3_ = model;
	gtk_tree_model_get_iter_first (_tmp3_, &_tmp4_);
	iter = _tmp4_;
	while (TRUE) {
		GValue can_app_value = {0};
		GtkTreeModel* _tmp5_;
		GtkTreeIter _tmp6_;
		GValue _tmp7_ = {0};
		const gchar* _tmp8_ = NULL;
		gchar* _tmp9_;
		gchar* cand_folder;
		const gchar* _tmp10_;
		const gchar* _tmp11_;
		GtkTreeModel* _tmp14_;
		gboolean _tmp15_ = FALSE;
		gboolean more_entires;
		gboolean _tmp16_;
		_tmp5_ = model;
		_tmp6_ = iter;
		gtk_tree_model_get_value (_tmp5_, &_tmp6_, 0, &_tmp7_);
		G_IS_VALUE (&can_app_value) ? (g_value_unset (&can_app_value), NULL) : NULL;
		can_app_value = _tmp7_;
		_tmp8_ = g_value_get_string (&can_app_value);
		_tmp9_ = g_strdup (_tmp8_);
		cand_folder = _tmp9_;
		_tmp10_ = folder;
		_tmp11_ = cand_folder;
		if (g_strcmp0 (_tmp10_, _tmp11_) == 0) {
			GtkListStore* _tmp12_;
			GtkTreeIter _tmp13_;
			_tmp12_ = self->priv->exception_list_store;
			_tmp13_ = iter;
			gtk_list_store_remove (_tmp12_, &_tmp13_);
			result = TRUE;
			_g_free0 (cand_folder);
			G_IS_VALUE (&can_app_value) ? (g_value_unset (&can_app_value), NULL) : NULL;
			_g_object_unref0 (model);
			return result;
		}
		_tmp14_ = model;
		_tmp15_ = gtk_tree_model_iter_next (_tmp14_, &iter);
		more_entires = _tmp15_;
		_tmp16_ = more_entires;
		if (!_tmp16_) {
			result = FALSE;
			_g_free0 (cand_folder);
			G_IS_VALUE (&can_app_value) ? (g_value_unset (&can_app_value), NULL) : NULL;
			_g_object_unref0 (model);
			return result;
		}
		_g_free0 (cand_folder);
		G_IS_VALUE (&can_app_value) ? (g_value_unset (&can_app_value), NULL) : NULL;
	}
	_g_object_unref0 (model);
}


static void alm_privacy_widget_add_app_to_view (AlmPrivacyWidget* self, const gchar* app) {
	const gchar* _tmp0_;
	GDesktopAppInfo* _tmp1_;
	GDesktopAppInfo* app_info;
	GDesktopAppInfo* _tmp2_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (app != NULL);
	_tmp0_ = app;
	_tmp1_ = g_desktop_app_info_new (_tmp0_);
	app_info = _tmp1_;
	_tmp2_ = app_info;
	if (_tmp2_ != NULL) {
		GDesktopAppInfo* _tmp3_;
		GIcon* _tmp4_ = NULL;
		GdkPixbuf* _tmp5_ = NULL;
		GdkPixbuf* pix;
		GDesktopAppInfo* _tmp6_;
		gchar* _tmp7_ = NULL;
		gchar* markup;
		GtkTreeIter iter = {0};
		GtkListStore* _tmp8_;
		GtkTreeIter _tmp9_ = {0};
		GtkListStore* _tmp10_;
		GtkTreeIter _tmp11_;
		const gchar* _tmp12_;
		GdkPixbuf* _tmp13_;
		GDesktopAppInfo* _tmp14_;
		const gchar* _tmp15_ = NULL;
		GHashTable* _tmp16_;
		const gchar* _tmp17_;
		gconstpointer _tmp18_ = NULL;
		_tmp3_ = app_info;
		_tmp4_ = g_app_info_get_icon ((GAppInfo*) _tmp3_);
		_tmp5_ = alm_applications_tree_view_get_pixbuf_from_gio_icon (_tmp4_, 24);
		pix = _tmp5_;
		_tmp6_ = app_info;
		_tmp7_ = alm_applications_tree_view_markup_for_app (_tmp6_);
		markup = _tmp7_;
		_tmp8_ = self->priv->exception_list_store;
		gtk_list_store_append (_tmp8_, &_tmp9_);
		iter = _tmp9_;
		_tmp10_ = self->priv->exception_list_store;
		_tmp11_ = iter;
		_tmp12_ = app;
		_tmp13_ = pix;
		_tmp14_ = app_info;
		_tmp15_ = g_app_info_get_name ((GAppInfo*) _tmp14_);
		gtk_list_store_set (_tmp10_, &_tmp11_, 0, _tmp12_, 1, _tmp13_, 2, _tmp15_, 3, ALM_ITEM_TYPE_APPLICATION, -1, -1);
		_tmp16_ = self->priv->blocked_list;
		_tmp17_ = app;
		_tmp18_ = g_hash_table_lookup (_tmp16_, _tmp17_);
		if (((AlmAppChooseInfo*) _tmp18_) == NULL) {
			GHashTable* _tmp19_;
			const gchar* _tmp20_;
			gchar* _tmp21_;
			GDesktopAppInfo* _tmp22_;
			const gchar* _tmp23_ = NULL;
			GDesktopAppInfo* _tmp24_;
			const gchar* _tmp25_ = NULL;
			GdkPixbuf* _tmp26_;
			AlmAppChooseInfo* _tmp27_;
			_tmp19_ = self->priv->blocked_list;
			_tmp20_ = app;
			_tmp21_ = g_strdup (_tmp20_);
			_tmp22_ = app_info;
			_tmp23_ = g_app_info_get_id ((GAppInfo*) _tmp22_);
			_tmp24_ = app_info;
			_tmp25_ = g_app_info_get_name ((GAppInfo*) _tmp24_);
			_tmp26_ = pix;
			_tmp27_ = alm_app_choose_info_new (_tmp23_, _tmp25_, _tmp26_, "", (gint64) 0, (guint) 0);
			g_hash_table_insert (_tmp19_, _tmp21_, _tmp27_);
		}
		_g_free0 (markup);
		_g_object_unref0 (pix);
	}
	_g_object_unref0 (app_info);
}


static void alm_privacy_widget_remove_app_from_view (AlmPrivacyWidget* self, const gchar* app) {
	GtkTreeView* _tmp0_;
	GtkTreeModel* _tmp1_ = NULL;
	GtkTreeModel* _tmp2_;
	GtkTreeModel* model;
	GtkTreeIter iter = {0};
	GtkTreeModel* _tmp3_;
	GtkTreeIter _tmp4_ = {0};
	g_return_if_fail (self != NULL);
	g_return_if_fail (app != NULL);
	_tmp0_ = self->priv->exception_list;
	_tmp1_ = gtk_tree_view_get_model (_tmp0_);
	_tmp2_ = _g_object_ref0 (_tmp1_);
	model = _tmp2_;
	_tmp3_ = model;
	gtk_tree_model_get_iter_first (_tmp3_, &_tmp4_);
	iter = _tmp4_;
	while (TRUE) {
		GValue can_app_value = {0};
		GtkTreeModel* _tmp5_;
		GtkTreeIter _tmp6_;
		GValue _tmp7_ = {0};
		const gchar* _tmp8_ = NULL;
		gchar* _tmp9_;
		gchar* can_app;
		const gchar* _tmp10_;
		const gchar* _tmp11_;
		GtkTreeModel* _tmp14_;
		gboolean _tmp15_ = FALSE;
		gboolean more_entires;
		gboolean _tmp16_;
		_tmp5_ = model;
		_tmp6_ = iter;
		gtk_tree_model_get_value (_tmp5_, &_tmp6_, 2, &_tmp7_);
		G_IS_VALUE (&can_app_value) ? (g_value_unset (&can_app_value), NULL) : NULL;
		can_app_value = _tmp7_;
		_tmp8_ = g_value_get_string (&can_app_value);
		_tmp9_ = g_strdup (_tmp8_);
		can_app = _tmp9_;
		_tmp10_ = app;
		_tmp11_ = can_app;
		if (g_strcmp0 (_tmp10_, _tmp11_) == 0) {
			GtkListStore* _tmp12_;
			GtkTreeIter _tmp13_;
			_tmp12_ = self->priv->exception_list_store;
			_tmp13_ = iter;
			gtk_list_store_remove (_tmp12_, &_tmp13_);
			_g_free0 (can_app);
			G_IS_VALUE (&can_app_value) ? (g_value_unset (&can_app_value), NULL) : NULL;
			break;
		}
		_tmp14_ = model;
		_tmp15_ = gtk_tree_model_iter_next (_tmp14_, &iter);
		more_entires = _tmp15_;
		_tmp16_ = more_entires;
		if (!_tmp16_) {
			_g_free0 (can_app);
			G_IS_VALUE (&can_app_value) ? (g_value_unset (&can_app_value), NULL) : NULL;
			break;
		}
		_g_free0 (can_app);
		G_IS_VALUE (&can_app_value) ? (g_value_unset (&can_app_value), NULL) : NULL;
	}
	_g_object_unref0 (model);
}


static void alm_privacy_widget_class_init (AlmPrivacyWidgetClass * klass) {
	alm_privacy_widget_parent_class = g_type_class_peek_parent (klass);
	g_type_class_add_private (klass, sizeof (AlmPrivacyWidgetPrivate));
	G_OBJECT_CLASS (klass)->finalize = alm_privacy_widget_finalize;
}


static void alm_privacy_widget_instance_init (AlmPrivacyWidget * self) {
	self->priv = ALM_PRIVACY_WIDGET_GET_PRIVATE (self);
	self->priv->file_type_fire_signal = TRUE;
}


static void alm_privacy_widget_finalize (GObject* obj) {
	AlmPrivacyWidget * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, ALM_TYPE_PRIVACY_WIDGET, AlmPrivacyWidget);
	_alm_blacklist_unref0 (self->priv->blacklist);
	_alm_file_type_blacklist_unref0 (self->priv->files_type_blacklist);
	_alm_path_blacklist_unref0 (self->priv->path_blacklist);
	_g_object_unref0 (self->priv->mime_dict);
	_g_object_unref0 (self->priv->checkboxes);
	_g_object_unref0 (self->priv->button_list);
	_g_object_unref0 (self->priv->defined_dirs);
	_alm_application_blacklist_unref0 (self->priv->app_blacklist);
	_g_object_unref0 (self->priv->app_dialog);
	_g_object_unref0 (self->priv->app_treeview);
	_g_object_unref0 (self->priv->container_box);
	_g_hash_table_unref0 (self->priv->blocked_list);
	_g_hash_table_unref0 (self->priv->unblocked_list);
	_g_object_unref0 (self->priv->exception_list);
	_g_object_unref0 (self->priv->exception_list_store);
	_g_object_unref0 (self->priv->record_button);
	_g_object_unref0 (self->priv->del_button);
	_g_object_unref0 (self->priv->delete_dialog);
	_g_object_unref0 (self->priv->stock_folder_icon);
	_g_object_unref0 (self->priv->exception_menu);
	_g_object_unref0 (self->priv->privacy_settings);
	G_OBJECT_CLASS (alm_privacy_widget_parent_class)->finalize (obj);
}


GType alm_privacy_widget_get_type (void) {
	static volatile gsize alm_privacy_widget_type_id__volatile = 0;
	if (g_once_init_enter (&alm_privacy_widget_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (AlmPrivacyWidgetClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) alm_privacy_widget_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (AlmPrivacyWidget), 0, (GInstanceInitFunc) alm_privacy_widget_instance_init, NULL };
		GType alm_privacy_widget_type_id;
		alm_privacy_widget_type_id = g_type_register_static (GTK_TYPE_BOX, "AlmPrivacyWidget", &g_define_type_info, 0);
		g_once_init_leave (&alm_privacy_widget_type_id__volatile, alm_privacy_widget_type_id);
	}
	return alm_privacy_widget_type_id__volatile;
}


AlmExceptionCellRenderer* alm_exception_cell_renderer_construct (GType object_type) {
	AlmExceptionCellRenderer * self = NULL;
	self = (AlmExceptionCellRenderer*) g_object_new (object_type, NULL);
	return self;
}


AlmExceptionCellRenderer* alm_exception_cell_renderer_new (void) {
	return alm_exception_cell_renderer_construct (ALM_TYPE_EXCEPTION_CELL_RENDERER);
}


static void _vala_PangoFontDescription_free (PangoFontDescription* self) {
	g_boxed_free (pango_font_description_get_type (), self);
}


static PangoAttrList* _vala_PangoAttrList_copy (PangoAttrList* self) {
	return g_boxed_copy (pango_attr_list_get_type (), self);
}


static gpointer __vala_PangoAttrList_copy0 (gpointer self) {
	return self ? _vala_PangoAttrList_copy (self) : NULL;
}


static void _vala_PangoAttrList_free (PangoAttrList* self) {
	g_boxed_free (pango_attr_list_get_type (), self);
}


static PangoLayout* alm_exception_cell_renderer_get_text_layout (AlmExceptionCellRenderer* self, GtkWidget* widget, GdkRectangle* cell_area, GtkCellRendererState flags, const gchar* text, gboolean bold, gint size) {
	PangoLayout* result = NULL;
	PangoLayout* layout = NULL;
	gint xpad = 0;
	PangoAttrList* _tmp0_;
	PangoAttrList* attr_list;
	GtkWidget* _tmp1_;
	const gchar* _tmp2_;
	PangoLayout* _tmp3_ = NULL;
	gint _tmp4_;
	PangoAttrSize* _tmp5_;
	PangoAttrSize* attr;
	PangoAttrSize* _tmp6_;
	PangoAttrSize* _tmp7_;
	PangoAttrSize* _tmp8_;
	PangoAttrSize* _tmp9_;
	guint _tmp10_;
	const gchar* _tmp11_;
	gint _tmp12_;
	gint _tmp13_;
	PangoAttrList* _tmp14_;
	PangoAttrSize* _tmp15_;
	gboolean _tmp16_;
	PangoLayout* _tmp22_;
	PangoAttrList* _tmp23_;
	PangoAttrList* _tmp24_;
	gint _tmp25_ = 0;
	PangoLayout* _tmp26_;
	PangoRectangle rect = {0};
	gint width = 0;
	gint text_width = 0;
	PangoLayout* _tmp27_;
	PangoRectangle _tmp28_ = {0};
	PangoRectangle _tmp29_;
	gint _tmp30_;
	GdkRectangle* _tmp31_;
	gint _tmp35_;
	gint _tmp36_;
	gint _tmp37_ = 0;
	PangoLayout* _tmp38_;
	gint _tmp39_;
	PangoAlignment align = 0;
	GtkWidget* _tmp40_;
	GtkTextDirection _tmp41_ = 0;
	PangoLayout* _tmp42_;
	PangoAlignment _tmp43_;
	g_return_val_if_fail (self != NULL, NULL);
	g_return_val_if_fail (widget != NULL, NULL);
	g_return_val_if_fail (text != NULL, NULL);
	_tmp0_ = pango_attr_list_new ();
	attr_list = _tmp0_;
	_tmp1_ = widget;
	_tmp2_ = text;
	_tmp3_ = gtk_widget_create_pango_layout (_tmp1_, _tmp2_);
	_g_object_unref0 (layout);
	layout = _tmp3_;
	_tmp4_ = size;
	_tmp5_ = (PangoAttrSize*) pango_attr_size_new (_tmp4_ * PANGO_SCALE);
	attr = _tmp5_;
	_tmp6_ = attr;
	_tmp6_->absolute = (guint) 1;
	_tmp7_ = attr;
	((PangoAttribute*) _tmp7_)->start_index = (guint) 0;
	_tmp8_ = attr;
	_tmp9_ = attr;
	_tmp10_ = ((PangoAttribute*) _tmp9_)->start_index;
	_tmp11_ = text;
	_tmp12_ = strlen (_tmp11_);
	_tmp13_ = _tmp12_;
	((PangoAttribute*) _tmp8_)->end_index = _tmp10_ + _tmp13_;
	_tmp14_ = attr_list;
	_tmp15_ = attr;
	attr = NULL;
	pango_attr_list_insert (_tmp14_, (PangoAttribute*) _tmp15_);
	_tmp16_ = bold;
	if (_tmp16_) {
		PangoFontDescription* _tmp17_;
		PangoFontDescription* desc;
		PangoFontDescription* _tmp18_;
		PangoAttrFontDesc* _tmp19_;
		PangoAttrFontDesc* attr_f;
		PangoAttrList* _tmp20_;
		PangoAttrFontDesc* _tmp21_;
		_tmp17_ = pango_font_description_new ();
		desc = _tmp17_;
		_tmp18_ = desc;
		_tmp19_ = (PangoAttrFontDesc*) pango_attr_font_desc_new (_tmp18_);
		attr_f = _tmp19_;
		_tmp20_ = attr_list;
		_tmp21_ = attr_f;
		attr_f = NULL;
		pango_attr_list_insert (_tmp20_, (PangoAttribute*) _tmp21_);
		_pango_attribute_destroy0 (attr_f);
		__vala_PangoFontDescription_free0 (desc);
	}
	_tmp22_ = layout;
	_tmp23_ = attr_list;
	_tmp24_ = __vala_PangoAttrList_copy0 (_tmp23_);
	pango_layout_set_attributes (_tmp22_, _tmp24_);
	gtk_cell_renderer_get_padding ((GtkCellRenderer*) self, &_tmp25_, NULL);
	xpad = _tmp25_;
	_tmp26_ = layout;
	pango_layout_set_ellipsize (_tmp26_, PANGO_ELLIPSIZE_END);
	_tmp27_ = layout;
	pango_layout_get_extents (_tmp27_, NULL, &_tmp28_);
	rect = _tmp28_;
	_tmp29_ = rect;
	_tmp30_ = _tmp29_.width;
	text_width = _tmp30_;
	_tmp31_ = cell_area;
	if (_tmp31_ != NULL) {
		GdkRectangle* _tmp32_;
		gint _tmp33_;
		gint _tmp34_;
		_tmp32_ = cell_area;
		_tmp33_ = (*_tmp32_).width;
		_tmp34_ = xpad;
		width = (_tmp33_ - _tmp34_) * PANGO_SCALE;
	} else {
		width = ALM_EXCEPTION_CELL_RENDERER_default_width * PANGO_SCALE;
	}
	_tmp35_ = width;
	_tmp36_ = text_width;
	_tmp37_ = MIN (_tmp35_, _tmp36_);
	width = _tmp37_;
	_tmp38_ = layout;
	_tmp39_ = width;
	pango_layout_set_width (_tmp38_, _tmp39_);
	_tmp40_ = widget;
	_tmp41_ = gtk_widget_get_direction (_tmp40_);
	if (_tmp41_ == GTK_TEXT_DIR_RTL) {
		align = PANGO_ALIGN_RIGHT;
	} else {
		align = PANGO_ALIGN_LEFT;
	}
	_tmp42_ = layout;
	_tmp43_ = align;
	pango_layout_set_alignment (_tmp42_, _tmp43_);
	result = layout;
	_pango_attribute_destroy0 (attr);
	__vala_PangoAttrList_free0 (attr_list);
	return result;
}


static void alm_exception_cell_renderer_real_get_size (GtkCellRenderer* base, GtkWidget* widget, GdkRectangle* cell_area, gint* x_offset, gint* y_offset, gint* width, gint* height) {
	AlmExceptionCellRenderer * self;
	gint _vala_x_offset = 0;
	gint _vala_y_offset = 0;
	gint _vala_width = 0;
	gint _vala_height = 0;
	self = (AlmExceptionCellRenderer*) base;
	g_return_if_fail (widget != NULL);
	_vala_height = 0;
	_vala_width = _vala_height;
	_vala_y_offset = _vala_width;
	_vala_x_offset = _vala_y_offset;
	if (x_offset) {
		*x_offset = _vala_x_offset;
	}
	if (y_offset) {
		*y_offset = _vala_y_offset;
	}
	if (width) {
		*width = _vala_width;
	}
	if (height) {
		*height = _vala_height;
	}
}


static void alm_exception_cell_renderer_do_get_size (AlmExceptionCellRenderer* self, GtkWidget* widget, GdkRectangle* cell_area, PangoLayout* layout, gint* x_offset, gint* y_offset) {
	gint _vala_x_offset = 0;
	gint _vala_y_offset = 0;
	PangoRectangle rect = {0};
	gint xpad = 0;
	gint ypad = 0;
	gint _tmp0_ = 0;
	gint _tmp1_ = 0;
	PangoLayout* _tmp2_;
	PangoRectangle _tmp3_ = {0};
	GdkRectangle* _tmp4_;
	gint _tmp21_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (widget != NULL);
	gtk_cell_renderer_get_padding ((GtkCellRenderer*) self, &_tmp0_, &_tmp1_);
	xpad = _tmp0_;
	ypad = _tmp1_;
	_tmp2_ = layout;
	pango_layout_get_pixel_extents (_tmp2_, NULL, &_tmp3_);
	rect = _tmp3_;
	_tmp4_ = cell_area;
	if (_tmp4_ != NULL) {
		PangoRectangle _tmp5_;
		gint _tmp6_;
		GdkRectangle* _tmp7_;
		gint _tmp8_;
		gint _tmp9_;
		gint _tmp10_ = 0;
		GtkWidget* _tmp11_;
		GtkTextDirection _tmp12_ = 0;
		gint _tmp19_;
		gint _tmp20_ = 0;
		_tmp5_ = rect;
		_tmp6_ = _tmp5_.width;
		_tmp7_ = cell_area;
		_tmp8_ = (*_tmp7_).width;
		_tmp9_ = xpad;
		_tmp10_ = MIN (_tmp6_, (_tmp8_ - (2 * _tmp9_)) + ALM_EXCEPTION_CELL_RENDERER_xspacing);
		rect.width = _tmp10_;
		_tmp11_ = widget;
		_tmp12_ = gtk_widget_get_direction (_tmp11_);
		if (_tmp12_ == GTK_TEXT_DIR_RTL) {
			GdkRectangle* _tmp13_;
			gint _tmp14_;
			PangoRectangle _tmp15_;
			gint _tmp16_;
			gint _tmp17_;
			_tmp13_ = cell_area;
			_tmp14_ = (*_tmp13_).width;
			_tmp15_ = rect;
			_tmp16_ = _tmp15_.width;
			_tmp17_ = xpad;
			_vala_x_offset = _tmp14_ - (_tmp16_ + _tmp17_);
		} else {
			gint _tmp18_;
			_tmp18_ = xpad;
			_vala_x_offset = _tmp18_;
		}
		_tmp19_ = _vala_x_offset;
		_tmp20_ = MAX (_tmp19_, 0);
		_vala_x_offset = _tmp20_;
	} else {
		_vala_x_offset = 0;
	}
	_tmp21_ = ypad;
	_vala_y_offset = _tmp21_;
	if (x_offset) {
		*x_offset = _vala_x_offset;
	}
	if (y_offset) {
		*y_offset = _vala_y_offset;
	}
}


static void alm_exception_cell_renderer_real_render (GtkCellRenderer* base, cairo_t* cr, GtkWidget* widget, GdkRectangle* background_area, GdkRectangle* cell_area, GtkCellRendererState flags) {
	AlmExceptionCellRenderer * self;
	GtkStyleContext* context = NULL;
	PangoLayout* text_layout = NULL;
	gint text_x_offset;
	gint text_y_offset;
	gint xpad = 0;
	PangoRectangle text_rect = {0};
	GtkWidget* _tmp0_;
	GtkWidget* _tmp1_;
	GtkWidget* _tmp2_;
	GtkStyleContext* _tmp3_ = NULL;
	GtkStyleContext* _tmp4_;
	PangoFontDescription* _tmp5_ = NULL;
	gint _tmp6_ = 0;
	gint font_size;
	gint _tmp7_ = 0;
	GtkWidget* _tmp8_;
	GdkRectangle _tmp9_;
	GtkCellRendererState _tmp10_;
	const gchar* _tmp11_;
	const gchar* _tmp12_;
	PangoLayout* _tmp13_ = NULL;
	GtkWidget* _tmp14_;
	GdkRectangle _tmp15_;
	gint _tmp16_ = 0;
	gint _tmp17_ = 0;
	PangoRectangle _tmp18_ = {0};
	gint _tmp19_;
	PangoRectangle _tmp20_;
	gint _tmp21_;
	cairo_t* _tmp22_;
	cairo_t* _tmp23_;
	GdkRectangle _tmp24_;
	cairo_t* _tmp25_;
	cairo_t* _tmp26_;
	GdkPixbuf* _tmp27_;
	GdkPixbuf* _tmp28_;
	GdkRectangle _tmp29_;
	gint _tmp30_;
	GdkRectangle _tmp31_;
	gint _tmp32_;
	cairo_t* _tmp33_;
	cairo_t* _tmp34_;
	GdkRectangle _tmp35_;
	gint _tmp36_;
	gint _tmp37_;
	GdkPixbuf* _tmp38_;
	GdkPixbuf* _tmp39_;
	gint _tmp40_;
	gint _tmp41_;
	GdkRectangle _tmp42_;
	gint _tmp43_;
	gint _tmp44_;
	cairo_t* _tmp45_;
	self = (AlmExceptionCellRenderer*) base;
	g_return_if_fail (cr != NULL);
	g_return_if_fail (widget != NULL);
	g_return_if_fail (background_area != NULL);
	g_return_if_fail (cell_area != NULL);
	text_x_offset = 0;
	text_y_offset = 0;
	_tmp0_ = widget;
	_tmp1_ = _g_object_ref0 (_tmp0_);
	_g_object_unref0 (self->priv->current_widget);
	self->priv->current_widget = _tmp1_;
	_tmp2_ = widget;
	_tmp3_ = gtk_widget_get_style_context (_tmp2_);
	_tmp4_ = _g_object_ref0 (_tmp3_);
	_g_object_unref0 (context);
	context = _tmp4_;
	_tmp5_ = gtk_style_context_get_font (context, GTK_STATE_FLAG_NORMAL);
	_tmp6_ = pango_font_description_get_size (_tmp5_);
	font_size = _tmp6_ / PANGO_SCALE;
	gtk_cell_renderer_get_padding ((GtkCellRenderer*) self, &_tmp7_, NULL);
	xpad = _tmp7_;
	_tmp8_ = widget;
	_tmp9_ = *cell_area;
	_tmp10_ = flags;
	_tmp11_ = alm_exception_cell_renderer_get_text (self);
	_tmp12_ = _tmp11_;
	_tmp13_ = alm_exception_cell_renderer_get_text_layout (self, _tmp8_, &_tmp9_, _tmp10_, _tmp12_, TRUE, font_size);
	_g_object_unref0 (text_layout);
	text_layout = _tmp13_;
	_tmp14_ = widget;
	_tmp15_ = *cell_area;
	alm_exception_cell_renderer_do_get_size (self, _tmp14_, &_tmp15_, text_layout, &_tmp16_, &_tmp17_);
	text_x_offset = _tmp16_;
	text_y_offset = _tmp17_;
	pango_layout_get_pixel_extents (text_layout, NULL, &_tmp18_);
	text_rect = _tmp18_;
	_tmp19_ = text_x_offset;
	_tmp20_ = text_rect;
	_tmp21_ = _tmp20_.x;
	text_x_offset = _tmp19_ - _tmp21_;
	_tmp22_ = cr;
	cairo_save (_tmp22_);
	_tmp23_ = cr;
	_tmp24_ = *cell_area;
	gdk_cairo_rectangle (_tmp23_, &_tmp24_);
	_tmp25_ = cr;
	cairo_clip (_tmp25_);
	_tmp26_ = cr;
	_tmp27_ = alm_exception_cell_renderer_get_pixbuf (self);
	_tmp28_ = _tmp27_;
	_tmp29_ = *cell_area;
	_tmp30_ = _tmp29_.x;
	_tmp31_ = *cell_area;
	_tmp32_ = _tmp31_.y;
	gdk_cairo_set_source_pixbuf (_tmp26_, _tmp28_, (gdouble) _tmp30_, (gdouble) _tmp32_);
	_tmp33_ = cr;
	cairo_paint (_tmp33_);
	_tmp34_ = cr;
	_tmp35_ = *cell_area;
	_tmp36_ = _tmp35_.x;
	_tmp37_ = text_x_offset;
	_tmp38_ = alm_exception_cell_renderer_get_pixbuf (self);
	_tmp39_ = _tmp38_;
	_tmp40_ = gdk_pixbuf_get_width (_tmp39_);
	_tmp41_ = _tmp40_;
	_tmp42_ = *cell_area;
	_tmp43_ = _tmp42_.y;
	_tmp44_ = text_y_offset;
	gtk_render_layout (context, _tmp34_, (gdouble) (((_tmp36_ + _tmp37_) + _tmp41_) + ALM_EXCEPTION_CELL_RENDERER_xspacing), (gdouble) ((_tmp43_ + _tmp44_) + 2), text_layout);
	_tmp45_ = cr;
	cairo_restore (_tmp45_);
	_g_object_unref0 (text_layout);
	_g_object_unref0 (context);
}


static void alm_exception_cell_renderer_real_get_preferred_width (GtkCellRenderer* base, GtkWidget* widget, gint* min_width, gint* nat_width) {
	AlmExceptionCellRenderer * self;
	gint _vala_min_width = 0;
	gint _vala_nat_width = 0;
	gint xpad = 0;
	gint _tmp0_ = 0;
	self = (AlmExceptionCellRenderer*) base;
	g_return_if_fail (widget != NULL);
	gtk_cell_renderer_get_padding ((GtkCellRenderer*) self, &_tmp0_, NULL);
	xpad = _tmp0_;
	_vala_min_width = xpad + ALM_EXCEPTION_CELL_RENDERER_default_width;
	_vala_nat_width = _vala_min_width;
	if (min_width) {
		*min_width = _vala_min_width;
	}
	if (nat_width) {
		*nat_width = _vala_nat_width;
	}
}


static void alm_exception_cell_renderer_real_get_preferred_height_for_width (GtkCellRenderer* base, GtkWidget* widget, gint width, gint* minimum_height, gint* natural_height) {
	AlmExceptionCellRenderer * self;
	gint _vala_minimum_height = 0;
	gint _vala_natural_height = 0;
	gint ypad = 0;
	gint _tmp0_ = 0;
	self = (AlmExceptionCellRenderer*) base;
	g_return_if_fail (widget != NULL);
	gtk_cell_renderer_get_padding ((GtkCellRenderer*) self, NULL, &_tmp0_);
	ypad = _tmp0_;
	_vala_minimum_height = ALM_EXCEPTION_CELL_RENDERER_renderer_height + ypad;
	_vala_natural_height = ALM_EXCEPTION_CELL_RENDERER_renderer_height + ypad;
	if (minimum_height) {
		*minimum_height = _vala_minimum_height;
	}
	if (natural_height) {
		*natural_height = _vala_natural_height;
	}
}


static void alm_exception_cell_renderer_real_get_preferred_height (GtkCellRenderer* base, GtkWidget* widget, gint* minimum_size, gint* natural_size) {
	AlmExceptionCellRenderer * self;
	gint _vala_minimum_size = 0;
	gint _vala_natural_size = 0;
	gint min_width = 0;
	GtkWidget* _tmp0_;
	gint _tmp1_ = 0;
	GtkWidget* _tmp2_;
	gint _tmp3_ = 0;
	gint _tmp4_ = 0;
	self = (AlmExceptionCellRenderer*) base;
	g_return_if_fail (widget != NULL);
	_tmp0_ = widget;
	gtk_cell_renderer_get_preferred_width ((GtkCellRenderer*) self, _tmp0_, &_tmp1_, NULL);
	min_width = _tmp1_;
	_tmp2_ = widget;
	gtk_cell_renderer_get_preferred_height_for_width ((GtkCellRenderer*) self, _tmp2_, min_width, &_tmp3_, &_tmp4_);
	_vala_minimum_size = _tmp3_;
	_vala_natural_size = _tmp4_;
	if (minimum_size) {
		*minimum_size = _vala_minimum_size;
	}
	if (natural_size) {
		*natural_size = _vala_natural_size;
	}
}


GdkPixbuf* alm_exception_cell_renderer_get_pixbuf (AlmExceptionCellRenderer* self) {
	GdkPixbuf* result;
	GdkPixbuf* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->pixbuf_;
	result = _tmp0_;
	return result;
}


void alm_exception_cell_renderer_set_pixbuf (AlmExceptionCellRenderer* self, GdkPixbuf* value) {
	GdkPixbuf* _tmp0_;
	GdkPixbuf* _tmp1_;
	g_return_if_fail (self != NULL);
	_tmp0_ = value;
	_tmp1_ = _g_object_ref0 (_tmp0_);
	_g_object_unref0 (self->priv->pixbuf_);
	self->priv->pixbuf_ = _tmp1_;
	g_object_notify ((GObject *) self, "pixbuf");
}


const gchar* alm_exception_cell_renderer_get_text (AlmExceptionCellRenderer* self) {
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->text_;
	result = _tmp0_;
	return result;
}


void alm_exception_cell_renderer_set_text (AlmExceptionCellRenderer* self, const gchar* value) {
	const gchar* _tmp0_;
	gchar* _tmp1_;
	g_return_if_fail (self != NULL);
	_tmp0_ = value;
	_tmp1_ = g_strdup (_tmp0_);
	_g_free0 (self->priv->text_);
	self->priv->text_ = _tmp1_;
	g_object_notify ((GObject *) self, "text");
}


static void alm_exception_cell_renderer_class_init (AlmExceptionCellRendererClass * klass) {
	alm_exception_cell_renderer_parent_class = g_type_class_peek_parent (klass);
	g_type_class_add_private (klass, sizeof (AlmExceptionCellRendererPrivate));
	GTK_CELL_RENDERER_CLASS (klass)->get_size = alm_exception_cell_renderer_real_get_size;
	GTK_CELL_RENDERER_CLASS (klass)->render = alm_exception_cell_renderer_real_render;
	GTK_CELL_RENDERER_CLASS (klass)->get_preferred_width = alm_exception_cell_renderer_real_get_preferred_width;
	GTK_CELL_RENDERER_CLASS (klass)->get_preferred_height_for_width = alm_exception_cell_renderer_real_get_preferred_height_for_width;
	GTK_CELL_RENDERER_CLASS (klass)->get_preferred_height = alm_exception_cell_renderer_real_get_preferred_height;
	G_OBJECT_CLASS (klass)->get_property = _vala_alm_exception_cell_renderer_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_alm_exception_cell_renderer_set_property;
	G_OBJECT_CLASS (klass)->finalize = alm_exception_cell_renderer_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), ALM_EXCEPTION_CELL_RENDERER_PIXBUF, g_param_spec_object ("pixbuf", "pixbuf", "pixbuf", GDK_TYPE_PIXBUF, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), ALM_EXCEPTION_CELL_RENDERER_TEXT, g_param_spec_string ("text", "text", "text", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
}


static void alm_exception_cell_renderer_instance_init (AlmExceptionCellRenderer * self) {
	self->priv = ALM_EXCEPTION_CELL_RENDERER_GET_PRIVATE (self);
}


static void alm_exception_cell_renderer_finalize (GObject* obj) {
	AlmExceptionCellRenderer * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, ALM_TYPE_EXCEPTION_CELL_RENDERER, AlmExceptionCellRenderer);
	_g_object_unref0 (self->priv->current_widget);
	_g_object_unref0 (self->priv->pixbuf_);
	_g_free0 (self->priv->text_);
	G_OBJECT_CLASS (alm_exception_cell_renderer_parent_class)->finalize (obj);
}


GType alm_exception_cell_renderer_get_type (void) {
	static volatile gsize alm_exception_cell_renderer_type_id__volatile = 0;
	if (g_once_init_enter (&alm_exception_cell_renderer_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (AlmExceptionCellRendererClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) alm_exception_cell_renderer_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (AlmExceptionCellRenderer), 0, (GInstanceInitFunc) alm_exception_cell_renderer_instance_init, NULL };
		GType alm_exception_cell_renderer_type_id;
		alm_exception_cell_renderer_type_id = g_type_register_static (GTK_TYPE_CELL_RENDERER, "AlmExceptionCellRenderer", &g_define_type_info, 0);
		g_once_init_leave (&alm_exception_cell_renderer_type_id__volatile, alm_exception_cell_renderer_type_id);
	}
	return alm_exception_cell_renderer_type_id__volatile;
}


static void _vala_alm_exception_cell_renderer_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) {
	AlmExceptionCellRenderer * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, ALM_TYPE_EXCEPTION_CELL_RENDERER, AlmExceptionCellRenderer);
	switch (property_id) {
		case ALM_EXCEPTION_CELL_RENDERER_PIXBUF:
		g_value_set_object (value, alm_exception_cell_renderer_get_pixbuf (self));
		break;
		case ALM_EXCEPTION_CELL_RENDERER_TEXT:
		g_value_set_string (value, alm_exception_cell_renderer_get_text (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}


static void _vala_alm_exception_cell_renderer_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec) {
	AlmExceptionCellRenderer * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, ALM_TYPE_EXCEPTION_CELL_RENDERER, AlmExceptionCellRenderer);
	switch (property_id) {
		case ALM_EXCEPTION_CELL_RENDERER_PIXBUF:
		alm_exception_cell_renderer_set_pixbuf (self, g_value_get_object (value));
		break;
		case ALM_EXCEPTION_CELL_RENDERER_TEXT:
		alm_exception_cell_renderer_set_text (self, g_value_get_string (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}


AlmDeleteHistoryDialog* alm_delete_history_dialog_construct (GType object_type, GtkButton* del_button) {
	AlmDeleteHistoryDialog * self = NULL;
	const gchar* _tmp0_ = NULL;
	ZeitgeistLog* _tmp1_;
	GtkButton* _tmp2_;
	AlmCalendarWidget* _tmp3_;
	g_return_val_if_fail (del_button != NULL, NULL);
	self = (AlmDeleteHistoryDialog*) g_object_new (object_type, NULL);
	_tmp0_ = _ ("Clear Usage Data");
	gtk_window_set_title ((GtkWindow*) self, _tmp0_);
	gtk_window_set_destroy_with_parent ((GtkWindow*) self, TRUE);
	gtk_window_set_skip_taskbar_hint ((GtkWindow*) self, TRUE);
	gtk_container_set_border_width ((GtkContainer*) self, (guint) 12);
	gtk_window_set_resizable ((GtkWindow*) self, FALSE);
	_tmp1_ = zeitgeist_log_new ();
	_g_object_unref0 (self->priv->zg_log);
	self->priv->zg_log = _tmp1_;
	_tmp2_ = del_button;
	_tmp3_ = alm_calendar_widget_new (_tmp2_);
	g_object_ref_sink (_tmp3_);
	_g_object_unref0 (self->priv->calendar_box);
	self->priv->calendar_box = _tmp3_;
	alm_delete_history_dialog_set_up_ui (self);
	return self;
}


AlmDeleteHistoryDialog* alm_delete_history_dialog_new (GtkButton* del_button) {
	return alm_delete_history_dialog_construct (ALM_TYPE_DELETE_HISTORY_DIALOG, del_button);
}


static void alm_delete_history_dialog_set_up_ui (AlmDeleteHistoryDialog* self) {
	const gchar* _tmp0_ = NULL;
	GtkLabel* _tmp1_;
	GtkLabel* label;
	const gchar* _tmp2_ = NULL;
	GtkRadioButton* _tmp3_;
	GtkRadioButton* _tmp4_;
	GSList* _tmp5_ = NULL;
	const gchar* _tmp6_ = NULL;
	GtkRadioButton* _tmp7_;
	GtkRadioButton* _tmp8_;
	GSList* _tmp9_ = NULL;
	const gchar* _tmp10_ = NULL;
	GtkRadioButton* _tmp11_;
	GtkRadioButton* _tmp12_;
	const gchar* _tmp13_ = NULL;
	GtkRadioButton* _tmp14_;
	GtkRadioButton* _tmp15_;
	const gchar* _tmp16_ = NULL;
	GtkRadioButton* _tmp17_;
	GtkBox* _tmp18_;
	GtkBox* hbox_calendar;
	GtkRadioButton* _tmp19_;
	AlmCalendarWidget* _tmp20_;
	GtkBox* _tmp21_;
	GtkBox* vbox;
	GtkRadioButton* _tmp22_;
	GtkRadioButton* _tmp23_;
	GtkRadioButton* _tmp24_;
	GtkRadioButton* _tmp25_;
	GtkBox* _tmp26_ = NULL;
	GtkBox* _tmp27_;
	GtkBox* area;
	g_return_if_fail (self != NULL);
	_tmp0_ = _ ("Delete records of which files and applications were used:");
	_tmp1_ = (GtkLabel*) gtk_label_new (_tmp0_);
	g_object_ref_sink (_tmp1_);
	label = _tmp1_;
	gtk_label_set_line_wrap (label, TRUE);
	gtk_label_set_line_wrap_mode (label, PANGO_WRAP_WORD);
	gtk_misc_set_alignment ((GtkMisc*) label, (gfloat) 0, 0.5f);
	_tmp2_ = _ ("In the past hour");
	_tmp3_ = (GtkRadioButton*) gtk_radio_button_new_with_label (NULL, _tmp2_);
	g_object_ref_sink (_tmp3_);
	_g_object_unref0 (self->priv->r_hour);
	self->priv->r_hour = _tmp3_;
	_tmp4_ = self->priv->r_hour;
	_tmp5_ = gtk_radio_button_get_group (_tmp4_);
	_tmp6_ = _ ("In the past day");
	_tmp7_ = (GtkRadioButton*) gtk_radio_button_new_with_label (_tmp5_, _tmp6_);
	g_object_ref_sink (_tmp7_);
	_g_object_unref0 (self->priv->r_day);
	self->priv->r_day = _tmp7_;
	_tmp8_ = self->priv->r_hour;
	_tmp9_ = gtk_radio_button_get_group (_tmp8_);
	_tmp10_ = _ ("In the past week");
	_tmp11_ = (GtkRadioButton*) gtk_radio_button_new_with_label (_tmp9_, _tmp10_);
	g_object_ref_sink (_tmp11_);
	_g_object_unref0 (self->priv->r_week);
	self->priv->r_week = _tmp11_;
	_tmp12_ = self->priv->r_hour;
	_tmp13_ = _ ("From:");
	_tmp14_ = (GtkRadioButton*) gtk_radio_button_new_with_label_from_widget (_tmp12_, _tmp13_);
	g_object_ref_sink (_tmp14_);
	_g_object_unref0 (self->priv->r_calendar);
	self->priv->r_calendar = _tmp14_;
	_tmp15_ = self->priv->r_hour;
	_tmp16_ = _ ("From all time");
	_tmp17_ = (GtkRadioButton*) gtk_radio_button_new_with_label_from_widget (_tmp15_, _tmp16_);
	g_object_ref_sink (_tmp17_);
	_g_object_unref0 (self->priv->r_ever);
	self->priv->r_ever = _tmp17_;
	_tmp18_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 5);
	g_object_ref_sink (_tmp18_);
	hbox_calendar = _tmp18_;
	_tmp19_ = self->priv->r_calendar;
	gtk_box_pack_start (hbox_calendar, (GtkWidget*) _tmp19_, FALSE, FALSE, (guint) 0);
	_tmp20_ = self->priv->calendar_box;
	gtk_box_pack_start (hbox_calendar, (GtkWidget*) _tmp20_, FALSE, FALSE, (guint) 0);
	_tmp21_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 5);
	g_object_ref_sink (_tmp21_);
	vbox = _tmp21_;
	gtk_box_pack_start (vbox, (GtkWidget*) label, FALSE, TRUE, (guint) 0);
	_tmp22_ = self->priv->r_hour;
	gtk_box_pack_start (vbox, (GtkWidget*) _tmp22_, FALSE, TRUE, (guint) 0);
	_tmp23_ = self->priv->r_day;
	gtk_box_pack_start (vbox, (GtkWidget*) _tmp23_, FALSE, TRUE, (guint) 0);
	_tmp24_ = self->priv->r_week;
	gtk_box_pack_start (vbox, (GtkWidget*) _tmp24_, FALSE, TRUE, (guint) 0);
	gtk_box_pack_start (vbox, (GtkWidget*) hbox_calendar, FALSE, TRUE, (guint) 0);
	_tmp25_ = self->priv->r_ever;
	gtk_box_pack_start (vbox, (GtkWidget*) _tmp25_, FALSE, TRUE, (guint) 0);
	_tmp26_ = gtk_dialog_get_content_area ((GtkDialog*) self);
	_tmp27_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp26_, GTK_TYPE_BOX) ? ((GtkBox*) _tmp26_) : NULL);
	area = _tmp27_;
	gtk_box_pack_start (area, (GtkWidget*) vbox, FALSE, FALSE, (guint) 0);
	gtk_dialog_add_buttons ((GtkDialog*) self, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, GTK_STOCK_OK, GTK_RESPONSE_OK, NULL);
	_g_object_unref0 (area);
	_g_object_unref0 (vbox);
	_g_object_unref0 (hbox_calendar);
	_g_object_unref0 (label);
}


gint alm_delete_history_dialog_get_active_radio_button (AlmDeleteHistoryDialog* self) {
	gint result = 0;
	GtkRadioButton* _tmp0_;
	gboolean _tmp1_ = FALSE;
	g_return_val_if_fail (self != NULL, 0);
	_tmp0_ = self->priv->r_hour;
	_tmp1_ = gtk_toggle_button_get_active ((GtkToggleButton*) _tmp0_);
	if (_tmp1_) {
		result = 0;
		return result;
	} else {
		GtkRadioButton* _tmp2_;
		gboolean _tmp3_ = FALSE;
		_tmp2_ = self->priv->r_day;
		_tmp3_ = gtk_toggle_button_get_active ((GtkToggleButton*) _tmp2_);
		if (_tmp3_) {
			result = 1;
			return result;
		} else {
			GtkRadioButton* _tmp4_;
			gboolean _tmp5_ = FALSE;
			_tmp4_ = self->priv->r_week;
			_tmp5_ = gtk_toggle_button_get_active ((GtkToggleButton*) _tmp4_);
			if (_tmp5_) {
				result = 2;
				return result;
			} else {
				GtkRadioButton* _tmp6_;
				gboolean _tmp7_ = FALSE;
				_tmp6_ = self->priv->r_calendar;
				_tmp7_ = gtk_toggle_button_get_active ((GtkToggleButton*) _tmp6_);
				if (_tmp7_) {
					result = 3;
					return result;
				} else {
					GtkRadioButton* _tmp8_;
					gboolean _tmp9_ = FALSE;
					_tmp8_ = self->priv->r_ever;
					_tmp9_ = gtk_toggle_button_get_active ((GtkToggleButton*) _tmp8_);
					if (_tmp9_) {
						result = 4;
						return result;
					} else {
						result = -1;
						return result;
					}
				}
			}
		}
	}
}


void alm_delete_history_dialog_on_delete_history (AlmDeleteHistoryDialog* self) {
	gint _tmp0_ = 0;
	gint res;
	gint _tmp1_;
	GError * _inner_error_ = NULL;
	g_return_if_fail (self != NULL);
	gtk_widget_show_all ((GtkWidget*) self);
	_tmp0_ = gtk_dialog_run ((GtkDialog*) self);
	res = _tmp0_;
	_tmp1_ = res;
	if (_tmp1_ == ((gint) GTK_RESPONSE_OK)) {
		ZeitgeistTimeRange* tr = NULL;
		GtkRecentManager* _tmp2_;
		GtkRecentManager* recent;
		gint _tmp3_ = 0;
		gint index;
		gint _tmp4_;
		_tmp2_ = gtk_recent_manager_new ();
		recent = _tmp2_;
		_tmp3_ = alm_delete_history_dialog_get_active_radio_button (self);
		index = _tmp3_;
		_tmp4_ = index;
		if (_tmp4_ < 3) {
			gint range;
			gint _tmp5_;
			gint64 _tmp11_ = 0LL;
			gint64 end;
			gint64 _tmp12_;
			gint _tmp13_;
			gint64 start;
			gint64 _tmp14_;
			gint64 _tmp15_;
			ZeitgeistTimeRange* _tmp16_;
			ZeitgeistTimeRange* _tmp17_;
			range = (60 * 60) * 1000;
			_tmp5_ = index;
			if (_tmp5_ == 0) {
				gint _tmp6_;
				_tmp6_ = range;
				range = 1 * _tmp6_;
			} else {
				gint _tmp7_;
				_tmp7_ = index;
				if (_tmp7_ == 1) {
					gint _tmp8_;
					_tmp8_ = range;
					range = _tmp8_ * 24;
				} else {
					gint _tmp9_;
					_tmp9_ = index;
					if (_tmp9_ == 2) {
						gint _tmp10_;
						_tmp10_ = range;
						range = (_tmp10_ * 24) * 7;
					}
				}
			}
			_tmp11_ = zeitgeist_timestamp_from_now ();
			end = _tmp11_;
			_tmp12_ = end;
			_tmp13_ = range;
			start = _tmp12_ - _tmp13_;
			_tmp14_ = start;
			_tmp15_ = end;
			_tmp16_ = zeitgeist_time_range_new (_tmp14_, _tmp15_);
			_g_object_unref0 (tr);
			tr = _tmp16_;
			_tmp17_ = tr;
			alm_delete_history_dialog_get_history (self, _tmp17_, NULL, NULL);
		} else {
			gint _tmp18_;
			_tmp18_ = index;
			if (_tmp18_ == 3) {
				AlmCalendarWidget* _tmp19_;
				ZeitgeistTimeRange* _tmp20_ = NULL;
				ZeitgeistTimeRange* _tmp21_;
				_tmp19_ = self->priv->calendar_box;
				_tmp20_ = alm_calendar_widget_get_range (_tmp19_);
				_g_object_unref0 (tr);
				tr = _tmp20_;
				_tmp21_ = tr;
				alm_delete_history_dialog_get_history (self, _tmp21_, NULL, NULL);
			} else {
				gint _tmp22_;
				_tmp22_ = index;
				if (_tmp22_ == 4) {
					ZeitgeistTimeRange* _tmp23_;
					ZeitgeistTimeRange* _tmp24_;
					_tmp23_ = zeitgeist_time_range_new_anytime ();
					_g_object_unref0 (tr);
					tr = _tmp23_;
					_tmp24_ = tr;
					alm_delete_history_dialog_get_history (self, _tmp24_, NULL, NULL);
					{
						GtkRecentManager* _tmp25_;
						_tmp25_ = recent;
						gtk_recent_manager_purge_items (_tmp25_, &_inner_error_);
						if (_inner_error_ != NULL) {
							goto __catch4_g_error;
						}
					}
					goto __finally4;
					__catch4_g_error:
					{
						GError* err = NULL;
						GError* _tmp26_;
						const gchar* _tmp27_;
						err = _inner_error_;
						_inner_error_ = NULL;
						_tmp26_ = err;
						_tmp27_ = _tmp26_->message;
						g_warning ("unified-privacy.vala:859: %s", _tmp27_);
						_g_error_free0 (err);
					}
					__finally4:
					if (_inner_error_ != NULL) {
						_g_object_unref0 (recent);
						_g_object_unref0 (tr);
						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);
						g_clear_error (&_inner_error_);
						return;
					}
				}
			}
		}
		_g_object_unref0 (recent);
		_g_object_unref0 (tr);
	}
	gtk_widget_hide ((GtkWidget*) self);
}


static void alm_delete_history_dialog_get_history_data_free (gpointer _data) {
	AlmDeleteHistoryDialogGetHistoryData* _data_;
	_data_ = _data;
	_g_object_unref0 (_data_->tr);
	_g_object_unref0 (_data_->self);
	g_slice_free (AlmDeleteHistoryDialogGetHistoryData, _data_);
}


static void alm_delete_history_dialog_get_history (AlmDeleteHistoryDialog* self, ZeitgeistTimeRange* tr, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	AlmDeleteHistoryDialogGetHistoryData* _data_;
	AlmDeleteHistoryDialog* _tmp0_;
	ZeitgeistTimeRange* _tmp1_;
	ZeitgeistTimeRange* _tmp2_;
	_data_ = g_slice_new0 (AlmDeleteHistoryDialogGetHistoryData);
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, alm_delete_history_dialog_get_history);
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, alm_delete_history_dialog_get_history_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	_tmp1_ = tr;
	_tmp2_ = _g_object_ref0 (_tmp1_);
	_g_object_unref0 (_data_->tr);
	_data_->tr = _tmp2_;
	alm_delete_history_dialog_get_history_co (_data_);
}


static void alm_delete_history_dialog_get_history_finish (AlmDeleteHistoryDialog* self, GAsyncResult* _res_) {
	AlmDeleteHistoryDialogGetHistoryData* _data_;
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
}


static gboolean _alm_delete_history_dialog_get_history_co_gsource_func (gpointer self) {
	gboolean result;
	result = alm_delete_history_dialog_get_history_co (self);
	return result;
}


static void _g_object_unref0_ (gpointer var) {
	(var == NULL) ? NULL : (var = (g_object_unref (var), NULL));
}


static void alm_delete_history_dialog_get_history_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	AlmDeleteHistoryDialogGetHistoryData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	alm_delete_history_dialog_get_history_co (_data_);
}


static gboolean alm_delete_history_dialog_get_history_co (AlmDeleteHistoryDialogGetHistoryData* _data_) {
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	g_idle_add_full (G_PRIORITY_LOW, _alm_delete_history_dialog_get_history_co_gsource_func, _data_, NULL);
	_data_->_state_ = 1;
	return FALSE;
	_state_1:
	;
	_data_->_tmp0_ = (GtkDialog*) gtk_dialog_new ();
	g_object_ref_sink (_data_->_tmp0_);
	_data_->dialog = _data_->_tmp0_;
	_data_->_tmp1_ = _data_->dialog;
	gtk_dialog_add_button (_data_->_tmp1_, GTK_STOCK_CANCEL, (gint) GTK_RESPONSE_CANCEL);
	_data_->_tmp2_ = _data_->dialog;
	gtk_dialog_add_button (_data_->_tmp2_, GTK_STOCK_YES, (gint) GTK_RESPONSE_OK);
	_data_->_tmp3_ = _data_->dialog;
	gtk_window_set_title ((GtkWindow*) _data_->_tmp3_, "");
	_data_->_tmp4_ = NULL;
	_data_->_tmp4_ = _ ("This operation cannot be undone, are you sure you want to delete this " \
"activity?");
	_data_->_tmp5_ = (GtkLabel*) gtk_label_new (_data_->_tmp4_);
	g_object_ref_sink (_data_->_tmp5_);
	_data_->label = _data_->_tmp5_;
	_data_->_tmp6_ = _data_->label;
	gtk_label_set_line_wrap (_data_->_tmp6_, TRUE);
	_data_->_tmp7_ = _data_->label;
	gtk_label_set_line_wrap_mode (_data_->_tmp7_, PANGO_WRAP_WORD);
	_data_->_tmp8_ = _data_->label;
	gtk_misc_set_padding ((GtkMisc*) _data_->_tmp8_, 9, 9);
	_data_->_tmp9_ = _data_->dialog;
	_data_->_tmp10_ = NULL;
	_data_->_tmp10_ = gtk_dialog_get_content_area (_data_->_tmp9_);
	_data_->_tmp11_ = _data_->label;
	gtk_container_add (G_TYPE_CHECK_INSTANCE_CAST (_data_->_tmp10_, GTK_TYPE_CONTAINER, GtkContainer), (GtkWidget*) _data_->_tmp11_);
	_data_->_tmp12_ = _data_->dialog;
	_data_->_tmp13_ = NULL;
	_data_->_tmp13_ = gtk_widget_get_toplevel ((GtkWidget*) _data_->self);
	gtk_window_set_transient_for ((GtkWindow*) _data_->_tmp12_, G_TYPE_CHECK_INSTANCE_CAST (_data_->_tmp13_, GTK_TYPE_WINDOW, GtkWindow));
	_data_->_tmp14_ = _data_->dialog;
	gtk_window_set_modal ((GtkWindow*) _data_->_tmp14_, TRUE);
	_data_->_tmp15_ = _data_->dialog;
	gtk_widget_show_all ((GtkWidget*) _data_->_tmp15_);
	_data_->_tmp16_ = _data_->dialog;
	_data_->_tmp17_ = 0;
	_data_->_tmp17_ = gtk_dialog_run (_data_->_tmp16_);
	_data_->res = _data_->_tmp17_;
	_data_->_tmp18_ = _data_->dialog;
	gtk_widget_destroy ((GtkWidget*) _data_->_tmp18_);
	_data_->_tmp19_ = _data_->res;
	if (_data_->_tmp19_ == ((gint) GTK_RESPONSE_OK)) {
		_data_->_tmp20_ = g_ptr_array_new_with_free_func (_g_object_unref0_);
		_data_->events = _data_->_tmp20_;
		_data_->_tmp21_ = _data_->events;
		_data_->_tmp22_ = zeitgeist_event_new ();
		g_ptr_array_add (_data_->_tmp21_, _data_->_tmp22_);
		{
			_data_->_tmp23_ = _data_->self->priv->zg_log;
			_data_->_tmp24_ = _data_->tr;
			_data_->_tmp25_ = _data_->events;
			_data_->_tmp26_ = 0;
			_data_->_state_ = 2;
			zeitgeist_log_find_event_ids (_data_->_tmp23_, _data_->_tmp24_, _data_->_tmp25_, ZEITGEIST_STORAGE_STATE_ANY, (guint32) 0, 0, NULL, alm_delete_history_dialog_get_history_ready, _data_);
			return FALSE;
			_state_2:
			_data_->_tmp27_ = NULL;
			_data_->_tmp27_ = zeitgeist_log_find_event_ids_finish (_data_->_tmp23_, _data_->_res_, &_data_->_tmp26_, &_data_->_inner_error_);
			_data_->ids = _data_->_tmp27_;
			_data_->ids_length1 = _data_->_tmp26_;
			_data_->_ids_size_ = _data_->ids_length1;
			if (_data_->_inner_error_ != NULL) {
				goto __catch5_g_error;
			}
			_data_->_tmp28_ = g_array_new (TRUE, TRUE, sizeof (gint));
			_data_->del_ids = _data_->_tmp28_;
			_data_->_tmp29_ = _data_->del_ids;
			_data_->_tmp30_ = _data_->ids;
			_data_->_tmp30__length1 = _data_->ids_length1;
			_data_->_tmp31_ = _data_->ids;
			_data_->_tmp31__length1 = _data_->ids_length1;
			g_array_append_vals (_data_->_tmp29_, _data_->_tmp30_, (guint) _data_->_tmp31__length1);
			_data_->_tmp32_ = _data_->del_ids;
			alm_delete_history_dialog_delete_history (_data_->self, _data_->_tmp32_, NULL, NULL);
			_g_array_unref0 (_data_->del_ids);
			_data_->ids = (g_free (_data_->ids), NULL);
		}
		goto __finally5;
		__catch5_g_error:
		{
			_data_->err = _data_->_inner_error_;
			_data_->_inner_error_ = NULL;
			_data_->_tmp33_ = _data_->err;
			_data_->_tmp34_ = _data_->_tmp33_->message;
			g_warning ("unified-privacy.vala:899: %s", _data_->_tmp34_);
			_g_error_free0 (_data_->err);
		}
		__finally5:
		if (_data_->_inner_error_ != NULL) {
			_g_ptr_array_unref0 (_data_->events);
			_g_object_unref0 (_data_->label);
			_g_object_unref0 (_data_->dialog);
			g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error_->message, g_quark_to_string (_data_->_inner_error_->domain), _data_->_inner_error_->code);
			g_clear_error (&_data_->_inner_error_);
			return FALSE;
		}
		_g_ptr_array_unref0 (_data_->events);
	}
	_g_object_unref0 (_data_->label);
	_g_object_unref0 (_data_->dialog);
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}


static void alm_delete_history_dialog_delete_history_data_free (gpointer _data) {
	AlmDeleteHistoryDialogDeleteHistoryData* _data_;
	_data_ = _data;
	_g_array_unref0 (_data_->ids);
	_g_object_unref0 (_data_->self);
	g_slice_free (AlmDeleteHistoryDialogDeleteHistoryData, _data_);
}


static gpointer _g_array_ref0 (gpointer self) {
	return self ? g_array_ref (self) : NULL;
}


static void alm_delete_history_dialog_delete_history (AlmDeleteHistoryDialog* self, GArray* ids, GAsyncReadyCallback _callback_, gpointer _user_data_) {
	AlmDeleteHistoryDialogDeleteHistoryData* _data_;
	AlmDeleteHistoryDialog* _tmp0_;
	GArray* _tmp1_;
	GArray* _tmp2_;
	_data_ = g_slice_new0 (AlmDeleteHistoryDialogDeleteHistoryData);
	_data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, alm_delete_history_dialog_delete_history);
	g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, alm_delete_history_dialog_delete_history_data_free);
	_tmp0_ = _g_object_ref0 (self);
	_data_->self = _tmp0_;
	_tmp1_ = ids;
	_tmp2_ = _g_array_ref0 (_tmp1_);
	_g_array_unref0 (_data_->ids);
	_data_->ids = _tmp2_;
	alm_delete_history_dialog_delete_history_co (_data_);
}


static void alm_delete_history_dialog_delete_history_finish (AlmDeleteHistoryDialog* self, GAsyncResult* _res_) {
	AlmDeleteHistoryDialogDeleteHistoryData* _data_;
	_data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_));
}


static gboolean _alm_delete_history_dialog_delete_history_co_gsource_func (gpointer self) {
	gboolean result;
	result = alm_delete_history_dialog_delete_history_co (self);
	return result;
}


static void alm_delete_history_dialog_delete_history_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) {
	AlmDeleteHistoryDialogDeleteHistoryData* _data_;
	_data_ = _user_data_;
	_data_->_source_object_ = source_object;
	_data_->_res_ = _res_;
	alm_delete_history_dialog_delete_history_co (_data_);
}


static gboolean alm_delete_history_dialog_delete_history_co (AlmDeleteHistoryDialogDeleteHistoryData* _data_) {
	switch (_data_->_state_) {
		case 0:
		goto _state_0;
		case 1:
		goto _state_1;
		case 2:
		goto _state_2;
		default:
		g_assert_not_reached ();
	}
	_state_0:
	g_idle_add_full (G_PRIORITY_LOW, _alm_delete_history_dialog_delete_history_co_gsource_func, _data_, NULL);
	_data_->_state_ = 1;
	return FALSE;
	_state_1:
	;
	{
		_data_->_tmp0_ = _data_->self->priv->zg_log;
		_data_->_tmp1_ = _data_->ids;
		_data_->_state_ = 2;
		zeitgeist_log_delete_events (_data_->_tmp0_, _data_->_tmp1_, NULL, alm_delete_history_dialog_delete_history_ready, _data_);
		return FALSE;
		_state_2:
		_data_->_tmp2_ = NULL;
		_data_->_tmp2_ = zeitgeist_log_delete_events_finish (_data_->_tmp0_, _data_->_res_, &_data_->_inner_error_);
		_data_->rs = _data_->_tmp2_;
		if (_data_->_inner_error_ != NULL) {
			goto __catch6_g_error;
		}
		_g_object_unref0 (_data_->rs);
	}
	goto __finally6;
	__catch6_g_error:
	{
		_data_->err = _data_->_inner_error_;
		_data_->_inner_error_ = NULL;
		_data_->_tmp3_ = _data_->err;
		_data_->_tmp4_ = _data_->_tmp3_->message;
		g_warning ("unified-privacy.vala:912: %s", _data_->_tmp4_);
		_g_error_free0 (_data_->err);
	}
	__finally6:
	if (_data_->_inner_error_ != NULL) {
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _data_->_inner_error_->message, g_quark_to_string (_data_->_inner_error_->domain), _data_->_inner_error_->code);
		g_clear_error (&_data_->_inner_error_);
		return FALSE;
	}
	if (_data_->_state_ == 0) {
		g_simple_async_result_complete_in_idle (_data_->_async_result);
	} else {
		g_simple_async_result_complete (_data_->_async_result);
	}
	g_object_unref (_data_->_async_result);
	return FALSE;
}


static void alm_delete_history_dialog_class_init (AlmDeleteHistoryDialogClass * klass) {
	alm_delete_history_dialog_parent_class = g_type_class_peek_parent (klass);
	g_type_class_add_private (klass, sizeof (AlmDeleteHistoryDialogPrivate));
	G_OBJECT_CLASS (klass)->finalize = alm_delete_history_dialog_finalize;
}


static void alm_delete_history_dialog_instance_init (AlmDeleteHistoryDialog * self) {
	self->priv = ALM_DELETE_HISTORY_DIALOG_GET_PRIVATE (self);
}


static void alm_delete_history_dialog_finalize (GObject* obj) {
	AlmDeleteHistoryDialog * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, ALM_TYPE_DELETE_HISTORY_DIALOG, AlmDeleteHistoryDialog);
	_g_object_unref0 (self->priv->r_hour);
	_g_object_unref0 (self->priv->r_day);
	_g_object_unref0 (self->priv->r_week);
	_g_object_unref0 (self->priv->r_calendar);
	_g_object_unref0 (self->priv->r_ever);
	_g_object_unref0 (self->priv->zg_log);
	_g_object_unref0 (self->priv->calendar_box);
	G_OBJECT_CLASS (alm_delete_history_dialog_parent_class)->finalize (obj);
}


GType alm_delete_history_dialog_get_type (void) {
	static volatile gsize alm_delete_history_dialog_type_id__volatile = 0;
	if (g_once_init_enter (&alm_delete_history_dialog_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (AlmDeleteHistoryDialogClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) alm_delete_history_dialog_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (AlmDeleteHistoryDialog), 0, (GInstanceInitFunc) alm_delete_history_dialog_instance_init, NULL };
		GType alm_delete_history_dialog_type_id;
		alm_delete_history_dialog_type_id = g_type_register_static (GTK_TYPE_DIALOG, "AlmDeleteHistoryDialog", &g_define_type_info, 0);
		g_once_init_leave (&alm_delete_history_dialog_type_id__volatile, alm_delete_history_dialog_type_id);
	}
	return alm_delete_history_dialog_type_id__volatile;
}



