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/core/SourceInterfaces.c | |
parent | 55778740c211992cc86ea87588ab62c6750f36d1 (diff) | |
parent | e8f4d7a9cdd37c5a9fb3b6991a4e9173829808da (diff) |
Merge branch 'feature/upstream' into develop
Diffstat (limited to 'src/core/SourceInterfaces.c')
-rw-r--r-- | src/core/SourceInterfaces.c | 240 |
1 files changed, 101 insertions, 139 deletions
diff --git a/src/core/SourceInterfaces.c b/src/core/SourceInterfaces.c index cc43f4e..a68996d 100644 --- a/src/core/SourceInterfaces.c +++ b/src/core/SourceInterfaces.c @@ -1,4 +1,4 @@ -/* SourceInterfaces.c generated by valac 0.36.6, the Vala compiler +/* SourceInterfaces.c generated by valac 0.40.4, the Vala compiler * generated from SourceInterfaces.vala, do not modify */ /* Copyright 2016 Software Freedom Conservancy Inc. @@ -16,6 +16,7 @@ /* When the indexable string has changed, the object should fire an alteration of*/ /* "indexable:keywords". The prepare methods will not do this.*/ + #include <glib.h> #include <glib-object.h> #include <stdlib.h> @@ -66,91 +67,77 @@ const gchar* indexable_get_indexable_keywords (Indexable* self); gchar* indexable_prepare_indexable_string (const gchar* str); gboolean is_string_empty (const gchar* s); gchar* string_remove_diacritics (const gchar* istring); -gchar* indexable_prepare_indexable_strings (gchar** strs, int strs_length1); +gchar* indexable_prepare_indexable_strings (gchar** strs, + int strs_length1); -const gchar* indexable_get_indexable_keywords (Indexable* self) { +const gchar* +indexable_get_indexable_keywords (Indexable* self) +{ #line 19 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" g_return_val_if_fail (IS_INDEXABLE (self), NULL); #line 19 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" return INDEXABLE_GET_INTERFACE (self)->get_indexable_keywords (self); -#line 78 "SourceInterfaces.c" +#line 82 "SourceInterfaces.c" } -gchar* indexable_prepare_indexable_string (const gchar* str) { +gchar* +indexable_prepare_indexable_string (const gchar* str) +{ gchar* result = NULL; - const gchar* _tmp0_; - gboolean _tmp1_; - const gchar* _tmp2_; + gchar* _tmp0_; + gchar* _tmp1_; + gchar* _tmp2_; gchar* _tmp3_; - gchar* _tmp4_; - gchar* _tmp5_; - gchar* _tmp6_; -#line 22 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp0_ = str; -#line 22 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp1_ = is_string_empty (_tmp0_); #line 22 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - if (_tmp1_) { + if (is_string_empty (str)) { #line 23 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" result = NULL; #line 23 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" return result; -#line 101 "SourceInterfaces.c" +#line 100 "SourceInterfaces.c" } #line 24 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp2_ = str; + _tmp0_ = g_utf8_strdown (str, (gssize) -1); #line 24 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp3_ = g_utf8_strdown (_tmp2_, (gssize) -1); + _tmp1_ = _tmp0_; #line 24 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp4_ = _tmp3_; + _tmp2_ = string_remove_diacritics (_tmp1_); #line 24 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp5_ = string_remove_diacritics (_tmp4_); + _tmp3_ = _tmp2_; #line 24 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp6_ = _tmp5_; + _g_free0 (_tmp1_); #line 24 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _g_free0 (_tmp4_); -#line 24 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - result = _tmp6_; + result = _tmp3_; #line 24 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" return result; -#line 119 "SourceInterfaces.c" +#line 116 "SourceInterfaces.c" } -gchar* indexable_prepare_indexable_strings (gchar** strs, int strs_length1) { +gchar* +indexable_prepare_indexable_strings (gchar** strs, + int strs_length1) +{ gchar* result = NULL; gboolean _tmp0_ = FALSE; - gchar** _tmp1_; - gint _tmp1__length1; GString* builder = NULL; - GString* _tmp3_; + GString* _tmp1_; gint ctr = 0; - const gchar* _tmp21_ = NULL; - GString* _tmp22_; - const gchar* _tmp23_; - gboolean _tmp24_; - gchar* _tmp27_; -#line 28 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp1_ = strs; + const gchar* _tmp14_ = NULL; + GString* _tmp15_; + const gchar* _tmp16_; + gchar* _tmp19_; #line 28 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp1__length1 = strs_length1; -#line 28 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - if (_tmp1_ == NULL) { + if (strs == NULL) { #line 28 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" _tmp0_ = TRUE; -#line 144 "SourceInterfaces.c" +#line 137 "SourceInterfaces.c" } else { - gchar** _tmp2_; - gint _tmp2__length1; -#line 28 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp2_ = strs; -#line 28 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp2__length1 = strs_length1; #line 28 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp0_ = _tmp2__length1 == 0; -#line 154 "SourceInterfaces.c" + _tmp0_ = strs_length1 == 0; +#line 141 "SourceInterfaces.c" } #line 28 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" if (_tmp0_) { @@ -158,161 +145,136 @@ gchar* indexable_prepare_indexable_strings (gchar** strs, int strs_length1) { result = NULL; #line 29 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" return result; -#line 162 "SourceInterfaces.c" +#line 149 "SourceInterfaces.c" } #line 31 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp3_ = g_string_new (""); + _tmp1_ = g_string_new (""); #line 31 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - builder = _tmp3_; + builder = _tmp1_; #line 32 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" ctr = 0; -#line 170 "SourceInterfaces.c" +#line 157 "SourceInterfaces.c" { - gboolean _tmp4_ = FALSE; + gboolean _tmp2_ = FALSE; #line 33 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp4_ = TRUE; + _tmp2_ = TRUE; #line 33 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" while (TRUE) { -#line 177 "SourceInterfaces.c" - gchar** _tmp8_; - gint _tmp8__length1; - gint _tmp9_; - const gchar* _tmp10_; - gboolean _tmp11_; +#line 164 "SourceInterfaces.c" + gint _tmp5_; + const gchar* _tmp6_; #line 33 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - if (!_tmp4_) { -#line 185 "SourceInterfaces.c" - gint _tmp5_; - gint _tmp6_; - gchar** _tmp7_; - gint _tmp7__length1; -#line 39 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp5_ = ctr; -#line 39 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - ctr = _tmp5_ + 1; + if (!_tmp2_) { +#line 169 "SourceInterfaces.c" + gint _tmp3_; + gint _tmp4_; #line 39 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp6_ = ctr; + _tmp3_ = ctr; #line 39 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp7_ = strs; + ctr = _tmp3_ + 1; #line 39 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp7__length1 = strs_length1; + _tmp4_ = ctr; #line 39 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - if (!(_tmp6_ < _tmp7__length1)) { + if (!(_tmp4_ < strs_length1)) { #line 39 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" break; -#line 204 "SourceInterfaces.c" +#line 182 "SourceInterfaces.c" } } #line 33 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp4_ = FALSE; + _tmp2_ = FALSE; #line 34 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp8_ = strs; + _tmp5_ = ctr; #line 34 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp8__length1 = strs_length1; + _tmp6_ = strs[_tmp5_]; #line 34 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp9_ = ctr; -#line 34 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp10_ = _tmp8_[_tmp9_]; -#line 34 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp11_ = is_string_empty (_tmp10_); -#line 34 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - if (!_tmp11_) { -#line 221 "SourceInterfaces.c" - GString* _tmp12_; - gchar** _tmp13_; - gint _tmp13__length1; - gint _tmp14_; - const gchar* _tmp15_; - gchar* _tmp16_; - gchar* _tmp17_; - gint _tmp18_; - gchar** _tmp19_; - gint _tmp19__length1; -#line 35 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp12_ = builder; -#line 35 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp13_ = strs; + if (!is_string_empty (_tmp6_)) { +#line 193 "SourceInterfaces.c" + GString* _tmp7_; + gint _tmp8_; + const gchar* _tmp9_; + gchar* _tmp10_; + gchar* _tmp11_; + gint _tmp12_; #line 35 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp13__length1 = strs_length1; + _tmp7_ = builder; #line 35 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp14_ = ctr; + _tmp8_ = ctr; #line 35 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp15_ = _tmp13_[_tmp14_]; + _tmp9_ = strs[_tmp8_]; #line 35 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp16_ = g_utf8_strdown (_tmp15_, (gssize) -1); + _tmp10_ = g_utf8_strdown (_tmp9_, (gssize) -1); #line 35 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp17_ = _tmp16_; + _tmp11_ = _tmp10_; #line 35 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - g_string_append (_tmp12_, _tmp17_); + g_string_append (_tmp7_, _tmp11_); #line 35 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _g_free0 (_tmp17_); + _g_free0 (_tmp11_); #line 36 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp18_ = ctr; + _tmp12_ = ctr; #line 36 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp19_ = strs; -#line 36 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp19__length1 = strs_length1; -#line 36 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - if (_tmp18_ < (_tmp19__length1 - 1)) { -#line 258 "SourceInterfaces.c" - GString* _tmp20_; + if (_tmp12_ < (strs_length1 - 1)) { +#line 218 "SourceInterfaces.c" + GString* _tmp13_; #line 37 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp20_ = builder; + _tmp13_ = builder; #line 37 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - g_string_append_c (_tmp20_, ' '); -#line 264 "SourceInterfaces.c" + g_string_append_c (_tmp13_, ' '); +#line 224 "SourceInterfaces.c" } } } } #line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp22_ = builder; + _tmp15_ = builder; #line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp23_ = _tmp22_->str; + _tmp16_ = _tmp15_->str; #line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp24_ = is_string_empty (_tmp23_); + if (!is_string_empty (_tmp16_)) { +#line 235 "SourceInterfaces.c" + GString* _tmp17_; + const gchar* _tmp18_; #line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - if (!_tmp24_) { -#line 277 "SourceInterfaces.c" - GString* _tmp25_; - const gchar* _tmp26_; + _tmp17_ = builder; #line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp25_ = builder; + _tmp18_ = _tmp17_->str; #line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp26_ = _tmp25_->str; -#line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp21_ = _tmp26_; -#line 286 "SourceInterfaces.c" + _tmp14_ = _tmp18_; +#line 244 "SourceInterfaces.c" } else { #line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp21_ = NULL; -#line 290 "SourceInterfaces.c" + _tmp14_ = NULL; +#line 248 "SourceInterfaces.c" } #line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - _tmp27_ = g_strdup (_tmp21_); + _tmp19_ = g_strdup (_tmp14_); #line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" - result = _tmp27_; + result = _tmp19_; #line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" _g_string_free0 (builder); #line 41 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" return result; -#line 300 "SourceInterfaces.c" +#line 258 "SourceInterfaces.c" } -static void indexable_base_init (IndexableIface * iface) { +static void +indexable_base_init (IndexableIface * iface) +{ #line 18 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" static gboolean initialized = FALSE; #line 18 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" if (!initialized) { #line 18 "/home/jens/Source/shotwell/src/core/SourceInterfaces.vala" initialized = TRUE; -#line 311 "SourceInterfaces.c" +#line 271 "SourceInterfaces.c" } } -GType indexable_get_type (void) { +GType +indexable_get_type (void) +{ static volatile gsize indexable_type_id__volatile = 0; if (g_once_init_enter (&indexable_type_id__volatile)) { static const GTypeInfo g_define_type_info = { sizeof (IndexableIface), (GBaseInitFunc) indexable_base_init, (GBaseFinalizeFunc) NULL, (GClassInitFunc) NULL, (GClassFinalizeFunc) NULL, NULL, 0, 0, (GInstanceInitFunc) NULL, NULL }; |