summaryrefslogtreecommitdiff
path: root/src/tags/HierarchicalTagIndex.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/tags/HierarchicalTagIndex.c')
-rw-r--r--src/tags/HierarchicalTagIndex.c695
1 files changed, 371 insertions, 324 deletions
diff --git a/src/tags/HierarchicalTagIndex.c b/src/tags/HierarchicalTagIndex.c
index c188835..44d6fae 100644
--- a/src/tags/HierarchicalTagIndex.c
+++ b/src/tags/HierarchicalTagIndex.c
@@ -1,4 +1,4 @@
-/* HierarchicalTagIndex.c generated by valac 0.36.6, the Vala compiler
+/* HierarchicalTagIndex.c generated by valac 0.40.4, the Vala compiler
* generated from HierarchicalTagIndex.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>
@@ -106,27 +107,38 @@ extern TagSourceCollection* tag_global;
gpointer hierarchical_tag_index_ref (gpointer instance);
void hierarchical_tag_index_unref (gpointer instance);
-GParamSpec* param_spec_hierarchical_tag_index (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
-void value_set_hierarchical_tag_index (GValue* value, gpointer v_object);
-void value_take_hierarchical_tag_index (GValue* value, gpointer v_object);
+GParamSpec* param_spec_hierarchical_tag_index (const gchar* name,
+ const gchar* nick,
+ const gchar* blurb,
+ GType object_type,
+ GParamFlags flags);
+void value_set_hierarchical_tag_index (GValue* value,
+ gpointer v_object);
+void value_take_hierarchical_tag_index (GValue* value,
+ gpointer v_object);
gpointer value_get_hierarchical_tag_index (const GValue* value);
GType hierarchical_tag_index_get_type (void) G_GNUC_CONST;
#define HIERARCHICAL_TAG_INDEX_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_HIERARCHICAL_TAG_INDEX, HierarchicalTagIndexPrivate))
-enum {
- HIERARCHICAL_TAG_INDEX_DUMMY_PROPERTY
-};
HierarchicalTagIndex* hierarchical_tag_index_new (void);
HierarchicalTagIndex* hierarchical_tag_index_construct (GType object_type);
HierarchicalTagIndex* hierarchical_tag_index_from_paths (GeeCollection* client_paths);
#define TAG_PATH_SEPARATOR_STRING "/"
GeeList* hierarchical_tag_utilities_enumerate_path_components (const gchar* in_path);
-void hierarchical_tag_index_add_path (HierarchicalTagIndex* self, const gchar* tag, const gchar* path);
+void hierarchical_tag_index_add_path (HierarchicalTagIndex* self,
+ const gchar* tag,
+ const gchar* path);
HierarchicalTagIndex* hierarchical_tag_index_get_global_index (void);
gpointer data_collection_ref (gpointer instance);
void data_collection_unref (gpointer instance);
-GParamSpec* param_spec_data_collection (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
-void value_set_data_collection (GValue* value, gpointer v_object);
-void value_take_data_collection (GValue* value, gpointer v_object);
+GParamSpec* param_spec_data_collection (const gchar* name,
+ const gchar* nick,
+ const gchar* blurb,
+ GType object_type,
+ GParamFlags flags);
+void value_set_data_collection (GValue* value,
+ gpointer v_object);
+void value_take_data_collection (GValue* value,
+ gpointer v_object);
gpointer value_get_data_collection (const GValue* value);
GType data_collection_get_type (void) G_GNUC_CONST;
GType source_collection_get_type (void) G_GNUC_CONST;
@@ -135,18 +147,33 @@ GType container_source_collection_get_type (void) G_GNUC_CONST;
GType tag_source_collection_get_type (void) G_GNUC_CONST;
GeeCollection* tag_source_collection_get_all_names (TagSourceCollection* self);
GeeCollection* hierarchical_tag_index_get_all_paths (HierarchicalTagIndex* self);
-gboolean hierarchical_tag_index_is_tag_in_index (HierarchicalTagIndex* self, const gchar* tag);
+gboolean hierarchical_tag_index_is_tag_in_index (HierarchicalTagIndex* self,
+ const gchar* tag);
GeeCollection* hierarchical_tag_index_get_all_tags (HierarchicalTagIndex* self);
-gboolean hierarchical_tag_index_is_path_known (HierarchicalTagIndex* self, const gchar* path);
-gchar* hierarchical_tag_index_get_path_for_name (HierarchicalTagIndex* self, const gchar* name);
-gchar** hierarchical_tag_index_get_paths_for_names_array (HierarchicalTagIndex* self, gchar** names, int names_length1, int* result_length1);
-static void _vala_array_add65 (gchar** * array, int* length, int* size, gchar* value);
+gboolean hierarchical_tag_index_is_path_known (HierarchicalTagIndex* self,
+ const gchar* path);
+gchar* hierarchical_tag_index_get_path_for_name (HierarchicalTagIndex* self,
+ const gchar* name);
+gchar** hierarchical_tag_index_get_paths_for_names_array (HierarchicalTagIndex* self,
+ gchar** names,
+ int names_length1,
+ int* result_length1);
+static void _vala_array_add68 (gchar** * array,
+ int* length,
+ int* size,
+ gchar* value);
static void hierarchical_tag_index_finalize (HierarchicalTagIndex * obj);
-static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func);
-static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func);
+static void _vala_array_destroy (gpointer array,
+ gint array_length,
+ GDestroyNotify destroy_func);
+static void _vala_array_free (gpointer array,
+ gint array_length,
+ GDestroyNotify destroy_func);
-HierarchicalTagIndex* hierarchical_tag_index_construct (GType object_type) {
+HierarchicalTagIndex*
+hierarchical_tag_index_construct (GType object_type)
+{
HierarchicalTagIndex* self = NULL;
GeeHashMap* _tmp0_;
GeeTreeSet* _tmp1_;
@@ -166,170 +193,162 @@ HierarchicalTagIndex* hierarchical_tag_index_construct (GType object_type) {
self->priv->known_paths = G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, GEE_TYPE_SORTED_SET, GeeSortedSet);
#line 11 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return self;
-#line 170 "HierarchicalTagIndex.c"
+#line 197 "HierarchicalTagIndex.c"
}
-HierarchicalTagIndex* hierarchical_tag_index_new (void) {
+HierarchicalTagIndex*
+hierarchical_tag_index_new (void)
+{
#line 11 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return hierarchical_tag_index_construct (TYPE_HIERARCHICAL_TAG_INDEX);
-#line 177 "HierarchicalTagIndex.c"
+#line 206 "HierarchicalTagIndex.c"
}
-HierarchicalTagIndex* hierarchical_tag_index_from_paths (GeeCollection* client_paths) {
+HierarchicalTagIndex*
+hierarchical_tag_index_from_paths (GeeCollection* client_paths)
+{
HierarchicalTagIndex* result = NULL;
GeeCollection* paths = NULL;
GeeCollection* _tmp0_;
GeeCollection* _tmp1_;
- GeeCollection* _tmp2_;
HierarchicalTagIndex* _result_ = NULL;
- HierarchicalTagIndex* _tmp3_;
+ HierarchicalTagIndex* _tmp2_;
#line 16 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_return_val_if_fail (GEE_IS_COLLECTION (client_paths), NULL);
#line 17 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp0_ = client_paths;
+ _tmp0_ = gee_collection_get_read_only_view (client_paths);
#line 17 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp1_ = gee_collection_get_read_only_view (_tmp0_);
+ _tmp1_ = _tmp0_;
#line 17 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp2_ = _tmp1_;
-#line 17 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- paths = _tmp2_;
+ paths = _tmp1_;
#line 19 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp3_ = hierarchical_tag_index_new ();
+ _tmp2_ = hierarchical_tag_index_new ();
#line 19 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _result_ = _tmp3_;
-#line 203 "HierarchicalTagIndex.c"
+ _result_ = _tmp2_;
+#line 231 "HierarchicalTagIndex.c"
{
GeeIterator* _path_it = NULL;
- GeeCollection* _tmp4_;
- GeeIterator* _tmp5_;
+ GeeCollection* _tmp3_;
+ GeeIterator* _tmp4_;
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp4_ = paths;
+ _tmp3_ = paths;
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp5_ = gee_iterable_iterator (G_TYPE_CHECK_INSTANCE_CAST (_tmp4_, GEE_TYPE_ITERABLE, GeeIterable));
+ _tmp4_ = gee_iterable_iterator (G_TYPE_CHECK_INSTANCE_CAST (_tmp3_, GEE_TYPE_ITERABLE, GeeIterable));
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _path_it = _tmp5_;
+ _path_it = _tmp4_;
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
while (TRUE) {
-#line 216 "HierarchicalTagIndex.c"
- GeeIterator* _tmp6_;
- gboolean _tmp7_;
+#line 244 "HierarchicalTagIndex.c"
+ GeeIterator* _tmp5_;
gchar* path = NULL;
- GeeIterator* _tmp8_;
- gpointer _tmp9_;
- const gchar* _tmp10_;
- gboolean _tmp11_;
-#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp6_ = _path_it;
+ GeeIterator* _tmp6_;
+ gpointer _tmp7_;
+ const gchar* _tmp8_;
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp7_ = gee_iterator_next (_tmp6_);
+ _tmp5_ = _path_it;
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- if (!_tmp7_) {
+ if (!gee_iterator_next (_tmp5_)) {
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
break;
-#line 232 "HierarchicalTagIndex.c"
+#line 256 "HierarchicalTagIndex.c"
}
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp8_ = _path_it;
+ _tmp6_ = _path_it;
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp9_ = gee_iterator_get (_tmp8_);
+ _tmp7_ = gee_iterator_get (_tmp6_);
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- path = (gchar*) _tmp9_;
-#line 22 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp10_ = path;
+ path = (gchar*) _tmp7_;
#line 22 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp11_ = g_str_has_prefix (_tmp10_, TAG_PATH_SEPARATOR_STRING);
+ _tmp8_ = path;
#line 22 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- if (_tmp11_) {
-#line 246 "HierarchicalTagIndex.c"
+ if (g_str_has_prefix (_tmp8_, TAG_PATH_SEPARATOR_STRING)) {
+#line 268 "HierarchicalTagIndex.c"
GeeCollection* components = NULL;
- const gchar* _tmp12_;
- GeeList* _tmp13_;
+ const gchar* _tmp9_;
+ GeeList* _tmp10_;
#line 23 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp12_ = path;
+ _tmp9_ = path;
#line 23 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp13_ = hierarchical_tag_utilities_enumerate_path_components (_tmp12_);
+ _tmp10_ = hierarchical_tag_utilities_enumerate_path_components (_tmp9_);
#line 23 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- components = G_TYPE_CHECK_INSTANCE_CAST (_tmp13_, GEE_TYPE_COLLECTION, GeeCollection);
-#line 256 "HierarchicalTagIndex.c"
+ components = G_TYPE_CHECK_INSTANCE_CAST (_tmp10_, GEE_TYPE_COLLECTION, GeeCollection);
+#line 278 "HierarchicalTagIndex.c"
{
GeeIterator* _component_it = NULL;
- GeeCollection* _tmp14_;
- GeeIterator* _tmp15_;
+ GeeCollection* _tmp11_;
+ GeeIterator* _tmp12_;
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp14_ = components;
+ _tmp11_ = components;
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp15_ = gee_iterable_iterator (G_TYPE_CHECK_INSTANCE_CAST (_tmp14_, GEE_TYPE_ITERABLE, GeeIterable));
+ _tmp12_ = gee_iterable_iterator (G_TYPE_CHECK_INSTANCE_CAST (_tmp11_, GEE_TYPE_ITERABLE, GeeIterable));
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _component_it = _tmp15_;
+ _component_it = _tmp12_;
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
while (TRUE) {
-#line 269 "HierarchicalTagIndex.c"
- GeeIterator* _tmp16_;
- gboolean _tmp17_;
+#line 291 "HierarchicalTagIndex.c"
+ GeeIterator* _tmp13_;
gchar* component = NULL;
- GeeIterator* _tmp18_;
- gpointer _tmp19_;
- HierarchicalTagIndex* _tmp20_;
- const gchar* _tmp21_;
- const gchar* _tmp22_;
+ GeeIterator* _tmp14_;
+ gpointer _tmp15_;
+ HierarchicalTagIndex* _tmp16_;
+ const gchar* _tmp17_;
+ const gchar* _tmp18_;
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp16_ = _component_it;
+ _tmp13_ = _component_it;
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp17_ = gee_iterator_next (_tmp16_);
-#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- if (!_tmp17_) {
+ if (!gee_iterator_next (_tmp13_)) {
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
break;
-#line 286 "HierarchicalTagIndex.c"
+#line 305 "HierarchicalTagIndex.c"
}
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp18_ = _component_it;
+ _tmp14_ = _component_it;
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp19_ = gee_iterator_get (_tmp18_);
+ _tmp15_ = gee_iterator_get (_tmp14_);
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- component = (gchar*) _tmp19_;
+ component = (gchar*) _tmp15_;
#line 27 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp20_ = _result_;
+ _tmp16_ = _result_;
#line 27 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp21_ = component;
+ _tmp17_ = component;
#line 27 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp22_ = path;
+ _tmp18_ = path;
#line 27 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- hierarchical_tag_index_add_path (_tmp20_, _tmp21_, _tmp22_);
+ hierarchical_tag_index_add_path (_tmp16_, _tmp17_, _tmp18_);
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_g_free0 (component);
-#line 304 "HierarchicalTagIndex.c"
+#line 323 "HierarchicalTagIndex.c"
}
#line 26 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_g_object_unref0 (_component_it);
-#line 308 "HierarchicalTagIndex.c"
+#line 327 "HierarchicalTagIndex.c"
}
#line 22 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_g_object_unref0 (components);
-#line 312 "HierarchicalTagIndex.c"
+#line 331 "HierarchicalTagIndex.c"
} else {
- HierarchicalTagIndex* _tmp23_;
- const gchar* _tmp24_;
- const gchar* _tmp25_;
+ HierarchicalTagIndex* _tmp19_;
+ const gchar* _tmp20_;
+ const gchar* _tmp21_;
#line 29 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp23_ = _result_;
+ _tmp19_ = _result_;
#line 29 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp24_ = path;
+ _tmp20_ = path;
#line 29 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp25_ = path;
+ _tmp21_ = path;
#line 29 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- hierarchical_tag_index_add_path (_tmp23_, _tmp24_, _tmp25_);
-#line 325 "HierarchicalTagIndex.c"
+ hierarchical_tag_index_add_path (_tmp19_, _tmp20_, _tmp21_);
+#line 344 "HierarchicalTagIndex.c"
}
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_g_free0 (path);
-#line 329 "HierarchicalTagIndex.c"
+#line 348 "HierarchicalTagIndex.c"
}
#line 21 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_g_object_unref0 (_path_it);
-#line 333 "HierarchicalTagIndex.c"
+#line 352 "HierarchicalTagIndex.c"
}
#line 33 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
result = _result_;
@@ -337,11 +356,13 @@ HierarchicalTagIndex* hierarchical_tag_index_from_paths (GeeCollection* client_p
_g_object_unref0 (paths);
#line 33 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return result;
-#line 341 "HierarchicalTagIndex.c"
+#line 360 "HierarchicalTagIndex.c"
}
-HierarchicalTagIndex* hierarchical_tag_index_get_global_index (void) {
+HierarchicalTagIndex*
+hierarchical_tag_index_get_global_index (void)
+{
HierarchicalTagIndex* result = NULL;
TagSourceCollection* _tmp0_;
GeeCollection* _tmp1_;
@@ -364,21 +385,20 @@ HierarchicalTagIndex* hierarchical_tag_index_get_global_index (void) {
result = _tmp4_;
#line 37 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return result;
-#line 368 "HierarchicalTagIndex.c"
+#line 389 "HierarchicalTagIndex.c"
}
-void hierarchical_tag_index_add_path (HierarchicalTagIndex* self, const gchar* tag, const gchar* path) {
+void
+hierarchical_tag_index_add_path (HierarchicalTagIndex* self,
+ const gchar* tag,
+ const gchar* path)
+{
GeeMap* _tmp0_;
- const gchar* _tmp1_;
- gboolean _tmp2_;
- GeeMap* _tmp7_;
- const gchar* _tmp8_;
- gpointer _tmp9_;
- GeeCollection* _tmp10_;
- const gchar* _tmp11_;
- GeeSortedSet* _tmp12_;
- const gchar* _tmp13_;
+ GeeMap* _tmp4_;
+ gpointer _tmp5_;
+ GeeCollection* _tmp6_;
+ GeeSortedSet* _tmp7_;
#line 40 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_return_if_fail (IS_HIERARCHICAL_TAG_INDEX (self));
#line 40 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
@@ -388,55 +408,44 @@ void hierarchical_tag_index_add_path (HierarchicalTagIndex* self, const gchar* t
#line 41 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_tmp0_ = self->priv->tag_table;
#line 41 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp1_ = tag;
-#line 41 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp2_ = gee_map_has_key (_tmp0_, _tmp1_);
-#line 41 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- if (!_tmp2_) {
-#line 397 "HierarchicalTagIndex.c"
- GeeMap* _tmp3_;
- const gchar* _tmp4_;
- GeeArrayList* _tmp5_;
- GeeArrayList* _tmp6_;
+ if (!gee_map_has_key (_tmp0_, tag)) {
+#line 413 "HierarchicalTagIndex.c"
+ GeeMap* _tmp1_;
+ GeeArrayList* _tmp2_;
+ GeeArrayList* _tmp3_;
#line 42 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp3_ = self->priv->tag_table;
+ _tmp1_ = self->priv->tag_table;
#line 42 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp4_ = tag;
+ _tmp2_ = gee_array_list_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, (GDestroyNotify) g_free, NULL, NULL, NULL);
#line 42 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp5_ = gee_array_list_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, (GDestroyNotify) g_free, NULL, NULL, NULL);
+ _tmp3_ = _tmp2_;
#line 42 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp6_ = _tmp5_;
+ gee_map_set (_tmp1_, tag, G_TYPE_CHECK_INSTANCE_CAST (_tmp3_, GEE_TYPE_COLLECTION, GeeCollection));
#line 42 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- gee_map_set (_tmp3_, _tmp4_, G_TYPE_CHECK_INSTANCE_CAST (_tmp6_, GEE_TYPE_COLLECTION, GeeCollection));
-#line 42 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _g_object_unref0 (_tmp6_);
-#line 414 "HierarchicalTagIndex.c"
+ _g_object_unref0 (_tmp3_);
+#line 427 "HierarchicalTagIndex.c"
}
#line 45 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp7_ = self->priv->tag_table;
-#line 45 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp8_ = tag;
-#line 45 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp9_ = gee_map_get (_tmp7_, _tmp8_);
+ _tmp4_ = self->priv->tag_table;
#line 45 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp10_ = (GeeCollection*) _tmp9_;
+ _tmp5_ = gee_map_get (_tmp4_, tag);
#line 45 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp11_ = path;
+ _tmp6_ = (GeeCollection*) _tmp5_;
#line 45 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- gee_collection_add (_tmp10_, _tmp11_);
+ gee_collection_add (_tmp6_, path);
#line 45 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _g_object_unref0 (_tmp10_);
-#line 46 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp12_ = self->priv->known_paths;
+ _g_object_unref0 (_tmp6_);
#line 46 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp13_ = path;
+ _tmp7_ = self->priv->known_paths;
#line 46 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- gee_collection_add (G_TYPE_CHECK_INSTANCE_CAST (_tmp12_, GEE_TYPE_COLLECTION, GeeCollection), _tmp13_);
-#line 436 "HierarchicalTagIndex.c"
+ gee_collection_add (G_TYPE_CHECK_INSTANCE_CAST (_tmp7_, GEE_TYPE_COLLECTION, GeeCollection), path);
+#line 443 "HierarchicalTagIndex.c"
}
-GeeCollection* hierarchical_tag_index_get_all_paths (HierarchicalTagIndex* self) {
+GeeCollection*
+hierarchical_tag_index_get_all_paths (HierarchicalTagIndex* self)
+{
GeeCollection* result = NULL;
GeeSortedSet* _tmp0_;
GeeSortedSet* _tmp1_;
@@ -453,15 +462,16 @@ GeeCollection* hierarchical_tag_index_get_all_paths (HierarchicalTagIndex* self)
result = G_TYPE_CHECK_INSTANCE_CAST (_tmp2_, GEE_TYPE_COLLECTION, GeeCollection);
#line 50 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return result;
-#line 457 "HierarchicalTagIndex.c"
+#line 466 "HierarchicalTagIndex.c"
}
-gboolean hierarchical_tag_index_is_tag_in_index (HierarchicalTagIndex* self, const gchar* tag) {
+gboolean
+hierarchical_tag_index_is_tag_in_index (HierarchicalTagIndex* self,
+ const gchar* tag)
+{
gboolean result = FALSE;
GeeMap* _tmp0_;
- const gchar* _tmp1_;
- gboolean _tmp2_;
#line 53 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_return_val_if_fail (IS_HIERARCHICAL_TAG_INDEX (self), FALSE);
#line 53 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
@@ -469,18 +479,16 @@ gboolean hierarchical_tag_index_is_tag_in_index (HierarchicalTagIndex* self, con
#line 54 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_tmp0_ = self->priv->tag_table;
#line 54 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp1_ = tag;
-#line 54 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp2_ = gee_map_has_key (_tmp0_, _tmp1_);
-#line 54 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- result = _tmp2_;
+ result = gee_map_has_key (_tmp0_, tag);
#line 54 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return result;
-#line 480 "HierarchicalTagIndex.c"
+#line 486 "HierarchicalTagIndex.c"
}
-GeeCollection* hierarchical_tag_index_get_all_tags (HierarchicalTagIndex* self) {
+GeeCollection*
+hierarchical_tag_index_get_all_tags (HierarchicalTagIndex* self)
+{
GeeCollection* result = NULL;
GeeMap* _tmp0_;
GeeSet* _tmp1_;
@@ -497,15 +505,16 @@ GeeCollection* hierarchical_tag_index_get_all_tags (HierarchicalTagIndex* self)
result = G_TYPE_CHECK_INSTANCE_CAST (_tmp2_, GEE_TYPE_COLLECTION, GeeCollection);
#line 58 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return result;
-#line 501 "HierarchicalTagIndex.c"
+#line 509 "HierarchicalTagIndex.c"
}
-gboolean hierarchical_tag_index_is_path_known (HierarchicalTagIndex* self, const gchar* path) {
+gboolean
+hierarchical_tag_index_is_path_known (HierarchicalTagIndex* self,
+ const gchar* path)
+{
gboolean result = FALSE;
GeeSortedSet* _tmp0_;
- const gchar* _tmp1_;
- gboolean _tmp2_;
#line 61 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_return_val_if_fail (IS_HIERARCHICAL_TAG_INDEX (self), FALSE);
#line 61 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
@@ -513,128 +522,109 @@ gboolean hierarchical_tag_index_is_path_known (HierarchicalTagIndex* self, const
#line 62 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_tmp0_ = self->priv->known_paths;
#line 62 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp1_ = path;
-#line 62 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp2_ = gee_collection_contains (G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, GEE_TYPE_COLLECTION, GeeCollection), _tmp1_);
-#line 62 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- result = _tmp2_;
+ result = gee_collection_contains (G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, GEE_TYPE_COLLECTION, GeeCollection), path);
#line 62 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return result;
-#line 524 "HierarchicalTagIndex.c"
+#line 529 "HierarchicalTagIndex.c"
}
-gchar* hierarchical_tag_index_get_path_for_name (HierarchicalTagIndex* self, const gchar* name) {
+gchar*
+hierarchical_tag_index_get_path_for_name (HierarchicalTagIndex* self,
+ const gchar* name)
+{
gchar* result = NULL;
- const gchar* _tmp0_;
- gboolean _tmp1_;
GeeCollection* paths = NULL;
- GeeMap* _tmp4_;
- const gchar* _tmp5_;
- gpointer _tmp6_;
+ GeeMap* _tmp1_;
+ gpointer _tmp2_;
#line 65 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_return_val_if_fail (IS_HIERARCHICAL_TAG_INDEX (self), NULL);
#line 65 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_return_val_if_fail (name != NULL, NULL);
#line 66 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp0_ = name;
-#line 66 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp1_ = hierarchical_tag_index_is_tag_in_index (self, _tmp0_);
-#line 66 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- if (!_tmp1_) {
-#line 546 "HierarchicalTagIndex.c"
- const gchar* _tmp2_;
- gchar* _tmp3_;
-#line 67 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp2_ = name;
+ if (!hierarchical_tag_index_is_tag_in_index (self, name)) {
+#line 547 "HierarchicalTagIndex.c"
+ gchar* _tmp0_;
#line 67 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp3_ = g_strdup (_tmp2_);
+ _tmp0_ = g_strdup (name);
#line 67 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- result = _tmp3_;
+ result = _tmp0_;
#line 67 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return result;
-#line 557 "HierarchicalTagIndex.c"
+#line 555 "HierarchicalTagIndex.c"
}
#line 69 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp4_ = self->priv->tag_table;
-#line 69 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp5_ = name;
+ _tmp1_ = self->priv->tag_table;
#line 69 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp6_ = gee_map_get (_tmp4_, _tmp5_);
+ _tmp2_ = gee_map_get (_tmp1_, name);
#line 69 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- paths = (GeeCollection*) _tmp6_;
-#line 567 "HierarchicalTagIndex.c"
+ paths = (GeeCollection*) _tmp2_;
+#line 563 "HierarchicalTagIndex.c"
{
GeeIterator* _path_it = NULL;
- GeeCollection* _tmp7_;
- GeeIterator* _tmp8_;
+ GeeCollection* _tmp3_;
+ GeeIterator* _tmp4_;
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp7_ = paths;
+ _tmp3_ = paths;
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp8_ = gee_iterable_iterator (G_TYPE_CHECK_INSTANCE_CAST (_tmp7_, GEE_TYPE_ITERABLE, GeeIterable));
+ _tmp4_ = gee_iterable_iterator (G_TYPE_CHECK_INSTANCE_CAST (_tmp3_, GEE_TYPE_ITERABLE, GeeIterable));
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _path_it = _tmp8_;
+ _path_it = _tmp4_;
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
while (TRUE) {
-#line 580 "HierarchicalTagIndex.c"
- GeeIterator* _tmp9_;
- gboolean _tmp10_;
+#line 576 "HierarchicalTagIndex.c"
+ GeeIterator* _tmp5_;
gchar* path = NULL;
- GeeIterator* _tmp11_;
- gpointer _tmp12_;
+ GeeIterator* _tmp6_;
+ gpointer _tmp7_;
GeeList* components = NULL;
- const gchar* _tmp13_;
- GeeList* _tmp14_;
- GeeList* _tmp15_;
- GeeList* _tmp16_;
- gint _tmp17_;
- gint _tmp18_;
- gpointer _tmp19_;
- gchar* _tmp20_;
- const gchar* _tmp21_;
- gboolean _tmp22_;
+ const gchar* _tmp8_;
+ GeeList* _tmp9_;
+ GeeList* _tmp10_;
+ GeeList* _tmp11_;
+ gint _tmp12_;
+ gint _tmp13_;
+ gpointer _tmp14_;
+ gchar* _tmp15_;
+ gboolean _tmp16_;
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp9_ = _path_it;
+ _tmp5_ = _path_it;
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp10_ = gee_iterator_next (_tmp9_);
-#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- if (!_tmp10_) {
+ if (!gee_iterator_next (_tmp5_)) {
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
break;
-#line 605 "HierarchicalTagIndex.c"
+#line 597 "HierarchicalTagIndex.c"
}
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp11_ = _path_it;
+ _tmp6_ = _path_it;
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp12_ = gee_iterator_get (_tmp11_);
+ _tmp7_ = gee_iterator_get (_tmp6_);
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- path = (gchar*) _tmp12_;
+ path = (gchar*) _tmp7_;
#line 71 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp13_ = path;
+ _tmp8_ = path;
#line 71 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp14_ = hierarchical_tag_utilities_enumerate_path_components (_tmp13_);
+ _tmp9_ = hierarchical_tag_utilities_enumerate_path_components (_tmp8_);
#line 71 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- components = _tmp14_;
-#line 72 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp15_ = components;
+ components = _tmp9_;
#line 72 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp16_ = components;
+ _tmp10_ = components;
#line 72 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp17_ = gee_collection_get_size (G_TYPE_CHECK_INSTANCE_CAST (_tmp16_, GEE_TYPE_COLLECTION, GeeCollection));
+ _tmp11_ = components;
#line 72 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp18_ = _tmp17_;
+ _tmp12_ = gee_collection_get_size (G_TYPE_CHECK_INSTANCE_CAST (_tmp11_, GEE_TYPE_COLLECTION, GeeCollection));
#line 72 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp19_ = gee_list_get (_tmp15_, _tmp18_ - 1);
+ _tmp13_ = _tmp12_;
#line 72 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp20_ = (gchar*) _tmp19_;
+ _tmp14_ = gee_list_get (_tmp10_, _tmp13_ - 1);
#line 72 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp21_ = name;
+ _tmp15_ = (gchar*) _tmp14_;
#line 72 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp22_ = g_strcmp0 (_tmp20_, _tmp21_) == 0;
+ _tmp16_ = g_strcmp0 (_tmp15_, name) == 0;
#line 72 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _g_free0 (_tmp20_);
+ _g_free0 (_tmp15_);
#line 72 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- if (_tmp22_) {
+ if (_tmp16_) {
#line 73 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
result = path;
#line 73 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
@@ -645,53 +635,61 @@ gchar* hierarchical_tag_index_get_path_for_name (HierarchicalTagIndex* self, con
_g_object_unref0 (paths);
#line 73 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return result;
-#line 649 "HierarchicalTagIndex.c"
+#line 639 "HierarchicalTagIndex.c"
}
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_g_object_unref0 (components);
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_g_free0 (path);
-#line 655 "HierarchicalTagIndex.c"
+#line 645 "HierarchicalTagIndex.c"
}
#line 70 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_g_object_unref0 (_path_it);
-#line 659 "HierarchicalTagIndex.c"
+#line 649 "HierarchicalTagIndex.c"
}
#line 77 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_assert_not_reached ();
#line 65 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_g_object_unref0 (paths);
-#line 665 "HierarchicalTagIndex.c"
+#line 655 "HierarchicalTagIndex.c"
}
-static void _vala_array_add65 (gchar** * array, int* length, int* size, gchar* value) {
+static void
+_vala_array_add68 (gchar** * array,
+ int* length,
+ int* size,
+ gchar* value)
+{
#line 84 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
if ((*length) == (*size)) {
#line 84 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
*size = (*size) ? (2 * (*size)) : 4;
#line 84 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
*array = g_renew (gchar*, *array, (*size) + 1);
-#line 676 "HierarchicalTagIndex.c"
+#line 671 "HierarchicalTagIndex.c"
}
#line 84 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
(*array)[(*length)++] = value;
#line 84 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
(*array)[*length] = NULL;
-#line 682 "HierarchicalTagIndex.c"
+#line 677 "HierarchicalTagIndex.c"
}
-gchar** hierarchical_tag_index_get_paths_for_names_array (HierarchicalTagIndex* self, gchar** names, int names_length1, int* result_length1) {
+gchar**
+hierarchical_tag_index_get_paths_for_names_array (HierarchicalTagIndex* self,
+ gchar** names,
+ int names_length1,
+ int* result_length1)
+{
gchar** result = NULL;
gchar** _result_ = NULL;
gchar** _tmp0_;
gint _result__length1;
gint __result__size_;
- gchar** _tmp1_;
- gint _tmp1__length1;
- gchar** _tmp6_;
- gint _tmp6__length1;
+ gchar** _tmp5_;
+ gint _tmp5__length1;
#line 80 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_return_val_if_fail (IS_HIERARCHICAL_TAG_INDEX (self), NULL);
#line 81 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
@@ -702,167 +700,188 @@ gchar** hierarchical_tag_index_get_paths_for_names_array (HierarchicalTagIndex*
_result__length1 = 0;
#line 81 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
__result__size_ = _result__length1;
-#line 83 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp1_ = names;
-#line 83 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp1__length1 = names_length1;
-#line 710 "HierarchicalTagIndex.c"
+#line 704 "HierarchicalTagIndex.c"
{
gchar** name_collection = NULL;
gint name_collection_length1 = 0;
gint _name_collection_size_ = 0;
gint name_it = 0;
#line 83 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- name_collection = _tmp1_;
+ name_collection = names;
#line 83 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- name_collection_length1 = _tmp1__length1;
+ name_collection_length1 = names_length1;
#line 83 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- for (name_it = 0; name_it < _tmp1__length1; name_it = name_it + 1) {
-#line 722 "HierarchicalTagIndex.c"
- gchar* _tmp2_;
+ for (name_it = 0; name_it < names_length1; name_it = name_it + 1) {
+#line 716 "HierarchicalTagIndex.c"
+ gchar* _tmp1_;
gchar* name = NULL;
#line 83 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp2_ = g_strdup (name_collection[name_it]);
+ _tmp1_ = g_strdup (name_collection[name_it]);
#line 83 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- name = _tmp2_;
-#line 729 "HierarchicalTagIndex.c"
+ name = _tmp1_;
+#line 723 "HierarchicalTagIndex.c"
{
- gchar** _tmp3_;
- gint _tmp3__length1;
- const gchar* _tmp4_;
- gchar* _tmp5_;
+ gchar** _tmp2_;
+ gint _tmp2__length1;
+ const gchar* _tmp3_;
+ gchar* _tmp4_;
#line 84 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp3_ = _result_;
+ _tmp2_ = _result_;
#line 84 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp3__length1 = _result__length1;
+ _tmp2__length1 = _result__length1;
#line 84 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp4_ = name;
+ _tmp3_ = name;
#line 84 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp5_ = hierarchical_tag_index_get_path_for_name (self, _tmp4_);
+ _tmp4_ = hierarchical_tag_index_get_path_for_name (self, _tmp3_);
#line 84 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _vala_array_add65 (&_result_, &_result__length1, &__result__size_, _tmp5_);
+ _vala_array_add68 (&_result_, &_result__length1, &__result__size_, _tmp4_);
#line 83 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_g_free0 (name);
-#line 747 "HierarchicalTagIndex.c"
+#line 741 "HierarchicalTagIndex.c"
}
}
}
#line 86 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp6_ = _result_;
+ _tmp5_ = _result_;
#line 86 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- _tmp6__length1 = _result__length1;
+ _tmp5__length1 = _result__length1;
#line 86 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
if (result_length1) {
#line 86 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- *result_length1 = _tmp6__length1;
-#line 759 "HierarchicalTagIndex.c"
+ *result_length1 = _tmp5__length1;
+#line 753 "HierarchicalTagIndex.c"
}
#line 86 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
- result = _tmp6_;
+ result = _tmp5_;
#line 86 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return result;
-#line 765 "HierarchicalTagIndex.c"
+#line 759 "HierarchicalTagIndex.c"
}
-static void value_hierarchical_tag_index_init (GValue* value) {
+static void
+value_hierarchical_tag_index_init (GValue* value)
+{
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
value->data[0].v_pointer = NULL;
-#line 772 "HierarchicalTagIndex.c"
+#line 768 "HierarchicalTagIndex.c"
}
-static void value_hierarchical_tag_index_free_value (GValue* value) {
+static void
+value_hierarchical_tag_index_free_value (GValue* value)
+{
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
if (value->data[0].v_pointer) {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
hierarchical_tag_index_unref (value->data[0].v_pointer);
-#line 781 "HierarchicalTagIndex.c"
+#line 779 "HierarchicalTagIndex.c"
}
}
-static void value_hierarchical_tag_index_copy_value (const GValue* src_value, GValue* dest_value) {
+static void
+value_hierarchical_tag_index_copy_value (const GValue* src_value,
+ GValue* dest_value)
+{
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
if (src_value->data[0].v_pointer) {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
dest_value->data[0].v_pointer = hierarchical_tag_index_ref (src_value->data[0].v_pointer);
-#line 791 "HierarchicalTagIndex.c"
+#line 792 "HierarchicalTagIndex.c"
} else {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
dest_value->data[0].v_pointer = NULL;
-#line 795 "HierarchicalTagIndex.c"
+#line 796 "HierarchicalTagIndex.c"
}
}
-static gpointer value_hierarchical_tag_index_peek_pointer (const GValue* value) {
+static gpointer
+value_hierarchical_tag_index_peek_pointer (const GValue* value)
+{
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return value->data[0].v_pointer;
-#line 803 "HierarchicalTagIndex.c"
+#line 806 "HierarchicalTagIndex.c"
}
-static gchar* value_hierarchical_tag_index_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
+static gchar*
+value_hierarchical_tag_index_collect_value (GValue* value,
+ guint n_collect_values,
+ GTypeCValue* collect_values,
+ guint collect_flags)
+{
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
if (collect_values[0].v_pointer) {
-#line 810 "HierarchicalTagIndex.c"
+#line 818 "HierarchicalTagIndex.c"
HierarchicalTagIndex * object;
object = collect_values[0].v_pointer;
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
if (object->parent_instance.g_class == NULL) {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
-#line 817 "HierarchicalTagIndex.c"
+#line 825 "HierarchicalTagIndex.c"
} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
-#line 821 "HierarchicalTagIndex.c"
+#line 829 "HierarchicalTagIndex.c"
}
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
value->data[0].v_pointer = hierarchical_tag_index_ref (object);
-#line 825 "HierarchicalTagIndex.c"
+#line 833 "HierarchicalTagIndex.c"
} else {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
value->data[0].v_pointer = NULL;
-#line 829 "HierarchicalTagIndex.c"
+#line 837 "HierarchicalTagIndex.c"
}
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return NULL;
-#line 833 "HierarchicalTagIndex.c"
+#line 841 "HierarchicalTagIndex.c"
}
-static gchar* value_hierarchical_tag_index_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
+static gchar*
+value_hierarchical_tag_index_lcopy_value (const GValue* value,
+ guint n_collect_values,
+ GTypeCValue* collect_values,
+ guint collect_flags)
+{
HierarchicalTagIndex ** object_p;
object_p = collect_values[0].v_pointer;
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
if (!object_p) {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
-#line 844 "HierarchicalTagIndex.c"
+#line 857 "HierarchicalTagIndex.c"
}
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
if (!value->data[0].v_pointer) {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
*object_p = NULL;
-#line 850 "HierarchicalTagIndex.c"
+#line 863 "HierarchicalTagIndex.c"
} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
*object_p = value->data[0].v_pointer;
-#line 854 "HierarchicalTagIndex.c"
+#line 867 "HierarchicalTagIndex.c"
} else {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
*object_p = hierarchical_tag_index_ref (value->data[0].v_pointer);
-#line 858 "HierarchicalTagIndex.c"
+#line 871 "HierarchicalTagIndex.c"
}
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return NULL;
-#line 862 "HierarchicalTagIndex.c"
+#line 875 "HierarchicalTagIndex.c"
}
-GParamSpec* param_spec_hierarchical_tag_index (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) {
+GParamSpec*
+param_spec_hierarchical_tag_index (const gchar* name,
+ const gchar* nick,
+ const gchar* blurb,
+ GType object_type,
+ GParamFlags flags)
+{
ParamSpecHierarchicalTagIndex* spec;
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_return_val_if_fail (g_type_is_a (object_type, TYPE_HIERARCHICAL_TAG_INDEX), NULL);
@@ -872,20 +891,25 @@ GParamSpec* param_spec_hierarchical_tag_index (const gchar* name, const gchar* n
G_PARAM_SPEC (spec)->value_type = object_type;
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return G_PARAM_SPEC (spec);
-#line 876 "HierarchicalTagIndex.c"
+#line 895 "HierarchicalTagIndex.c"
}
-gpointer value_get_hierarchical_tag_index (const GValue* value) {
+gpointer
+value_get_hierarchical_tag_index (const GValue* value)
+{
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_HIERARCHICAL_TAG_INDEX), NULL);
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return value->data[0].v_pointer;
-#line 885 "HierarchicalTagIndex.c"
+#line 906 "HierarchicalTagIndex.c"
}
-void value_set_hierarchical_tag_index (GValue* value, gpointer v_object) {
+void
+value_set_hierarchical_tag_index (GValue* value,
+ gpointer v_object)
+{
HierarchicalTagIndex * old;
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_HIERARCHICAL_TAG_INDEX));
@@ -901,22 +925,25 @@ void value_set_hierarchical_tag_index (GValue* value, gpointer v_object) {
value->data[0].v_pointer = v_object;
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
hierarchical_tag_index_ref (value->data[0].v_pointer);
-#line 905 "HierarchicalTagIndex.c"
+#line 929 "HierarchicalTagIndex.c"
} else {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
value->data[0].v_pointer = NULL;
-#line 909 "HierarchicalTagIndex.c"
+#line 933 "HierarchicalTagIndex.c"
}
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
if (old) {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
hierarchical_tag_index_unref (old);
-#line 915 "HierarchicalTagIndex.c"
+#line 939 "HierarchicalTagIndex.c"
}
}
-void value_take_hierarchical_tag_index (GValue* value, gpointer v_object) {
+void
+value_take_hierarchical_tag_index (GValue* value,
+ gpointer v_object)
+{
HierarchicalTagIndex * old;
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_HIERARCHICAL_TAG_INDEX));
@@ -930,42 +957,48 @@ void value_take_hierarchical_tag_index (GValue* value, gpointer v_object) {
g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
value->data[0].v_pointer = v_object;
-#line 934 "HierarchicalTagIndex.c"
+#line 961 "HierarchicalTagIndex.c"
} else {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
value->data[0].v_pointer = NULL;
-#line 938 "HierarchicalTagIndex.c"
+#line 965 "HierarchicalTagIndex.c"
}
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
if (old) {
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
hierarchical_tag_index_unref (old);
-#line 944 "HierarchicalTagIndex.c"
+#line 971 "HierarchicalTagIndex.c"
}
}
-static void hierarchical_tag_index_class_init (HierarchicalTagIndexClass * klass) {
+static void
+hierarchical_tag_index_class_init (HierarchicalTagIndexClass * klass)
+{
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
hierarchical_tag_index_parent_class = g_type_class_peek_parent (klass);
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
((HierarchicalTagIndexClass *) klass)->finalize = hierarchical_tag_index_finalize;
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_type_class_add_private (klass, sizeof (HierarchicalTagIndexPrivate));
-#line 956 "HierarchicalTagIndex.c"
+#line 985 "HierarchicalTagIndex.c"
}
-static void hierarchical_tag_index_instance_init (HierarchicalTagIndex * self) {
+static void
+hierarchical_tag_index_instance_init (HierarchicalTagIndex * self)
+{
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
self->priv = HIERARCHICAL_TAG_INDEX_GET_PRIVATE (self);
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
self->ref_count = 1;
-#line 965 "HierarchicalTagIndex.c"
+#line 996 "HierarchicalTagIndex.c"
}
-static void hierarchical_tag_index_finalize (HierarchicalTagIndex * obj) {
+static void
+hierarchical_tag_index_finalize (HierarchicalTagIndex * obj)
+{
HierarchicalTagIndex * self;
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_HIERARCHICAL_TAG_INDEX, HierarchicalTagIndex);
@@ -975,11 +1008,13 @@ static void hierarchical_tag_index_finalize (HierarchicalTagIndex * obj) {
_g_object_unref0 (self->priv->tag_table);
#line 9 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
_g_object_unref0 (self->priv->known_paths);
-#line 979 "HierarchicalTagIndex.c"
+#line 1012 "HierarchicalTagIndex.c"
}
-GType hierarchical_tag_index_get_type (void) {
+GType
+hierarchical_tag_index_get_type (void)
+{
static volatile gsize hierarchical_tag_index_type_id__volatile = 0;
if (g_once_init_enter (&hierarchical_tag_index_type_id__volatile)) {
static const GTypeValueTable g_define_type_value_table = { value_hierarchical_tag_index_init, value_hierarchical_tag_index_free_value, value_hierarchical_tag_index_copy_value, value_hierarchical_tag_index_peek_pointer, "p", value_hierarchical_tag_index_collect_value, "p", value_hierarchical_tag_index_lcopy_value };
@@ -993,18 +1028,22 @@ GType hierarchical_tag_index_get_type (void) {
}
-gpointer hierarchical_tag_index_ref (gpointer instance) {
+gpointer
+hierarchical_tag_index_ref (gpointer instance)
+{
HierarchicalTagIndex * self;
self = instance;
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_atomic_int_inc (&self->ref_count);
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
return instance;
-#line 1004 "HierarchicalTagIndex.c"
+#line 1041 "HierarchicalTagIndex.c"
}
-void hierarchical_tag_index_unref (gpointer instance) {
+void
+hierarchical_tag_index_unref (gpointer instance)
+{
HierarchicalTagIndex * self;
self = instance;
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
@@ -1013,12 +1052,16 @@ void hierarchical_tag_index_unref (gpointer instance) {
HIERARCHICAL_TAG_INDEX_GET_CLASS (self)->finalize (self);
#line 7 "/home/jens/Source/shotwell/src/tags/HierarchicalTagIndex.vala"
g_type_free_instance ((GTypeInstance *) self);
-#line 1017 "HierarchicalTagIndex.c"
+#line 1056 "HierarchicalTagIndex.c"
}
}
-static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) {
+static void
+_vala_array_destroy (gpointer array,
+ gint array_length,
+ GDestroyNotify destroy_func)
+{
if ((array != NULL) && (destroy_func != NULL)) {
int i;
for (i = 0; i < array_length; i = i + 1) {
@@ -1030,7 +1073,11 @@ static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNoti
}
-static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func) {
+static void
+_vala_array_free (gpointer array,
+ gint array_length,
+ GDestroyNotify destroy_func)
+{
_vala_array_destroy (array, array_length, destroy_func);
g_free (array);
}