[gnome-commander] GnomeCmdMainWin: added FileSelectorID fs(GnomeCmdFileSelector *fs) method
- From: Piotr Eljasiak <epiotr src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-commander] GnomeCmdMainWin: added FileSelectorID fs(GnomeCmdFileSelector *fs) method
- Date: Sun, 18 Jul 2010 18:10:40 +0000 (UTC)
commit bf6ef92a6ad65ba6a0dd07504f36bdce95732a98
Author: Piotr Eljasiak <epiotr src gnome org>
Date: Sun Jul 18 20:10:10 2010 +0200
GnomeCmdMainWin: added FileSelectorID fs(GnomeCmdFileSelector *fs) method
src/gnome-cmd-main-win.cc | 26 ++++++++++++++++++++------
src/gnome-cmd-main-win.h | 3 ++-
2 files changed, 22 insertions(+), 7 deletions(-)
---
diff --git a/src/gnome-cmd-main-win.cc b/src/gnome-cmd-main-win.cc
index e22c58e..d3d4f78 100644
--- a/src/gnome-cmd-main-win.cc
+++ b/src/gnome-cmd-main-win.cc
@@ -874,6 +874,26 @@ GtkType gnome_cmd_main_win_get_type ()
}
+FileSelectorID GnomeCmdMainWin::fs() const
+{
+ return priv->current_fs;
+}
+
+
+FileSelectorID GnomeCmdMainWin::fs(GnomeCmdFileSelector *fs) const
+{
+ if (!priv->file_selector[LEFT] || priv->file_selector[LEFT]==*fs)
+ return LEFT;
+
+ if (!priv->file_selector[RIGHT] || priv->file_selector[RIGHT]==*fs)
+ return RIGHT;
+
+ g_assert_not_reached();
+
+ return LEFT; // never reached, to make compiler happy
+}
+
+
GnomeCmdFileSelector *GnomeCmdMainWin::fs(FileSelectorID id) const
{
switch (id)
@@ -897,12 +917,6 @@ GnomeCmdFileSelector *GnomeCmdMainWin::fs(FileSelectorID id) const
}
-FileSelectorID GnomeCmdMainWin::fs() const
-{
- return priv->current_fs;
-}
-
-
void GnomeCmdMainWin::update_style()
{
g_return_if_fail (priv != NULL);
diff --git a/src/gnome-cmd-main-win.h b/src/gnome-cmd-main-win.h
index 5652a07..13e6004 100644
--- a/src/gnome-cmd-main-win.h
+++ b/src/gnome-cmd-main-win.h
@@ -60,8 +60,9 @@ struct GnomeCmdMainWin
GnomeCmdAdvrenameDialog *advrename_dlg;
- GnomeCmdFileSelector *fs(FileSelectorID id) const;
FileSelectorID fs() const;
+ FileSelectorID fs(GnomeCmdFileSelector *fs) const;
+ GnomeCmdFileSelector *fs(FileSelectorID id) const;
gboolean key_pressed (GdkEventKey *event);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]