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

#include <adwaita.h>
#include "libdino.h"
#include <glib-object.h>
#include <stdlib.h>
#include <string.h>
#include <glib.h>
#include <gio/gio.h>
#include <gtk/gtk.h>
#include <gee.h>
#include "xmpp-vala.h"
#include "dino_i18n.h"

#if !defined(VALA_STRICT_C)
#if !defined(__clang__) && defined(__GNUC__) && (__GNUC__ >= 14)
#pragma GCC diagnostic warning "-Wincompatible-pointer-types"
#elif defined(__clang__) && (__clang_major__ >= 16)
#pragma clang diagnostic ignored "-Wincompatible-function-pointer-types"
#pragma clang diagnostic ignored "-Wincompatible-pointer-types"
#endif
#endif
#if !defined(VALA_EXTERN)
#if defined(_MSC_VER)
#define VALA_EXTERN __declspec(dllexport) extern
#elif __GNUC__ >= 4
#define VALA_EXTERN __attribute__((visibility("default"))) extern
#else
#define VALA_EXTERN extern
#endif
#endif

#define DINO_UI_TYPE_APPLICATION (dino_ui_application_get_type ())
#define DINO_UI_APPLICATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_APPLICATION, DinoUiApplication))
#define DINO_UI_APPLICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_APPLICATION, DinoUiApplicationClass))
#define DINO_UI_IS_APPLICATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_APPLICATION))
#define DINO_UI_IS_APPLICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_APPLICATION))
#define DINO_UI_APPLICATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_APPLICATION, DinoUiApplicationClass))

typedef struct _DinoUiApplication DinoUiApplication;
typedef struct _DinoUiApplicationClass DinoUiApplicationClass;
typedef struct _DinoUiApplicationPrivate DinoUiApplicationPrivate;

#define DINO_UI_TYPE_MAIN_WINDOW (dino_ui_main_window_get_type ())
#define DINO_UI_MAIN_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_MAIN_WINDOW, DinoUiMainWindow))
#define DINO_UI_MAIN_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_MAIN_WINDOW, DinoUiMainWindowClass))
#define DINO_UI_IS_MAIN_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_MAIN_WINDOW))
#define DINO_UI_IS_MAIN_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_MAIN_WINDOW))
#define DINO_UI_MAIN_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_MAIN_WINDOW, DinoUiMainWindowClass))

typedef struct _DinoUiMainWindow DinoUiMainWindow;
typedef struct _DinoUiMainWindowClass DinoUiMainWindowClass;

#define DINO_UI_TYPE_MAIN_WINDOW_CONTROLLER (dino_ui_main_window_controller_get_type ())
#define DINO_UI_MAIN_WINDOW_CONTROLLER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_MAIN_WINDOW_CONTROLLER, DinoUiMainWindowController))
#define DINO_UI_MAIN_WINDOW_CONTROLLER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_MAIN_WINDOW_CONTROLLER, DinoUiMainWindowControllerClass))
#define DINO_UI_IS_MAIN_WINDOW_CONTROLLER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_MAIN_WINDOW_CONTROLLER))
#define DINO_UI_IS_MAIN_WINDOW_CONTROLLER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_MAIN_WINDOW_CONTROLLER))
#define DINO_UI_MAIN_WINDOW_CONTROLLER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_MAIN_WINDOW_CONTROLLER, DinoUiMainWindowControllerClass))

typedef struct _DinoUiMainWindowController DinoUiMainWindowController;
typedef struct _DinoUiMainWindowControllerClass DinoUiMainWindowControllerClass;

#define DINO_UI_TYPE_CONFIG (dino_ui_config_get_type ())
#define DINO_UI_CONFIG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_CONFIG, DinoUiConfig))
#define DINO_UI_CONFIG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_CONFIG, DinoUiConfigClass))
#define DINO_UI_IS_CONFIG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_CONFIG))
#define DINO_UI_IS_CONFIG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_CONFIG))
#define DINO_UI_CONFIG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_CONFIG, DinoUiConfigClass))

typedef struct _DinoUiConfig DinoUiConfig;
typedef struct _DinoUiConfigClass DinoUiConfigClass;
enum  {
	DINO_UI_APPLICATION_0_PROPERTY,
	DINO_UI_APPLICATION_DB_PROPERTY,
	DINO_UI_APPLICATION_SETTINGS_PROPERTY,
	DINO_UI_APPLICATION_STREAM_INTERACTOR_PROPERTY,
	DINO_UI_APPLICATION_PLUGIN_REGISTRY_PROPERTY,
	DINO_UI_APPLICATION_SEARCH_PATH_GENERATOR_PROPERTY,
	DINO_UI_APPLICATION_NUM_PROPERTIES
};
static GParamSpec* dino_ui_application_properties[DINO_UI_APPLICATION_NUM_PROPERTIES];
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _qlite_database_unref0(var) ((var == NULL) ? NULL : (var = (qlite_database_unref (var), NULL)))
#define _dino_plugins_registry_unref0(var) ((var == NULL) ? NULL : (var = (dino_plugins_registry_unref (var), NULL)))
#define _dino_search_path_generator_unref0(var) ((var == NULL) ? NULL : (var = (dino_search_path_generator_unref (var), NULL)))
typedef struct _Block8Data Block8Data;
#define _g_free0(var) (var = (g_free (var), NULL))

#define DINO_UI_TYPE_FREE_DESKTOP_NOTIFIER (dino_ui_free_desktop_notifier_get_type ())
#define DINO_UI_FREE_DESKTOP_NOTIFIER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_FREE_DESKTOP_NOTIFIER, DinoUiFreeDesktopNotifier))
#define DINO_UI_FREE_DESKTOP_NOTIFIER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_FREE_DESKTOP_NOTIFIER, DinoUiFreeDesktopNotifierClass))
#define DINO_UI_IS_FREE_DESKTOP_NOTIFIER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_FREE_DESKTOP_NOTIFIER))
#define DINO_UI_IS_FREE_DESKTOP_NOTIFIER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_FREE_DESKTOP_NOTIFIER))
#define DINO_UI_FREE_DESKTOP_NOTIFIER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_FREE_DESKTOP_NOTIFIER, DinoUiFreeDesktopNotifierClass))

typedef struct _DinoUiFreeDesktopNotifier DinoUiFreeDesktopNotifier;
typedef struct _DinoUiFreeDesktopNotifierClass DinoUiFreeDesktopNotifierClass;

#define DINO_UI_TYPE_GNOTIFICATIONS_NOTIFIER (dino_ui_gnotifications_notifier_get_type ())
#define DINO_UI_GNOTIFICATIONS_NOTIFIER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_GNOTIFICATIONS_NOTIFIER, DinoUiGNotificationsNotifier))
#define DINO_UI_GNOTIFICATIONS_NOTIFIER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_GNOTIFICATIONS_NOTIFIER, DinoUiGNotificationsNotifierClass))
#define DINO_UI_IS_GNOTIFICATIONS_NOTIFIER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_GNOTIFICATIONS_NOTIFIER))
#define DINO_UI_IS_GNOTIFICATIONS_NOTIFIER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_GNOTIFICATIONS_NOTIFIER))
#define DINO_UI_GNOTIFICATIONS_NOTIFIER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_GNOTIFICATIONS_NOTIFIER, DinoUiGNotificationsNotifierClass))

typedef struct _DinoUiGNotificationsNotifier DinoUiGNotificationsNotifier;
typedef struct _DinoUiGNotificationsNotifierClass DinoUiGNotificationsNotifierClass;
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))

#define DINO_UI_UTIL_TYPE_AUDIO_VIDEO_FILE_METADATA_PROVIDER (dino_ui_util_audio_video_file_metadata_provider_get_type ())
#define DINO_UI_UTIL_AUDIO_VIDEO_FILE_METADATA_PROVIDER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_UTIL_TYPE_AUDIO_VIDEO_FILE_METADATA_PROVIDER, DinoUiUtilAudioVideoFileMetadataProvider))
#define DINO_UI_UTIL_AUDIO_VIDEO_FILE_METADATA_PROVIDER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_UTIL_TYPE_AUDIO_VIDEO_FILE_METADATA_PROVIDER, DinoUiUtilAudioVideoFileMetadataProviderClass))
#define DINO_UI_UTIL_IS_AUDIO_VIDEO_FILE_METADATA_PROVIDER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_UTIL_TYPE_AUDIO_VIDEO_FILE_METADATA_PROVIDER))
#define DINO_UI_UTIL_IS_AUDIO_VIDEO_FILE_METADATA_PROVIDER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_UTIL_TYPE_AUDIO_VIDEO_FILE_METADATA_PROVIDER))
#define DINO_UI_UTIL_AUDIO_VIDEO_FILE_METADATA_PROVIDER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_UTIL_TYPE_AUDIO_VIDEO_FILE_METADATA_PROVIDER, DinoUiUtilAudioVideoFileMetadataProviderClass))

typedef struct _DinoUiUtilAudioVideoFileMetadataProvider DinoUiUtilAudioVideoFileMetadataProvider;
typedef struct _DinoUiUtilAudioVideoFileMetadataProviderClass DinoUiUtilAudioVideoFileMetadataProviderClass;
#define _xmpp_jid_unref0(var) ((var == NULL) ? NULL : (var = (xmpp_jid_unref (var), NULL)))

#define DINO_UI_TYPE_SELECT_CONTACT_DIALOG (dino_ui_select_contact_dialog_get_type ())
#define DINO_UI_SELECT_CONTACT_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_SELECT_CONTACT_DIALOG, DinoUiSelectContactDialog))
#define DINO_UI_SELECT_CONTACT_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_SELECT_CONTACT_DIALOG, DinoUiSelectContactDialogClass))
#define DINO_UI_IS_SELECT_CONTACT_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_SELECT_CONTACT_DIALOG))
#define DINO_UI_IS_SELECT_CONTACT_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_SELECT_CONTACT_DIALOG))
#define DINO_UI_SELECT_CONTACT_DIALOG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_SELECT_CONTACT_DIALOG, DinoUiSelectContactDialogClass))

typedef struct _DinoUiSelectContactDialog DinoUiSelectContactDialog;
typedef struct _DinoUiSelectContactDialogClass DinoUiSelectContactDialogClass;

#define DINO_UI_TYPE_ADD_CHAT_DIALOG (dino_ui_add_chat_dialog_get_type ())
#define DINO_UI_ADD_CHAT_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_ADD_CHAT_DIALOG, DinoUiAddChatDialog))
#define DINO_UI_ADD_CHAT_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_ADD_CHAT_DIALOG, DinoUiAddChatDialogClass))
#define DINO_UI_IS_ADD_CHAT_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_ADD_CHAT_DIALOG))
#define DINO_UI_IS_ADD_CHAT_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_ADD_CHAT_DIALOG))
#define DINO_UI_ADD_CHAT_DIALOG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_ADD_CHAT_DIALOG, DinoUiAddChatDialogClass))

typedef struct _DinoUiAddChatDialog DinoUiAddChatDialog;
typedef struct _DinoUiAddChatDialogClass DinoUiAddChatDialogClass;
#define _g_variant_type_free0(var) ((var == NULL) ? NULL : (var = (g_variant_type_free (var), NULL)))
#define _g_variant_unref0(var) ((var == NULL) ? NULL : (var = (g_variant_unref (var), NULL)))

#define DINO_UI_CONVERSATION_DETAILS_TYPE_DIALOG (dino_ui_conversation_details_dialog_get_type ())
#define DINO_UI_CONVERSATION_DETAILS_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_CONVERSATION_DETAILS_TYPE_DIALOG, DinoUiConversationDetailsDialog))
#define DINO_UI_CONVERSATION_DETAILS_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_CONVERSATION_DETAILS_TYPE_DIALOG, DinoUiConversationDetailsDialogClass))
#define DINO_UI_CONVERSATION_DETAILS_IS_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_CONVERSATION_DETAILS_TYPE_DIALOG))
#define DINO_UI_CONVERSATION_DETAILS_IS_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_CONVERSATION_DETAILS_TYPE_DIALOG))
#define DINO_UI_CONVERSATION_DETAILS_DIALOG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_CONVERSATION_DETAILS_TYPE_DIALOG, DinoUiConversationDetailsDialogClass))

typedef struct _DinoUiConversationDetailsDialog DinoUiConversationDetailsDialog;
typedef struct _DinoUiConversationDetailsDialogClass DinoUiConversationDetailsDialogClass;
typedef struct _DinoUiConversationDetailsDialogPrivate DinoUiConversationDetailsDialogPrivate;

#define DINO_UI_TYPE_ADD_CONFERENCE_DIALOG (dino_ui_add_conference_dialog_get_type ())
#define DINO_UI_ADD_CONFERENCE_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_ADD_CONFERENCE_DIALOG, DinoUiAddConferenceDialog))
#define DINO_UI_ADD_CONFERENCE_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_ADD_CONFERENCE_DIALOG, DinoUiAddConferenceDialogClass))
#define DINO_UI_IS_ADD_CONFERENCE_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_ADD_CONFERENCE_DIALOG))
#define DINO_UI_IS_ADD_CONFERENCE_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_ADD_CONFERENCE_DIALOG))
#define DINO_UI_ADD_CONFERENCE_DIALOG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_ADD_CONFERENCE_DIALOG, DinoUiAddConferenceDialogClass))

typedef struct _DinoUiAddConferenceDialog DinoUiAddConferenceDialog;
typedef struct _DinoUiAddConferenceDialogClass DinoUiAddConferenceDialogClass;

#define DINO_UI_TYPE_CALL_WINDOW (dino_ui_call_window_get_type ())
#define DINO_UI_CALL_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_CALL_WINDOW, DinoUiCallWindow))
#define DINO_UI_CALL_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_CALL_WINDOW, DinoUiCallWindowClass))
#define DINO_UI_IS_CALL_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_CALL_WINDOW))
#define DINO_UI_IS_CALL_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_CALL_WINDOW))
#define DINO_UI_CALL_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_CALL_WINDOW, DinoUiCallWindowClass))

typedef struct _DinoUiCallWindow DinoUiCallWindow;
typedef struct _DinoUiCallWindowClass DinoUiCallWindowClass;

#define DINO_UI_TYPE_CALL_WINDOW_CONTROLLER (dino_ui_call_window_controller_get_type ())
#define DINO_UI_CALL_WINDOW_CONTROLLER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_CALL_WINDOW_CONTROLLER, DinoUiCallWindowController))
#define DINO_UI_CALL_WINDOW_CONTROLLER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_CALL_WINDOW_CONTROLLER, DinoUiCallWindowControllerClass))
#define DINO_UI_IS_CALL_WINDOW_CONTROLLER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_CALL_WINDOW_CONTROLLER))
#define DINO_UI_IS_CALL_WINDOW_CONTROLLER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_CALL_WINDOW_CONTROLLER))
#define DINO_UI_CALL_WINDOW_CONTROLLER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_CALL_WINDOW_CONTROLLER, DinoUiCallWindowControllerClass))

typedef struct _DinoUiCallWindowController DinoUiCallWindowController;
typedef struct _DinoUiCallWindowControllerClass DinoUiCallWindowControllerClass;
typedef struct _DinoUiCallWindowPrivate DinoUiCallWindowPrivate;

#define DINO_UI_TYPE_CALL_BOTTOM_BAR (dino_ui_call_bottom_bar_get_type ())
#define DINO_UI_CALL_BOTTOM_BAR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_CALL_BOTTOM_BAR, DinoUiCallBottomBar))
#define DINO_UI_CALL_BOTTOM_BAR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_CALL_BOTTOM_BAR, DinoUiCallBottomBarClass))
#define DINO_UI_IS_CALL_BOTTOM_BAR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_CALL_BOTTOM_BAR))
#define DINO_UI_IS_CALL_BOTTOM_BAR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_CALL_BOTTOM_BAR))
#define DINO_UI_CALL_BOTTOM_BAR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_CALL_BOTTOM_BAR, DinoUiCallBottomBarClass))

typedef struct _DinoUiCallBottomBar DinoUiCallBottomBar;
typedef struct _DinoUiCallBottomBarClass DinoUiCallBottomBarClass;

#define DINO_UI_TYPE_PREFERENCES_WINDOW (dino_ui_preferences_window_get_type ())
#define DINO_UI_PREFERENCES_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_PREFERENCES_WINDOW, DinoUiPreferencesWindow))
#define DINO_UI_PREFERENCES_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_PREFERENCES_WINDOW, DinoUiPreferencesWindowClass))
#define DINO_UI_IS_PREFERENCES_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_PREFERENCES_WINDOW))
#define DINO_UI_IS_PREFERENCES_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_PREFERENCES_WINDOW))
#define DINO_UI_PREFERENCES_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_PREFERENCES_WINDOW, DinoUiPreferencesWindowClass))

typedef struct _DinoUiPreferencesWindow DinoUiPreferencesWindow;
typedef struct _DinoUiPreferencesWindowClass DinoUiPreferencesWindowClass;

