comparison src/thumb_standard.c @ 436:f0289d80ecc1

Rename inappropriate folder_size to folder.
author zas_
date Sat, 19 Apr 2008 23:12:30 +0000
parents 767b53cd9ab7
children 4b2d7f9af171
comparison
equal deleted inserted replaced
435:6802aeeed196 436:f0289d80ecc1
167 return result; 167 return result;
168 } 168 }
169 169
170 static gchar *thumb_loader_std_cache_path(ThumbLoaderStd *tl, gint local, GdkPixbuf *pixbuf, gint fail) 170 static gchar *thumb_loader_std_cache_path(ThumbLoaderStd *tl, gint local, GdkPixbuf *pixbuf, gint fail)
171 { 171 {
172 const gchar *folder_size; 172 const gchar *folder;
173 gint w, h; 173 gint w, h;
174 174
175 if (!tl->source_path || !tl->thumb_uri) return NULL; 175 if (!tl->source_path || !tl->thumb_uri) return NULL;
176 176
177 if (pixbuf) 177 if (pixbuf)
185 h = tl->requested_height; 185 h = tl->requested_height;
186 } 186 }
187 187
188 if (fail) 188 if (fail)
189 { 189 {
190 folder_size = THUMB_FOLDER_FAIL; 190 folder = THUMB_FOLDER_FAIL;
191 } 191 }
192 else if (w > THUMB_SIZE_NORMAL || h > THUMB_SIZE_NORMAL) 192 else if (w > THUMB_SIZE_NORMAL || h > THUMB_SIZE_NORMAL)
193 { 193 {
194 folder_size = THUMB_FOLDER_LARGE; 194 folder = THUMB_FOLDER_LARGE;
195 } 195 }
196 else 196 else
197 { 197 {
198 folder_size = THUMB_FOLDER_NORMAL; 198 folder = THUMB_FOLDER_NORMAL;
199 } 199 }
200 200
201 return thumb_std_cache_path(tl->source_path, 201 return thumb_std_cache_path(tl->source_path,
202 (local) ? tl->local_uri : tl->thumb_uri, 202 (local) ? tl->local_uri : tl->thumb_uri,
203 local, folder_size); 203 local, folder);
204 } 204 }
205 205
206 static gint thumb_loader_std_fail_check(ThumbLoaderStd *tl) 206 static gint thumb_loader_std_fail_check(ThumbLoaderStd *tl)
207 { 207 {
208 gchar *fail_path; 208 gchar *fail_path;
293 if (!pixbuf) 293 if (!pixbuf)
294 { 294 {
295 /* local failures are not stored */ 295 /* local failures are not stored */
296 if (tl->cache_local) return; 296 if (tl->cache_local) return;
297 297
298 pixbuf = gdk_pixbuf_new (GDK_COLORSPACE_RGB, TRUE, 8, 1, 1); 298 pixbuf = gdk_pixbuf_new(GDK_COLORSPACE_RGB, TRUE, 8, 1, 1);
299 fail = TRUE; 299 fail = TRUE;
300 } 300 }
301 else 301 else
302 { 302 {
303 g_object_ref(G_OBJECT(pixbuf)); 303 g_object_ref(G_OBJECT(pixbuf));