diff src/view_file.c @ 968:065a129fd42b

Simplify things related to ViewFileInfoList * and ViewFileInfoIcon * type casting: - drop VFICON_INFO() and VFLIST_INFO() macros - rename VFLIST_INFO_POINTER() and VFICON_INFO_POINTER() to shorter VFLIST() and VFICON(). - replace all related occurrences by shorter expressions. For example: VFICON_INFO(vf, columns) becomes VFICON(vf)->columns VFLIST_INFO(vf, click_fd) becomes VFLIST(vf)->click_fd
author zas_
date Sun, 17 Aug 2008 09:30:45 +0000
parents ba1d3c4bc0cd
children 33db1ec31e85
line wrap: on
line diff
--- a/src/view_file.c	Sun Aug 17 09:00:33 2008 +0000
+++ b/src/view_file.c	Sun Aug 17 09:30:45 2008 +0000
@@ -496,11 +496,11 @@
 	switch(vf->type)
 	{
 	case FILEVIEW_LIST:
-		vflist_color_set(vf, VFLIST_INFO(vf, click_fd), TRUE);
-		active = (VFLIST_INFO(vf, click_fd) != NULL);
+		vflist_color_set(vf, VFLIST(vf)->click_fd, TRUE);
+		active = (VFLIST(vf)->click_fd != NULL);
 		break;
 	case FILEVIEW_ICON:
-		active = (VFICON_INFO(vf, click_id) != NULL);
+		active = (VFICON(vf)->click_id != NULL);
 		break;
 	}
 
@@ -594,11 +594,11 @@
 	switch(vf->type)
 	{
 	case FILEVIEW_LIST:
-		menu_item_add_check(menu, _("Show _thumbnails"), VFLIST_INFO(vf, thumbs_enabled),
+		menu_item_add_check(menu, _("Show _thumbnails"), VFLIST(vf)->thumbs_enabled,
 				    G_CALLBACK(vflist_pop_menu_thumbs_cb), vf);
 		break;
 	case FILEVIEW_ICON:
-		menu_item_add_check(menu, _("Show filename _text"), VFICON_INFO(vf, show_text),
+		menu_item_add_check(menu, _("Show filename _text"), VFICON(vf)->show_text,
 				    G_CALLBACK(vficon_pop_menu_show_names_cb), vf);
 		break;
 	}