annotate src/filedata.h @ 800:a25b228978a0

various notification improvements
author nadvornik
date Sat, 07 Jun 2008 15:08:33 +0000
parents 99ea3d973ad3
children db68d673448f
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
1 /*
196
f6e307c7bad6 rename GQview -> Geeqie over the code
nadvornik
parents: 170
diff changeset
2 * Geeqie
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
3 * (C) 2004 John Ellis
475
48c8e49b571c updated copyright in source files
nadvornik
parents: 446
diff changeset
4 * Copyright (C) 2008 The Geeqie Team
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
5 *
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
6 * Author: John Ellis
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
7 *
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
8 * This software is released under the GNU General Public License (GNU GPL).
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
9 * Please read the included file COPYING for more information.
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
10 * This software comes with no warranty of any kind, use at your own risk!
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
11 */
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
12
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
13
586
905688aa2317 split filelist.c to filefilter.c and filedata.c
nadvornik
parents: 576
diff changeset
14 #ifndef FILEDATA_H
905688aa2317 split filelist.c to filefilter.c and filedata.c
nadvornik
parents: 576
diff changeset
15 #define FILEDATA_H
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
16
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
17 gchar *text_from_size(gint64 size);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
18 gchar *text_from_size_abrev(gint64 size);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
19 const gchar *text_from_time(time_t t);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
20
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
21 /* this expects a utf-8 path */
138
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
22 FileData *file_data_new_simple(const gchar *path_utf8);
145
8be2cc687304 fixed grouping sidecar files and made it configurable via config file
nadvornik
parents: 143
diff changeset
23
138
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
24 FileData *file_data_ref(FileData *fd);
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
25 void file_data_unref(FileData *fd);
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
26
763
81f9e8dbb4bf improved infrastructure for tracing changes, optimized vflist_populate_view
nadvornik
parents: 753
diff changeset
27 void file_data_increment_version(FileData *fd);
81f9e8dbb4bf improved infrastructure for tracing changes, optimized vflist_populate_view
nadvornik
parents: 753
diff changeset
28
143
0d1bf3ac6cd8 improved FileDataChangeInfo structure, check for another file operation in progress
nadvornik
parents: 139
diff changeset
29 gboolean file_data_add_change_info(FileData *fd, FileDataChangeType type, const gchar *src, const gchar *dest);
138
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
30 void file_data_change_info_free(FileDataChangeInfo *fdci, FileData *fd);
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
31
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
32 gint filelist_sort_compare_filedata(FileData *fa, FileData *fb);
167
05bf5d364dba fixed filelist refresh
nadvornik
parents: 147
diff changeset
33 gint filelist_sort_compare_filedata_full(FileData *fa, FileData *fb, SortType method, gint ascend);
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
34 GList *filelist_sort(GList *list, SortType method, gint ascend);
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
35 GList *filelist_insert_sort(GList *list, FileData *fd, SortType method, gint ascend);
138
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
36 GList *filelist_sort_full(GList *list, SortType method, gint ascend, GCompareFunc cb);
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
37 GList *filelist_insert_sort_full(GList *list, void *data, SortType method, gint ascend, GCompareFunc cb);
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
38
783
d6a7fb4b8e7c replaced directory path with FileData* dir_fd
nadvornik
parents: 763
diff changeset
39 gint filelist_read(FileData *dir_fd, GList **files, GList **dirs);
d6a7fb4b8e7c replaced directory path with FileData* dir_fd
nadvornik
parents: 763
diff changeset
40 gint filelist_read_lstat(FileData *dir_fd, GList **files, GList **dirs);
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
41 void filelist_free(GList *list);
138
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
42 GList *filelist_copy(GList *list);
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
43 GList *filelist_from_path_list(GList *list);
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
44 GList *filelist_to_path_list(GList *list);
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
45
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
46 GList *filelist_filter(GList *list, gint is_dir_list);
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
47
71e1ebee420e replaced gchar* path with FileData *fd
nadvornik
parents: 9
diff changeset
48 GList *filelist_sort_path(GList *list);
783
d6a7fb4b8e7c replaced directory path with FileData* dir_fd
nadvornik
parents: 763
diff changeset
49 GList *filelist_recursive(FileData *dir_fd);
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
50
800
a25b228978a0 various notification improvements
nadvornik
parents: 792
diff changeset
51 gboolean file_data_get_mark(FileData *fd, gint n);
a25b228978a0 various notification improvements
nadvornik
parents: 792
diff changeset
52 void file_data_set_mark(FileData *fd, gint n, gboolean value);
a25b228978a0 various notification improvements
nadvornik
parents: 792
diff changeset
53 gint file_data_get_user_orientation(FileData *fd);
a25b228978a0 various notification improvements
nadvornik
parents: 792
diff changeset
54 void file_data_set_user_orientation(FileData *fd, gint value);
a25b228978a0 various notification improvements
nadvornik
parents: 792
diff changeset
55
590
2b7b966f61cf started implementation of API for sidecar files
nadvornik
parents: 586
diff changeset
56 gchar *file_data_sc_list_to_string(FileData *fd);
2b7b966f61cf started implementation of API for sidecar files
nadvornik
parents: 586
diff changeset
57 gboolean file_data_add_ci(FileData *fd, FileDataChangeType type, const gchar *src, const gchar *dest);
751
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
58 gboolean file_data_sc_add_ci_copy(FileData *fd, const gchar *dest_path);
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
59 gboolean file_data_sc_add_ci_move(FileData *fd, const gchar *dest_path);
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
60 gboolean file_data_sc_add_ci_rename(FileData *fd, const gchar *dest_path);
590
2b7b966f61cf started implementation of API for sidecar files
nadvornik
parents: 586
diff changeset
61 gboolean file_data_sc_add_ci_delete(FileData *fd);
753
477f48ba28d8 rewritten utilops.h:
nadvornik
parents: 751
diff changeset
62 gboolean file_data_sc_add_ci_unspecified(FileData *fd, const gchar *dest_path);
751
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
63
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
64 gboolean file_data_sc_add_ci_delete_list(GList *fd_list);
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
65 gboolean file_data_sc_add_ci_copy_list(GList *fd_list, const gchar *dest);
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
66 gboolean file_data_sc_add_ci_move_list(GList *fd_list, const gchar *dest);
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
67 gboolean file_data_sc_add_ci_rename_list(GList *fd_list, const gchar *dest);
753
477f48ba28d8 rewritten utilops.h:
nadvornik
parents: 751
diff changeset
68 gboolean file_data_sc_add_ci_unspecified_list(GList *fd_list, const gchar *dest);
751
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
69
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
70 gboolean file_data_sc_update_ci_copy_list(GList *fd_list, const gchar *dest);
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
71 gboolean file_data_sc_update_ci_move_list(GList *fd_list, const gchar *dest);
753
477f48ba28d8 rewritten utilops.h:
nadvornik
parents: 751
diff changeset
72 gboolean file_data_sc_update_ci_unspecified_list(GList *fd_list, const gchar *dest);
751
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
73
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
74
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
75 gint file_data_sc_update_ci_copy(FileData *fd, const gchar *dest_path);
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
76 gint file_data_sc_update_ci_move(FileData *fd, const gchar *dest_path);
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
77 gint file_data_sc_update_ci_rename(FileData *fd, const gchar *dest_path);
753
477f48ba28d8 rewritten utilops.h:
nadvornik
parents: 751
diff changeset
78 gint file_data_sc_update_ci_unspecified(FileData *fd, const gchar *dest_path);
590
2b7b966f61cf started implementation of API for sidecar files
nadvornik
parents: 586
diff changeset
79 gint file_data_sc_check_ci_dest(FileData *fd);
2b7b966f61cf started implementation of API for sidecar files
nadvornik
parents: 586
diff changeset
80 gboolean file_data_sc_perform_ci(FileData *fd);
2b7b966f61cf started implementation of API for sidecar files
nadvornik
parents: 586
diff changeset
81 gint file_data_sc_apply_ci(FileData *fd);
751
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
82 void file_data_sc_free_ci(FileData *fd);
f73df252aa05 improved filedata interface
nadvornik
parents: 596
diff changeset
83 void file_data_sc_free_ci_list(GList *fd_list);
590
2b7b966f61cf started implementation of API for sidecar files
nadvornik
parents: 586
diff changeset
84
792
99ea3d973ad3 added NotifyType
nadvornik
parents: 791
diff changeset
85 typedef void (*FileDataNotifyFunc)(FileData *fd, NotifyType type, gpointer data);
791
6d65167764ea realtime file monitor
nadvornik
parents: 784
diff changeset
86 gint file_data_register_notify_func(FileDataNotifyFunc func, gpointer data, NotifyPriority priority);
784
16b3a5c8aedc new notification system (used only in vflist for now)
nadvornik
parents: 783
diff changeset
87 gint file_data_unregister_notify_func(FileDataNotifyFunc func, gpointer data);
792
99ea3d973ad3 added NotifyType
nadvornik
parents: 791
diff changeset
88 void file_data_send_notification(FileData *fd, NotifyType type);
791
6d65167764ea realtime file monitor
nadvornik
parents: 784
diff changeset
89
6d65167764ea realtime file monitor
nadvornik
parents: 784
diff changeset
90 gint file_data_register_real_time_monitor(FileData *fd);
6d65167764ea realtime file monitor
nadvornik
parents: 784
diff changeset
91 gint file_data_unregister_real_time_monitor(FileData *fd);
6d65167764ea realtime file monitor
nadvornik
parents: 784
diff changeset
92
9
d907d608745f Sync to GQview 1.5.9 release.
gqview
parents:
diff changeset
93 #endif