#define DINO_UI_VIEW_MODEL_TYPE_PREFERENCES_WINDOW (dino_ui_view_model_preferences_window_get_type ())
#define DINO_UI_VIEW_MODEL_PREFERENCES_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_VIEW_MODEL_TYPE_PREFERENCES_WINDOW, DinoUiViewModelPreferencesWindow))
#define DINO_UI_VIEW_MODEL_PREFERENCES_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_VIEW_MODEL_TYPE_PREFERENCES_WINDOW, DinoUiViewModelPreferencesWindowClass))
#define DINO_UI_VIEW_MODEL_IS_PREFERENCES_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_VIEW_MODEL_TYPE_PREFERENCES_WINDOW))
#define DINO_UI_VIEW_MODEL_IS_PREFERENCES_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_VIEW_MODEL_TYPE_PREFERENCES_WINDOW))
#define DINO_UI_VIEW_MODEL_PREFERENCES_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_VIEW_MODEL_TYPE_PREFERENCES_WINDOW, DinoUiViewModelPreferencesWindowClass))

typedef struct _DinoUiViewModelPreferencesWindow DinoUiViewModelPreferencesWindow;
typedef struct _DinoUiViewModelPreferencesWindowClass DinoUiViewModelPreferencesWindowClass;
typedef struct _DinoUiPreferencesWindowPrivate DinoUiPreferencesWindowPrivate;

#define DINO_UI_TYPE_PREFERENCES_WINDOW_ACCOUNTS (dino_ui_preferences_window_accounts_get_type ())
#define DINO_UI_PREFERENCES_WINDOW_ACCOUNTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_PREFERENCES_WINDOW_ACCOUNTS, DinoUiPreferencesWindowAccounts))
#define DINO_UI_PREFERENCES_WINDOW_ACCOUNTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_PREFERENCES_WINDOW_ACCOUNTS, DinoUiPreferencesWindowAccountsClass))
#define DINO_UI_IS_PREFERENCES_WINDOW_ACCOUNTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_PREFERENCES_WINDOW_ACCOUNTS))
#define DINO_UI_IS_PREFERENCES_WINDOW_ACCOUNTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_PREFERENCES_WINDOW_ACCOUNTS))
#define DINO_UI_PREFERENCES_WINDOW_ACCOUNTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_PREFERENCES_WINDOW_ACCOUNTS, DinoUiPreferencesWindowAccountsClass))

typedef struct _DinoUiPreferencesWindowAccounts DinoUiPreferencesWindowAccounts;
typedef struct _DinoUiPreferencesWindowAccountsClass DinoUiPreferencesWindowAccountsClass;

#define DINO_UI_TYPE_PREFERENCES_WINDOW_ENCRYPTION (dino_ui_preferences_window_encryption_get_type ())
#define DINO_UI_PREFERENCES_WINDOW_ENCRYPTION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_PREFERENCES_WINDOW_ENCRYPTION, DinoUiPreferencesWindowEncryption))
#define DINO_UI_PREFERENCES_WINDOW_ENCRYPTION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_PREFERENCES_WINDOW_ENCRYPTION, DinoUiPreferencesWindowEncryptionClass))
#define DINO_UI_IS_PREFERENCES_WINDOW_ENCRYPTION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_PREFERENCES_WINDOW_ENCRYPTION))
#define DINO_UI_IS_PREFERENCES_WINDOW_ENCRYPTION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_PREFERENCES_WINDOW_ENCRYPTION))
#define DINO_UI_PREFERENCES_WINDOW_ENCRYPTION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_PREFERENCES_WINDOW_ENCRYPTION, DinoUiPreferencesWindowEncryptionClass))

typedef struct _DinoUiPreferencesWindowEncryption DinoUiPreferencesWindowEncryption;
typedef struct _DinoUiPreferencesWindowEncryptionClass DinoUiPreferencesWindowEncryptionClass;

#define DINO_UI_TYPE_GENERAL_PREFERENCES_PAGE (dino_ui_general_preferences_page_get_type ())
#define DINO_UI_GENERAL_PREFERENCES_PAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_GENERAL_PREFERENCES_PAGE, DinoUiGeneralPreferencesPage))
#define DINO_UI_GENERAL_PREFERENCES_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_GENERAL_PREFERENCES_PAGE, DinoUiGeneralPreferencesPageClass))
#define DINO_UI_IS_GENERAL_PREFERENCES_PAGE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_GENERAL_PREFERENCES_PAGE))
#define DINO_UI_IS_GENERAL_PREFERENCES_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_GENERAL_PREFERENCES_PAGE))
#define DINO_UI_GENERAL_PREFERENCES_PAGE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_GENERAL_PREFERENCES_PAGE, DinoUiGeneralPreferencesPageClass))

typedef struct _DinoUiGeneralPreferencesPage DinoUiGeneralPreferencesPage;
typedef struct _DinoUiGeneralPreferencesPageClass DinoUiGeneralPreferencesPageClass;

#define DINO_UI_TYPE_ACCOUNT_PREFERENCES_SUBPAGE (dino_ui_account_preferences_subpage_get_type ())
#define DINO_UI_ACCOUNT_PREFERENCES_SUBPAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_ACCOUNT_PREFERENCES_SUBPAGE, DinoUiAccountPreferencesSubpage))
#define DINO_UI_ACCOUNT_PREFERENCES_SUBPAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_ACCOUNT_PREFERENCES_SUBPAGE, DinoUiAccountPreferencesSubpageClass))
#define DINO_UI_IS_ACCOUNT_PREFERENCES_SUBPAGE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_ACCOUNT_PREFERENCES_SUBPAGE))
#define DINO_UI_IS_ACCOUNT_PREFERENCES_SUBPAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_ACCOUNT_PREFERENCES_SUBPAGE))
#define DINO_UI_ACCOUNT_PREFERENCES_SUBPAGE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_ACCOUNT_PREFERENCES_SUBPAGE, DinoUiAccountPreferencesSubpageClass))

typedef struct _DinoUiAccountPreferencesSubpage DinoUiAccountPreferencesSubpage;
typedef struct _DinoUiAccountPreferencesSubpageClass DinoUiAccountPreferencesSubpageClass;
typedef struct _Block9Data Block9Data;

#define DINO_UI_TYPE_CONFERENCE_DETAILS_FRAGMENT (dino_ui_conference_details_fragment_get_type ())
#define DINO_UI_CONFERENCE_DETAILS_FRAGMENT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), DINO_UI_TYPE_CONFERENCE_DETAILS_FRAGMENT, DinoUiConferenceDetailsFragment))
#define DINO_UI_CONFERENCE_DETAILS_FRAGMENT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), DINO_UI_TYPE_CONFERENCE_DETAILS_FRAGMENT, DinoUiConferenceDetailsFragmentClass))
#define DINO_UI_IS_CONFERENCE_DETAILS_FRAGMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), DINO_UI_TYPE_CONFERENCE_DETAILS_FRAGMENT))
#define DINO_UI_IS_CONFERENCE_DETAILS_FRAGMENT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), DINO_UI_TYPE_CONFERENCE_DETAILS_FRAGMENT))
#define DINO_UI_CONFERENCE_DETAILS_FRAGMENT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), DINO_UI_TYPE_CONFERENCE_DETAILS_FRAGMENT, DinoUiConferenceDetailsFragmentClass))

typedef struct _DinoUiConferenceDetailsFragment DinoUiConferenceDetailsFragment;
typedef struct _DinoUiConferenceDetailsFragmentClass DinoUiConferenceDetailsFragmentClass;

struct _DinoUiApplication {
	AdwApplication parent_instance;
	DinoUiApplicationPrivate * priv;
	DinoUiMainWindow* window;
	DinoUiMainWindowController* controller;
};

struct _DinoUiApplicationClass {
	AdwApplicationClass parent_class;
};

struct _DinoUiApplicationPrivate {
	DinoDatabase* _db;
	DinoEntitiesSettings* _settings;
	DinoUiConfig* _config;
	DinoStreamInteractor* _stream_interactor;
	DinoPluginsRegistry* _plugin_registry;
	DinoSearchPathGenerator* _search_path_generator;
};

struct _Block8Data {
	int _ref_count_;
	DinoUiApplication* self;
	DinoNotificationEvents* notification_events;
};

struct _DinoUiConversationDetailsDialog {
	AdwWindow parent_instance;
	DinoUiConversationDetailsDialogPrivate * priv;
	GtkStack* stack;
	GtkBox* about_box;
	GtkButton* pin_button;
	AdwButtonContent* pin_button_content;
	GtkMenuButton* block_button;
	AdwButtonContent* block_button_content;
	GtkButton* notification_button_toggle;
	AdwButtonContent* notification_button_toggle_content;
	GtkMenuButton* notification_button_menu;
	AdwButtonContent* notification_button_menu_content;
	AdwSplitButton* notification_button_split;
	AdwButtonContent* notification_button_split_content;
	GtkStackPage* encryption_stack_page;
	GtkBox* encryption_box;
	GtkStackPage* member_stack_page;
	GtkBox* member_box;
};

struct _DinoUiConversationDetailsDialogClass {
	AdwWindowClass parent_class;
};

struct _DinoUiCallWindow {
	GtkWindow parent_instance;
	DinoUiCallWindowPrivate * priv;
	DinoUiCallWindowController* controller;
	GtkOverlay* overlay;
	GtkGrid* grid;
	DinoUiCallBottomBar* bottom_bar;
	GtkRevealer* bottom_bar_revealer;
	GtkHeaderBar* header_bar;
	GtkRevealer* header_bar_revealer;
	GtkBox* own_video_box;
};

struct _DinoUiCallWindowClass {
	GtkWindowClass parent_class;
};

struct _DinoUiPreferencesWindow {
	AdwPreferencesWindow parent_instance;
	DinoUiPreferencesWindowPrivate * priv;
	DinoUiPreferencesWindowAccounts* accounts_page;
	DinoUiPreferencesWindowEncryption* encryption_page;
	DinoUiGeneralPreferencesPage* general_page;
	DinoUiAccountPreferencesSubpage* account_page;
};

struct _DinoUiPreferencesWindowClass {
	AdwPreferencesWindowClass parent_class;
};

struct _Block9Data {
	int _ref_count_;
	DinoUiApplication* self;
	GtkDialog* dialog;
};

static gint DinoUiApplication_private_offset;
static gpointer dino_ui_application_parent_class = NULL;
VALA_EXTERN gboolean dino_ui_application_print_version;
gboolean dino_ui_application_print_version = FALSE;
static DinoApplicationIface * dino_ui_application_dino_application_parent_iface = NULL;

VALA_EXTERN GType dino_ui_application_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiApplication, g_object_unref)
VALA_EXTERN GType dino_ui_main_window_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiMainWindow, g_object_unref)
VALA_EXTERN GType dino_ui_main_window_controller_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiMainWindowController, g_object_unref)
VALA_EXTERN GType dino_ui_config_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiConfig, g_object_unref)
VALA_EXTERN DinoUiApplication* dino_ui_application_new (GError** error);
VALA_EXTERN DinoUiApplication* dino_ui_application_construct (GType object_type,
                                                  GError** error);
static void dino_ui_application_create_actions (DinoUiApplication* self);
static void __lambda316_ (DinoUiApplication* self);
static Block8Data* block8_data_ref (Block8Data* _data8_);
static void block8_data_unref (void * _userdata_);
static void __lambda317_ (Block8Data* _data8_,
                   GObject* _,
                   GAsyncResult* res);
VALA_EXTERN GType dino_ui_free_desktop_notifier_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiFreeDesktopNotifier, g_object_unref)
VALA_EXTERN DinoUiFreeDesktopNotifier* dino_ui_free_desktop_notifier_new (DinoStreamInteractor* stream_interactor,
                                                              DinoDBusNotifications* dbus_notifications);
VALA_EXTERN DinoUiFreeDesktopNotifier* dino_ui_free_desktop_notifier_construct (GType object_type,
                                                                    DinoStreamInteractor* stream_interactor,
                                                                    DinoDBusNotifications* dbus_notifications);
VALA_EXTERN DinoUiGNotificationsNotifier* dino_ui_gnotifications_notifier_new (DinoStreamInteractor* stream_interactor);
VALA_EXTERN DinoUiGNotificationsNotifier* dino_ui_gnotifications_notifier_construct (GType object_type,
                                                                         DinoStreamInteractor* stream_interactor);
VALA_EXTERN GType dino_ui_gnotifications_notifier_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiGNotificationsNotifier, g_object_unref)
static void ___lambda317__gasync_ready_callback (GObject* source_object,
                                          GAsyncResult* res,
                                          gpointer self);
static void __lambda333_ (DinoUiApplication* self,
                   DinoContentItem* content_item,
                   DinoEntitiesConversation* conversation);
static void ___lambda333__dino_notification_events_notify_content_item (DinoNotificationEvents* _sender,
                                                                 DinoContentItem* content_item,
                                                                 DinoEntitiesConversation* conversation,
                                                                 gpointer self);
VALA_EXTERN DinoUiUtilAudioVideoFileMetadataProvider* dino_ui_util_audio_video_file_metadata_provider_new (void);
VALA_EXTERN DinoUiUtilAudioVideoFileMetadataProvider* dino_ui_util_audio_video_file_metadata_provider_construct (GType object_type);
VALA_EXTERN GType dino_ui_util_audio_video_file_metadata_provider_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiUtilAudioVideoFileMetadataProvider, g_object_unref)
static void ___lambda316__g_application_startup (GApplication* _sender,
                                          gpointer self);
static void __lambda335_ (DinoUiApplication* self);
VALA_EXTERN DinoUiMainWindowController* dino_ui_main_window_controller_new (DinoUiApplication* application,
                                                                DinoStreamInteractor* stream_interactor,
                                                                DinoDatabase* db);
VALA_EXTERN DinoUiMainWindowController* dino_ui_main_window_controller_construct (GType object_type,
                                                                      DinoUiApplication* application,
                                                                      DinoStreamInteractor* stream_interactor,
                                                                      DinoDatabase* db);
VALA_EXTERN DinoUiConfig* dino_ui_config_new (DinoDatabase* db);
VALA_EXTERN DinoUiConfig* dino_ui_config_construct (GType object_type,
                                        DinoDatabase* db);
static void dino_ui_application_set_config (DinoUiApplication* self,
                                     DinoUiConfig* value);
static DinoUiConfig* dino_ui_application_get_config (DinoUiApplication* self);
VALA_EXTERN DinoUiMainWindow* dino_ui_main_window_new (DinoUiApplication* application,
                                           DinoStreamInteractor* stream_interactor,
                                           DinoDatabase* db,
                                           DinoUiConfig* config);
VALA_EXTERN DinoUiMainWindow* dino_ui_main_window_construct (GType object_type,
                                                 DinoUiApplication* application,
                                                 DinoStreamInteractor* stream_interactor,
                                                 DinoDatabase* db,
                                                 DinoUiConfig* config);
VALA_EXTERN void dino_ui_main_window_controller_set_window (DinoUiMainWindowController* self,
                                                DinoUiMainWindow* window);
static void ___lambda335__g_application_activate (GApplication* _sender,
                                           gpointer self);
static void dino_ui_application_real_handle_uri (DinoApplication* base,
                                          const gchar* jid,
                                          const gchar* query,
                                          GeeMap* options);
static void dino_ui_application_show_join_muc_dialog (DinoUiApplication* self,
                                               DinoEntitiesAccount* account,
                                               const gchar* jid);
VALA_EXTERN void dino_ui_main_window_controller_select_conversation (DinoUiMainWindowController* self,
                                                         DinoEntitiesConversation* conversation,
                                                         gboolean do_reset_search,
                                                         gboolean default_initialize_conversation);
VALA_EXTERN GType dino_ui_select_contact_dialog_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiSelectContactDialog, g_object_unref)
VALA_EXTERN GType dino_ui_add_chat_dialog_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiAddChatDialog, g_object_unref)
VALA_EXTERN DinoUiAddChatDialog* dino_ui_add_chat_dialog_new (DinoStreamInteractor* stream_interactor,
                                                  GeeList* accounts);
VALA_EXTERN DinoUiAddChatDialog* dino_ui_add_chat_dialog_construct (GType object_type,
                                                        DinoStreamInteractor* stream_interactor,
                                                        GeeList* accounts);
VALA_EXTERN void dino_ui_select_contact_dialog_set_filter (DinoUiSelectContactDialog* self,
                                               const gchar* str);
static void ____lambda336_ (DinoUiApplication* self,
                     DinoEntitiesConversation* conversation);
static void _____lambda336__dino_ui_add_chat_dialog_added (DinoUiAddChatDialog* _sender,
                                                    DinoEntitiesConversation* conversation,
                                                    gpointer self);
static void dino_ui_application_show_preferences_window (DinoUiApplication* self);
static void _dino_ui_application_show_preferences_window_g_simple_action_activate (GSimpleAction* _sender,
                                                                            GVariant* parameter,
                                                                            gpointer self);
static void __lambda283_ (DinoUiApplication* self,
                   GVariant* variant);
static void dino_ui_application_show_preferences_account_window (DinoUiApplication* self,
                                                          DinoEntitiesAccount* account);
static void ___lambda283__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
static void dino_ui_application_show_about_window (DinoUiApplication* self);
static void _dino_ui_application_show_about_window_g_simple_action_activate (GSimpleAction* _sender,
                                                                      GVariant* parameter,
                                                                      gpointer self);
static void _g_application_quit_g_simple_action_activate (GSimpleAction* _sender,
                                                   GVariant* parameter,
                                                   gpointer self);
static void __lambda284_ (DinoUiApplication* self,
                   GVariant* variant);
