[Cxplorer-cvs 01018] CVS update: cxplorer/src

Back to archive index

Yasumichi Akahoshi yasum****@users*****
2005年 4月 10日 (日) 23:53:32 JST


Index: cxplorer/src/cxplorer-window.c
diff -u cxplorer/src/cxplorer-window.c:1.24 cxplorer/src/cxplorer-window.c:1.25
--- cxplorer/src/cxplorer-window.c:1.24	Sun Apr 10 23:28:10 2005
+++ cxplorer/src/cxplorer-window.c	Sun Apr 10 23:53:32 2005
@@ -52,7 +52,6 @@
 	GtkWidget *right_pane;
 	GtkWidget *statusbar;
 	CxpProfile *profile;
-	gboolean showdotfile;
 	gboolean dispose_has_run;
 } CxplorerWindowPrivate;
 
@@ -84,6 +83,7 @@
 static void cxplorer_window_property_action (GtkWidget * widget, gpointer user_data);
 static void cxplorer_window_copy_action (GtkWidget * widget, gpointer user_data);
 static void cxplorer_window_paste_action (GtkWidget *widget, gpointer user_data);
+static void cxplorer_window_show_dot_file_toggled (GtkToggleAction *action, gpointer user_data);
 static void cxplorer_window_refresh_views_action (GtkWidget *widget, gpointer user_data);
 static void cxplorer_window_go_up_action (GtkWidget *widget, gpointer user_data);
 static void cxplorer_window_go_home_action (GtkWidget *widget, gpointer user_data);
@@ -257,6 +257,7 @@
 	private->statusbar = statusbar;
 	private->dispose_has_run = FALSE;
 
+	g_signal_connect (dot_file_act, "toggled", G_CALLBACK(cxplorer_window_show_dot_file_toggled), self);
 	g_signal_connect (entry, "activate",
 			  G_CALLBACK (cxplorer_window_entry_activate),
 			  self);
@@ -604,6 +605,23 @@
 }
 
 /**
+ * This function called back when "Show dot file" is toggled.
+ * @param gcmItem [in] Pointer to menu item "View->Show dot file".
+ * @param gpData [in] Pointer to data which is defined by user.
+ */
+static void cxplorer_window_show_dot_file_toggled (GtkToggleAction *action, gpointer user_data)
+{
+	CxplorerWindowPrivate *private = CXPLORER_WINDOW_GET_PRIVATE (user_data);
+	gboolean show_dot_file;
+
+	show_dot_file = gtk_toggle_action_get_active(action);
+	cxp_profile_set_integer(private->profile, "ShowDotFile", show_dot_file);
+	cxp_dir_view_set_show_dot_file (CXP_DIR_VIEW(private->dirview), show_dot_file);
+	cxp_right_pane_set_show_dot_file (CXP_RIGHT_PANE(private->right_pane), show_dot_file);
+	cxp_dir_view_refresh (CXP_DIR_VIEW(private->dirview));
+}
+
+/**
  * This function refresh views When user request.
  * @param widget [in] Pointer to GtkWidget which calls this function.
  * @param user_data [in] Pointer to data which is defined by user.


Cxplorer-cvs メーリングリストの案内
Back to archive index