changeset 657:3f4bd5ead07a

vficon_pop_menu(): drop "gint active" parameter, use stored click_id instead.
author zas_
date Tue, 13 May 2008 19:54:13 +0000
parents a2d74c9843db
children dc09f544d292
files src/view_file_icon.c
diffstat 1 files changed, 6 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/view_file_icon.c	Tue May 13 19:51:22 2008 +0000
+++ b/src/view_file_icon.c	Tue May 13 19:54:13 2008 +0000
@@ -225,11 +225,14 @@
 	vf->popup = NULL;
 }
 
-static GtkWidget *vficon_pop_menu(ViewFile *vf, gint active)
+static GtkWidget *vficon_pop_menu(ViewFile *vf)
 {
 	GtkWidget *menu;
 	GtkWidget *item;
 	GtkWidget *submenu;
+	gint active;
+
+	active = (VFICON_INFO(vf, click_id) != NULL);
 
 	menu = popup_menu_short_lived();
 
@@ -1291,7 +1294,7 @@
 			vficon_selection_add(vf, VFICON_INFO(vf, click_id), SELECTION_PRELIGHT, NULL);
 			tip_unschedule(vf);
 
-			vf->popup = vficon_pop_menu(vf, (id != NULL));
+			vf->popup = vficon_pop_menu(vf);
 			gtk_menu_popup(GTK_MENU(vf->popup), NULL, NULL, vfi_menu_position_cb, vf, 0, GDK_CURRENT_TIME);
 			break;
 		default:
@@ -1395,7 +1398,7 @@
 #endif
 			break;
 		case MOUSE_BUTTON_RIGHT:
-			vf->popup = vficon_pop_menu(vf, (id != NULL));
+			vf->popup = vficon_pop_menu(vf);
 			gtk_menu_popup(GTK_MENU(vf->popup), NULL, NULL, NULL, NULL, bevent->button, bevent->time);
 			break;
 		default: