[gnome-commander] GnomeCmdFileSelector: more C++ rework



commit aeb29dd98ae5d92f23e2d81554d63cb3938723e0
Author: Piotr Eljasiak <epiotr src gnome org>
Date:   Thu Dec 30 11:14:09 2010 +0100

    GnomeCmdFileSelector: more C++ rework

 src/gnome-cmd-file-selector.cc |    6 +++---
 src/gnome-cmd-file-selector.h  |    2 ++
 2 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/src/gnome-cmd-file-selector.cc b/src/gnome-cmd-file-selector.cc
index c81119e..47f44b9 100644
--- a/src/gnome-cmd-file-selector.cc
+++ b/src/gnome-cmd-file-selector.cc
@@ -244,7 +244,7 @@ inline void GnomeCmdFileSelector::update_vol_label()
 }
 
 
-static void do_file_specific_action (GnomeCmdFileList *fl, GnomeCmdFile *f)
+void GnomeCmdFileSelector::do_file_specific_action (GnomeCmdFileList *fl, GnomeCmdFile *f)
 {
     g_return_if_fail (GNOME_CMD_IS_FILE_LIST (fl));
     g_return_if_fail (f!=NULL);
@@ -442,14 +442,14 @@ static void on_notebook_switch_page (GtkNotebook *notebook, GtkNotebookPage *pag
 static void on_list_file_clicked (GnomeCmdFileList *fl, GnomeCmdFile *f, GdkEventButton *event, GnomeCmdFileSelector *fs)
 {
     if (event->type == GDK_2BUTTON_PRESS && event->button == 1 && gnome_cmd_data.left_mouse_button_mode == GnomeCmdData::LEFT_BUTTON_OPENS_WITH_DOUBLE_CLICK)
-        do_file_specific_action (fl, f);
+        fs->do_file_specific_action (fl, f);
 }
 
 
 static void on_list_file_released (GnomeCmdFileList *fl, GnomeCmdFile *f, GdkEventButton *event, GnomeCmdFileSelector *fs)
 {
     if (event->type == GDK_BUTTON_RELEASE && event->button == 1 && !fl->modifier_click && gnome_cmd_data.left_mouse_button_mode == GnomeCmdData::LEFT_BUTTON_OPENS_WITH_SINGLE_CLICK)
-        do_file_specific_action (fl, f);
+        fs->do_file_specific_action (fl, f);
 }
 
 
diff --git a/src/gnome-cmd-file-selector.h b/src/gnome-cmd-file-selector.h
index 9c86cfc..a23ab6c 100644
--- a/src/gnome-cmd-file-selector.h
+++ b/src/gnome-cmd-file-selector.h
@@ -100,6 +100,8 @@ struct GnomeCmdFileSelector
     void update_conbuttons_visibility();
     void update_concombo_visibility();
 
+    void do_file_specific_action (GnomeCmdFileList *fl, GnomeCmdFile *f);
+
     gboolean key_pressed(GdkEventKey *event);
 
     friend XML::xstream &operator << (XML::xstream &xml, GnomeCmdFileSelector &fs);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]