X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;f=gtk%2Fgtkfilesystem.h;h=83e1f34d5627c468d41161361181aad7f1f9d2ce;hb=126a2308ca467744178d4be3309403f6899de987;hp=0b3dd937418c8d85b17f6a8e217c06726e86c328;hpb=fce9c8b7d45145c4556650843218e0b76c065c18;p=~andy%2Fgtk diff --git a/gtk/gtkfilesystem.h b/gtk/gtkfilesystem.h index 0b3dd9374..83e1f34d5 100644 --- a/gtk/gtkfilesystem.h +++ b/gtk/gtkfilesystem.h @@ -1,4 +1,4 @@ -/* GTK - The GTK+ Toolkit +/* GTK - The GIMP Toolkit * gtkfilesystem.h: Filesystem abstraction functions. * Copyright (C) 2003, Red Hat, Inc. * @@ -13,9 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. + * License along with this library. If not, see . */ #ifndef __GTK_FILE_SYSTEM_H__ @@ -33,56 +31,31 @@ G_BEGIN_DECLS #define GTK_IS_FILE_SYSTEM_CLASS(c) (G_TYPE_CHECK_CLASS_TYPE ((c), GTK_TYPE_FILE_SYSTEM)) #define GTK_FILE_SYSTEM_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), GTK_TYPE_FILE_SYSTEM, GtkFileSystemClass)) -#define GTK_TYPE_FOLDER (_gtk_folder_get_type ()) -#define GTK_FOLDER(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), GTK_TYPE_FOLDER, GtkFolder)) -#define GTK_FOLDER_CLASS(c) (G_TYPE_CHECK_CLASS_CAST ((c), GTK_TYPE_FOLDER, GtkFolderClass)) -#define GTK_IS_FOLDER(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), GTK_TYPE_FOLDER)) -#define GTK_IS_FOLDER_CLASS(c) (G_TYPE_CHECK_CLASS_TYPE ((c), GTK_TYPE_FOLDER)) -#define GTK_FOLDER_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), GTK_TYPE_FOLDER, GtkFolderClass)) - -typedef struct GtkFileSystemClass GtkFileSystemClass; -typedef struct GtkFileSystem GtkFileSystem; -typedef struct GtkFolderClass GtkFolderClass; -typedef struct GtkFolder GtkFolder; +typedef struct GtkFileSystem GtkFileSystem; +typedef struct GtkFileSystemPrivate GtkFileSystemPrivate; +typedef struct GtkFileSystemClass GtkFileSystemClass; + + typedef struct GtkFileSystemVolume GtkFileSystemVolume; /* opaque struct */ typedef struct GtkFileSystemBookmark GtkFileSystemBookmark; /* opaque struct */ -struct GtkFileSystemClass -{ - GObjectClass parent_class; - - void (*bookmarks_changed) (GtkFileSystem *file_system); - void (*volumes_changed) (GtkFileSystem *file_system); -}; struct GtkFileSystem { GObject parent_object; + + GtkFileSystemPrivate *priv; }; -struct GtkFolderClass +struct GtkFileSystemClass { GObjectClass parent_class; - void (*files_added) (GtkFolder *folder, - GList *paths); - void (*files_removed) (GtkFolder *folder, - GList *paths); - void (*files_changed) (GtkFolder *folder, - GList *paths); - void (*finished_loading) (GtkFolder *folder); - void (*deleted) (GtkFolder *folder); + void (*bookmarks_changed) (GtkFileSystem *file_system); + void (*volumes_changed) (GtkFileSystem *file_system); }; -struct GtkFolder -{ - GObject parent_object; -}; -typedef void (* GtkFileSystemGetFolderCallback) (GCancellable *cancellable, - GtkFolder *folder, - const GError *error, - gpointer data); typedef void (* GtkFileSystemGetInfoCallback) (GCancellable *cancellable, GFileInfo *file_info, const GError *error, @@ -100,18 +73,6 @@ GtkFileSystem * _gtk_file_system_new (void); GSList * _gtk_file_system_list_volumes (GtkFileSystem *file_system); GSList * _gtk_file_system_list_bookmarks (GtkFileSystem *file_system); -gboolean _gtk_file_system_parse (GtkFileSystem *file_system, - GFile *base_file, - const gchar *str, - GFile **folder, - gchar **file_part, - GError **error); - -GCancellable * _gtk_file_system_get_folder (GtkFileSystem *file_system, - GFile *file, - const gchar *attributes, - GtkFileSystemGetFolderCallback callback, - gpointer data); GCancellable * _gtk_file_system_get_info (GtkFileSystem *file_system, GFile *file, const gchar *attributes, @@ -145,14 +106,6 @@ void _gtk_file_system_set_bookmark_label (GtkFileSystem *file_system, GtkFileSystemVolume * _gtk_file_system_get_volume_for_file (GtkFileSystem *file_system, GFile *file); -/* GtkFolder functions */ -GSList * _gtk_folder_list_children (GtkFolder *folder); -GFileInfo * _gtk_folder_get_info (GtkFolder *folder, - GFile *file); - -gboolean _gtk_folder_is_finished_loading (GtkFolder *folder); - - /* GtkFileSystemVolume methods */ gchar * _gtk_file_system_volume_get_display_name (GtkFileSystemVolume *volume); gboolean _gtk_file_system_volume_is_mounted (GtkFileSystemVolume *volume); @@ -162,7 +115,8 @@ GdkPixbuf * _gtk_file_system_volume_render_icon (GtkFileSystemVol gint icon_size, GError **error); -void _gtk_file_system_volume_free (GtkFileSystemVolume *volume); +GtkFileSystemVolume *_gtk_file_system_volume_ref (GtkFileSystemVolume *volume); +void _gtk_file_system_volume_unref (GtkFileSystemVolume *volume); /* GtkFileSystemBookmark methods */ void _gtk_file_system_bookmark_free (GtkFileSystemBookmark *bookmark); @@ -172,6 +126,8 @@ GdkPixbuf * _gtk_file_info_render_icon (GFileInfo *info, GtkWidget *widget, gint icon_size); +gboolean _gtk_file_info_consider_as_directory (GFileInfo *info); + G_END_DECLS #endif /* __GTK_FILE_SYSTEM_H__ */