diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2018-06-25 21:12:13 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2018-06-25 21:12:13 +0200 |
commit | 059a62ee3c820a42fbce980c3256049adecc9100 (patch) | |
tree | e51eab94fd7d65459640ca227fb2257bb41d2acb /src/searches/SearchesBranch.c | |
parent | 55778740c211992cc86ea87588ab62c6750f36d1 (diff) | |
parent | e8f4d7a9cdd37c5a9fb3b6991a4e9173829808da (diff) |
Merge branch 'feature/upstream' into develop
Diffstat (limited to 'src/searches/SearchesBranch.c')
-rw-r--r-- | src/searches/SearchesBranch.c | 658 |
1 files changed, 379 insertions, 279 deletions
diff --git a/src/searches/SearchesBranch.c b/src/searches/SearchesBranch.c index dfa635b..ce75f2a 100644 --- a/src/searches/SearchesBranch.c +++ b/src/searches/SearchesBranch.c @@ -1,4 +1,4 @@ -/* SearchesBranch.c generated by valac 0.36.6, the Vala compiler +/* SearchesBranch.c generated by valac 0.40.4, the Vala compiler * generated from SearchesBranch.vala, do not modify */ /* Copyright 2016 Software Freedom Conservancy Inc. @@ -7,6 +7,7 @@ * See the COPYING file in this distribution. */ + #include <glib.h> #include <glib-object.h> #include <gee.h> @@ -89,6 +90,11 @@ typedef struct _SidebarSimplePageEntryClass SidebarSimplePageEntryClass; typedef struct _SearchesSidebarEntry SearchesSidebarEntry; typedef struct _SearchesSidebarEntryClass SearchesSidebarEntryClass; +enum { + SEARCHES_BRANCH_0_PROPERTY, + SEARCHES_BRANCH_NUM_PROPERTIES +}; +static GParamSpec* searches_branch_properties[SEARCHES_BRANCH_NUM_PROPERTIES]; #define TYPE_SAVED_SEARCH_TABLE (saved_search_table_get_type ()) #define SAVED_SEARCH_TABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SAVED_SEARCH_TABLE, SavedSearchTable)) @@ -186,6 +192,11 @@ typedef struct _SidebarHeaderPrivate SidebarHeaderPrivate; typedef struct _SidebarContextable SidebarContextable; typedef struct _SidebarContextableIface SidebarContextableIface; typedef struct _SearchesHeaderPrivate SearchesHeaderPrivate; +enum { + SEARCHES_HEADER_0_PROPERTY, + SEARCHES_HEADER_NUM_PROPERTIES +}; +static GParamSpec* searches_header_properties[SEARCHES_HEADER_NUM_PROPERTIES]; #define _g_free0(var) (var = (g_free (var), NULL)) #define TYPE_APPLICATION (application_get_type ()) @@ -235,6 +246,11 @@ typedef struct _SidebarSimplePageEntryPrivate SidebarSimplePageEntryPrivate; typedef struct _SidebarDestroyableEntry SidebarDestroyableEntry; typedef struct _SidebarDestroyableEntryIface SidebarDestroyableEntryIface; typedef struct _SearchesSidebarEntryPrivate SearchesSidebarEntryPrivate; +enum { + SEARCHES_SIDEBAR_ENTRY_0_PROPERTY, + SEARCHES_SIDEBAR_ENTRY_NUM_PROPERTIES +}; +static GParamSpec* searches_sidebar_entry_properties[SEARCHES_SIDEBAR_ENTRY_NUM_PROPERTIES]; #define TYPE_CHECKERBOARD_PAGE (checkerboard_page_get_type ()) #define CHECKERBOARD_PAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CHECKERBOARD_PAGE, CheckerboardPage)) @@ -494,21 +510,30 @@ GType saved_search_get_type (void) G_GNUC_CONST; GType sidebar_simple_page_entry_get_type (void) G_GNUC_CONST; GType searches_sidebar_entry_get_type (void) G_GNUC_CONST; #define SEARCHES_BRANCH_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), SEARCHES_TYPE_BRANCH, SearchesBranchPrivate)) -enum { - SEARCHES_BRANCH_DUMMY_PROPERTY -}; gpointer saved_search_table_ref (gpointer instance); void saved_search_table_unref (gpointer instance); -GParamSpec* param_spec_saved_search_table (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_saved_search_table (GValue* value, gpointer v_object); -void value_take_saved_search_table (GValue* value, gpointer v_object); +GParamSpec* param_spec_saved_search_table (const gchar* name, + const gchar* nick, + const gchar* blurb, + GType object_type, + GParamFlags flags); +void value_set_saved_search_table (GValue* value, + gpointer v_object); +void value_take_saved_search_table (GValue* value, + gpointer v_object); gpointer value_get_saved_search_table (const GValue* value); GType saved_search_table_get_type (void) G_GNUC_CONST; SavedSearchTable* saved_search_table_get_instance (void); -static void searches_branch_on_saved_search_added (SearchesBranch* self, SavedSearch* search); -static void _searches_branch_on_saved_search_added_saved_search_table_search_added (SavedSearchTable* _sender, SavedSearch* search, gpointer self); -static void searches_branch_on_saved_search_removed (SearchesBranch* self, SavedSearch* search); -static void _searches_branch_on_saved_search_removed_saved_search_table_search_removed (SavedSearchTable* _sender, SavedSearch* search, gpointer self); +static void searches_branch_on_saved_search_added (SearchesBranch* self, + SavedSearch* search); +static void _searches_branch_on_saved_search_added_saved_search_table_search_added (SavedSearchTable* _sender, + SavedSearch* search, + gpointer self); +static void searches_branch_on_saved_search_removed (SearchesBranch* self, + SavedSearch* search); +static void _searches_branch_on_saved_search_removed_saved_search_table_search_removed (SavedSearchTable* _sender, + SavedSearch* search, + gpointer self); SearchesBranch* searches_branch_new (void); SearchesBranch* searches_branch_construct (GType object_type); SearchesHeader* searches_header_new (void); @@ -519,52 +544,75 @@ GType searches_header_get_type (void) G_GNUC_CONST; GType sidebar_tree_get_type (void) G_GNUC_CONST; GType sidebar_entry_get_type (void) G_GNUC_CONST; GType sidebar_branch_options_get_type (void) G_GNUC_CONST; -static gint searches_branch_comparator (SidebarEntry* a, SidebarEntry* b); -static gint _searches_branch_comparator_gcompare_func (gconstpointer a, gconstpointer b); -SidebarBranch* sidebar_branch_new (SidebarEntry* root, SidebarBranchOptions options, GCompareFunc default_comparator, GCompareFunc root_comparator); -SidebarBranch* sidebar_branch_construct (GType object_type, SidebarEntry* root, SidebarBranchOptions options, GCompareFunc default_comparator, GCompareFunc root_comparator); +static gint searches_branch_comparator (SidebarEntry* a, + SidebarEntry* b); +static gint _searches_branch_comparator_gcompare_func (gconstpointer a, + gconstpointer b); +SidebarBranch* sidebar_branch_new (SidebarEntry* root, + SidebarBranchOptions options, + GCompareFunc default_comparator, + GCompareFunc root_comparator); +SidebarBranch* sidebar_branch_construct (GType object_type, + SidebarEntry* root, + SidebarBranchOptions options, + GCompareFunc default_comparator, + GCompareFunc root_comparator); GeeCollection* saved_search_table_get_all (SavedSearchTable* self); -SearchesSidebarEntry* searches_branch_get_entry_for_saved_search (SearchesBranch* self, SavedSearch* search); -gint saved_search_compare_names (void* a, void* b); +SearchesSidebarEntry* searches_branch_get_entry_for_saved_search (SearchesBranch* self, + SavedSearch* search); +gint saved_search_compare_names (void* a, + void* b); SavedSearch* searches_sidebar_entry_for_saved_search (SearchesSidebarEntry* self); SearchesSidebarEntry* searches_sidebar_entry_new (SavedSearch* search); -SearchesSidebarEntry* searches_sidebar_entry_construct (GType object_type, SavedSearch* search); -void sidebar_branch_graft (SidebarBranch* self, SidebarEntry* parent, SidebarEntry* entry, GCompareFunc comparator); +SearchesSidebarEntry* searches_sidebar_entry_construct (GType object_type, + SavedSearch* search); +void sidebar_branch_graft (SidebarBranch* self, + SidebarEntry* parent, + SidebarEntry* entry, + GCompareFunc comparator); SidebarEntry* sidebar_branch_get_root (SidebarBranch* self); -void sidebar_branch_prune (SidebarBranch* self, SidebarEntry* entry); +void sidebar_branch_prune (SidebarBranch* self, + SidebarEntry* entry); static void searches_branch_finalize (GObject * obj); GType sidebar_expandable_entry_get_type (void) G_GNUC_CONST; GType sidebar_renameable_entry_get_type (void) G_GNUC_CONST; GType sidebar_emphasizable_entry_get_type (void) G_GNUC_CONST; GType sidebar_contextable_get_type (void) G_GNUC_CONST; #define SEARCHES_HEADER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), SEARCHES_TYPE_HEADER, SearchesHeaderPrivate)) -enum { - SEARCHES_HEADER_DUMMY_PROPERTY -}; -SidebarHeader* sidebar_header_new (const gchar* name, const gchar* tooltip, gboolean emphasized); -SidebarHeader* sidebar_header_construct (GType object_type, const gchar* name, const gchar* tooltip, gboolean emphasized); +SidebarHeader* sidebar_header_new (const gchar* name, + const gchar* tooltip, + gboolean emphasized); +SidebarHeader* sidebar_header_construct (GType object_type, + const gchar* name, + const gchar* tooltip, + gboolean emphasized); static void searches_header_setup_context_menu (SearchesHeader* self); gchar* resources_get_ui (const gchar* filename); -void app_window_error_message (const gchar* message, GtkWindow* parent); +void app_window_error_message (const gchar* message, + GtkWindow* parent); gpointer application_ref (gpointer instance); void application_unref (gpointer instance); -GParamSpec* param_spec_application (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_application (GValue* value, gpointer v_object); -void value_take_application (GValue* value, gpointer v_object); +GParamSpec* param_spec_application (const gchar* name, + const gchar* nick, + const gchar* blurb, + GType object_type, + GParamFlags flags); +void value_set_application (GValue* value, + gpointer v_object); +void value_take_application (GValue* value, + gpointer v_object); gpointer value_get_application (const GValue* value); GType application_get_type (void) G_GNUC_CONST; Application* application_get_instance (void); void application_panic (Application* self); -static GtkMenu* searches_header_real_get_sidebar_context_menu (SidebarContextable* base, GdkEventButton* event); +static GtkMenu* searches_header_real_get_sidebar_context_menu (SidebarContextable* base, + GdkEventButton* event); static void searches_header_finalize (GObject * obj); GType sidebar_selectable_entry_get_type (void) G_GNUC_CONST; GType page_get_type (void) G_GNUC_CONST; GType sidebar_page_representative_get_type (void) G_GNUC_CONST; GType sidebar_destroyable_entry_get_type (void) G_GNUC_CONST; #define SEARCHES_SIDEBAR_ENTRY_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), SEARCHES_TYPE_SIDEBAR_ENTRY, SearchesSidebarEntryPrivate)) -enum { - SEARCHES_SIDEBAR_ENTRY_DUMMY_PROPERTY -}; SidebarSimplePageEntry* sidebar_simple_page_entry_construct (GType object_type); void searches_sidebar_entry_init (void); void searches_sidebar_entry_terminate (void); @@ -573,26 +621,39 @@ gchar* data_object_get_name (DataObject* self); static gchar* searches_sidebar_entry_real_get_sidebar_icon (SidebarSimplePageEntry* base); static Page* searches_sidebar_entry_real_create_page (SidebarSimplePageEntry* base); SavedSearchPage* saved_search_page_new (SavedSearch* search); -SavedSearchPage* saved_search_page_construct (GType object_type, SavedSearch* search); +SavedSearchPage* saved_search_page_construct (GType object_type, + SavedSearch* search); GType checkerboard_page_get_type (void) G_GNUC_CONST; GType media_page_get_type (void) G_GNUC_CONST; GType collection_page_get_type (void) G_GNUC_CONST; GType saved_search_page_get_type (void) G_GNUC_CONST; static gboolean searches_sidebar_entry_real_is_user_renameable (SidebarRenameableEntry* base); -static void searches_sidebar_entry_real_rename (SidebarRenameableEntry* base, const gchar* new_name); -gboolean saved_search_table_exists (SavedSearchTable* self, const gchar* search_name); +static void searches_sidebar_entry_real_rename (SidebarRenameableEntry* base, + const gchar* new_name); +gboolean saved_search_table_exists (SavedSearchTable* self, + const gchar* search_name); gpointer command_manager_ref (gpointer instance); void command_manager_unref (gpointer instance); -GParamSpec* param_spec_command_manager (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_command_manager (GValue* value, gpointer v_object); -void value_take_command_manager (GValue* value, gpointer v_object); +GParamSpec* param_spec_command_manager (const gchar* name, + const gchar* nick, + const gchar* blurb, + GType object_type, + GParamFlags flags); +void value_set_command_manager (GValue* value, + gpointer v_object); +void value_take_command_manager (GValue* value, + gpointer v_object); gpointer value_get_command_manager (const GValue* value); GType command_manager_get_type (void) G_GNUC_CONST; CommandManager* app_window_get_command_manager (void); GType command_get_type (void) G_GNUC_CONST; -void command_manager_execute (CommandManager* self, Command* command); -RenameSavedSearchCommand* rename_saved_search_command_new (SavedSearch* search, const gchar* new_name); -RenameSavedSearchCommand* rename_saved_search_command_construct (GType object_type, SavedSearch* search, const gchar* new_name); +void command_manager_execute (CommandManager* self, + Command* command); +RenameSavedSearchCommand* rename_saved_search_command_new (SavedSearch* search, + const gchar* new_name); +RenameSavedSearchCommand* rename_saved_search_command_construct (GType object_type, + SavedSearch* search, + const gchar* new_name); GType page_command_get_type (void) G_GNUC_CONST; GType single_data_source_command_get_type (void) G_GNUC_CONST; GType rename_saved_search_command_get_type (void) G_GNUC_CONST; @@ -600,42 +661,56 @@ gchar* resources_rename_search_exists_message (const gchar* name); static void searches_sidebar_entry_real_destroy_source (SidebarDestroyableEntry* base); gboolean dialogs_confirm_delete_saved_search (SavedSearch* search); DeleteSavedSearchCommand* delete_saved_search_command_new (SavedSearch* search); -DeleteSavedSearchCommand* delete_saved_search_command_construct (GType object_type, SavedSearch* search); +DeleteSavedSearchCommand* delete_saved_search_command_construct (GType object_type, + SavedSearch* search); GType delete_saved_search_command_get_type (void) G_GNUC_CONST; static void searches_sidebar_entry_finalize (GObject * obj); -static void _searches_branch_on_saved_search_added_saved_search_table_search_added (SavedSearchTable* _sender, SavedSearch* search, gpointer self) { +static void +_searches_branch_on_saved_search_added_saved_search_table_search_added (SavedSearchTable* _sender, + SavedSearch* search, + gpointer self) +{ #line 28 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" searches_branch_on_saved_search_added ((SearchesBranch*) self, search); -#line 612 "SearchesBranch.c" +#line 678 "SearchesBranch.c" } -static void _searches_branch_on_saved_search_removed_saved_search_table_search_removed (SavedSearchTable* _sender, SavedSearch* search, gpointer self) { +static void +_searches_branch_on_saved_search_removed_saved_search_table_search_removed (SavedSearchTable* _sender, + SavedSearch* search, + gpointer self) +{ #line 29 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" searches_branch_on_saved_search_removed ((SearchesBranch*) self, search); -#line 619 "SearchesBranch.c" +#line 689 "SearchesBranch.c" } -static gint _searches_branch_comparator_gcompare_func (gconstpointer a, gconstpointer b) { +static gint +_searches_branch_comparator_gcompare_func (gconstpointer a, + gconstpointer b) +{ gint result; result = searches_branch_comparator ((SidebarEntry*) a, (SidebarEntry*) b); #line 12 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return result; -#line 628 "SearchesBranch.c" +#line 701 "SearchesBranch.c" } -SearchesBranch* searches_branch_construct (GType object_type) { +SearchesBranch* +searches_branch_construct (GType object_type) +{ SearchesBranch * self = NULL; SearchesHeader* _tmp0_; SearchesHeader* _tmp1_; + SavedSearchTable* _tmp12_; SavedSearchTable* _tmp13_; SavedSearchTable* _tmp14_; SavedSearchTable* _tmp15_; - SavedSearchTable* _tmp16_; #line 12 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _tmp0_ = searches_header_new (); #line 12 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" @@ -644,7 +719,7 @@ SearchesBranch* searches_branch_construct (GType object_type) { self = (SearchesBranch*) sidebar_branch_construct (object_type, G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, SIDEBAR_TYPE_ENTRY, SidebarEntry), (SIDEBAR_BRANCH_OPTIONS_HIDE_IF_EMPTY | SIDEBAR_BRANCH_OPTIONS_AUTO_OPEN_ON_NEW_CHILD) | SIDEBAR_BRANCH_OPTIONS_STARTUP_EXPAND_TO_FIRST_CHILD, _searches_branch_comparator_gcompare_func, NULL); #line 12 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _g_object_unref0 (_tmp1_); -#line 648 "SearchesBranch.c" +#line 723 "SearchesBranch.c" { GeeIterator* _search_it = NULL; SavedSearchTable* _tmp2_; @@ -673,75 +748,76 @@ SearchesBranch* searches_branch_construct (GType object_type) { _search_it = _tmp7_; #line 19 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" while (TRUE) { -#line 677 "SearchesBranch.c" +#line 752 "SearchesBranch.c" GeeIterator* _tmp8_; - gboolean _tmp9_; SavedSearch* search = NULL; - GeeIterator* _tmp10_; - gpointer _tmp11_; - SavedSearch* _tmp12_; + GeeIterator* _tmp9_; + gpointer _tmp10_; + SavedSearch* _tmp11_; #line 19 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _tmp8_ = _search_it; #line 19 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp9_ = gee_iterator_next (_tmp8_); -#line 19 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - if (!_tmp9_) { + if (!gee_iterator_next (_tmp8_)) { #line 19 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" break; -#line 692 "SearchesBranch.c" +#line 764 "SearchesBranch.c" } #line 19 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp10_ = _search_it; + _tmp9_ = _search_it; #line 19 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp11_ = gee_iterator_get (_tmp10_); + _tmp10_ = gee_iterator_get (_tmp9_); #line 19 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - search = (SavedSearch*) _tmp11_; + search = (SavedSearch*) _tmp10_; #line 20 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp12_ = search; + _tmp11_ = search; #line 20 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - searches_branch_on_saved_search_added (self, _tmp12_); + searches_branch_on_saved_search_added (self, _tmp11_); #line 19 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _g_object_unref0 (search); -#line 706 "SearchesBranch.c" +#line 778 "SearchesBranch.c" } #line 19 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _g_object_unref0 (_search_it); -#line 710 "SearchesBranch.c" +#line 782 "SearchesBranch.c" } #line 23 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp13_ = saved_search_table_get_instance (); + _tmp12_ = saved_search_table_get_instance (); #line 23 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp14_ = _tmp13_; + _tmp13_ = _tmp12_; #line 23 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - g_signal_connect_object (_tmp14_, "search-added", (GCallback) _searches_branch_on_saved_search_added_saved_search_table_search_added, self, 0); + g_signal_connect_object (_tmp13_, "search-added", (GCallback) _searches_branch_on_saved_search_added_saved_search_table_search_added, self, 0); #line 23 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _saved_search_table_unref0 (_tmp14_); + _saved_search_table_unref0 (_tmp13_); #line 24 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp15_ = saved_search_table_get_instance (); + _tmp14_ = saved_search_table_get_instance (); #line 24 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp16_ = _tmp15_; + _tmp15_ = _tmp14_; #line 24 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - g_signal_connect_object (_tmp16_, "search-removed", (GCallback) _searches_branch_on_saved_search_removed_saved_search_table_search_removed, self, 0); + g_signal_connect_object (_tmp15_, "search-removed", (GCallback) _searches_branch_on_saved_search_removed_saved_search_table_search_removed, self, 0); #line 24 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _saved_search_table_unref0 (_tmp16_); + _saved_search_table_unref0 (_tmp15_); #line 11 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return self; -#line 730 "SearchesBranch.c" +#line 802 "SearchesBranch.c" } -SearchesBranch* searches_branch_new (void) { +SearchesBranch* +searches_branch_new (void) +{ #line 11 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return searches_branch_construct (SEARCHES_TYPE_BRANCH); -#line 737 "SearchesBranch.c" +#line 811 "SearchesBranch.c" } -SearchesSidebarEntry* searches_branch_get_entry_for_saved_search (SearchesBranch* self, SavedSearch* search) { +SearchesSidebarEntry* +searches_branch_get_entry_for_saved_search (SearchesBranch* self, + SavedSearch* search) +{ SearchesSidebarEntry* result = NULL; GeeHashMap* _tmp0_; - SavedSearch* _tmp1_; - gpointer _tmp2_; + gpointer _tmp1_; #line 32 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" g_return_val_if_fail (SEARCHES_IS_BRANCH (self), NULL); #line 32 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" @@ -749,68 +825,55 @@ SearchesSidebarEntry* searches_branch_get_entry_for_saved_search (SearchesBranch #line 33 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _tmp0_ = self->priv->entry_map; #line 33 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp1_ = search; + _tmp1_ = gee_abstract_map_get (G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, GEE_TYPE_ABSTRACT_MAP, GeeAbstractMap), search); #line 33 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp2_ = gee_abstract_map_get (G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, GEE_TYPE_ABSTRACT_MAP, GeeAbstractMap), _tmp1_); -#line 33 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - result = (SearchesSidebarEntry*) _tmp2_; + result = (SearchesSidebarEntry*) _tmp1_; #line 33 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return result; -#line 760 "SearchesBranch.c" +#line 834 "SearchesBranch.c" } -static gint searches_branch_comparator (SidebarEntry* a, SidebarEntry* b) { +static gint +searches_branch_comparator (SidebarEntry* a, + SidebarEntry* b) +{ gint result = 0; - SidebarEntry* _tmp0_; - SidebarEntry* _tmp1_; - SidebarEntry* _tmp2_; - SavedSearch* _tmp3_; - SidebarEntry* _tmp4_; - SavedSearch* _tmp5_; - gint _tmp6_; + SavedSearch* _tmp0_; + SavedSearch* _tmp1_; #line 36 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" g_return_val_if_fail (SIDEBAR_IS_ENTRY (a), 0); #line 36 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" g_return_val_if_fail (SIDEBAR_IS_ENTRY (b), 0); #line 37 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp0_ = a; -#line 37 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp1_ = b; -#line 37 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - if (_tmp0_ == _tmp1_) { + if (a == b) { #line 38 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" result = 0; #line 38 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return result; -#line 787 "SearchesBranch.c" +#line 855 "SearchesBranch.c" } #line 40 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp2_ = a; -#line 40 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp3_ = searches_sidebar_entry_for_saved_search (G_TYPE_CHECK_INSTANCE_CAST (_tmp2_, SEARCHES_TYPE_SIDEBAR_ENTRY, SearchesSidebarEntry)); -#line 40 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp4_ = b; + _tmp0_ = searches_sidebar_entry_for_saved_search (G_TYPE_CHECK_INSTANCE_CAST (a, SEARCHES_TYPE_SIDEBAR_ENTRY, SearchesSidebarEntry)); #line 40 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp5_ = searches_sidebar_entry_for_saved_search (G_TYPE_CHECK_INSTANCE_CAST (_tmp4_, SEARCHES_TYPE_SIDEBAR_ENTRY, SearchesSidebarEntry)); + _tmp1_ = searches_sidebar_entry_for_saved_search (G_TYPE_CHECK_INSTANCE_CAST (b, SEARCHES_TYPE_SIDEBAR_ENTRY, SearchesSidebarEntry)); #line 40 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp6_ = saved_search_compare_names (_tmp3_, _tmp5_); -#line 40 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - result = _tmp6_; + result = saved_search_compare_names (_tmp0_, _tmp1_); #line 40 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return result; -#line 803 "SearchesBranch.c" +#line 865 "SearchesBranch.c" } -static void searches_branch_on_saved_search_added (SearchesBranch* self, SavedSearch* search) { +static void +searches_branch_on_saved_search_added (SearchesBranch* self, + SavedSearch* search) +{ SearchesSidebarEntry* entry = NULL; - SavedSearch* _tmp0_; - SearchesSidebarEntry* _tmp1_; - GeeHashMap* _tmp2_; - SavedSearch* _tmp3_; - SidebarEntry* _tmp4_; - SidebarEntry* _tmp5_; + SearchesSidebarEntry* _tmp0_; + GeeHashMap* _tmp1_; + SidebarEntry* _tmp2_; + SidebarEntry* _tmp3_; #line 44 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" g_return_if_fail (SEARCHES_IS_BRANCH (self)); #line 44 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" @@ -818,40 +881,37 @@ static void searches_branch_on_saved_search_added (SearchesBranch* self, SavedSe #line 45 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" g_debug ("SearchesBranch.vala:45: search added"); #line 46 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp0_ = search; + _tmp0_ = searches_sidebar_entry_new (search); #line 46 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp1_ = searches_sidebar_entry_new (_tmp0_); -#line 46 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - entry = _tmp1_; -#line 47 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp2_ = self->priv->entry_map; + entry = _tmp0_; #line 47 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp3_ = search; + _tmp1_ = self->priv->entry_map; #line 47 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - gee_abstract_map_set (G_TYPE_CHECK_INSTANCE_CAST (_tmp2_, GEE_TYPE_ABSTRACT_MAP, GeeAbstractMap), _tmp3_, entry); + gee_abstract_map_set (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, GEE_TYPE_ABSTRACT_MAP, GeeAbstractMap), search, entry); #line 48 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp4_ = sidebar_branch_get_root (G_TYPE_CHECK_INSTANCE_CAST (self, SIDEBAR_TYPE_BRANCH, SidebarBranch)); + _tmp2_ = sidebar_branch_get_root (G_TYPE_CHECK_INSTANCE_CAST (self, SIDEBAR_TYPE_BRANCH, SidebarBranch)); #line 48 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp5_ = _tmp4_; + _tmp3_ = _tmp2_; #line 48 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - sidebar_branch_graft (G_TYPE_CHECK_INSTANCE_CAST (self, SIDEBAR_TYPE_BRANCH, SidebarBranch), _tmp5_, G_TYPE_CHECK_INSTANCE_CAST (entry, SIDEBAR_TYPE_ENTRY, SidebarEntry), NULL); + sidebar_branch_graft (G_TYPE_CHECK_INSTANCE_CAST (self, SIDEBAR_TYPE_BRANCH, SidebarBranch), _tmp3_, G_TYPE_CHECK_INSTANCE_CAST (entry, SIDEBAR_TYPE_ENTRY, SidebarEntry), NULL); #line 48 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _g_object_unref0 (_tmp5_); + _g_object_unref0 (_tmp3_); #line 44 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _g_object_unref0 (entry); -#line 843 "SearchesBranch.c" +#line 902 "SearchesBranch.c" } -static void searches_branch_on_saved_search_removed (SearchesBranch* self, SavedSearch* search) { +static void +searches_branch_on_saved_search_removed (SearchesBranch* self, + SavedSearch* search) +{ SearchesSidebarEntry* entry = NULL; GeeHashMap* _tmp0_; - SavedSearch* _tmp1_; - gpointer _tmp2_; + gpointer _tmp1_; gboolean is_removed = FALSE; - GeeHashMap* _tmp3_; - SavedSearch* _tmp4_; - gboolean _tmp5_; + GeeHashMap* _tmp2_; + gboolean _tmp3_; #line 51 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" g_return_if_fail (SEARCHES_IS_BRANCH (self)); #line 51 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" @@ -861,43 +921,43 @@ static void searches_branch_on_saved_search_removed (SearchesBranch* self, Saved #line 53 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _tmp0_ = self->priv->entry_map; #line 53 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp1_ = search; -#line 53 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp2_ = gee_abstract_map_get (G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, GEE_TYPE_ABSTRACT_MAP, GeeAbstractMap), _tmp1_); + _tmp1_ = gee_abstract_map_get (G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, GEE_TYPE_ABSTRACT_MAP, GeeAbstractMap), search); #line 53 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - entry = (SearchesSidebarEntry*) _tmp2_; + entry = (SearchesSidebarEntry*) _tmp1_; #line 54 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _vala_assert (entry != NULL, "entry != null"); #line 56 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp3_ = self->priv->entry_map; -#line 56 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp4_ = search; + _tmp2_ = self->priv->entry_map; #line 56 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp5_ = gee_abstract_map_unset (G_TYPE_CHECK_INSTANCE_CAST (_tmp3_, GEE_TYPE_ABSTRACT_MAP, GeeAbstractMap), _tmp4_, NULL); + _tmp3_ = gee_abstract_map_unset (G_TYPE_CHECK_INSTANCE_CAST (_tmp2_, GEE_TYPE_ABSTRACT_MAP, GeeAbstractMap), search, NULL); #line 56 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - is_removed = _tmp5_; + is_removed = _tmp3_; #line 57 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _vala_assert (is_removed, "is_removed"); #line 59 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" sidebar_branch_prune (G_TYPE_CHECK_INSTANCE_CAST (self, SIDEBAR_TYPE_BRANCH, SidebarBranch), G_TYPE_CHECK_INSTANCE_CAST (entry, SIDEBAR_TYPE_ENTRY, SidebarEntry)); #line 51 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _g_object_unref0 (entry); -#line 886 "SearchesBranch.c" +#line 942 "SearchesBranch.c" } -static void searches_branch_class_init (SearchesBranchClass * klass) { +static void +searches_branch_class_init (SearchesBranchClass * klass) +{ #line 7 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" searches_branch_parent_class = g_type_class_peek_parent (klass); #line 7 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" g_type_class_add_private (klass, sizeof (SearchesBranchPrivate)); #line 7 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" G_OBJECT_CLASS (klass)->finalize = searches_branch_finalize; -#line 897 "SearchesBranch.c" +#line 955 "SearchesBranch.c" } -static void searches_branch_instance_init (SearchesBranch * self) { +static void +searches_branch_instance_init (SearchesBranch * self) +{ GeeHashMap* _tmp0_; #line 7 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self->priv = SEARCHES_BRANCH_GET_PRIVATE (self); @@ -905,11 +965,13 @@ static void searches_branch_instance_init (SearchesBranch * self) { _tmp0_ = gee_hash_map_new (TYPE_SAVED_SEARCH, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, SEARCHES_TYPE_SIDEBAR_ENTRY, (GBoxedCopyFunc) g_object_ref, (GDestroyNotify) g_object_unref, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); #line 8 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self->priv->entry_map = _tmp0_; -#line 909 "SearchesBranch.c" +#line 969 "SearchesBranch.c" } -static void searches_branch_finalize (GObject * obj) { +static void +searches_branch_finalize (GObject * obj) +{ SearchesBranch * self; SavedSearchTable* _tmp0_; SavedSearchTable* _tmp1_; @@ -943,11 +1005,13 @@ static void searches_branch_finalize (GObject * obj) { _g_object_unref0 (self->priv->entry_map); #line 7 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" G_OBJECT_CLASS (searches_branch_parent_class)->finalize (obj); -#line 947 "SearchesBranch.c" +#line 1009 "SearchesBranch.c" } -GType searches_branch_get_type (void) { +GType +searches_branch_get_type (void) +{ static volatile gsize searches_branch_type_id__volatile = 0; if (g_once_init_enter (&searches_branch_type_id__volatile)) { static const GTypeInfo g_define_type_info = { sizeof (SearchesBranchClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) searches_branch_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SearchesBranch), 0, (GInstanceInitFunc) searches_branch_instance_init, NULL }; @@ -959,7 +1023,9 @@ GType searches_branch_get_type (void) { } -SearchesHeader* searches_header_construct (GType object_type) { +SearchesHeader* +searches_header_construct (GType object_type) +{ SearchesHeader * self = NULL; #line 68 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self = (SearchesHeader*) sidebar_header_construct (object_type, _ ("Saved Searches"), _ ("Organize your saved searches"), TRUE); @@ -967,25 +1033,31 @@ SearchesHeader* searches_header_construct (GType object_type) { searches_header_setup_context_menu (self); #line 67 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return self; -#line 971 "SearchesBranch.c" +#line 1037 "SearchesBranch.c" } -SearchesHeader* searches_header_new (void) { +SearchesHeader* +searches_header_new (void) +{ #line 67 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return searches_header_construct (SEARCHES_TYPE_HEADER); -#line 978 "SearchesBranch.c" +#line 1046 "SearchesBranch.c" } -static gpointer _g_object_ref0 (gpointer self) { +static gpointer +_g_object_ref0 (gpointer self) +{ #line 76 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return self ? g_object_ref (self) : NULL; -#line 985 "SearchesBranch.c" +#line 1055 "SearchesBranch.c" } -static void searches_header_setup_context_menu (SearchesHeader* self) { +static void +searches_header_setup_context_menu (SearchesHeader* self) +{ GtkBuilder* _tmp0_; GError * _inner_error_ = NULL; #line 72 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" @@ -996,7 +1068,7 @@ static void searches_header_setup_context_menu (SearchesHeader* self) { _g_object_unref0 (self->priv->builder); #line 73 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self->priv->builder = _tmp0_; -#line 1000 "SearchesBranch.c" +#line 1072 "SearchesBranch.c" { GtkBuilder* _tmp1_; gchar* _tmp2_; @@ -1019,7 +1091,7 @@ static void searches_header_setup_context_menu (SearchesHeader* self) { _g_free0 (_tmp3_); #line 75 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1023 "SearchesBranch.c" +#line 1095 "SearchesBranch.c" goto __catch85_g_error; } #line 76 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" @@ -1042,7 +1114,7 @@ static void searches_header_setup_context_menu (SearchesHeader* self) { self->priv->context_menu = _tmp8_; #line 74 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _g_object_unref0 (model); -#line 1046 "SearchesBranch.c" +#line 1118 "SearchesBranch.c" } goto __finally85; __catch85_g_error: @@ -1080,7 +1152,7 @@ static void searches_header_setup_context_menu (SearchesHeader* self) { _application_unref0 (_tmp14_); #line 74 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _g_error_free0 (_error_); -#line 1084 "SearchesBranch.c" +#line 1156 "SearchesBranch.c" } __finally85: #line 74 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" @@ -1091,12 +1163,15 @@ static void searches_header_setup_context_menu (SearchesHeader* self) { g_clear_error (&_inner_error_); #line 74 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return; -#line 1095 "SearchesBranch.c" +#line 1167 "SearchesBranch.c" } } -static GtkMenu* searches_header_real_get_sidebar_context_menu (SidebarContextable* base, GdkEventButton* event) { +static GtkMenu* +searches_header_real_get_sidebar_context_menu (SidebarContextable* base, + GdkEventButton* event) +{ SearchesHeader * self; GtkMenu* result = NULL; GtkMenu* _tmp0_; @@ -1111,40 +1186,48 @@ static GtkMenu* searches_header_real_get_sidebar_context_menu (SidebarContextabl result = _tmp1_; #line 86 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return result; -#line 1115 "SearchesBranch.c" +#line 1190 "SearchesBranch.c" } -static void searches_header_class_init (SearchesHeaderClass * klass) { +static void +searches_header_class_init (SearchesHeaderClass * klass) +{ #line 63 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" searches_header_parent_class = g_type_class_peek_parent (klass); #line 63 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" g_type_class_add_private (klass, sizeof (SearchesHeaderPrivate)); #line 63 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" G_OBJECT_CLASS (klass)->finalize = searches_header_finalize; -#line 1126 "SearchesBranch.c" +#line 1203 "SearchesBranch.c" } -static void searches_header_sidebar_contextable_interface_init (SidebarContextableIface * iface) { +static void +searches_header_sidebar_contextable_interface_init (SidebarContextableIface * iface) +{ #line 63 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" searches_header_sidebar_contextable_parent_iface = g_type_interface_peek_parent (iface); #line 63 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" iface->get_sidebar_context_menu = (GtkMenu* (*) (SidebarContextable *, GdkEventButton*)) searches_header_real_get_sidebar_context_menu; -#line 1135 "SearchesBranch.c" +#line 1214 "SearchesBranch.c" } -static void searches_header_instance_init (SearchesHeader * self) { +static void +searches_header_instance_init (SearchesHeader * self) +{ #line 63 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self->priv = SEARCHES_HEADER_GET_PRIVATE (self); #line 65 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self->priv->context_menu = NULL; -#line 1144 "SearchesBranch.c" +#line 1225 "SearchesBranch.c" } -static void searches_header_finalize (GObject * obj) { +static void +searches_header_finalize (GObject * obj) +{ SearchesHeader * self; #line 63 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self = G_TYPE_CHECK_INSTANCE_CAST (obj, SEARCHES_TYPE_HEADER, SearchesHeader); @@ -1154,11 +1237,13 @@ static void searches_header_finalize (GObject * obj) { _g_object_unref0 (self->priv->context_menu); #line 63 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" G_OBJECT_CLASS (searches_header_parent_class)->finalize (obj); -#line 1158 "SearchesBranch.c" +#line 1241 "SearchesBranch.c" } -GType searches_header_get_type (void) { +GType +searches_header_get_type (void) +{ static volatile gsize searches_header_type_id__volatile = 0; if (g_once_init_enter (&searches_header_type_id__volatile)) { static const GTypeInfo g_define_type_info = { sizeof (SearchesHeaderClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) searches_header_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SearchesHeader), 0, (GInstanceInitFunc) searches_header_instance_init, NULL }; @@ -1172,44 +1257,52 @@ GType searches_header_get_type (void) { } -SearchesSidebarEntry* searches_sidebar_entry_construct (GType object_type, SavedSearch* search) { +SearchesSidebarEntry* +searches_sidebar_entry_construct (GType object_type, + SavedSearch* search) +{ SearchesSidebarEntry * self = NULL; SavedSearch* _tmp0_; - SavedSearch* _tmp1_; #line 96 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" g_return_val_if_fail (IS_SAVED_SEARCH (search), NULL); #line 96 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self = (SearchesSidebarEntry*) sidebar_simple_page_entry_construct (object_type); #line 97 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp0_ = search; -#line 97 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp1_ = _g_object_ref0 (_tmp0_); + _tmp0_ = _g_object_ref0 (search); #line 97 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _g_object_unref0 (self->priv->search); #line 97 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - self->priv->search = _tmp1_; + self->priv->search = _tmp0_; #line 96 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return self; -#line 1194 "SearchesBranch.c" +#line 1279 "SearchesBranch.c" } -SearchesSidebarEntry* searches_sidebar_entry_new (SavedSearch* search) { +SearchesSidebarEntry* +searches_sidebar_entry_new (SavedSearch* search) +{ #line 96 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return searches_sidebar_entry_construct (SEARCHES_TYPE_SIDEBAR_ENTRY, search); -#line 1201 "SearchesBranch.c" +#line 1288 "SearchesBranch.c" } -void searches_sidebar_entry_init (void) { +void +searches_sidebar_entry_init (void) +{ } -void searches_sidebar_entry_terminate (void) { +void +searches_sidebar_entry_terminate (void) +{ } -SavedSearch* searches_sidebar_entry_for_saved_search (SearchesSidebarEntry* self) { +SavedSearch* +searches_sidebar_entry_for_saved_search (SearchesSidebarEntry* self) +{ SavedSearch* result = NULL; SavedSearch* _tmp0_; SavedSearch* _tmp1_; @@ -1223,11 +1316,13 @@ SavedSearch* searches_sidebar_entry_for_saved_search (SearchesSidebarEntry* self result = _tmp1_; #line 107 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return result; -#line 1227 "SearchesBranch.c" +#line 1320 "SearchesBranch.c" } -static gchar* searches_sidebar_entry_real_get_sidebar_name (SidebarSimplePageEntry* base) { +static gchar* +searches_sidebar_entry_real_get_sidebar_name (SidebarSimplePageEntry* base) +{ SearchesSidebarEntry * self; gchar* result = NULL; SavedSearch* _tmp0_; @@ -1242,11 +1337,13 @@ static gchar* searches_sidebar_entry_real_get_sidebar_name (SidebarSimplePageEnt result = _tmp1_; #line 111 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return result; -#line 1246 "SearchesBranch.c" +#line 1341 "SearchesBranch.c" } -static gchar* searches_sidebar_entry_real_get_sidebar_icon (SidebarSimplePageEntry* base) { +static gchar* +searches_sidebar_entry_real_get_sidebar_icon (SidebarSimplePageEntry* base) +{ SearchesSidebarEntry * self; gchar* result = NULL; const gchar* _tmp0_; @@ -1261,11 +1358,13 @@ static gchar* searches_sidebar_entry_real_get_sidebar_icon (SidebarSimplePageEnt result = _tmp1_; #line 115 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return result; -#line 1265 "SearchesBranch.c" +#line 1362 "SearchesBranch.c" } -static Page* searches_sidebar_entry_real_create_page (SidebarSimplePageEntry* base) { +static Page* +searches_sidebar_entry_real_create_page (SidebarSimplePageEntry* base) +{ SearchesSidebarEntry * self; Page* result = NULL; SavedSearch* _tmp0_; @@ -1282,11 +1381,13 @@ static Page* searches_sidebar_entry_real_create_page (SidebarSimplePageEntry* ba result = G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, TYPE_PAGE, Page); #line 119 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return result; -#line 1286 "SearchesBranch.c" +#line 1385 "SearchesBranch.c" } -static gboolean searches_sidebar_entry_real_is_user_renameable (SidebarRenameableEntry* base) { +static gboolean +searches_sidebar_entry_real_is_user_renameable (SidebarRenameableEntry* base) +{ SearchesSidebarEntry * self; gboolean result = FALSE; #line 122 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" @@ -1295,17 +1396,18 @@ static gboolean searches_sidebar_entry_real_is_user_renameable (SidebarRenameabl result = TRUE; #line 123 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" return result; -#line 1299 "SearchesBranch.c" +#line 1400 "SearchesBranch.c" } -static void searches_sidebar_entry_real_rename (SidebarRenameableEntry* base, const gchar* new_name) { +static void +searches_sidebar_entry_real_rename (SidebarRenameableEntry* base, + const gchar* new_name) +{ SearchesSidebarEntry * self; SavedSearchTable* _tmp0_; SavedSearchTable* _tmp1_; - const gchar* _tmp2_; - gboolean _tmp3_; - gboolean _tmp4_; + gboolean _tmp2_; #line 126 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self = G_TYPE_CHECK_INSTANCE_CAST (base, SEARCHES_TYPE_SIDEBAR_ENTRY, SearchesSidebarEntry); #line 126 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" @@ -1315,121 +1417,109 @@ static void searches_sidebar_entry_real_rename (SidebarRenameableEntry* base, co #line 127 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _tmp1_ = _tmp0_; #line 127 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp2_ = new_name; -#line 127 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp3_ = saved_search_table_exists (_tmp1_, _tmp2_); -#line 127 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp4_ = !_tmp3_; + _tmp2_ = !saved_search_table_exists (_tmp1_, new_name); #line 127 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _saved_search_table_unref0 (_tmp1_); #line 127 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - if (_tmp4_) { -#line 1328 "SearchesBranch.c" - CommandManager* _tmp5_; - CommandManager* _tmp6_; - SavedSearch* _tmp7_; - const gchar* _tmp8_; - RenameSavedSearchCommand* _tmp9_; - RenameSavedSearchCommand* _tmp10_; -#line 128 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp5_ = app_window_get_command_manager (); + if (_tmp2_) { +#line 1426 "SearchesBranch.c" + CommandManager* _tmp3_; + CommandManager* _tmp4_; + SavedSearch* _tmp5_; + RenameSavedSearchCommand* _tmp6_; + RenameSavedSearchCommand* _tmp7_; #line 128 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp6_ = _tmp5_; + _tmp3_ = app_window_get_command_manager (); #line 128 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp7_ = self->priv->search; + _tmp4_ = _tmp3_; #line 128 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp8_ = new_name; + _tmp5_ = self->priv->search; #line 128 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp9_ = rename_saved_search_command_new (_tmp7_, _tmp8_); + _tmp6_ = rename_saved_search_command_new (_tmp5_, new_name); #line 128 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp10_ = _tmp9_; + _tmp7_ = _tmp6_; #line 128 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - command_manager_execute (_tmp6_, G_TYPE_CHECK_INSTANCE_CAST (_tmp10_, TYPE_COMMAND, Command)); + command_manager_execute (_tmp4_, G_TYPE_CHECK_INSTANCE_CAST (_tmp7_, TYPE_COMMAND, Command)); #line 128 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _g_object_unref0 (_tmp10_); + _g_object_unref0 (_tmp7_); #line 128 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _command_manager_unref0 (_tmp6_); -#line 1353 "SearchesBranch.c" + _command_manager_unref0 (_tmp4_); +#line 1448 "SearchesBranch.c" } else { - const gchar* _tmp11_; - SavedSearch* _tmp12_; - gchar* _tmp13_; - gchar* _tmp14_; - gboolean _tmp15_; -#line 129 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp11_ = new_name; + SavedSearch* _tmp8_; + gchar* _tmp9_; + gchar* _tmp10_; + gboolean _tmp11_; #line 129 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp12_ = self->priv->search; + _tmp8_ = self->priv->search; #line 129 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp13_ = data_object_get_name (G_TYPE_CHECK_INSTANCE_CAST (_tmp12_, TYPE_DATA_OBJECT, DataObject)); + _tmp9_ = data_object_get_name (G_TYPE_CHECK_INSTANCE_CAST (_tmp8_, TYPE_DATA_OBJECT, DataObject)); #line 129 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp14_ = _tmp13_; + _tmp10_ = _tmp9_; #line 129 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp15_ = g_strcmp0 (_tmp11_, _tmp14_) != 0; + _tmp11_ = g_strcmp0 (new_name, _tmp10_) != 0; #line 129 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _g_free0 (_tmp14_); + _g_free0 (_tmp10_); #line 129 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - if (_tmp15_) { -#line 1374 "SearchesBranch.c" - const gchar* _tmp16_; - gchar* _tmp17_; - gchar* _tmp18_; -#line 130 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp16_ = new_name; + if (_tmp11_) { +#line 1466 "SearchesBranch.c" + gchar* _tmp12_; + gchar* _tmp13_; #line 130 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp17_ = resources_rename_search_exists_message (_tmp16_); + _tmp12_ = resources_rename_search_exists_message (new_name); #line 130 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp18_ = _tmp17_; + _tmp13_ = _tmp12_; #line 130 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - app_window_error_message (_tmp18_, NULL); + app_window_error_message (_tmp13_, NULL); #line 130 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _g_free0 (_tmp18_); -#line 1388 "SearchesBranch.c" + _g_free0 (_tmp13_); +#line 1477 "SearchesBranch.c" } } } -static void searches_sidebar_entry_real_destroy_source (SidebarDestroyableEntry* base) { +static void +searches_sidebar_entry_real_destroy_source (SidebarDestroyableEntry* base) +{ SearchesSidebarEntry * self; SavedSearch* _tmp0_; - gboolean _tmp1_; #line 133 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self = G_TYPE_CHECK_INSTANCE_CAST (base, SEARCHES_TYPE_SIDEBAR_ENTRY, SearchesSidebarEntry); #line 134 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" _tmp0_ = self->priv->search; #line 134 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp1_ = dialogs_confirm_delete_saved_search (_tmp0_); -#line 134 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - if (_tmp1_) { -#line 1406 "SearchesBranch.c" + if (dialogs_confirm_delete_saved_search (_tmp0_)) { +#line 1494 "SearchesBranch.c" + CommandManager* _tmp1_; CommandManager* _tmp2_; - CommandManager* _tmp3_; - SavedSearch* _tmp4_; + SavedSearch* _tmp3_; + DeleteSavedSearchCommand* _tmp4_; DeleteSavedSearchCommand* _tmp5_; - DeleteSavedSearchCommand* _tmp6_; #line 135 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp2_ = app_window_get_command_manager (); + _tmp1_ = app_window_get_command_manager (); #line 135 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp3_ = _tmp2_; + _tmp2_ = _tmp1_; #line 135 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp4_ = self->priv->search; + _tmp3_ = self->priv->search; #line 135 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp5_ = delete_saved_search_command_new (_tmp4_); + _tmp4_ = delete_saved_search_command_new (_tmp3_); #line 135 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _tmp6_ = _tmp5_; + _tmp5_ = _tmp4_; #line 135 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - command_manager_execute (_tmp3_, G_TYPE_CHECK_INSTANCE_CAST (_tmp6_, TYPE_COMMAND, Command)); + command_manager_execute (_tmp2_, G_TYPE_CHECK_INSTANCE_CAST (_tmp5_, TYPE_COMMAND, Command)); #line 135 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _g_object_unref0 (_tmp6_); + _g_object_unref0 (_tmp5_); #line 135 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" - _command_manager_unref0 (_tmp3_); -#line 1428 "SearchesBranch.c" + _command_manager_unref0 (_tmp2_); +#line 1516 "SearchesBranch.c" } } -static void searches_sidebar_entry_class_init (SearchesSidebarEntryClass * klass) { +static void +searches_sidebar_entry_class_init (SearchesSidebarEntryClass * klass) +{ gchar* _tmp0_; #line 90 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" searches_sidebar_entry_parent_class = g_type_class_peek_parent (klass); @@ -1447,38 +1537,46 @@ static void searches_sidebar_entry_class_init (SearchesSidebarEntryClass * klass _tmp0_ = g_strdup ("edit-find"); #line 92 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" searches_sidebar_entry_single_search_icon = _tmp0_; -#line 1451 "SearchesBranch.c" +#line 1541 "SearchesBranch.c" } -static void searches_sidebar_entry_sidebar_renameable_entry_interface_init (SidebarRenameableEntryIface * iface) { +static void +searches_sidebar_entry_sidebar_renameable_entry_interface_init (SidebarRenameableEntryIface * iface) +{ #line 90 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" searches_sidebar_entry_sidebar_renameable_entry_parent_iface = g_type_interface_peek_parent (iface); #line 90 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" iface->is_user_renameable = (gboolean (*) (SidebarRenameableEntry *)) searches_sidebar_entry_real_is_user_renameable; #line 90 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" iface->rename = (void (*) (SidebarRenameableEntry *, const gchar*)) searches_sidebar_entry_real_rename; -#line 1462 "SearchesBranch.c" +#line 1554 "SearchesBranch.c" } -static void searches_sidebar_entry_sidebar_destroyable_entry_interface_init (SidebarDestroyableEntryIface * iface) { +static void +searches_sidebar_entry_sidebar_destroyable_entry_interface_init (SidebarDestroyableEntryIface * iface) +{ #line 90 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" searches_sidebar_entry_sidebar_destroyable_entry_parent_iface = g_type_interface_peek_parent (iface); #line 90 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" iface->destroy_source = (void (*) (SidebarDestroyableEntry *)) searches_sidebar_entry_real_destroy_source; -#line 1471 "SearchesBranch.c" +#line 1565 "SearchesBranch.c" } -static void searches_sidebar_entry_instance_init (SearchesSidebarEntry * self) { +static void +searches_sidebar_entry_instance_init (SearchesSidebarEntry * self) +{ #line 90 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self->priv = SEARCHES_SIDEBAR_ENTRY_GET_PRIVATE (self); -#line 1478 "SearchesBranch.c" +#line 1574 "SearchesBranch.c" } -static void searches_sidebar_entry_finalize (GObject * obj) { +static void +searches_sidebar_entry_finalize (GObject * obj) +{ SearchesSidebarEntry * self; #line 90 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" self = G_TYPE_CHECK_INSTANCE_CAST (obj, SEARCHES_TYPE_SIDEBAR_ENTRY, SearchesSidebarEntry); @@ -1486,11 +1584,13 @@ static void searches_sidebar_entry_finalize (GObject * obj) { _g_object_unref0 (self->priv->search); #line 90 "/home/jens/Source/shotwell/src/searches/SearchesBranch.vala" G_OBJECT_CLASS (searches_sidebar_entry_parent_class)->finalize (obj); -#line 1490 "SearchesBranch.c" +#line 1588 "SearchesBranch.c" } -GType searches_sidebar_entry_get_type (void) { +GType +searches_sidebar_entry_get_type (void) +{ static volatile gsize searches_sidebar_entry_type_id__volatile = 0; if (g_once_init_enter (&searches_sidebar_entry_type_id__volatile)) { static const GTypeInfo g_define_type_info = { sizeof (SearchesSidebarEntryClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) searches_sidebar_entry_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SearchesSidebarEntry), 0, (GInstanceInitFunc) searches_sidebar_entry_instance_init, NULL }; |