VALA_EXTERN void dino_ui_util_present_window (GtkWindow* window);
static void ___lambda284__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
static void __lambda285_ (DinoUiApplication* self,
                   GVariant* variant);
VALA_EXTERN GType dino_ui_conversation_details_dialog_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiConversationDetailsDialog, g_object_unref)
VALA_EXTERN DinoUiConversationDetailsDialog* dino_ui_conversation_details_setup_dialog (DinoEntitiesConversation* conversation,
                                                                            DinoStreamInteractor* stream_interactor,
                                                                            GtkWindow* parent);
static void ___lambda285__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
static void __lambda286_ (DinoUiApplication* self,
                   GVariant* variant);
static void ___lambda286__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
static void __lambda287_ (DinoUiApplication* self);
static void __lambda289_ (DinoUiApplication* self,
                   DinoEntitiesConversation* conversation);
static void ___lambda289__dino_ui_add_chat_dialog_added (DinoUiAddChatDialog* _sender,
                                                  DinoEntitiesConversation* conversation,
                                                  gpointer self);
static void ___lambda287__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
static void __lambda290_ (DinoUiApplication* self);
VALA_EXTERN GType dino_ui_add_conference_dialog_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiAddConferenceDialog, g_object_unref)
VALA_EXTERN DinoUiAddConferenceDialog* dino_ui_add_conference_dialog_new (DinoStreamInteractor* stream_interactor);
VALA_EXTERN DinoUiAddConferenceDialog* dino_ui_add_conference_dialog_construct (GType object_type,
                                                                    DinoStreamInteractor* stream_interactor);
static void ___lambda290__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
static void __lambda308_ (DinoUiApplication* self,
                   GVariant* variant);
static void ___lambda308__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
static void __lambda311_ (DinoUiApplication* self,
                   GVariant* variant);
static void ___lambda311__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
static void __lambda312_ (DinoUiApplication* self);
VALA_EXTERN void dino_ui_main_window_loop_conversations (DinoUiMainWindow* self,
                                             gboolean backwards);
static void ___lambda312__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
static void __lambda313_ (DinoUiApplication* self);
static void ___lambda313__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
static void __lambda314_ (DinoUiApplication* self,
                   GVariant* variant);
VALA_EXTERN GType dino_ui_call_window_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiCallWindow, g_object_unref)
VALA_EXTERN DinoUiCallWindow* dino_ui_call_window_new (void);
VALA_EXTERN DinoUiCallWindow* dino_ui_call_window_construct (GType object_type);
VALA_EXTERN DinoUiCallWindowController* dino_ui_call_window_controller_new (DinoUiCallWindow* call_window,
                                                                DinoCallState* call_state,
                                                                DinoStreamInteractor* stream_interactor);
VALA_EXTERN DinoUiCallWindowController* dino_ui_call_window_controller_construct (GType object_type,
                                                                      DinoUiCallWindow* call_window,
                                                                      DinoCallState* call_state,
                                                                      DinoStreamInteractor* stream_interactor);
VALA_EXTERN GType dino_ui_call_window_controller_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiCallWindowController, g_object_unref)
VALA_EXTERN GType dino_ui_call_bottom_bar_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiCallBottomBar, g_object_unref)
static void ___lambda314__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
static void __lambda315_ (DinoUiApplication* self,
                   GVariant* variant);
static void ___lambda315__g_simple_action_activate (GSimpleAction* _sender,
                                             GVariant* parameter,
                                             gpointer self);
VALA_EXTERN GType dino_ui_preferences_window_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiPreferencesWindow, g_object_unref)
VALA_EXTERN DinoUiPreferencesWindow* dino_ui_preferences_window_new (void);
VALA_EXTERN DinoUiPreferencesWindow* dino_ui_preferences_window_construct (GType object_type);
VALA_EXTERN GType dino_ui_view_model_preferences_window_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiViewModelPreferencesWindow, g_object_unref)
VALA_EXTERN DinoUiViewModelPreferencesWindow* dino_ui_preferences_window_get_model (DinoUiPreferencesWindow* self);
VALA_EXTERN void dino_ui_view_model_preferences_window_populate (DinoUiViewModelPreferencesWindow* self,
                                                     DinoDatabase* db,
                                                     DinoStreamInteractor* stream_interactor);
VALA_EXTERN GType dino_ui_preferences_window_accounts_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiPreferencesWindowAccounts, g_object_unref)
VALA_EXTERN GType dino_ui_preferences_window_encryption_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiPreferencesWindowEncryption, g_object_unref)
VALA_EXTERN GType dino_ui_general_preferences_page_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiGeneralPreferencesPage, g_object_unref)
VALA_EXTERN GType dino_ui_account_preferences_subpage_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiAccountPreferencesSubpage, g_object_unref)
static Block9Data* block9_data_ref (Block9Data* _data9_);
static void block9_data_unref (void * _userdata_);
VALA_EXTERN GType dino_ui_conference_details_fragment_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (DinoUiConferenceDetailsFragment, g_object_unref)
VALA_EXTERN DinoUiConferenceDetailsFragment* dino_ui_conference_details_fragment_new (DinoStreamInteractor* stream_interactor);
VALA_EXTERN DinoUiConferenceDetailsFragment* dino_ui_conference_details_fragment_construct (GType object_type,
                                                                                DinoStreamInteractor* stream_interactor);
VALA_EXTERN void dino_ui_conference_details_fragment_set_ok_button (DinoUiConferenceDetailsFragment* self,
                                                        GtkButton* value);
VALA_EXTERN void dino_ui_conference_details_fragment_set_jid (DinoUiConferenceDetailsFragment* self,
                                                  const gchar* value);
VALA_EXTERN void dino_ui_conference_details_fragment_set_account (DinoUiConferenceDetailsFragment* self,
                                                      DinoEntitiesAccount* value);
static void __lambda309_ (Block9Data* _data9_);
static void ___lambda309__dino_ui_conference_details_fragment_joined (DinoUiConferenceDetailsFragment* _sender,
                                                               gpointer self);
static void __lambda310_ (Block9Data* _data9_,
                   gint response_id);
static void ___lambda310__gtk_dialog_response (GtkDialog* _sender,
                                        gint response_id,
                                        gpointer self);
static void dino_ui_application_finalize (GObject * obj);
static GType dino_ui_application_get_type_once (void);
static void _vala_dino_ui_application_get_property (GObject * object,
                                             guint property_id,
                                             GValue * value,
                                             GParamSpec * pspec);
static void _vala_dino_ui_application_set_property (GObject * object,
                                             guint property_id,
                                             const GValue * value,
                                             GParamSpec * pspec);
static void _vala_array_destroy (gpointer array,
                          gssize array_length,
                          GDestroyNotify destroy_func);
static void _vala_array_free (gpointer array,
                       gssize array_length,
                       GDestroyNotify destroy_func);

static const gchar* DINO_UI_APPLICATION_KEY_COMBINATION_QUIT[2] = {"<Ctrl>Q", NULL};
static const gchar* DINO_UI_APPLICATION_KEY_COMBINATION_ADD_CHAT[2] = {"<Ctrl>T", NULL};
static const gchar* DINO_UI_APPLICATION_KEY_COMBINATION_ADD_CONFERENCE[2] = {"<Ctrl>G", NULL};
static const gchar* DINO_UI_APPLICATION_KEY_COMBINATION_LOOP_CONVERSATIONS[2] = {"<Ctrl>Tab", NULL};
static const gchar* DINO_UI_APPLICATION_KEY_COMBINATION_LOOP_CONVERSATIONS_REV[2] = {"<Ctrl><Shift>Tab", NULL};
static const gchar* DINO_UI_APPLICATION_KEY_COMBINATION_SHOW_SETTINGS[2] = {"<Ctrl>comma", NULL};
static const GOptionEntry DINO_UI_APPLICATION_options[2] = {{"version", (gchar) 0, (gint) 0, G_OPTION_ARG_NONE, &dino_ui_application_print_version, "Display version number", NULL}, {NULL}};

static inline gpointer
dino_ui_application_get_instance_private (DinoUiApplication* self)
{
	return G_STRUCT_MEMBER_P (self, DinoUiApplication_private_offset);
}

static Block8Data*
block8_data_ref (Block8Data* _data8_)
{
	g_atomic_int_inc (&_data8_->_ref_count_);
	return _data8_;
}

static void
block8_data_unref (void * _userdata_)
{
	Block8Data* _data8_;
	_data8_ = (Block8Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data8_->_ref_count_)) {
		DinoUiApplication* self;
		self = _data8_->self;
		_g_object_unref0 (_data8_->notification_events);
		_g_object_unref0 (self);
		g_slice_free (Block8Data, _data8_);
	}
}

static const gchar*
string_to_string (const gchar* self)
{
	const gchar* result;
	g_return_val_if_fail (self != NULL, NULL);
	result = self;
	return result;
}

static void
__lambda317_ (Block8Data* _data8_,
              GObject* _,
              GAsyncResult* res)
{
	DinoUiApplication* self;
	GError* _inner_error0_ = NULL;
	self = _data8_->self;
	g_return_if_fail (res != NULL);
	{
		DinoDBusNotifications* dbus_notifications = NULL;
		DinoDBusNotifications* _tmp0_;
		DinoDBusNotifications* _tmp1_;
		_tmp0_ = dino_get_notifications_dbus_finish (res);
		dbus_notifications = _tmp0_;
		_tmp1_ = dbus_notifications;
		if (_tmp1_ != NULL) {
			DinoUiFreeDesktopNotifier* free_desktop_notifier = NULL;
			DinoStreamInteractor* _tmp2_;
			DinoStreamInteractor* _tmp3_;
			DinoDBusNotifications* _tmp4_;
			DinoUiFreeDesktopNotifier* _tmp5_;
			DinoUiFreeDesktopNotifier* _tmp6_;
			_tmp2_ = dino_application_get_stream_interactor ((DinoApplication*) self);
			_tmp3_ = _tmp2_;
			_tmp4_ = dbus_notifications;
			_tmp5_ = dino_ui_free_desktop_notifier_new (_tmp3_, _tmp4_);
			free_desktop_notifier = _tmp5_;
			_tmp6_ = free_desktop_notifier;
			dino_notification_events_register_notification_provider (_data8_->notification_events, (DinoNotificationProvider*) _tmp6_, NULL, NULL);
			_g_object_unref0 (free_desktop_notifier);
		} else {
			DinoStreamInteractor* _tmp7_;
			DinoStreamInteractor* _tmp8_;
			DinoUiGNotificationsNotifier* _tmp9_;
			DinoUiGNotificationsNotifier* _tmp10_;
			_tmp7_ = dino_application_get_stream_interactor ((DinoApplication*) self);
			_tmp8_ = _tmp7_;
			_tmp9_ = dino_ui_gnotifications_notifier_new (_tmp8_);
			_tmp10_ = _tmp9_;
			dino_notification_events_register_notification_provider (_data8_->notification_events, (DinoNotificationProvider*) _tmp10_, NULL, NULL);
			_g_object_unref0 (_tmp10_);
		}
		_g_object_unref0 (dbus_notifications);
	}
	goto __finally0;
	__catch0_g_error:
	{
		GError* e = NULL;
		GError* _tmp11_;
		const gchar* _tmp12_;
		e = _inner_error0_;
		_inner_error0_ = NULL;
		_tmp11_ = e;
		_tmp12_ = _tmp11_->message;
		g_debug ("application.vala:58: Failed accessing fdo notification server: %s", _tmp12_);
		_g_error_free0 (e);
	}
	__finally0:
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
		g_clear_error (&_inner_error0_);
		return;
	}
}

static void
___lambda317__gasync_ready_callback (GObject* source_object,
                                     GAsyncResult* res,
                                     gpointer self)
{
	__lambda317_ (self, source_object, res);
	block8_data_unref (self);
}

static gboolean
string_contains (const gchar* self,
                 const gchar* needle)
{
	gchar* _tmp0_;
	gboolean result;
	g_return_val_if_fail (self != NULL, FALSE);
	g_return_val_if_fail (needle != NULL, FALSE);
	_tmp0_ = strstr ((gchar*) self, (gchar*) needle);
	result = _tmp0_ != NULL;
	return result;
}

static void
__lambda333_ (DinoUiApplication* self,
              DinoContentItem* content_item,
              DinoEntitiesConversation* conversation)
{
	gchar* desktop_env = NULL;
	const gchar* _tmp0_;
	gchar* _tmp1_;
	gboolean _tmp2_ = FALSE;
	const gchar* _tmp3_;
	g_return_if_fail (content_item != NULL);
	g_return_if_fail (conversation != NULL);
	_tmp0_ = g_getenv ("XDG_CURRENT_DESKTOP");
	_tmp1_ = g_strdup (_tmp0_);
	desktop_env = _tmp1_;
	_tmp3_ = desktop_env;
	if (_tmp3_ == NULL) {
		_tmp2_ = TRUE;
	} else {
		const gchar* _tmp4_;
		gchar* _tmp5_;
		gchar* _tmp6_;
		_tmp4_ = desktop_env;
		_tmp5_ = g_utf8_strdown (_tmp4_, (gssize) -1);
		_tmp6_ = _tmp5_;
		_tmp2_ = !string_contains (_tmp6_, "gnome");
		_g_free0 (_tmp6_);
	}
	if (_tmp2_) {
		GtkWindow* _tmp7_;
		GtkWindow* _tmp8_;
		_tmp7_ = gtk_application_get_active_window ((GtkApplication*) self);
		_tmp8_ = _tmp7_;
		if (_tmp8_ != NULL) {
		}
	}
	_g_free0 (desktop_env);
}

static void
___lambda333__dino_notification_events_notify_content_item (DinoNotificationEvents* _sender,
                                                            DinoContentItem* content_item,
                                                            DinoEntitiesConversation* conversation,
                                                            gpointer self)
{
	__lambda333_ ((DinoUiApplication*) self, content_item, conversation);
}

static void
__lambda316_ (DinoUiApplication* self)
{
	Block8Data* _data8_;
	DinoStreamInteractor* _tmp5_;
	DinoStreamInteractor* _tmp6_;
	DinoModuleIdentity* _tmp7_;
	gpointer _tmp8_;
	DinoStreamInteractor* _tmp9_;
	DinoStreamInteractor* _tmp10_;
	DinoModuleIdentity* _tmp11_;
	gpointer _tmp12_;
	DinoFileManager* _tmp13_;
	DinoUiUtilAudioVideoFileMetadataProvider* _tmp14_;
	DinoUiUtilAudioVideoFileMetadataProvider* _tmp15_;
	_data8_ = g_slice_new0 (Block8Data);
	_data8_->_ref_count_ = 1;
	_data8_->self = g_object_ref (self);
	if (dino_ui_application_print_version) {
		gchar* _tmp0_;
		gchar* _tmp1_;
		const gchar* _tmp2_;
		gchar* _tmp3_;
		gchar* _tmp4_;
		_tmp0_ = dino_get_version ();
		_tmp1_ = _tmp0_;
		_tmp2_ = string_to_string (_tmp1_);
		_tmp3_ = g_strconcat ("Dino ", _tmp2_, "\n", NULL);
		_tmp4_ = _tmp3_;
		g_print ("%s", _tmp4_);
		_g_free0 (_tmp4_);
		_g_free0 (_tmp1_);
		exit (0);
	}
	_tmp5_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp6_ = _tmp5_;
	_tmp7_ = dino_notification_events_IDENTITY;
	_tmp8_ = dino_stream_interactor_get_module (_tmp6_, DINO_TYPE_NOTIFICATION_EVENTS, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp7_);
	_data8_->notification_events = (DinoNotificationEvents*) _tmp8_;
	dino_get_notifications_dbus (___lambda317__gasync_ready_callback, block8_data_ref (_data8_));
	g_signal_connect_object (_data8_->notification_events, "notify-content-item", (GCallback) ___lambda333__dino_notification_events_notify_content_item, self, 0);
	_tmp9_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp10_ = _tmp9_;
	_tmp11_ = dino_file_manager_IDENTITY;
	_tmp12_ = dino_stream_interactor_get_module (_tmp10_, DINO_TYPE_FILE_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp11_);
	_tmp13_ = (DinoFileManager*) _tmp12_;
	_tmp14_ = dino_ui_util_audio_video_file_metadata_provider_new ();
	_tmp15_ = _tmp14_;
	dino_file_manager_add_metadata_provider (_tmp13_, (DinoFileMetadataProvider*) _tmp15_);
	_g_object_unref0 (_tmp15_);
	_g_object_unref0 (_tmp13_);
	block8_data_unref (_data8_);
	_data8_ = NULL;
}

static void
___lambda316__g_application_startup (GApplication* _sender,
                                     gpointer self)
{
	__lambda316_ ((DinoUiApplication*) self);
}

