changeset 340:77103f3f2cb1

Rename option thumbnails.enabled to layout.show_thumbnails as it makes more sense.
author zas_
date Sat, 12 Apr 2008 21:45:30 +0000
parents de1c2cd06fce
children 15c6b94545a2
files src/globals.c src/layout.c src/main.c src/rcfile.c src/typedefs.h
diffstat 5 files changed, 9 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/src/globals.c	Sat Apr 12 21:38:55 2008 +0000
+++ b/src/globals.c	Sat Apr 12 21:45:30 2008 +0000
@@ -71,7 +71,7 @@
 	options->file_filter.disable = FALSE;
 	
 	
-	options->thumbnails.enabled = FALSE;
+	options->layout.show_thumbnails = FALSE;
 	options->file_sort.method = SORT_NAME;
 	options->file_sort.ascending = TRUE;
 	
--- a/src/layout.c	Sat Apr 12 21:38:55 2008 +0000
+++ b/src/layout.c	Sat Apr 12 21:45:30 2008 +0000
@@ -1879,7 +1879,7 @@
 
 	lw = g_new0(LayoutWindow, 1);
 
-	lw->thumbs_enabled = options->thumbnails.enabled;
+	lw->thumbs_enabled = options->layout.show_thumbnails;
 	lw->sort_method = SORT_NAME;
 	lw->sort_ascend = TRUE;
 
--- a/src/main.c	Sat Apr 12 21:38:55 2008 +0000
+++ b/src/main.c	Sat Apr 12 21:45:30 2008 +0000
@@ -1211,7 +1211,7 @@
 
 	layout_views_get(NULL, &options->layout.view_as_tree, &options->layout.view_as_icons);
 
-	options->thumbnails.enabled = layout_thumb_get(NULL);
+	options->layout.show_thumbnails = layout_thumb_get(NULL);
 	layout_sort_get(NULL, &options->file_sort.method, &options->file_sort.ascending);
 
 	layout_geometry_get_tools(NULL, &options->layout.float_window.x, &options->layout.float_window.y,
--- a/src/rcfile.c	Sat Apr 12 21:38:55 2008 +0000
+++ b/src/rcfile.c	Sat Apr 12 21:45:30 2008 +0000
@@ -311,6 +311,7 @@
 	write_char_option(ssi, "layout.order", options->layout.order);
 	write_bool_option(ssi, "layout.view_as_icons", options->layout.view_as_icons);
 	write_bool_option(ssi, "layout.view_as_tree", options->layout.view_as_tree);
+	write_bool_option(ssi, "layout.show_thumbnails", options->layout.show_thumbnails);
 	secure_fputc(ssi, '\n');
 
 	write_bool_option(ssi, "layout.save_window_positions", options->layout.save_window_positions);
@@ -366,7 +367,6 @@
 
 	secure_fprintf(ssi, "\n##### Thumbnails Options #####\n\n");
 
-	write_bool_option(ssi, "thumbnails.enabled", options->thumbnails.enabled);
 	write_int_option(ssi, "thumbnails.max_width", options->thumbnails.max_width);
 	write_int_option(ssi, "thumbnails.max_height", options->thumbnails.max_height);
 	write_bool_option(ssi, "thumbnails.enable_caching", options->thumbnails.enable_caching);
@@ -550,6 +550,9 @@
 			"layout.view_as_icons", value, options->layout.view_as_icons);
 		options->layout.view_as_tree = read_bool_option(f, option,
 			"layout.view_as_tree", value, options->layout.view_as_tree);
+		options->layout.show_thumbnails = read_bool_option(f, option,
+			"layout.show_thumbnails", value, options->layout.show_thumbnails);
+
 		/* window positions */
 
 		options->layout.save_window_positions = read_bool_option(f, option,
@@ -650,8 +653,6 @@
 
 
 		/* thumbnails options */
-		options->thumbnails.enabled = read_bool_option(f, option,
-			"thumbnails.enabled", value, options->thumbnails.enabled);
 		options->thumbnails.max_width = read_int_option(f, option,
 			"thumbnails.max_width", value, options->thumbnails.max_width);
 		if (options->thumbnails.max_width < 16) options->thumbnails.max_width = 16;
--- a/src/typedefs.h	Sat Apr 12 21:38:55 2008 +0000
+++ b/src/typedefs.h	Sat Apr 12 21:45:30 2008 +0000
@@ -793,7 +793,6 @@
 		gint use_xvpics;
 		gint spec_standard;
 		gint quality;
-		gint enabled;	/* TODO: move to layout ? */
 	} thumbnails;
 
 	/* file filtering */
@@ -842,6 +841,8 @@
 
 		gint view_as_icons;
 		gint view_as_tree;
+		
+		gint show_thumbnails;
 
 		struct {
 			gint w;