gnome-commander r1480 - in branches/gcmd-1-3: . src



Author: epiotr
Date: Tue Jan  8 21:33:55 2008
New Revision: 1480
URL: http://svn.gnome.org/viewvc/gnome-commander?rev=1480&view=rev

Log:
Added gnome_cmd_file_get_dirname()

Modified:
   branches/gcmd-1-3/ChangeLog
   branches/gcmd-1-3/src/gnome-cmd-file.cc
   branches/gcmd-1-3/src/gnome-cmd-file.h

Modified: branches/gcmd-1-3/src/gnome-cmd-file.cc
==============================================================================
--- branches/gcmd-1-3/src/gnome-cmd-file.cc	(original)
+++ branches/gcmd-1-3/src/gnome-cmd-file.cc	Tue Jan  8 21:33:55 2008
@@ -334,7 +334,7 @@
 gchar *gnome_cmd_file_get_real_path (GnomeCmdFile *finfo)
 {
     GnomeVFSURI *uri = gnome_cmd_file_get_uri (finfo);
-    gchar *path = gnome_vfs_unescape_string(gnome_vfs_uri_get_path (uri), NULL);
+    gchar *path = gnome_vfs_unescape_string (gnome_vfs_uri_get_path (uri), NULL);
 
     gnome_vfs_uri_unref (uri);
 
@@ -357,6 +357,17 @@
 }
 
 
+gchar *gnome_cmd_file_get_dirname (GnomeCmdFile *finfo)
+{
+    GnomeVFSURI *uri = gnome_cmd_file_get_uri (finfo);
+    gchar *path = gnome_vfs_uri_extract_dirname (uri);
+
+    gnome_vfs_uri_unref (uri);
+
+    return path;
+}
+
+
 GnomeVFSURI *gnome_cmd_file_get_uri (GnomeCmdFile *finfo)
 {
     g_return_val_if_fail (GNOME_CMD_IS_FILE (finfo), NULL);

Modified: branches/gcmd-1-3/src/gnome-cmd-file.h
==============================================================================
--- branches/gcmd-1-3/src/gnome-cmd-file.h	(original)
+++ branches/gcmd-1-3/src/gnome-cmd-file.h	Tue Jan  8 21:33:55 2008
@@ -77,6 +77,7 @@
 gchar *gnome_cmd_file_get_path (GnomeCmdFile *finfo);
 gchar *gnome_cmd_file_get_real_path (GnomeCmdFile *finfo);
 gchar *gnome_cmd_file_get_quoted_real_path (GnomeCmdFile *finfo);
+gchar *gnome_cmd_file_get_dirname (GnomeCmdFile *finfo);
 GnomeVFSURI *gnome_cmd_file_get_uri (GnomeCmdFile *finfo);
 gchar *gnome_cmd_file_get_uri_str (GnomeCmdFile *finfo);
 



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