static void
__lambda335_ (DinoUiApplication* self)
{
	DinoUiMainWindow* _tmp0_;
	DinoUiMainWindow* _tmp19_;
	_tmp0_ = self->window;
	if (_tmp0_ == NULL) {
		DinoStreamInteractor* _tmp1_;
		DinoStreamInteractor* _tmp2_;
		DinoDatabase* _tmp3_;
		DinoDatabase* _tmp4_;
		DinoUiMainWindowController* _tmp5_;
		DinoDatabase* _tmp6_;
		DinoDatabase* _tmp7_;
		DinoUiConfig* _tmp8_;
		DinoUiConfig* _tmp9_;
		DinoStreamInteractor* _tmp10_;
		DinoStreamInteractor* _tmp11_;
		DinoDatabase* _tmp12_;
		DinoDatabase* _tmp13_;
		DinoUiConfig* _tmp14_;
		DinoUiMainWindow* _tmp15_;
		DinoUiMainWindowController* _tmp16_;
		DinoUiMainWindow* _tmp17_;
		_tmp1_ = dino_application_get_stream_interactor ((DinoApplication*) self);
		_tmp2_ = _tmp1_;
		_tmp3_ = dino_application_get_db ((DinoApplication*) self);
		_tmp4_ = _tmp3_;
		_tmp5_ = dino_ui_main_window_controller_new (self, _tmp2_, _tmp4_);
		_g_object_unref0 (self->controller);
		self->controller = _tmp5_;
		_tmp6_ = dino_application_get_db ((DinoApplication*) self);
		_tmp7_ = _tmp6_;
		_tmp8_ = dino_ui_config_new (_tmp7_);
		_tmp9_ = _tmp8_;
		dino_ui_application_set_config (self, _tmp9_);
		_g_object_unref0 (_tmp9_);
		_tmp10_ = dino_application_get_stream_interactor ((DinoApplication*) self);
		_tmp11_ = _tmp10_;
		_tmp12_ = dino_application_get_db ((DinoApplication*) self);
		_tmp13_ = _tmp12_;
		_tmp14_ = self->priv->_config;
		_tmp15_ = dino_ui_main_window_new (self, _tmp11_, _tmp13_, _tmp14_);
		g_object_ref_sink (_tmp15_);
		_g_object_unref0 (self->window);
		self->window = _tmp15_;
		_tmp16_ = self->controller;
		_tmp17_ = self->window;
		dino_ui_main_window_controller_set_window (_tmp16_, _tmp17_);
		if ((g_application_get_flags ((GApplication*) self) & G_APPLICATION_IS_SERVICE) == G_APPLICATION_IS_SERVICE) {
			DinoUiMainWindow* _tmp18_;
			_tmp18_ = self->window;
			gtk_window_set_hide_on_close ((GtkWindow*) _tmp18_, TRUE);
		}
	}
	_tmp19_ = self->window;
	gtk_window_present ((GtkWindow*) _tmp19_);
}

static void
___lambda335__g_application_activate (GApplication* _sender,
                                      gpointer self)
{
	__lambda335_ ((DinoUiApplication*) self);
}

DinoUiApplication*
dino_ui_application_construct (GType object_type,
                               GError** error)
{
	DinoUiApplication * self = NULL;
	GError* _inner_error0_ = NULL;
	self = (DinoUiApplication*) g_object_new (object_type, "application-id", "im.dino.Dino", "flags", G_APPLICATION_HANDLES_OPEN, NULL);
	dino_application_init ((DinoApplication*) self, &_inner_error0_);
	if (G_UNLIKELY (_inner_error0_ != NULL)) {
		g_propagate_error (error, _inner_error0_);
		_g_object_unref0 (self);
		return NULL;
	}
	g_set_application_name ("Dino");
	gtk_window_set_default_icon_name ("im.dino.Dino");
	dino_ui_application_create_actions (self);
	g_application_add_main_option_entries ((GApplication*) self, DINO_UI_APPLICATION_options);
	g_signal_connect_object ((GApplication*) self, "startup", (GCallback) ___lambda316__g_application_startup, self, 0);
	g_signal_connect_object ((GApplication*) self, "activate", (GCallback) ___lambda335__g_application_activate, self, 0);
	return self;
}

DinoUiApplication*
dino_ui_application_new (GError** error)
{
	return dino_ui_application_construct (DINO_UI_TYPE_APPLICATION, error);
}

static void
____lambda336_ (DinoUiApplication* self,
                DinoEntitiesConversation* conversation)
{
	DinoUiMainWindowController* _tmp0_;
	g_return_if_fail (conversation != NULL);
	_tmp0_ = self->controller;
	dino_ui_main_window_controller_select_conversation (_tmp0_, conversation, TRUE, TRUE);
}

static void
_____lambda336__dino_ui_add_chat_dialog_added (DinoUiAddChatDialog* _sender,
                                               DinoEntitiesConversation* conversation,
                                               gpointer self)
{
	____lambda336_ ((DinoUiApplication*) self, conversation);
}

static void
dino_ui_application_real_handle_uri (DinoApplication* base,
                                     const gchar* jid,
                                     const gchar* query,
                                     GeeMap* options)
{
	DinoUiApplication * self;
	const gchar* _tmp0_;
	GQuark _tmp2_ = 0U;
	static GQuark _tmp1_label0 = 0;
	static GQuark _tmp1_label1 = 0;
	GError* _inner_error0_ = NULL;
	self = (DinoUiApplication*) base;
	g_return_if_fail (jid != NULL);
	g_return_if_fail (query != NULL);
	g_return_if_fail (options != NULL);
	_tmp0_ = query;
	_tmp2_ = (NULL == _tmp0_) ? 0 : g_quark_from_string (_tmp0_);
	if (_tmp2_ == ((0 != _tmp1_label0) ? _tmp1_label0 : (_tmp1_label0 = g_quark_from_static_string ("join")))) {
		switch (0) {
			default:
			{
				dino_ui_application_show_join_muc_dialog (self, NULL, jid);
				break;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label1) ? _tmp1_label1 : (_tmp1_label1 = g_quark_from_static_string ("message")))) {
		switch (0) {
			default:
			{
				GeeList* accounts = NULL;
				DinoStreamInteractor* _tmp3_;
				DinoStreamInteractor* _tmp4_;
				GeeArrayList* _tmp5_;
				XmppJid* parsed_jid = NULL;
				gboolean _tmp9_ = FALSE;
				GeeList* _tmp10_;
				gint _tmp11_;
				gint _tmp12_;
				_tmp3_ = dino_application_get_stream_interactor ((DinoApplication*) self);
				_tmp4_ = _tmp3_;
				_tmp5_ = dino_stream_interactor_get_accounts (_tmp4_);
				accounts = (GeeList*) _tmp5_;
				parsed_jid = NULL;
				{
					XmppJid* _tmp6_ = NULL;
					XmppJid* _tmp7_;
					XmppJid* _tmp8_;
					_tmp7_ = xmpp_jid_new (jid, &_inner_error0_);
					_tmp6_ = _tmp7_;
					if (G_UNLIKELY (_inner_error0_ != NULL)) {
						if (_inner_error0_->domain == XMPP_INVALID_JID_ERROR) {
							goto __catch0_xmpp_invalid_jid_error;
						}
						_xmpp_jid_unref0 (parsed_jid);
						_g_object_unref0 (accounts);
						g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
						g_clear_error (&_inner_error0_);
						return;
					}
					_tmp8_ = _tmp6_;
					_tmp6_ = NULL;
					_xmpp_jid_unref0 (parsed_jid);
					parsed_jid = _tmp8_;
					_xmpp_jid_unref0 (_tmp6_);
				}
				goto __finally0;
				__catch0_xmpp_invalid_jid_error:
				{
					g_clear_error (&_inner_error0_);
				}
				__finally0:
				if (G_UNLIKELY (_inner_error0_ != NULL)) {
					_xmpp_jid_unref0 (parsed_jid);
					_g_object_unref0 (accounts);
					g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
					g_clear_error (&_inner_error0_);
					return;
				}
				_tmp10_ = accounts;
				_tmp11_ = gee_collection_get_size ((GeeCollection*) _tmp10_);
				_tmp12_ = _tmp11_;
				if (_tmp12_ == 1) {
					XmppJid* _tmp13_;
					_tmp13_ = parsed_jid;
					_tmp9_ = _tmp13_ != NULL;
				} else {
					_tmp9_ = FALSE;
				}
				if (_tmp9_) {
					DinoEntitiesConversation* conversation = NULL;
					DinoStreamInteractor* _tmp14_;
					DinoStreamInteractor* _tmp15_;
					DinoModuleIdentity* _tmp16_;
					gpointer _tmp17_;
					DinoConversationManager* _tmp18_;
					XmppJid* _tmp19_;
					GeeList* _tmp20_;
					gpointer _tmp21_;
					DinoEntitiesAccount* _tmp22_;
					DinoEntitiesConversationType _tmp23_;
					DinoEntitiesConversation* _tmp24_;
					DinoEntitiesConversation* _tmp25_;
					DinoStreamInteractor* _tmp26_;
					DinoStreamInteractor* _tmp27_;
					DinoModuleIdentity* _tmp28_;
					gpointer _tmp29_;
					DinoConversationManager* _tmp30_;
					DinoEntitiesConversation* _tmp31_;
					DinoUiMainWindowController* _tmp32_;
					DinoEntitiesConversation* _tmp33_;
					_tmp14_ = dino_application_get_stream_interactor ((DinoApplication*) self);
					_tmp15_ = _tmp14_;
					_tmp16_ = dino_conversation_manager_IDENTITY;
					_tmp17_ = dino_stream_interactor_get_module (_tmp15_, DINO_TYPE_CONVERSATION_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp16_);
					_tmp18_ = (DinoConversationManager*) _tmp17_;
					_tmp19_ = parsed_jid;
					_tmp20_ = accounts;
					_tmp21_ = gee_list_get (_tmp20_, 0);
					_tmp22_ = (DinoEntitiesAccount*) _tmp21_;
					_tmp23_ = DINO_ENTITIES_CONVERSATION_TYPE_CHAT;
					_tmp24_ = dino_conversation_manager_create_conversation (_tmp18_, _tmp19_, _tmp22_, &_tmp23_);
					_tmp25_ = _tmp24_;
					_g_object_unref0 (_tmp22_);
					_g_object_unref0 (_tmp18_);
					conversation = _tmp25_;
					_tmp26_ = dino_application_get_stream_interactor ((DinoApplication*) self);
					_tmp27_ = _tmp26_;
					_tmp28_ = dino_conversation_manager_IDENTITY;
					_tmp29_ = dino_stream_interactor_get_module (_tmp27_, DINO_TYPE_CONVERSATION_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp28_);
					_tmp30_ = (DinoConversationManager*) _tmp29_;
					_tmp31_ = conversation;
					dino_conversation_manager_start_conversation (_tmp30_, _tmp31_);
					_g_object_unref0 (_tmp30_);
					_tmp32_ = self->controller;
					_tmp33_ = conversation;
					dino_ui_main_window_controller_select_conversation (_tmp32_, _tmp33_, TRUE, TRUE);
					_g_object_unref0 (conversation);
				} else {
					DinoUiAddChatDialog* dialog = NULL;
					DinoStreamInteractor* _tmp34_;
					DinoStreamInteractor* _tmp35_;
					DinoStreamInteractor* _tmp36_;
					DinoStreamInteractor* _tmp37_;
					GeeArrayList* _tmp38_;
					GeeArrayList* _tmp39_;
					DinoUiAddChatDialog* _tmp40_;
					DinoUiAddChatDialog* _tmp41_;
					DinoUiAddChatDialog* _tmp42_;
					DinoUiAddChatDialog* _tmp43_;
					DinoUiMainWindow* _tmp44_;
					DinoUiAddChatDialog* _tmp45_;
					DinoUiAddChatDialog* _tmp46_;
					_tmp34_ = dino_application_get_stream_interactor ((DinoApplication*) self);
					_tmp35_ = _tmp34_;
					_tmp36_ = dino_application_get_stream_interactor ((DinoApplication*) self);
					_tmp37_ = _tmp36_;
					_tmp38_ = dino_stream_interactor_get_accounts (_tmp37_);
					_tmp39_ = _tmp38_;
					_tmp40_ = dino_ui_add_chat_dialog_new (_tmp35_, (GeeList*) _tmp39_);
					g_object_ref_sink (_tmp40_);
					_tmp41_ = _tmp40_;
					_g_object_unref0 (_tmp39_);
					dialog = _tmp41_;
					_tmp42_ = dialog;
					dino_ui_select_contact_dialog_set_filter ((DinoUiSelectContactDialog*) _tmp42_, jid);
					_tmp43_ = dialog;
					_tmp44_ = self->window;
					gtk_window_set_transient_for ((GtkWindow*) _tmp43_, (GtkWindow*) _tmp44_);
					_tmp45_ = dialog;
					g_signal_connect_object (_tmp45_, "added", (GCallback) _____lambda336__dino_ui_add_chat_dialog_added, self, 0);
					_tmp46_ = dialog;
					gtk_window_present ((GtkWindow*) _tmp46_);
					_g_object_unref0 (dialog);
				}
				_xmpp_jid_unref0 (parsed_jid);
				_g_object_unref0 (accounts);
				break;
			}
		}
	}
}

static void
_dino_ui_application_show_preferences_window_g_simple_action_activate (GSimpleAction* _sender,
                                                                       GVariant* parameter,
                                                                       gpointer self)
{
	dino_ui_application_show_preferences_window ((DinoUiApplication*) self);
}

static void
__lambda283_ (DinoUiApplication* self,
              GVariant* variant)
{
	DinoEntitiesAccount* account = NULL;
	DinoDatabase* _tmp0_;
	DinoDatabase* _tmp1_;
	DinoEntitiesAccount* _tmp2_;
	DinoEntitiesAccount* _tmp3_;
	DinoEntitiesAccount* _tmp4_;
	_tmp0_ = dino_application_get_db ((DinoApplication*) self);
	_tmp1_ = _tmp0_;
	_tmp2_ = dino_database_get_account_by_id (_tmp1_, (gint) g_variant_get_int32 (variant));
	account = _tmp2_;
	_tmp3_ = account;
	if (_tmp3_ == NULL) {
		_g_object_unref0 (account);
		return;
	}
	_tmp4_ = account;
	dino_ui_application_show_preferences_account_window (self, _tmp4_);
	_g_object_unref0 (account);
}

static void
___lambda283__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda283_ ((DinoUiApplication*) self, parameter);
}

static void
_dino_ui_application_show_about_window_g_simple_action_activate (GSimpleAction* _sender,
                                                                 GVariant* parameter,
                                                                 gpointer self)
{
	dino_ui_application_show_about_window ((DinoUiApplication*) self);
}

static void
_g_application_quit_g_simple_action_activate (GSimpleAction* _sender,
                                              GVariant* parameter,
                                              gpointer self)
{
	g_application_quit ((GApplication*) self);
}

static void
__lambda284_ (DinoUiApplication* self,
              GVariant* variant)
{
	DinoEntitiesConversation* conversation = NULL;
	DinoStreamInteractor* _tmp0_;
	DinoStreamInteractor* _tmp1_;
	DinoModuleIdentity* _tmp2_;
	gpointer _tmp3_;
	DinoConversationManager* _tmp4_;
	DinoEntitiesConversation* _tmp5_;
	DinoEntitiesConversation* _tmp6_;
	DinoEntitiesConversation* _tmp7_;
	DinoUiMainWindow* _tmp10_;
	_tmp0_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp1_ = _tmp0_;
	_tmp2_ = dino_conversation_manager_IDENTITY;
	_tmp3_ = dino_stream_interactor_get_module (_tmp1_, DINO_TYPE_CONVERSATION_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp2_);
	_tmp4_ = (DinoConversationManager*) _tmp3_;
	_tmp5_ = dino_conversation_manager_get_conversation_by_id (_tmp4_, (gint) g_variant_get_int32 (variant));
	_tmp6_ = _tmp5_;
	_g_object_unref0 (_tmp4_);
	conversation = _tmp6_;
	_tmp7_ = conversation;
	if (_tmp7_ != NULL) {
		DinoUiMainWindowController* _tmp8_;
		DinoEntitiesConversation* _tmp9_;
		_tmp8_ = self->controller;
		_tmp9_ = conversation;
		dino_ui_main_window_controller_select_conversation (_tmp8_, _tmp9_, TRUE, TRUE);
	}
	_tmp10_ = self->window;
	dino_ui_util_present_window ((GtkWindow*) _tmp10_);
	_g_object_unref0 (conversation);
}

static void
___lambda284__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda284_ ((DinoUiApplication*) self, parameter);
}

static gpointer
_g_variant_type_copy0 (gpointer self)
{
	return self ? g_variant_type_copy (self) : NULL;
}

