Namespace waste reduction, move some g_get_unix_mount functions to the
authorMatthias Clasen <mclasen@redhat.com>
Mon, 17 Dec 2007 14:59:23 +0000 (14:59 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Mon, 17 Dec 2007 14:59:23 +0000 (14:59 +0000)
2007-12-17  Matthias Clasen  <mclasen@redhat.com>

        * gio.symbols:
        * gunixmounts.[hc]: Namespace waste reduction, move some
        g_get_unix_mount functions to the g_unix_mount namespace.

        * gunixmounts.c:
        * gunixvolumemonitor.c:
        * glocalfile.c:
        * glocaldirectorymonitor.c: Update all callers.

        * gunixmounts.h: Remove leftover g_unix_get_canonical_device_path

svn path=/trunk/; revision=6143

docs/reference/ChangeLog
docs/reference/gio/gio-sections.txt
gio/ChangeLog
gio/gio.symbols
gio/glocaldirectorymonitor.c
gio/glocalfile.c
gio/gunixmounts.c
gio/gunixmounts.h
gio/gunixvolumemonitor.c
gio/gunixvolumemonitor.h

index 1f335d6..974892e 100644 (file)
@@ -1,3 +1,7 @@
+2007-12-17  Matthias Clasen <mclasen@redhat.com>
+
+       * gio/gio-sections.txt: Updates
+
 2007-12-14  Matthias Clasen <mclasen@redhat.com>
 
        * glib/tmpl/hash_tables.sgml:
index 0ee3aa7..97f8580 100644 (file)
@@ -1111,13 +1111,12 @@ g_unix_mount_point_is_user_mountable
 g_unix_mount_point_is_loopback
 g_unix_mount_point_guess_icon
 g_unix_mount_point_guess_name
-g_get_unix_mount_points
-g_get_unix_mounts
-g_get_unix_mount_at
+g_unix_mount_points_get
+g_unix_mounts_get
+g_unix_mount_at
 g_unix_mounts_changed_since
 g_unix_mount_points_changed_since
 g_unix_mount_monitor_new
-g_unix_get_canonical_device_path
 g_unix_is_mount_path_system_internal
 <SUBSECTION Standard>
 GUnixMountClass
index afd265d..8fd3ac7 100644 (file)
@@ -1,3 +1,16 @@
+2007-12-17  Matthias Clasen  <mclasen@redhat.com>
+
+       * gio.symbols:
+       * gunixmounts.[hc]: Namespace waste reduction, move some
+       g_get_unix_mount functions to the g_unix_mount namespace.
+
+       * gunixmounts.c:
+       * gunixvolumemonitor.c:
+       * glocalfile.c:
+       * glocaldirectorymonitor.c: Update all callers.
+
+       * gunixmounts.h: Remove leftover g_unix_get_canonical_device_path
+
 2007-12-17  Alexander Larsson  <alexl@redhat.com>
 
         * gfile.c:
index ed1b97b..3f2806e 100644 (file)
@@ -645,9 +645,9 @@ g_unix_mount_point_is_user_mountable
 g_unix_mount_point_is_loopback 
 g_unix_mount_point_guess_name 
 g_unix_mount_point_guess_icon
-g_get_unix_mount_points 
-g_get_unix_mounts 
-g_get_unix_mount_at 
+g_unix_mount_points_get
+g_unix_mounts_get
+g_unix_mount_at 
 g_unix_mounts_changed_since 
 g_unix_mount_points_changed_since 
 g_unix_mount_monitor_get_type  G_GNUC_CONST
index 5047067..5a275ec 100644 (file)
@@ -119,7 +119,7 @@ g_local_directory_monitor_constructor (GType                  type,
       
       /* Emulate unmount detection */
       
-      mount = g_get_unix_mount_at (local_monitor->dirname, NULL);
+      mount = g_unix_mount_at (local_monitor->dirname, NULL);
       
       local_monitor->was_mounted = mount != NULL;
       
@@ -173,7 +173,7 @@ mounts_changed (GUnixMountMonitor *mount_monitor,
   mount = NULL;
   g_warning ("G_OS_WIN32: no mount emulation");
 #else  
-  mount = g_get_unix_mount_at (local_monitor->dirname, NULL);
+  mount = g_unix_mount_at (local_monitor->dirname, NULL);
   
   is_mounted = mount != NULL;
   
index 2d981a5..9dcb962 100644 (file)
@@ -730,7 +730,7 @@ get_mount_info (GFileInfo             *fs_info,
       if (mountpoint == NULL)
        mountpoint = "/";
 
-      mount = g_get_unix_mount_at (mountpoint, &cache_time);
+      mount = g_unix_mount_at (mountpoint, &cache_time);
       if (mount)
        {
          if (g_unix_mount_is_readonly (mount))
index b3d7b4d..2d3e041 100644 (file)
@@ -981,7 +981,7 @@ get_mount_points_timestamp (void)
 }
 
 /**
- * g_get_unix_mounts:
+ * g_unix_mounts_get:
  * @time_read: guint64 to contain a timestamp.
  * 
  * Gets a #GList of strings containing the unix mounts. 
@@ -992,7 +992,7 @@ get_mount_points_timestamp (void)
  * Returns: a #GList of the UNIX mounts. 
  **/
 GList *
-g_get_unix_mounts (guint64 *time_read)
+g_unix_mounts_get (guint64 *time_read)
 {
   if (time_read)
     *time_read = get_mounts_timestamp ();
@@ -1001,7 +1001,7 @@ g_get_unix_mounts (guint64 *time_read)
 }
 
 /**
- * g_get_unix_mount_at:
+ * g_unix_mount_at:
  * @mount_path: path for a possible unix mount.
  * @time_read: guint64 to contain a timestamp.
  * 
@@ -1012,13 +1012,13 @@ g_get_unix_mounts (guint64 *time_read)
  * Returns: a #GUnixMount. 
  **/
 GUnixMountEntry *
-g_get_unix_mount_at (const char *mount_path,
-                    guint64 *time_read)
+g_unix_mount_at (const char *mount_path,
+                guint64    *time_read)
 {
   GList *mounts, *l;
   GUnixMountEntry *mount_entry, *found;
   
-  mounts = g_get_unix_mounts (time_read);
+  mounts = g_unix_mounts_get (time_read);
 
   found = NULL;
   for (l = mounts; l != NULL; l = l->next)
@@ -1037,7 +1037,7 @@ g_get_unix_mount_at (const char *mount_path,
 }
 
 /**
- * g_get_unix_mount_points:
+ * g_unix_mount_points_get:
  * @time_read: guint64 to contain a timestamp.
  * 
  * Gets a #GList of strings containing the unix mount points. 
@@ -1048,7 +1048,7 @@ g_get_unix_mount_at (const char *mount_path,
  * Returns: a #GList of the UNIX mountpoints. 
  **/
 GList *
-g_get_unix_mount_points (guint64 *time_read)
+g_unix_mount_points_get (guint64 *time_read)
 {
   if (time_read)
     *time_read = get_mount_points_timestamp ();
index 5bf7faa..ced5dd1 100644 (file)
@@ -30,14 +30,16 @@ G_BEGIN_DECLS
 /**
  * GUnixMountEntry:
  * 
- * Defines a Unix mount entry (e.g. "/media/cdrom").
+ * Defines a Unix mount entry (e.g. <filename>/media/cdrom</filename>). 
+ * This corresponds roughly to a mtab entry.
  **/
 typedef struct _GUnixMountEntry GUnixMountEntry;
 
 /**
  * GUnixMountPoint:
  * 
- * Defines a Unix mount point (e.g. "/dev").
+ * Defines a Unix mount point (e.g. <filename>/dev</filename>).
+ * This corresponds roughly to a fstab entry.
  **/
 typedef struct _GUnixMountPoint GUnixMountPoint;
 
@@ -80,9 +82,9 @@ gboolean       g_unix_mount_point_guess_can_eject   (GUnixMountPoint    *mount_p
 char *         g_unix_mount_point_guess_name        (GUnixMountPoint    *mount_point);
 GIcon *        g_unix_mount_point_guess_icon        (GUnixMountPoint    *mount_point);
 
-GList *        g_get_unix_mount_points              (guint64            *time_read);
-GList *        g_get_unix_mounts                    (guint64            *time_read);
-GUnixMountEntry * g_get_unix_mount_at               (const char         *mount_path,
+GList *        g_unix_mount_points_get              (guint64            *time_read);
+GList *        g_unix_mounts_get                    (guint64            *time_read);
+GUnixMountEntry *g_unix_mount_at                    (const char         *mount_path,
                                                     guint64            *time_read);
 gboolean       g_unix_mounts_changed_since          (guint64             time);
 gboolean       g_unix_mount_points_changed_since    (guint64             time);
@@ -90,10 +92,6 @@ gboolean       g_unix_mount_points_changed_since    (guint64             time);
 GType              g_unix_mount_monitor_get_type (void) G_GNUC_CONST;
 GUnixMountMonitor *g_unix_mount_monitor_new      (void);
 
-
-
-char *g_unix_get_canonical_device_path (const char *device_path);
-
 gboolean g_unix_is_mount_path_system_internal (const char *mount_path);
 
 G_END_DECLS
index 0f73d09..dab8eca 100644 (file)
@@ -137,7 +137,7 @@ get_mount_for_mount_path (const char *mount_path)
   GUnixMountEntry *mount_entry;
   GUnixMount *mount;
 
-  mount_entry = g_get_unix_mount_at (mount_path, NULL);
+  mount_entry = g_unix_mount_at (mount_path, NULL);
   
   /* TODO: Set mountable volume? */
   mount = _g_unix_mount_new (NULL, mount_entry, NULL);
@@ -312,7 +312,7 @@ update_volumes (GUnixVolumeMonitor *monitor)
   GList *l;
   GUnixVolume *volume;
   
-  new_mountpoints = g_get_unix_mount_points (NULL);
+  new_mountpoints = g_unix_mount_points_get (NULL);
   
   new_mountpoints = g_list_sort (new_mountpoints, (GCompareFunc) g_unix_mount_point_compare);
   
@@ -365,7 +365,7 @@ update_mounts (GUnixVolumeMonitor *monitor)
   GUnixVolume *volume;
   const char *mount_path;
   
-  new_mounts = g_get_unix_mounts (NULL);
+  new_mounts = g_unix_mounts_get (NULL);
   
   new_mounts = g_list_sort (new_mounts, (GCompareFunc) g_unix_mount_compare);
   
index 1732c14..6aed8a4 100644 (file)
@@ -39,6 +39,12 @@ typedef struct _GUnixVolumeMonitor GUnixVolumeMonitor;
 typedef struct _GUnixVolumeMonitorClass GUnixVolumeMonitorClass;
 
 /* Forward definitions */
+
+/**
+ * GUnixMount:
+ *
+ * Implementation of the #GMount interface for Unix systems.
+ */
 typedef struct _GUnixMount GUnixMount;
 typedef struct _GUnixVolume GUnixVolume;