summaryrefslogtreecommitdiff
path: root/libnautilus-extensions/nautilus-directory-private.h
blob: e4acddba10e9cdc4c69322126c3472c5109aee78 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*-

   nautilus-directory.c: Nautilus directory model.
 
   Copyright (C) 1999, 2000 Eazel, Inc.
  
   This program is free software; you can redistribute it and/or
   modify it under the terms of the GNU General Public License as
   published by the Free Software Foundation; either version 2 of the
   License, or (at your option) any later version.
  
   This program is distributed in the hope that it will be useful,
   but WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
   General Public License for more details.
  
   You should have received a copy of the GNU General Public
   License along with this program; if not, write to the
   Free Software Foundation, Inc., 59 Temple Place - Suite 330,
   Boston, MA 02111-1307, USA.
  
   Author: Darin Adler <darin@eazel.com>
*/

#include "nautilus-directory.h"

#include <libgnomevfs/gnome-vfs-types.h>
#include <libgnomevfs/gnome-vfs-uri.h>
#include <libgnomevfs/gnome-vfs-file-info.h>

#include <gnome-xml/tree.h>

#include "nautilus-file.h"

struct NautilusDirectoryDetails
{
	char *uri_text;
	GnomeVFSURI *uri;

	GnomeVFSURI *metafile_uri;
	GnomeVFSURI *alternate_metafile_uri;
	gboolean use_alternate_metafile;

	xmlDoc *metafile_tree;
	guint write_metafile_idle_id;

	GnomeVFSAsyncHandle *directory_load_in_progress;
	GnomeVFSDirectoryListPosition directory_load_list_last_handled;

	GList *pending_file_info;
        guint dequeue_pending_idle_id;

	gboolean directory_loaded;

	GList *files;
};

NautilusFile *nautilus_directory_find_file              (NautilusDirectory *directory,
							 const char        *file_name);
NautilusFile *nautilus_directory_new_file               (NautilusDirectory *directory,
							 GnomeVFSFileInfo  *info);
char *        nautilus_directory_get_file_metadata      (NautilusDirectory *directory,
							 const char        *file_name,
							 const char        *tag,
							 const char        *default_metadata);
void          nautilus_directory_set_file_metadata      (NautilusDirectory *directory,
							 const char        *file_name,
							 const char        *tag,
							 const char        *default_metadata,
							 const char        *metadata);
xmlNode *     nautilus_directory_get_file_metadata_node (NautilusDirectory *directory,
							 const char        *file_name,
							 gboolean           create);
void          nautilus_directory_files_changed          (NautilusDirectory *directory,
							 GList             *changed_files);
void          nautilus_directory_files_removed          (NautilusDirectory *directory,
							 GList             *removed_files);
void          nautilus_directory_request_write_metafile (NautilusDirectory *directory);