static void
__lambda285_ (DinoUiApplication* self,
              GVariant* variant)
{
	gint conversation_id = 0;
	GVariant* _tmp0_;
	GVariant* _tmp1_;
	gint _tmp2_;
	DinoEntitiesConversation* conversation = NULL;
	DinoStreamInteractor* _tmp3_;
	DinoStreamInteractor* _tmp4_;
	DinoModuleIdentity* _tmp5_;
	gpointer _tmp6_;
	DinoConversationManager* _tmp7_;
	DinoEntitiesConversation* _tmp8_;
	DinoEntitiesConversation* _tmp9_;
	DinoEntitiesConversation* _tmp10_;
	gchar* stack_value = NULL;
	GVariant* _tmp11_;
	GVariant* _tmp12_;
	const gchar* _tmp13_;
	gchar* _tmp14_;
	gchar* _tmp15_;
	DinoUiConversationDetailsDialog* conversation_details = NULL;
	DinoEntitiesConversation* _tmp16_;
	DinoStreamInteractor* _tmp17_;
	DinoStreamInteractor* _tmp18_;
	DinoUiMainWindow* _tmp19_;
	DinoUiConversationDetailsDialog* _tmp20_;
	DinoUiConversationDetailsDialog* _tmp21_;
	GtkStack* _tmp22_;
	const gchar* _tmp23_;
	DinoUiConversationDetailsDialog* _tmp24_;
	_tmp0_ = g_variant_get_child_value (variant, (gsize) 0);
	_tmp1_ = _tmp0_;
	_tmp2_ = (gint) g_variant_get_int32 (_tmp1_);
	_g_variant_unref0 (_tmp1_);
	conversation_id = _tmp2_;
	_tmp3_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp4_ = _tmp3_;
	_tmp5_ = dino_conversation_manager_IDENTITY;
	_tmp6_ = dino_stream_interactor_get_module (_tmp4_, DINO_TYPE_CONVERSATION_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp5_);
	_tmp7_ = (DinoConversationManager*) _tmp6_;
	_tmp8_ = dino_conversation_manager_get_conversation_by_id (_tmp7_, conversation_id);
	_tmp9_ = _tmp8_;
	_g_object_unref0 (_tmp7_);
	conversation = _tmp9_;
	_tmp10_ = conversation;
	if (_tmp10_ == NULL) {
		_g_object_unref0 (conversation);
		return;
	}
	_tmp11_ = g_variant_get_child_value (variant, (gsize) 1);
	_tmp12_ = _tmp11_;
	_tmp13_ = g_variant_get_string (_tmp12_, NULL);
	_tmp14_ = g_strdup (_tmp13_);
	_tmp15_ = _tmp14_;
	_g_variant_unref0 (_tmp12_);
	stack_value = _tmp15_;
	_tmp16_ = conversation;
	_tmp17_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp18_ = _tmp17_;
	_tmp19_ = self->window;
	_tmp20_ = dino_ui_conversation_details_setup_dialog (_tmp16_, _tmp18_, (GtkWindow*) _tmp19_);
	conversation_details = _tmp20_;
	_tmp21_ = conversation_details;
	_tmp22_ = _tmp21_->stack;
	_tmp23_ = stack_value;
	gtk_stack_set_visible_child_name (_tmp22_, _tmp23_);
	_tmp24_ = conversation_details;
	gtk_window_present ((GtkWindow*) _tmp24_);
	_g_object_unref0 (conversation_details);
	_g_free0 (stack_value);
	_g_object_unref0 (conversation);
}

static void
___lambda285__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda285_ ((DinoUiApplication*) self, parameter);
}

static void
__lambda286_ (DinoUiApplication* self,
              GVariant* variant)
{
	DinoEntitiesConversation* conversation = NULL;
	DinoStreamInteractor* _tmp0_;
	DinoStreamInteractor* _tmp1_;
	DinoModuleIdentity* _tmp2_;
	gpointer _tmp3_;
	DinoConversationManager* _tmp4_;
	DinoEntitiesConversation* _tmp5_;
	DinoEntitiesConversation* _tmp6_;
	DinoEntitiesConversation* _tmp7_;
	DinoStreamInteractor* _tmp8_;
	DinoStreamInteractor* _tmp9_;
	DinoModuleIdentity* _tmp10_;
	gpointer _tmp11_;
	DinoPresenceManager* _tmp12_;
	DinoEntitiesConversation* _tmp13_;
	DinoEntitiesAccount* _tmp14_;
	DinoEntitiesAccount* _tmp15_;
	DinoEntitiesConversation* _tmp16_;
	XmppJid* _tmp17_;
	XmppJid* _tmp18_;
	_tmp0_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp1_ = _tmp0_;
	_tmp2_ = dino_conversation_manager_IDENTITY;
	_tmp3_ = dino_stream_interactor_get_module (_tmp1_, DINO_TYPE_CONVERSATION_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp2_);
	_tmp4_ = (DinoConversationManager*) _tmp3_;
	_tmp5_ = dino_conversation_manager_get_conversation_by_id (_tmp4_, (gint) g_variant_get_int32 (variant));
	_tmp6_ = _tmp5_;
	_g_object_unref0 (_tmp4_);
	conversation = _tmp6_;
	_tmp7_ = conversation;
	if (_tmp7_ == NULL) {
		_g_object_unref0 (conversation);
		return;
	}
	_tmp8_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp9_ = _tmp8_;
	_tmp10_ = dino_presence_manager_IDENTITY;
	_tmp11_ = dino_stream_interactor_get_module (_tmp9_, DINO_TYPE_PRESENCE_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp10_);
	_tmp12_ = (DinoPresenceManager*) _tmp11_;
	_tmp13_ = conversation;
	_tmp14_ = dino_entities_conversation_get_account (_tmp13_);
	_tmp15_ = _tmp14_;
	_tmp16_ = conversation;
	_tmp17_ = dino_entities_conversation_get_counterpart (_tmp16_);
	_tmp18_ = _tmp17_;
	dino_presence_manager_deny_subscription (_tmp12_, _tmp15_, _tmp18_);
	_g_object_unref0 (_tmp12_);
	_g_object_unref0 (conversation);
}

static void
___lambda286__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda286_ ((DinoUiApplication*) self, parameter);
}

static void
__lambda289_ (DinoUiApplication* self,
              DinoEntitiesConversation* conversation)
{
	DinoUiMainWindowController* _tmp0_;
	g_return_if_fail (conversation != NULL);
	_tmp0_ = self->controller;
	dino_ui_main_window_controller_select_conversation (_tmp0_, conversation, TRUE, TRUE);
}

static void
___lambda289__dino_ui_add_chat_dialog_added (DinoUiAddChatDialog* _sender,
                                             DinoEntitiesConversation* conversation,
                                             gpointer self)
{
	__lambda289_ ((DinoUiApplication*) self, conversation);
}

static void
__lambda287_ (DinoUiApplication* self)
{
	DinoUiAddChatDialog* add_chat_dialog = NULL;
	DinoStreamInteractor* _tmp0_;
	DinoStreamInteractor* _tmp1_;
	DinoStreamInteractor* _tmp2_;
	DinoStreamInteractor* _tmp3_;
	GeeArrayList* _tmp4_;
	GeeArrayList* _tmp5_;
	DinoUiAddChatDialog* _tmp6_;
	DinoUiAddChatDialog* _tmp7_;
	DinoUiMainWindow* _tmp8_;
	_tmp0_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp1_ = _tmp0_;
	_tmp2_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp3_ = _tmp2_;
	_tmp4_ = dino_stream_interactor_get_accounts (_tmp3_);
	_tmp5_ = _tmp4_;
	_tmp6_ = dino_ui_add_chat_dialog_new (_tmp1_, (GeeList*) _tmp5_);
	g_object_ref_sink (_tmp6_);
	_tmp7_ = _tmp6_;
	_g_object_unref0 (_tmp5_);
	add_chat_dialog = _tmp7_;
	_tmp8_ = self->window;
	gtk_window_set_transient_for ((GtkWindow*) add_chat_dialog, (GtkWindow*) _tmp8_);
	g_signal_connect_object (add_chat_dialog, "added", (GCallback) ___lambda289__dino_ui_add_chat_dialog_added, self, 0);
	gtk_window_present ((GtkWindow*) add_chat_dialog);
	_g_object_unref0 (add_chat_dialog);
}

static void
___lambda287__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda287_ ((DinoUiApplication*) self);
}

static void
__lambda290_ (DinoUiApplication* self)
{
	DinoUiAddConferenceDialog* add_conference_dialog = NULL;
	DinoStreamInteractor* _tmp0_;
	DinoStreamInteractor* _tmp1_;
	DinoUiAddConferenceDialog* _tmp2_;
	DinoUiMainWindow* _tmp3_;
	_tmp0_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp1_ = _tmp0_;
	_tmp2_ = dino_ui_add_conference_dialog_new (_tmp1_);
	g_object_ref_sink (_tmp2_);
	add_conference_dialog = _tmp2_;
	_tmp3_ = self->window;
	gtk_window_set_transient_for ((GtkWindow*) add_conference_dialog, (GtkWindow*) _tmp3_);
	gtk_window_present ((GtkWindow*) add_conference_dialog);
	_g_object_unref0 (add_conference_dialog);
}

static void
___lambda290__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda290_ ((DinoUiApplication*) self);
}

static void
__lambda308_ (DinoUiApplication* self,
              GVariant* variant)
{
	DinoEntitiesConversation* conversation = NULL;
	DinoStreamInteractor* _tmp0_;
	DinoStreamInteractor* _tmp1_;
	DinoModuleIdentity* _tmp2_;
	gpointer _tmp3_;
	DinoConversationManager* _tmp4_;
	DinoEntitiesConversation* _tmp5_;
	DinoEntitiesConversation* _tmp6_;
	DinoEntitiesConversation* _tmp7_;
	DinoEntitiesConversation* _tmp8_;
	DinoEntitiesAccount* _tmp9_;
	DinoEntitiesAccount* _tmp10_;
	DinoEntitiesConversation* _tmp11_;
	XmppJid* _tmp12_;
	XmppJid* _tmp13_;
	gchar* _tmp14_;
	gchar* _tmp15_;
	_tmp0_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp1_ = _tmp0_;
	_tmp2_ = dino_conversation_manager_IDENTITY;
	_tmp3_ = dino_stream_interactor_get_module (_tmp1_, DINO_TYPE_CONVERSATION_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp2_);
	_tmp4_ = (DinoConversationManager*) _tmp3_;
	_tmp5_ = dino_conversation_manager_get_conversation_by_id (_tmp4_, (gint) g_variant_get_int32 (variant));
	_tmp6_ = _tmp5_;
	_g_object_unref0 (_tmp4_);
	conversation = _tmp6_;
	_tmp7_ = conversation;
	if (_tmp7_ == NULL) {
		_g_object_unref0 (conversation);
		return;
	}
	_tmp8_ = conversation;
	_tmp9_ = dino_entities_conversation_get_account (_tmp8_);
	_tmp10_ = _tmp9_;
	_tmp11_ = conversation;
	_tmp12_ = dino_entities_conversation_get_counterpart (_tmp11_);
	_tmp13_ = _tmp12_;
	_tmp14_ = xmpp_jid_to_string (_tmp13_);
	_tmp15_ = _tmp14_;
	dino_ui_application_show_join_muc_dialog (self, _tmp10_, _tmp15_);
	_g_free0 (_tmp15_);
	_g_object_unref0 (conversation);
}

static void
___lambda308__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda308_ ((DinoUiApplication*) self, parameter);
}

static void
__lambda311_ (DinoUiApplication* self,
              GVariant* variant)
{
	gint conversation_id = 0;
	GVariant* _tmp0_;
	GVariant* _tmp1_;
	gint _tmp2_;
	DinoEntitiesConversation* conversation = NULL;
	DinoStreamInteractor* _tmp3_;
	DinoStreamInteractor* _tmp4_;
	DinoModuleIdentity* _tmp5_;
	gpointer _tmp6_;
	DinoConversationManager* _tmp7_;
	DinoEntitiesConversation* _tmp8_;
	DinoEntitiesConversation* _tmp9_;
	DinoEntitiesConversation* _tmp10_;
	gchar* nick = NULL;
	GVariant* _tmp11_;
	GVariant* _tmp12_;
	const gchar* _tmp13_;
	gchar* _tmp14_;
	gchar* _tmp15_;
	DinoStreamInteractor* _tmp16_;
	DinoStreamInteractor* _tmp17_;
	DinoModuleIdentity* _tmp18_;
	gpointer _tmp19_;
	DinoMucManager* _tmp20_;
	DinoEntitiesConversation* _tmp21_;
	DinoEntitiesAccount* _tmp22_;
	DinoEntitiesAccount* _tmp23_;
	DinoEntitiesConversation* _tmp24_;
	XmppJid* _tmp25_;
	XmppJid* _tmp26_;
	const gchar* _tmp27_;
	_tmp0_ = g_variant_get_child_value (variant, (gsize) 0);
	_tmp1_ = _tmp0_;
	_tmp2_ = (gint) g_variant_get_int32 (_tmp1_);
	_g_variant_unref0 (_tmp1_);
	conversation_id = _tmp2_;
	_tmp3_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp4_ = _tmp3_;
	_tmp5_ = dino_conversation_manager_IDENTITY;
	_tmp6_ = dino_stream_interactor_get_module (_tmp4_, DINO_TYPE_CONVERSATION_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp5_);
	_tmp7_ = (DinoConversationManager*) _tmp6_;
	_tmp8_ = dino_conversation_manager_get_conversation_by_id (_tmp7_, conversation_id);
	_tmp9_ = _tmp8_;
	_g_object_unref0 (_tmp7_);
	conversation = _tmp9_;
	_tmp10_ = conversation;
	if (_tmp10_ == NULL) {
		_g_object_unref0 (conversation);
		return;
	}
	_tmp11_ = g_variant_get_child_value (variant, (gsize) 1);
	_tmp12_ = _tmp11_;
	_tmp13_ = g_variant_get_string (_tmp12_, NULL);
	_tmp14_ = g_strdup (_tmp13_);
	_tmp15_ = _tmp14_;
	_g_variant_unref0 (_tmp12_);
	nick = _tmp15_;
	_tmp16_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp17_ = _tmp16_;
	_tmp18_ = dino_muc_manager_IDENTITY;
	_tmp19_ = dino_stream_interactor_get_module (_tmp17_, DINO_TYPE_MUC_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp18_);
	_tmp20_ = (DinoMucManager*) _tmp19_;
	_tmp21_ = conversation;
	_tmp22_ = dino_entities_conversation_get_account (_tmp21_);
	_tmp23_ = _tmp22_;
	_tmp24_ = conversation;
	_tmp25_ = dino_entities_conversation_get_counterpart (_tmp24_);
	_tmp26_ = _tmp25_;
	_tmp27_ = nick;
	dino_muc_manager_change_role (_tmp20_, _tmp23_, _tmp26_, _tmp27_, "participant");
	_g_object_unref0 (_tmp20_);
	_g_free0 (nick);
	_g_object_unref0 (conversation);
}

static void
___lambda311__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda311_ ((DinoUiApplication*) self, parameter);
}

static void
__lambda312_ (DinoUiApplication* self)
{
	DinoUiMainWindow* _tmp0_;
	_tmp0_ = self->window;
	dino_ui_main_window_loop_conversations (_tmp0_, FALSE);
}

static void
___lambda312__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda312_ ((DinoUiApplication*) self);
}

static void
__lambda313_ (DinoUiApplication* self)
{
	DinoUiMainWindow* _tmp0_;
	_tmp0_ = self->window;
	dino_ui_main_window_loop_conversations (_tmp0_, TRUE);
}

static void
___lambda313__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda313_ ((DinoUiApplication*) self);
}

