Fix #314: Remote commands for thumbnail maintenance
[geeqie.git] / src / filedata.h
index 26129a7..ea29f2f 100644 (file)
@@ -1,16 +1,24 @@
 /*
- * Geeqie
- * (C) 2004 John Ellis
- * Copyright (C) 2008 - 2010 The Geeqie Team
+ * Copyright (C) 2004 John Ellis
+ * Copyright (C) 2008 - 2016 The Geeqie Team
  *
  * Author: John Ellis
  *
- * This software is released under the GNU General Public License (GNU GPL).
- * Please read the included file COPYING for more information.
- * This software comes with no warranty of any kind, use at your own risk!
+ * 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.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  */
 
-
 #ifndef FILEDATA_H
 #define FILEDATA_H
 
 #define DEBUG_FILEDATA
 #endif
 
+#define FD_MAGICK 0x12345678u
+
 gchar *text_from_size(gint64 size);
 gchar *text_from_size_abrev(gint64 size);
 const gchar *text_from_time(time_t t);
 
 /* scan for sidecar files - expensive */
-FileData *file_data_new_simple(const gchar *path_utf8);
+FileData *file_data_new_group(const gchar *path_utf8);
 
 /* should be used on helper files which can't have sidecars */
 FileData *file_data_new_no_grouping(const gchar *path_utf8);
@@ -31,6 +41,8 @@ FileData *file_data_new_no_grouping(const gchar *path_utf8);
 /* should be used on dirs */
 FileData *file_data_new_dir(const gchar *path_utf8);
 
+FileData *file_data_new_simple(const gchar *path_utf8);
+
 #ifdef DEBUG_FILEDATA
 FileData *file_data_ref_debug(const gchar *file, gint line, FileData *fd);
 void file_data_unref_debug(const gchar *file, gint line, FileData *fd);
@@ -41,6 +53,11 @@ FileData *file_data_ref(FileData *fd);
 void file_data_unref(FileData *fd);
 #endif
 
+void file_data_lock(FileData *fd);
+void file_data_unlock(FileData *fd);
+void file_data_lock_list(GList *list);
+void file_data_unlock_list(GList *list);
+
 gboolean file_data_check_changed_files(FileData *fd);
 
 void file_data_increment_version(FileData *fd);
@@ -116,7 +133,7 @@ gboolean file_data_sc_update_ci_unspecified(FileData *fd, const gchar *dest_path
 
 gchar *file_data_get_error_string(gint error);
 
-gint file_data_verify_ci(FileData *fd);
+gint file_data_verify_ci(FileData *fd, GList *list);
 gint file_data_verify_ci_list(GList *list, gchar **desc, gboolean with_sidecars);
 
 gboolean file_data_perform_ci(FileData *fd);
@@ -126,7 +143,7 @@ void file_data_free_ci_list(GList *fd_list);
 
 void file_data_set_regroup_when_finished(FileData *fd, gboolean enable);
 
-gint file_data_sc_verify_ci(FileData *fd);
+gint file_data_sc_verify_ci(FileData *fd, GList *list);
 
 gboolean file_data_sc_perform_ci(FileData *fd);
 gboolean file_data_sc_apply_ci(FileData *fd);
@@ -144,5 +161,6 @@ void file_data_send_notification(FileData *fd, NotifyType type);
 gboolean file_data_register_real_time_monitor(FileData *fd);
 gboolean file_data_unregister_real_time_monitor(FileData *fd);
 
+void read_exif_time_data(FileData *file);
 #endif
 /* vim: set shiftwidth=8 softtabstop=0 cindent cinoptions={1s: */