diff src/pan-view.c @ 318:b16b9b8979e5

Add a new struct ConfOptions to handle options. Changes were made among the code to use only one global var named "options" of type ConfOptions *. Initialization takes place in new init_options().
author zas_
date Fri, 11 Apr 2008 22:14:36 +0000
parents 6a7298988a7a
children 6c2cf2f12b0d
line wrap: on
line diff
--- a/src/pan-view.c	Fri Apr 11 20:35:37 2008 +0000
+++ b/src/pan-view.c	Fri Apr 11 22:14:36 2008 +0000
@@ -131,7 +131,7 @@
 
 			tmp = pi->pixbuf;
 			pi->pixbuf = gdk_pixbuf_scale_simple(tmp, pi->width, pi->height,
-							     (GdkInterpType)zoom_quality);
+							     (GdkInterpType)options->zoom_quality);
 			g_object_unref(tmp);
 			}
 
@@ -2566,8 +2566,8 @@
 		return TRUE;
 		}
 
-	if (enable_thumb_caching &&
-	    thumbnail_spec_standard) return FALSE;
+	if (options->enable_thumb_caching &&
+	    options->thumbnail_spec_standard) return FALSE;
 
 	if (!pref_list_int_get(PAN_PREF_GROUP, PAN_PREF_HIDE_WARNING, &hide_dlg)) hide_dlg = FALSE;
 	if (hide_dlg) return FALSE;
@@ -2589,9 +2589,9 @@
 	group = pref_box_new(group, TRUE, GTK_ORIENTATION_VERTICAL, PREF_PAD_GAP);
 
 	ct_button = pref_checkbox_new_int(group, _("Cache thumbnails"),
-			  		  enable_thumb_caching, &enable_thumb_caching);
+			  		  options->enable_thumb_caching, &options->enable_thumb_caching);
 	button = pref_checkbox_new_int(group, _("Use shared thumbnail cache"),
-				       thumbnail_spec_standard, &thumbnail_spec_standard);
+				       options->thumbnail_spec_standard, &options->thumbnail_spec_standard);
 	pref_checkbox_link_sensitivity(ct_button, button);
 
 	pref_line(box, 0);