static void
__lambda314_ (DinoUiApplication* self,
              GVariant* variant)
{
	gint conversation_id = 0;
	GVariant* _tmp0_;
	GVariant* _tmp1_;
	gint _tmp2_;
	DinoEntitiesConversation* conversation = NULL;
	DinoStreamInteractor* _tmp3_;
	DinoStreamInteractor* _tmp4_;
	DinoModuleIdentity* _tmp5_;
	gpointer _tmp6_;
	DinoConversationManager* _tmp7_;
	DinoEntitiesConversation* _tmp8_;
	DinoEntitiesConversation* _tmp9_;
	DinoEntitiesConversation* _tmp10_;
	gint call_id = 0;
	GVariant* _tmp11_;
	GVariant* _tmp12_;
	gint _tmp13_;
	DinoEntitiesCall* call = NULL;
	DinoStreamInteractor* _tmp14_;
	DinoStreamInteractor* _tmp15_;
	DinoModuleIdentity* _tmp16_;
	gpointer _tmp17_;
	DinoCallStore* _tmp18_;
	DinoEntitiesConversation* _tmp19_;
	DinoEntitiesCall* _tmp20_;
	DinoEntitiesCall* _tmp21_;
	DinoCallState* call_state = NULL;
	DinoStreamInteractor* _tmp22_;
	DinoStreamInteractor* _tmp23_;
	DinoModuleIdentity* _tmp24_;
	gpointer _tmp25_;
	DinoCalls* _tmp26_;
	GeeHashMap* _tmp27_;
	DinoEntitiesCall* _tmp28_;
	gpointer _tmp29_;
	DinoCallState* _tmp30_;
	DinoCallState* _tmp31_;
	DinoCallState* _tmp32_;
	DinoUiCallWindow* call_window = NULL;
	DinoUiCallWindow* _tmp33_;
	DinoUiCallWindow* _tmp34_;
	DinoUiCallWindow* _tmp35_;
	DinoCallState* _tmp36_;
	DinoStreamInteractor* _tmp37_;
	DinoStreamInteractor* _tmp38_;
	DinoUiCallWindowController* _tmp39_;
	DinoUiCallWindow* _tmp40_;
	_tmp0_ = g_variant_get_child_value (variant, (gsize) 0);
	_tmp1_ = _tmp0_;
	_tmp2_ = (gint) g_variant_get_int32 (_tmp1_);
	_g_variant_unref0 (_tmp1_);
	conversation_id = _tmp2_;
	_tmp3_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp4_ = _tmp3_;
	_tmp5_ = dino_conversation_manager_IDENTITY;
	_tmp6_ = dino_stream_interactor_get_module (_tmp4_, DINO_TYPE_CONVERSATION_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp5_);
	_tmp7_ = (DinoConversationManager*) _tmp6_;
	_tmp8_ = dino_conversation_manager_get_conversation_by_id (_tmp7_, conversation_id);
	_tmp9_ = _tmp8_;
	_g_object_unref0 (_tmp7_);
	conversation = _tmp9_;
	_tmp10_ = conversation;
	if (_tmp10_ == NULL) {
		_g_object_unref0 (conversation);
		return;
	}
	_tmp11_ = g_variant_get_child_value (variant, (gsize) 1);
	_tmp12_ = _tmp11_;
	_tmp13_ = (gint) g_variant_get_int32 (_tmp12_);
	_g_variant_unref0 (_tmp12_);
	call_id = _tmp13_;
	_tmp14_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp15_ = _tmp14_;
	_tmp16_ = dino_call_store_IDENTITY;
	_tmp17_ = dino_stream_interactor_get_module (_tmp15_, DINO_TYPE_CALL_STORE, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp16_);
	_tmp18_ = (DinoCallStore*) _tmp17_;
	_tmp19_ = conversation;
	_tmp20_ = dino_call_store_get_call_by_id (_tmp18_, call_id, _tmp19_);
	_tmp21_ = _tmp20_;
	_g_object_unref0 (_tmp18_);
	call = _tmp21_;
	_tmp22_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp23_ = _tmp22_;
	_tmp24_ = dino_calls_IDENTITY;
	_tmp25_ = dino_stream_interactor_get_module (_tmp23_, DINO_TYPE_CALLS, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp24_);
	_tmp26_ = (DinoCalls*) _tmp25_;
	_tmp27_ = _tmp26_->call_states;
	_tmp28_ = call;
	_tmp29_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp27_, _tmp28_);
	_tmp30_ = (DinoCallState*) _tmp29_;
	_g_object_unref0 (_tmp26_);
	call_state = _tmp30_;
	_tmp31_ = call_state;
	if (_tmp31_ == NULL) {
		_g_object_unref0 (call_state);
		_g_object_unref0 (call);
		_g_object_unref0 (conversation);
		return;
	}
	_tmp32_ = call_state;
	dino_call_state_accept (_tmp32_);
	_tmp33_ = dino_ui_call_window_new ();
	g_object_ref_sink (_tmp33_);
	call_window = _tmp33_;
	_tmp34_ = call_window;
	_tmp35_ = call_window;
	_tmp36_ = call_state;
	_tmp37_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp38_ = _tmp37_;
	_tmp39_ = dino_ui_call_window_controller_new (_tmp35_, _tmp36_, _tmp38_);
	_g_object_unref0 (_tmp34_->controller);
	_tmp34_->controller = _tmp39_;
	_tmp40_ = call_window;
	gtk_window_present ((GtkWindow*) _tmp40_);
	_g_object_unref0 (call_window);
	_g_object_unref0 (call_state);
	_g_object_unref0 (call);
	_g_object_unref0 (conversation);
}

static void
___lambda314__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda314_ ((DinoUiApplication*) self, parameter);
}

static void
__lambda315_ (DinoUiApplication* self,
              GVariant* variant)
{
	gint conversation_id = 0;
	GVariant* _tmp0_;
	GVariant* _tmp1_;
	gint _tmp2_;
	DinoEntitiesConversation* conversation = NULL;
	DinoStreamInteractor* _tmp3_;
	DinoStreamInteractor* _tmp4_;
	DinoModuleIdentity* _tmp5_;
	gpointer _tmp6_;
	DinoConversationManager* _tmp7_;
	DinoEntitiesConversation* _tmp8_;
	DinoEntitiesConversation* _tmp9_;
	DinoEntitiesConversation* _tmp10_;
	gint call_id = 0;
	GVariant* _tmp11_;
	GVariant* _tmp12_;
	gint _tmp13_;
	DinoEntitiesCall* call = NULL;
	DinoStreamInteractor* _tmp14_;
	DinoStreamInteractor* _tmp15_;
	DinoModuleIdentity* _tmp16_;
	gpointer _tmp17_;
	DinoCallStore* _tmp18_;
	DinoEntitiesConversation* _tmp19_;
	DinoEntitiesCall* _tmp20_;
	DinoEntitiesCall* _tmp21_;
	DinoCallState* call_state = NULL;
	DinoStreamInteractor* _tmp22_;
	DinoStreamInteractor* _tmp23_;
	DinoModuleIdentity* _tmp24_;
	gpointer _tmp25_;
	DinoCalls* _tmp26_;
	GeeHashMap* _tmp27_;
	DinoEntitiesCall* _tmp28_;
	gpointer _tmp29_;
	DinoCallState* _tmp30_;
	DinoCallState* _tmp31_;
	DinoCallState* _tmp32_;
	_tmp0_ = g_variant_get_child_value (variant, (gsize) 0);
	_tmp1_ = _tmp0_;
	_tmp2_ = (gint) g_variant_get_int32 (_tmp1_);
	_g_variant_unref0 (_tmp1_);
	conversation_id = _tmp2_;
	_tmp3_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp4_ = _tmp3_;
	_tmp5_ = dino_conversation_manager_IDENTITY;
	_tmp6_ = dino_stream_interactor_get_module (_tmp4_, DINO_TYPE_CONVERSATION_MANAGER, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp5_);
	_tmp7_ = (DinoConversationManager*) _tmp6_;
	_tmp8_ = dino_conversation_manager_get_conversation_by_id (_tmp7_, conversation_id);
	_tmp9_ = _tmp8_;
	_g_object_unref0 (_tmp7_);
	conversation = _tmp9_;
	_tmp10_ = conversation;
	if (_tmp10_ == NULL) {
		_g_object_unref0 (conversation);
		return;
	}
	_tmp11_ = g_variant_get_child_value (variant, (gsize) 1);
	_tmp12_ = _tmp11_;
	_tmp13_ = (gint) g_variant_get_int32 (_tmp12_);
	_g_variant_unref0 (_tmp12_);
	call_id = _tmp13_;
	_tmp14_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp15_ = _tmp14_;
	_tmp16_ = dino_call_store_IDENTITY;
	_tmp17_ = dino_stream_interactor_get_module (_tmp15_, DINO_TYPE_CALL_STORE, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp16_);
	_tmp18_ = (DinoCallStore*) _tmp17_;
	_tmp19_ = conversation;
	_tmp20_ = dino_call_store_get_call_by_id (_tmp18_, call_id, _tmp19_);
	_tmp21_ = _tmp20_;
	_g_object_unref0 (_tmp18_);
	call = _tmp21_;
	_tmp22_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp23_ = _tmp22_;
	_tmp24_ = dino_calls_IDENTITY;
	_tmp25_ = dino_stream_interactor_get_module (_tmp23_, DINO_TYPE_CALLS, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, _tmp24_);
	_tmp26_ = (DinoCalls*) _tmp25_;
	_tmp27_ = _tmp26_->call_states;
	_tmp28_ = call;
	_tmp29_ = gee_abstract_map_get ((GeeAbstractMap*) _tmp27_, _tmp28_);
	_tmp30_ = (DinoCallState*) _tmp29_;
	_g_object_unref0 (_tmp26_);
	call_state = _tmp30_;
	_tmp31_ = call_state;
	if (_tmp31_ == NULL) {
		_g_object_unref0 (call_state);
		_g_object_unref0 (call);
		_g_object_unref0 (conversation);
		return;
	}
	_tmp32_ = call_state;
	dino_call_state_reject (_tmp32_);
	_g_object_unref0 (call_state);
	_g_object_unref0 (call);
	_g_object_unref0 (conversation);
}

static void
___lambda315__g_simple_action_activate (GSimpleAction* _sender,
                                        GVariant* parameter,
                                        gpointer self)
{
	__lambda315_ ((DinoUiApplication*) self, parameter);
}

static void
dino_ui_application_create_actions (DinoUiApplication* self)
{
	GSimpleAction* preferences_action = NULL;
	GSimpleAction* _tmp0_;
	GSimpleAction* preferences_account_action = NULL;
	const GVariantType* _tmp1_;
	GSimpleAction* _tmp2_;
	GSimpleAction* about_action = NULL;
	GSimpleAction* _tmp3_;
	GSimpleAction* quit_action = NULL;
	GSimpleAction* _tmp4_;
	GSimpleAction* open_conversation_action = NULL;
	const GVariantType* _tmp5_;
	GSimpleAction* _tmp6_;
	GSimpleAction* open_conversation_details_action = NULL;
	const GVariantType* _tmp7_;
	GVariantType* _tmp8_;
	const GVariantType* _tmp9_;
	GVariantType* _tmp10_;
	GVariantType** _tmp11_;
	GVariantType** _tmp12_;
	gint _tmp12__length1;
	GVariantType* _tmp13_;
	GVariantType* _tmp14_;
	GSimpleAction* _tmp15_;
	GSimpleAction* _tmp16_;
	GSimpleAction* deny_subscription_action = NULL;
	const GVariantType* _tmp17_;
	GSimpleAction* _tmp18_;
	GSimpleAction* contacts_action = NULL;
	GSimpleAction* _tmp19_;
	GSimpleAction* conference_action = NULL;
	GSimpleAction* _tmp20_;
	GSimpleAction* accept_muc_invite_action = NULL;
	const GVariantType* _tmp21_;
	GSimpleAction* _tmp22_;
	GSimpleAction* accept_voice_request_action = NULL;
	const GVariantType* _tmp23_;
	GVariantType* _tmp24_;
	const GVariantType* _tmp25_;
	GVariantType* _tmp26_;
	GVariantType** _tmp27_;
	GVariantType** _tmp28_;
	gint _tmp28__length1;
	GVariantType* _tmp29_;
	GVariantType* _tmp30_;
	GSimpleAction* _tmp31_;
	GSimpleAction* _tmp32_;
	GSimpleAction* loop_conversations_action = NULL;
	GSimpleAction* _tmp33_;
	GSimpleAction* loop_conversations_bw_action = NULL;
	GSimpleAction* _tmp34_;
	GSimpleAction* accept_call_action = NULL;
	const GVariantType* _tmp35_;
	GVariantType* _tmp36_;
	const GVariantType* _tmp37_;
	GVariantType* _tmp38_;
	GVariantType** _tmp39_;
	GVariantType** _tmp40_;
	gint _tmp40__length1;
	GVariantType* _tmp41_;
	GVariantType* _tmp42_;
	GSimpleAction* _tmp43_;
	GSimpleAction* _tmp44_;
	GSimpleAction* deny_call_action = NULL;
	const GVariantType* _tmp45_;
	GVariantType* _tmp46_;
	const GVariantType* _tmp47_;
	GVariantType* _tmp48_;
	GVariantType** _tmp49_;
	GVariantType** _tmp50_;
	gint _tmp50__length1;
	GVariantType* _tmp51_;
	GVariantType* _tmp52_;
	GSimpleAction* _tmp53_;
	GSimpleAction* _tmp54_;
	g_return_if_fail (self != NULL);
	_tmp0_ = g_simple_action_new ("preferences", NULL);
	preferences_action = _tmp0_;
	g_signal_connect_object (preferences_action, "activate", (GCallback) _dino_ui_application_show_preferences_window_g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) preferences_action);
	gtk_application_set_accels_for_action ((GtkApplication*) self, "app.preferences", DINO_UI_APPLICATION_KEY_COMBINATION_SHOW_SETTINGS);
	_tmp1_ = G_VARIANT_TYPE_INT32;
	_tmp2_ = g_simple_action_new ("preferences-account", _tmp1_);
	preferences_account_action = _tmp2_;
	g_signal_connect_object (preferences_account_action, "activate", (GCallback) ___lambda283__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) preferences_account_action);
	_tmp3_ = g_simple_action_new ("about", NULL);
	about_action = _tmp3_;
	g_signal_connect_object (about_action, "activate", (GCallback) _dino_ui_application_show_about_window_g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) about_action);
	_tmp4_ = g_simple_action_new ("quit", NULL);
	quit_action = _tmp4_;
	g_signal_connect_object (quit_action, "activate", (GCallback) _g_application_quit_g_simple_action_activate, (GApplication*) self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) quit_action);
	gtk_application_set_accels_for_action ((GtkApplication*) self, "app.quit", DINO_UI_APPLICATION_KEY_COMBINATION_QUIT);
	_tmp5_ = G_VARIANT_TYPE_INT32;
	_tmp6_ = g_simple_action_new ("open-conversation", _tmp5_);
	open_conversation_action = _tmp6_;
	g_signal_connect_object (open_conversation_action, "activate", (GCallback) ___lambda284__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) open_conversation_action);
	_tmp7_ = G_VARIANT_TYPE_INT32;
	_tmp8_ = _g_variant_type_copy0 (_tmp7_);
	_tmp9_ = G_VARIANT_TYPE_STRING;
	_tmp10_ = _g_variant_type_copy0 (_tmp9_);
	_tmp11_ = g_new0 (GVariantType*, 2 + 1);
	_tmp11_[0] = _tmp8_;
	_tmp11_[1] = _tmp10_;
	_tmp12_ = _tmp11_;
	_tmp12__length1 = 2;
	_tmp13_ = g_variant_type_new_tuple (_tmp12_, 2);
	_tmp14_ = _tmp13_;
	_tmp15_ = g_simple_action_new ("open-conversation-details", _tmp14_);
	_tmp16_ = _tmp15_;
	_g_variant_type_free0 (_tmp14_);
	_tmp12_ = (_vala_array_free (_tmp12_, _tmp12__length1, (GDestroyNotify) g_variant_type_free), NULL);
	open_conversation_details_action = _tmp16_;
	g_signal_connect_object (open_conversation_details_action, "activate", (GCallback) ___lambda285__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) open_conversation_details_action);
	_tmp17_ = G_VARIANT_TYPE_INT32;
	_tmp18_ = g_simple_action_new ("deny-subscription", _tmp17_);
	deny_subscription_action = _tmp18_;
	g_signal_connect_object (deny_subscription_action, "activate", (GCallback) ___lambda286__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) deny_subscription_action);
	_tmp19_ = g_simple_action_new ("add_chat", NULL);
	contacts_action = _tmp19_;
	g_signal_connect_object (contacts_action, "activate", (GCallback) ___lambda287__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) contacts_action);
	gtk_application_set_accels_for_action ((GtkApplication*) self, "app.add_chat", DINO_UI_APPLICATION_KEY_COMBINATION_ADD_CHAT);
	_tmp20_ = g_simple_action_new ("add_conference", NULL);
	conference_action = _tmp20_;
	g_signal_connect_object (conference_action, "activate", (GCallback) ___lambda290__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) conference_action);
	gtk_application_set_accels_for_action ((GtkApplication*) self, "app.add_conference", DINO_UI_APPLICATION_KEY_COMBINATION_ADD_CONFERENCE);
	_tmp21_ = G_VARIANT_TYPE_INT32;
	_tmp22_ = g_simple_action_new ("open-muc-join", _tmp21_);
	accept_muc_invite_action = _tmp22_;
	g_signal_connect_object (accept_muc_invite_action, "activate", (GCallback) ___lambda308__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) accept_muc_invite_action);
	_tmp23_ = G_VARIANT_TYPE_INT32;
	_tmp24_ = _g_variant_type_copy0 (_tmp23_);
	_tmp25_ = G_VARIANT_TYPE_STRING;
	_tmp26_ = _g_variant_type_copy0 (_tmp25_);
	_tmp27_ = g_new0 (GVariantType*, 2 + 1);
	_tmp27_[0] = _tmp24_;
	_tmp27_[1] = _tmp26_;
	_tmp28_ = _tmp27_;
	_tmp28__length1 = 2;
	_tmp29_ = g_variant_type_new_tuple (_tmp28_, 2);
	_tmp30_ = _tmp29_;
	_tmp31_ = g_simple_action_new ("accept-voice-request", _tmp30_);
	_tmp32_ = _tmp31_;
	_g_variant_type_free0 (_tmp30_);
	_tmp28_ = (_vala_array_free (_tmp28_, _tmp28__length1, (GDestroyNotify) g_variant_type_free), NULL);
	accept_voice_request_action = _tmp32_;
	g_signal_connect_object (accept_voice_request_action, "activate", (GCallback) ___lambda311__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) accept_voice_request_action);
	_tmp33_ = g_simple_action_new ("loop_conversations", NULL);
	loop_conversations_action = _tmp33_;
	g_signal_connect_object (loop_conversations_action, "activate", (GCallback) ___lambda312__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) loop_conversations_action);
	gtk_application_set_accels_for_action ((GtkApplication*) self, "app.loop_conversations", DINO_UI_APPLICATION_KEY_COMBINATION_LOOP_CONVERSATIONS);
	_tmp34_ = g_simple_action_new ("loop_conversations_bw", NULL);
	loop_conversations_bw_action = _tmp34_;
	g_signal_connect_object (loop_conversations_bw_action, "activate", (GCallback) ___lambda313__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) loop_conversations_bw_action);
	gtk_application_set_accels_for_action ((GtkApplication*) self, "app.loop_conversations_bw", DINO_UI_APPLICATION_KEY_COMBINATION_LOOP_CONVERSATIONS_REV);
	_tmp35_ = G_VARIANT_TYPE_INT32;
	_tmp36_ = _g_variant_type_copy0 (_tmp35_);
	_tmp37_ = G_VARIANT_TYPE_INT32;
	_tmp38_ = _g_variant_type_copy0 (_tmp37_);
	_tmp39_ = g_new0 (GVariantType*, 2 + 1);
	_tmp39_[0] = _tmp36_;
	_tmp39_[1] = _tmp38_;
	_tmp40_ = _tmp39_;
	_tmp40__length1 = 2;
	_tmp41_ = g_variant_type_new_tuple (_tmp40_, 2);
	_tmp42_ = _tmp41_;
	_tmp43_ = g_simple_action_new ("accept-call", _tmp42_);
	_tmp44_ = _tmp43_;
	_g_variant_type_free0 (_tmp42_);
	_tmp40_ = (_vala_array_free (_tmp40_, _tmp40__length1, (GDestroyNotify) g_variant_type_free), NULL);
	accept_call_action = _tmp44_;
	g_signal_connect_object (accept_call_action, "activate", (GCallback) ___lambda314__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) accept_call_action);
	_tmp45_ = G_VARIANT_TYPE_INT32;
	_tmp46_ = _g_variant_type_copy0 (_tmp45_);
	_tmp47_ = G_VARIANT_TYPE_INT32;
	_tmp48_ = _g_variant_type_copy0 (_tmp47_);
	_tmp49_ = g_new0 (GVariantType*, 2 + 1);
	_tmp49_[0] = _tmp46_;
	_tmp49_[1] = _tmp48_;
	_tmp50_ = _tmp49_;
	_tmp50__length1 = 2;
	_tmp51_ = g_variant_type_new_tuple (_tmp50_, 2);
	_tmp52_ = _tmp51_;
	_tmp53_ = g_simple_action_new ("reject-call", _tmp52_);
	_tmp54_ = _tmp53_;
	_g_variant_type_free0 (_tmp52_);
	_tmp50_ = (_vala_array_free (_tmp50_, _tmp50__length1, (GDestroyNotify) g_variant_type_free), NULL);
	deny_call_action = _tmp54_;
	g_signal_connect_object (deny_call_action, "activate", (GCallback) ___lambda315__g_simple_action_activate, self, 0);
	g_action_map_add_action ((GActionMap*) self, (GAction*) deny_call_action);
	_g_object_unref0 (deny_call_action);
	_g_object_unref0 (accept_call_action);
	_g_object_unref0 (loop_conversations_bw_action);
	_g_object_unref0 (loop_conversations_action);
	_g_object_unref0 (accept_voice_request_action);
	_g_object_unref0 (accept_muc_invite_action);
	_g_object_unref0 (conference_action);
	_g_object_unref0 (contacts_action);
	_g_object_unref0 (deny_subscription_action);
	_g_object_unref0 (open_conversation_details_action);
	_g_object_unref0 (open_conversation_action);
	_g_object_unref0 (quit_action);
	_g_object_unref0 (about_action);
	_g_object_unref0 (preferences_account_action);
	_g_object_unref0 (preferences_action);
}

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

static void
dino_ui_application_show_preferences_window (DinoUiApplication* self)
{
	DinoUiPreferencesWindow* dialog = NULL;
	DinoUiMainWindow* _tmp0_;
	GtkWindow* _tmp1_;
	DinoUiPreferencesWindow* _tmp2_ = NULL;
	DinoUiViewModelPreferencesWindow* _tmp3_;
	DinoUiViewModelPreferencesWindow* _tmp4_;
	DinoDatabase* _tmp5_;
	DinoDatabase* _tmp6_;
	DinoStreamInteractor* _tmp7_;
	DinoStreamInteractor* _tmp8_;
	g_return_if_fail (self != NULL);
	_tmp0_ = self->window;
	_tmp1_ = _g_object_ref0 ((GtkWindow*) _tmp0_);
	_tmp2_ = dino_ui_preferences_window_new ();
	gtk_window_set_transient_for ((GtkWindow*) _tmp2_, _tmp1_);
	_g_object_unref0 (_tmp1_);
	g_object_ref_sink (_tmp2_);
	dialog = _tmp2_;
	_tmp3_ = dino_ui_preferences_window_get_model (dialog);
	_tmp4_ = _tmp3_;
	_tmp5_ = dino_application_get_db ((DinoApplication*) self);
	_tmp6_ = _tmp5_;
	_tmp7_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp8_ = _tmp7_;
	dino_ui_view_model_preferences_window_populate (_tmp4_, _tmp6_, _tmp8_);
	gtk_window_present ((GtkWindow*) dialog);
	_g_object_unref0 (dialog);
}

static void
dino_ui_application_show_preferences_account_window (DinoUiApplication* self,
                                                     DinoEntitiesAccount* account)
{
	DinoUiPreferencesWindow* dialog = NULL;
	DinoUiMainWindow* _tmp0_;
	GtkWindow* _tmp1_;
	DinoUiPreferencesWindow* _tmp2_ = NULL;
	DinoUiViewModelPreferencesWindow* _tmp3_;
	DinoUiViewModelPreferencesWindow* _tmp4_;
	DinoDatabase* _tmp5_;
	DinoDatabase* _tmp6_;
	DinoStreamInteractor* _tmp7_;
	DinoStreamInteractor* _tmp8_;
	DinoUiPreferencesWindowAccounts* _tmp9_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (account != NULL);
	_tmp0_ = self->window;
	_tmp1_ = _g_object_ref0 ((GtkWindow*) _tmp0_);
	_tmp2_ = dino_ui_preferences_window_new ();
	gtk_window_set_transient_for ((GtkWindow*) _tmp2_, _tmp1_);
	_g_object_unref0 (_tmp1_);
	g_object_ref_sink (_tmp2_);
	dialog = _tmp2_;
	_tmp3_ = dino_ui_preferences_window_get_model (dialog);
	_tmp4_ = _tmp3_;
	_tmp5_ = dino_application_get_db ((DinoApplication*) self);
	_tmp6_ = _tmp5_;
	_tmp7_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp8_ = _tmp7_;
	dino_ui_view_model_preferences_window_populate (_tmp4_, _tmp6_, _tmp8_);
	_tmp9_ = dialog->accounts_page;
	g_signal_emit_by_name (_tmp9_, "account-chosen", account);
	gtk_window_present ((GtkWindow*) dialog);
	_g_object_unref0 (dialog);
}

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

static glong
string_strnlen (gchar* str,
                glong maxlen)
{
	gchar* end = NULL;
	gchar* _tmp0_;
	gchar* _tmp1_;
	glong result;
	_tmp0_ = memchr (str, 0, (gsize) maxlen);
	end = _tmp0_;
	_tmp1_ = end;
	if (_tmp1_ == NULL) {
		result = maxlen;
		return result;
	} else {
		gchar* _tmp2_;
		_tmp2_ = end;
		result = (glong) (_tmp2_ - str);
		return result;
	}
}

static gchar*
string_substring (const gchar* self,
                  glong offset,
                  glong len)
{
	glong string_length = 0L;
	gboolean _tmp0_ = FALSE;
	gchar* _tmp3_;
	gchar* result;
	g_return_val_if_fail (self != NULL, NULL);
	if (offset >= ((glong) 0)) {
		_tmp0_ = len >= ((glong) 0);
	} else {
		_tmp0_ = FALSE;
	}
	if (_tmp0_) {
		string_length = string_strnlen ((gchar*) self, offset + len);
	} else {
		gint _tmp1_;
		gint _tmp2_;
		_tmp1_ = strlen (self);
		_tmp2_ = _tmp1_;
		string_length = (glong) _tmp2_;
	}
	if (offset < ((glong) 0)) {
		offset = string_length + offset;
		g_return_val_if_fail (offset >= ((glong) 0), NULL);
	} else {
		g_return_val_if_fail (offset <= string_length, NULL);
	}
	if (len < ((glong) 0)) {
		len = string_length - offset;
	}
	g_return_val_if_fail ((offset + len) <= string_length, NULL);
	_tmp3_ = g_strndup (((gchar*) self) + offset, (gsize) len);
	result = _tmp3_;
	return result;
}

static void
dino_ui_application_show_about_window (DinoUiApplication* self)
{
	gchar* _tmp0_ = NULL;
	gchar* _tmp1_;
	gchar* _tmp2_;
	gchar* _tmp3_;
	gchar* _tmp4_;
	gint _tmp5_;
	gint _tmp6_;
	gboolean _tmp7_;
	gchar* version = NULL;
	gchar* _tmp9_;
	gboolean _tmp10_ = FALSE;
	const gchar* _tmp11_;
	AdwAboutWindow* about_window = NULL;
	AdwAboutWindow* _tmp30_;
	DinoUiMainWindow* _tmp31_;
	const gchar* _tmp32_;
	const gchar* _tmp33_;
	g_return_if_fail (self != NULL);
	_tmp1_ = dino_get_version ();
	_tmp2_ = _tmp1_;
	_tmp3_ = string_strip (_tmp2_);
	_tmp4_ = _tmp3_;
	_tmp5_ = strlen (_tmp4_);
	_tmp6_ = _tmp5_;
	_tmp7_ = _tmp6_ == 0;
	_g_free0 (_tmp4_);
	_g_free0 (_tmp2_);
	if (_tmp7_) {
		_g_free0 (_tmp0_);
		_tmp0_ = NULL;
	} else {
		gchar* _tmp8_;
		_tmp8_ = dino_get_version ();
		_g_free0 (_tmp0_);
		_tmp0_ = _tmp8_;
	}
	_tmp9_ = _tmp0_;
	_tmp0_ = NULL;
	version = _tmp9_;
	_tmp11_ = version;
	if (_tmp11_ != NULL) {
		const gchar* _tmp12_;
		_tmp12_ = version;
		_tmp10_ = !string_contains (_tmp12_, "git");
	} else {
		_tmp10_ = FALSE;
	}
	if (_tmp10_) {
		const gchar* _tmp13_;
		gchar* _tmp14_;
		gchar* _tmp15_;
		GQuark _tmp17_ = 0U;
		static GQuark _tmp16_label0 = 0;
		static GQuark _tmp16_label1 = 0;
		static GQuark _tmp16_label2 = 0;
		static GQuark _tmp16_label3 = 0;
		_tmp13_ = version;
		_tmp14_ = string_substring (_tmp13_, (glong) 0, (glong) 3);
		_tmp15_ = _tmp14_;
		_tmp17_ = (NULL == _tmp15_) ? 0 : g_quark_from_string (_tmp15_);
		g_free (_tmp15_);
		if (_tmp17_ == ((0 != _tmp16_label0) ? _tmp16_label0 : (_tmp16_label0 = g_quark_from_static_string ("0.2")))) {
			switch (0) {
				default:
				{
					const gchar* _tmp18_;
					const gchar* _tmp19_;
					gchar* _tmp20_;
					_tmp18_ = version;
					_tmp19_ = string_to_string (_tmp18_);
					_tmp20_ = g_strconcat (_tmp19_, " - Mexican Caribbean Coral Reefs", NULL);
					_g_free0 (version);
					version = _tmp20_;
					break;
				}
			}
		} else if (_tmp17_ == ((0 != _tmp16_label1) ? _tmp16_label1 : (_tmp16_label1 = g_quark_from_static_string ("0.3")))) {
			switch (0) {
				default:
				{
					const gchar* _tmp21_;
					const gchar* _tmp22_;
					gchar* _tmp23_;
					_tmp21_ = version;
					_tmp22_ = string_to_string (_tmp21_);
					_tmp23_ = g_strconcat (_tmp22_, " - Theikenmeer", NULL);
					_g_free0 (version);
					version = _tmp23_;
					break;
				}
			}
		} else if (_tmp17_ == ((0 != _tmp16_label2) ? _tmp16_label2 : (_tmp16_label2 = g_quark_from_static_string ("0.4")))) {
			switch (0) {
				default:
				{
					const gchar* _tmp24_;
					const gchar* _tmp25_;
					gchar* _tmp26_;
					_tmp24_ = version;
					_tmp25_ = string_to_string (_tmp24_);
					_tmp26_ = g_strconcat (_tmp25_, " - Ilulissat", NULL);
					_g_free0 (version);
					version = _tmp26_;
					break;
				}
			}
		} else if (_tmp17_ == ((0 != _tmp16_label3) ? _tmp16_label3 : (_tmp16_label3 = g_quark_from_static_string ("0.5")))) {
			switch (0) {
				default:
				{
					const gchar* _tmp27_;
					const gchar* _tmp28_;
					gchar* _tmp29_;
					_tmp27_ = version;
					_tmp28_ = string_to_string (_tmp27_);
					_tmp29_ = g_strconcat (_tmp28_, " - Alentejo", NULL);
					_g_free0 (version);
					version = _tmp29_;
					break;
				}
			}
		}
	}
	_tmp30_ = (AdwAboutWindow*) adw_about_window_new ();
	g_object_ref_sink (_tmp30_);
	about_window = _tmp30_;
	adw_about_window_set_application_icon (about_window, "im.dino.Dino");
	adw_about_window_set_application_name (about_window, "Dino");
	adw_about_window_set_issue_url (about_window, "https://github.com/dino/dino/issues");
	gtk_window_set_destroy_with_parent ((GtkWindow*) about_window, TRUE);
	_tmp31_ = self->window;
	gtk_window_set_transient_for ((GtkWindow*) about_window, (GtkWindow*) _tmp31_);
	gtk_window_set_modal ((GtkWindow*) about_window, TRUE);
	_tmp32_ = dino_gettext ("About Dino");
	gtk_window_set_title ((GtkWindow*) about_window, _tmp32_);
	_tmp33_ = version;
	adw_about_window_set_version (about_window, _tmp33_);
	adw_about_window_set_website (about_window, "https://dino.im/");
	adw_about_window_set_copyright (about_window, "Copyright © 2016-2025 - Dino Team");
	adw_about_window_set_license_type (about_window, GTK_LICENSE_GPL_3_0);
	gtk_window_present ((GtkWindow*) about_window);
	_g_object_unref0 (about_window);
	_g_free0 (version);
	_g_free0 (_tmp0_);
}

static Block9Data*
block9_data_ref (Block9Data* _data9_)
{
	g_atomic_int_inc (&_data9_->_ref_count_);
	return _data9_;
}

static void
block9_data_unref (void * _userdata_)
{
	Block9Data* _data9_;
	_data9_ = (Block9Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data9_->_ref_count_)) {
		DinoUiApplication* self;
		self = _data9_->self;
		_g_object_unref0 (_data9_->dialog);
		_g_object_unref0 (self);
		g_slice_free (Block9Data, _data9_);
	}
}

static void
__lambda309_ (Block9Data* _data9_)
{
	DinoUiApplication* self;
	GtkDialog* _tmp0_;
	self = _data9_->self;
	_tmp0_ = _data9_->dialog;
	gtk_window_destroy ((GtkWindow*) _tmp0_);
}

static void
___lambda309__dino_ui_conference_details_fragment_joined (DinoUiConferenceDetailsFragment* _sender,
                                                          gpointer self)
{
	__lambda309_ (self);
}

static void
__lambda310_ (Block9Data* _data9_,
              gint response_id)
{
	DinoUiApplication* self;
	self = _data9_->self;
	if (response_id == ((gint) GTK_RESPONSE_CANCEL)) {
		GtkDialog* _tmp0_;
		_tmp0_ = _data9_->dialog;
		gtk_window_destroy ((GtkWindow*) _tmp0_);
	}
}

static void
___lambda310__gtk_dialog_response (GtkDialog* _sender,
                                   gint response_id,
                                   gpointer self)
{
	__lambda310_ (self, response_id);
}

static void
dino_ui_application_show_join_muc_dialog (DinoUiApplication* self,
                                          DinoEntitiesAccount* account,
                                          const gchar* jid)
{
	Block9Data* _data9_;
	const gchar* _tmp0_;
	DinoUiMainWindow* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	GtkDialog* _tmp4_;
	GtkDialog* _tmp5_;
	GtkButton* ok_button = NULL;
	GtkDialog* _tmp6_;
	GtkWidget* _tmp7_;
	GtkButton* _tmp8_;
	GtkButton* _tmp9_;
	DinoUiConferenceDetailsFragment* conference_fragment = NULL;
	DinoStreamInteractor* _tmp10_;
	DinoStreamInteractor* _tmp11_;
	GtkButton* _tmp12_;
	GtkButton* _tmp13_;
	DinoUiConferenceDetailsFragment* _tmp14_ = NULL;
	DinoUiConferenceDetailsFragment* _tmp15_;
	GtkBox* content_area = NULL;
	GtkDialog* _tmp17_;
	GtkBox* _tmp18_;
	GtkBox* _tmp19_;
	DinoUiConferenceDetailsFragment* _tmp20_;
	DinoUiConferenceDetailsFragment* _tmp21_;
	GtkDialog* _tmp22_;
	GtkDialog* _tmp23_;
	g_return_if_fail (self != NULL);
	g_return_if_fail (jid != NULL);
	_data9_ = g_slice_new0 (Block9Data);
	_data9_->_ref_count_ = 1;
	_data9_->self = g_object_ref (self);
	_tmp0_ = dino_gettext ("Join Channel");
	_tmp1_ = self->window;
	_tmp2_ = dino_gettext ("Join");
	_tmp3_ = dino_gettext ("Cancel");
	_tmp4_ = (GtkDialog*) gtk_dialog_new_with_buttons (_tmp0_, (GtkWindow*) _tmp1_, GTK_DIALOG_MODAL | GTK_DIALOG_USE_HEADER_BAR, _tmp2_, GTK_RESPONSE_OK, _tmp3_, GTK_RESPONSE_CANCEL, NULL);
	g_object_ref_sink (_tmp4_);
	_data9_->dialog = _tmp4_;
	_tmp5_ = _data9_->dialog;
	gtk_window_set_modal ((GtkWindow*) _tmp5_, TRUE);
	_tmp6_ = _data9_->dialog;
	_tmp7_ = gtk_dialog_get_widget_for_response (_tmp6_, (gint) GTK_RESPONSE_OK);
	_tmp8_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp7_, gtk_button_get_type ()) ? ((GtkButton*) _tmp7_) : NULL);
	ok_button = _tmp8_;
	_tmp9_ = ok_button;
	gtk_widget_add_css_class ((GtkWidget*) _tmp9_, "suggested-action");
	_tmp10_ = dino_application_get_stream_interactor ((DinoApplication*) self);
	_tmp11_ = _tmp10_;
	_tmp12_ = ok_button;
	_tmp13_ = _g_object_ref0 (_tmp12_);
	_tmp14_ = dino_ui_conference_details_fragment_new (_tmp11_);
	dino_ui_conference_details_fragment_set_ok_button (_tmp14_, _tmp13_);
	_g_object_unref0 (_tmp13_);
	g_object_ref_sink (_tmp14_);
	conference_fragment = _tmp14_;
	_tmp15_ = conference_fragment;
	dino_ui_conference_details_fragment_set_jid (_tmp15_, jid);
	if (account != NULL) {
		DinoUiConferenceDetailsFragment* _tmp16_;
		_tmp16_ = conference_fragment;
		dino_ui_conference_details_fragment_set_account (_tmp16_, account);
	}
	_tmp17_ = _data9_->dialog;
	_tmp18_ = gtk_dialog_get_content_area (_tmp17_);
	_tmp19_ = _g_object_ref0 (_tmp18_);
	content_area = _tmp19_;
	_tmp20_ = conference_fragment;
	gtk_box_append (content_area, (GtkWidget*) _tmp20_);
	_tmp21_ = conference_fragment;
	g_signal_connect_data (_tmp21_, "joined", (GCallback) ___lambda309__dino_ui_conference_details_fragment_joined, block9_data_ref (_data9_), (GClosureNotify) block9_data_unref, 0);
	_tmp22_ = _data9_->dialog;
	g_signal_connect_data (_tmp22_, "response", (GCallback) ___lambda310__gtk_dialog_response, block9_data_ref (_data9_), (GClosureNotify) block9_data_unref, 0);
	_tmp23_ = _data9_->dialog;
	gtk_window_present ((GtkWindow*) _tmp23_);
	_g_object_unref0 (content_area);
	_g_object_unref0 (conference_fragment);
	_g_object_unref0 (ok_button);
	block9_data_unref (_data9_);
	_data9_ = NULL;
}

static DinoDatabase*
dino_ui_application_real_get_db (DinoApplication* base)
{
	DinoDatabase* result;
	DinoUiApplication* self;
	DinoDatabase* _tmp0_;
	self = (DinoUiApplication*) base;
	_tmp0_ = self->priv->_db;
	result = _tmp0_;
	return result;
}

static gpointer
_qlite_database_ref0 (gpointer self)
{
	return self ? qlite_database_ref (self) : NULL;
}

static void
dino_ui_application_real_set_db (DinoApplication* base,
                                 DinoDatabase* value)
{
	DinoUiApplication* self;
	DinoDatabase* old_value;
	self = (DinoUiApplication*) base;
	old_value = dino_ui_application_real_get_db (base);
	if (old_value != value) {
		DinoDatabase* _tmp0_;
		_tmp0_ = _qlite_database_ref0 (value);
		_qlite_database_unref0 (self->priv->_db);
		self->priv->_db = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, dino_ui_application_properties[DINO_UI_APPLICATION_DB_PROPERTY]);
	}
}

static DinoEntitiesSettings*
dino_ui_application_real_get_settings (DinoApplication* base)
{
	DinoEntitiesSettings* result;
	DinoUiApplication* self;
	DinoEntitiesSettings* _tmp0_;
	self = (DinoUiApplication*) base;
	_tmp0_ = self->priv->_settings;
	result = _tmp0_;
	return result;
}

static void
dino_ui_application_real_set_settings (DinoApplication* base,
                                       DinoEntitiesSettings* value)
{
	DinoUiApplication* self;
	DinoEntitiesSettings* old_value;
	self = (DinoUiApplication*) base;
	old_value = dino_ui_application_real_get_settings (base);
	if (old_value != value) {
		DinoEntitiesSettings* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_settings);
		self->priv->_settings = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, dino_ui_application_properties[DINO_UI_APPLICATION_SETTINGS_PROPERTY]);
	}
}

static DinoUiConfig*
dino_ui_application_get_config (DinoUiApplication* self)
{
	DinoUiConfig* result;
	DinoUiConfig* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_config;
	result = _tmp0_;
	return result;
}

static void
dino_ui_application_set_config (DinoUiApplication* self,
                                DinoUiConfig* value)
{
	DinoUiConfig* _tmp0_;
	g_return_if_fail (self != NULL);
	_tmp0_ = _g_object_ref0 (value);
	_g_object_unref0 (self->priv->_config);
	self->priv->_config = _tmp0_;
}

static DinoStreamInteractor*
dino_ui_application_real_get_stream_interactor (DinoApplication* base)
{
	DinoStreamInteractor* result;
	DinoUiApplication* self;
	DinoStreamInteractor* _tmp0_;
	self = (DinoUiApplication*) base;
	_tmp0_ = self->priv->_stream_interactor;
	result = _tmp0_;
	return result;
}

static void
dino_ui_application_real_set_stream_interactor (DinoApplication* base,
                                                DinoStreamInteractor* value)
{
	DinoUiApplication* self;
	DinoStreamInteractor* old_value;
	self = (DinoUiApplication*) base;
	old_value = dino_ui_application_real_get_stream_interactor (base);
	if (old_value != value) {
		DinoStreamInteractor* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_stream_interactor);
		self->priv->_stream_interactor = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, dino_ui_application_properties[DINO_UI_APPLICATION_STREAM_INTERACTOR_PROPERTY]);
	}
}

static DinoPluginsRegistry*
dino_ui_application_real_get_plugin_registry (DinoApplication* base)
{
	DinoPluginsRegistry* result;
	DinoUiApplication* self;
	DinoPluginsRegistry* _tmp0_;
	self = (DinoUiApplication*) base;
	_tmp0_ = self->priv->_plugin_registry;
	result = _tmp0_;
	return result;
}

static gpointer
_dino_plugins_registry_ref0 (gpointer self)
{
	return self ? dino_plugins_registry_ref (self) : NULL;
}

static void
dino_ui_application_real_set_plugin_registry (DinoApplication* base,
                                              DinoPluginsRegistry* value)
{
	DinoUiApplication* self;
	DinoPluginsRegistry* old_value;
	self = (DinoUiApplication*) base;
	old_value = dino_ui_application_real_get_plugin_registry (base);
	if (old_value != value) {
		DinoPluginsRegistry* _tmp0_;
		_tmp0_ = _dino_plugins_registry_ref0 (value);
		_dino_plugins_registry_unref0 (self->priv->_plugin_registry);
		self->priv->_plugin_registry = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, dino_ui_application_properties[DINO_UI_APPLICATION_PLUGIN_REGISTRY_PROPERTY]);
	}
}

static DinoSearchPathGenerator*
dino_ui_application_real_get_search_path_generator (DinoApplication* base)
{
	DinoSearchPathGenerator* result;
	DinoUiApplication* self;
	DinoSearchPathGenerator* _tmp0_;
	self = (DinoUiApplication*) base;
	_tmp0_ = self->priv->_search_path_generator;
	result = _tmp0_;
	return result;
}

static gpointer
_dino_search_path_generator_ref0 (gpointer self)
{
	return self ? dino_search_path_generator_ref (self) : NULL;
}

static void
dino_ui_application_real_set_search_path_generator (DinoApplication* base,
                                                    DinoSearchPathGenerator* value)
{
	DinoUiApplication* self;
	DinoSearchPathGenerator* old_value;
	self = (DinoUiApplication*) base;
	old_value = dino_ui_application_real_get_search_path_generator (base);
	if (old_value != value) {
		DinoSearchPathGenerator* _tmp0_;
		_tmp0_ = _dino_search_path_generator_ref0 (value);
		_dino_search_path_generator_unref0 (self->priv->_search_path_generator);
		self->priv->_search_path_generator = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, dino_ui_application_properties[DINO_UI_APPLICATION_SEARCH_PATH_GENERATOR_PROPERTY]);
	}
}

static void
dino_ui_application_class_init (DinoUiApplicationClass * klass,
                                gpointer klass_data)
{
	dino_ui_application_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &DinoUiApplication_private_offset);
	G_OBJECT_CLASS (klass)->get_property = _vala_dino_ui_application_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_dino_ui_application_set_property;
	G_OBJECT_CLASS (klass)->finalize = dino_ui_application_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), DINO_UI_APPLICATION_DB_PROPERTY, dino_ui_application_properties[DINO_UI_APPLICATION_DB_PROPERTY] = qlite_param_spec_database ("db", "db", "db", DINO_TYPE_DATABASE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), DINO_UI_APPLICATION_SETTINGS_PROPERTY, dino_ui_application_properties[DINO_UI_APPLICATION_SETTINGS_PROPERTY] = g_param_spec_object ("settings", "settings", "settings", DINO_ENTITIES_TYPE_SETTINGS, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), DINO_UI_APPLICATION_STREAM_INTERACTOR_PROPERTY, dino_ui_application_properties[DINO_UI_APPLICATION_STREAM_INTERACTOR_PROPERTY] = g_param_spec_object ("stream-interactor", "stream-interactor", "stream-interactor", DINO_TYPE_STREAM_INTERACTOR, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), DINO_UI_APPLICATION_PLUGIN_REGISTRY_PROPERTY, dino_ui_application_properties[DINO_UI_APPLICATION_PLUGIN_REGISTRY_PROPERTY] = dino_plugins_param_spec_registry ("plugin-registry", "plugin-registry", "plugin-registry", DINO_PLUGINS_TYPE_REGISTRY, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), DINO_UI_APPLICATION_SEARCH_PATH_GENERATOR_PROPERTY, dino_ui_application_properties[DINO_UI_APPLICATION_SEARCH_PATH_GENERATOR_PROPERTY] = dino_param_spec_search_path_generator ("search-path-generator", "search-path-generator", "search-path-generator", DINO_TYPE_SEARCH_PATH_GENERATOR, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
}

static void
dino_ui_application_dino_application_interface_init (DinoApplicationIface * iface,
                                                     gpointer iface_data)
{
	dino_ui_application_dino_application_parent_iface = g_type_interface_peek_parent (iface);
	iface->handle_uri = (void (*) (DinoApplication*, const gchar*, const gchar*, GeeMap*)) dino_ui_application_real_handle_uri;
	iface->get_db = dino_ui_application_real_get_db;
	iface->set_db = dino_ui_application_real_set_db;
	iface->get_settings = dino_ui_application_real_get_settings;
	iface->set_settings = dino_ui_application_real_set_settings;
	iface->get_stream_interactor = dino_ui_application_real_get_stream_interactor;
	iface->set_stream_interactor = dino_ui_application_real_set_stream_interactor;
	iface->get_plugin_registry = dino_ui_application_real_get_plugin_registry;
	iface->set_plugin_registry = dino_ui_application_real_set_plugin_registry;
	iface->get_search_path_generator = dino_ui_application_real_get_search_path_generator;
	iface->set_search_path_generator = dino_ui_application_real_set_search_path_generator;
}

static void
dino_ui_application_instance_init (DinoUiApplication * self,
                                   gpointer klass)
{
	DinoPluginsRegistry* _tmp0_;
	self->priv = dino_ui_application_get_instance_private (self);
	_tmp0_ = dino_plugins_registry_new ();
	self->priv->_plugin_registry = _tmp0_;
}

static void
dino_ui_application_finalize (GObject * obj)
{
	DinoUiApplication * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, DINO_UI_TYPE_APPLICATION, DinoUiApplication);
	_g_object_unref0 (self->window);
	_g_object_unref0 (self->controller);
	_qlite_database_unref0 (self->priv->_db);
	_g_object_unref0 (self->priv->_settings);
	_g_object_unref0 (self->priv->_config);
	_g_object_unref0 (self->priv->_stream_interactor);
	_dino_plugins_registry_unref0 (self->priv->_plugin_registry);
	_dino_search_path_generator_unref0 (self->priv->_search_path_generator);
	G_OBJECT_CLASS (dino_ui_application_parent_class)->finalize (obj);
}

static GType
dino_ui_application_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (DinoUiApplicationClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) dino_ui_application_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (DinoUiApplication), 0, (GInstanceInitFunc) dino_ui_application_instance_init, NULL };
	static const GInterfaceInfo dino_application_info = { (GInterfaceInitFunc) dino_ui_application_dino_application_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
	GType dino_ui_application_type_id;
	dino_ui_application_type_id = g_type_register_static (adw_application_get_type (), "DinoUiApplication", &g_define_type_info, 0);
	g_type_add_interface_static (dino_ui_application_type_id, DINO_TYPE_APPLICATION, &dino_application_info);
	DinoUiApplication_private_offset = g_type_add_instance_private (dino_ui_application_type_id, sizeof (DinoUiApplicationPrivate));
	return dino_ui_application_type_id;
}

GType
dino_ui_application_get_type (void)
{
	static volatile gsize dino_ui_application_type_id__once = 0;
	if (g_once_init_enter (&dino_ui_application_type_id__once)) {
		GType dino_ui_application_type_id;
		dino_ui_application_type_id = dino_ui_application_get_type_once ();
		g_once_init_leave (&dino_ui_application_type_id__once, dino_ui_application_type_id);
	}
	return dino_ui_application_type_id__once;
}

static void
_vala_dino_ui_application_get_property (GObject * object,
                                        guint property_id,
                                        GValue * value,
                                        GParamSpec * pspec)
{
	DinoUiApplication * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, DINO_UI_TYPE_APPLICATION, DinoUiApplication);
	switch (property_id) {
		case DINO_UI_APPLICATION_DB_PROPERTY:
		qlite_value_set_database (value, dino_application_get_db ((DinoApplication*) self));
		break;
		case DINO_UI_APPLICATION_SETTINGS_PROPERTY:
		g_value_set_object (value, dino_application_get_settings ((DinoApplication*) self));
		break;
		case DINO_UI_APPLICATION_STREAM_INTERACTOR_PROPERTY:
		g_value_set_object (value, dino_application_get_stream_interactor ((DinoApplication*) self));
		break;
		case DINO_UI_APPLICATION_PLUGIN_REGISTRY_PROPERTY:
		dino_plugins_value_set_registry (value, dino_application_get_plugin_registry ((DinoApplication*) self));
		break;
		case DINO_UI_APPLICATION_SEARCH_PATH_GENERATOR_PROPERTY:
		dino_value_set_search_path_generator (value, dino_application_get_search_path_generator ((DinoApplication*) self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_dino_ui_application_set_property (GObject * object,
                                        guint property_id,
                                        const GValue * value,
                                        GParamSpec * pspec)
{
	DinoUiApplication * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, DINO_UI_TYPE_APPLICATION, DinoUiApplication);
	switch (property_id) {
		case DINO_UI_APPLICATION_DB_PROPERTY:
		dino_application_set_db ((DinoApplication*) self, qlite_value_get_database (value));
		break;
		case DINO_UI_APPLICATION_SETTINGS_PROPERTY:
		dino_application_set_settings ((DinoApplication*) self, g_value_get_object (value));
		break;
		case DINO_UI_APPLICATION_STREAM_INTERACTOR_PROPERTY:
		dino_application_set_stream_interactor ((DinoApplication*) self, g_value_get_object (value));
		break;
		case DINO_UI_APPLICATION_PLUGIN_REGISTRY_PROPERTY:
		dino_application_set_plugin_registry ((DinoApplication*) self, dino_plugins_value_get_registry (value));
		break;
		case DINO_UI_APPLICATION_SEARCH_PATH_GENERATOR_PROPERTY:
		dino_application_set_search_path_generator ((DinoApplication*) self, dino_value_get_search_path_generator (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_array_destroy (gpointer array,
                     gssize array_length,
                     GDestroyNotify destroy_func)
{
	if ((array != NULL) && (destroy_func != NULL)) {
		gssize i;
		for (i = 0; i < array_length; i = i + 1) {
			if (((gpointer*) array)[i] != NULL) {
				destroy_func (((gpointer*) array)[i]);
			}
		}
	}
}

static void
_vala_array_free (gpointer array,
                  gssize array_length,
                  GDestroyNotify destroy_func)
{
	_vala_array_destroy (array, array_length, destroy_func);
	g_free (array);
}

