![]() |
Ansel 0.0
A darktable fork - bloat + design vision
|
Include dependency graph for film.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Data Structures | |
| struct | dt_film_t |
Typedefs | |
| typedef struct dt_film_t | dt_film_t |
| typedef void(* | dt_film_confirm_rmdir_handler_t) (GList *empty_dirs) |
| typedef void(* | dt_film_rolls_changed_handler_t) (void) |
| The film-roll list changed. Raised on whichever thread changed it; a handler that touches widgets gets itself onto the GUI thread, as the signal emission it replaces did. | |
Functions | |
| void | dt_film_init (dt_film_t *film) |
| void | dt_film_cleanup (dt_film_t *film) |
| int | dt_film_open (const int32_t id) |
| int | dt_film_import (const char *dirname) |
| void | dt_film_set_query (const int32_t id) |
| int32_t | dt_film_get_id (const char *folder) |
| void | dt_film_remove (const int id) |
| gboolean | dt_film_is_empty (const int id) |
| int | dt_film_new (dt_film_t *film, const char *directory) |
| void | dt_film_remove_empty () |
| GList * | dt_film_get_image_ids (const int filmid) |
| void | dt_film_set_folder_status () |
| void | dt_film_relocate (const char *old_path, const char *new_path) |
| void | dt_film_set_confirm_rmdir_handler (dt_film_confirm_rmdir_handler_t handler) |
| void | dt_film_remove_directories (const GList *dirs) |
| void | dt_film_set_rolls_changed_handler (dt_film_rolls_changed_handler_t handler) |
| Install the handler, or NULL to remove it. | |
| void | dt_film_notify_rolls_changed (void) |
| State that the film-roll list changed. | |
| typedef void(* dt_film_confirm_rmdir_handler_t) (GList *empty_dirs) |
Invoked with the directories that are now empty. TAKES OWNERSHIP of the list: the handler must free it with g_list_free_full(list, dt_free_gpointer) when done, which may be after it returns (the GUI defers to an idle callback).
film roll. this is one directory of images on disk. also manages the preview image cache.
Definition at line 84 of file film.c.
References dt_film_t::dir, dt_pthread_mutex_destroy(), dt_film_t::images_mutex, and L.
Referenced by _drop_move_to_folder(), _film_import1(), create_test_image(), dt_film_import(), and dt_film_import1_cleanup().
| int32_t dt_film_get_id | ( | const char * | folder | ) |
get id associated with filmroll
Definition at line 108 of file film.c.
References dt_film_repository_find_by_folder(), and folder.
Referenced by _folders_root_collapse_path(), _is_in_library_by_path(), and dt_film_new().
gets all image ids in film. the returned GList has to be freed with g_list_free().
Definition at line 398 of file film.c.
References dt_film_repository_get_image_ids(), and L.
Referenced by main().
| int dt_film_import | ( | const char * | dirname | ) |
import new film and all images in this directory as a background task(non-recursive, existing films/images are respected).
Definition at line 187 of file film.c.
References dt_film_t::dir, dt_film_t::dirname, dt_control_add_job(), dt_control_get_global(), dt_film_cleanup(), dt_film_import1_create(), dt_film_init(), dt_film_is_empty(), dt_film_new(), dt_film_remove(), dt_free, DT_JOB_QUEUE_USER_BG, error(), dt_film_t::id, L, and dt_film_t::last_loaded.
Referenced by dt_load_from_string(), and main().
Definition at line 74 of file film.c.
References dt_film_t::dir, dt_film_t::dirname, dt_pthread_mutex_init(), dt_film_t::id, dt_film_t::images_mutex, L, dt_film_t::last_loaded, dt_film_t::num_images, and dt_film_t::ref.
Referenced by _drop_move_to_folder(), _film_import1(), create_test_image(), and dt_film_import().
| gboolean dt_film_is_empty | ( | const int | id | ) |
checks if film is empty
Definition at line 333 of file film.c.
References dt_film_repository_has_images().
Referenced by _film_import1(), dt_film_import(), and dt_film_import1_run().
Creating a new filmroll
Definition at line 129 of file film.c.
References directory, dt_film_t::dirname, dt_database_get_last_error(), DT_DEBUG_IMPORT, dt_film_get_id(), dt_film_repository_folder_status_set(), dt_film_repository_get_folder(), dt_film_repository_insert(), dt_free, dt_print(), dt_film_t::id, L, dt_film_t::last_loaded, and TRUE.
Referenced by _drop_move_to_folder(), _film_import1(), _generic_dt_control_fileop_images_job_run(), _import_job(), create_test_image(), dt_control_merge_hdr_job_run(), dt_film_import(), dt_load_from_string(), and main().
State that the film-roll list changed.
Definition at line 247 of file film.c.
References _rolls_changed_handler, and L.
Referenced by _pop_undo(), and dt_film_remove().
| int dt_film_open | ( | const int32_t | id | ) |
open film with given id.
Definition at line 113 of file film.c.
References dt_control_queue_redraw_center(), dt_film_repository_get_folder(), dt_film_repository_touch_access(), dt_film_set_query(), dt_free, dt_view_manager_get_global(), dt_view_manager_reset(), and folder.
Referenced by dt_load_from_string().
relocate every film roll located under old_path so it sits under new_path (database only, does not move files on disk). Used by the library module to fix moved folders.
Definition at line 380 of file film.c.
References _collect_relocation(), dt_film_repository_foreach_under(), dt_film_repository_set_folder(), f, i, IS_NULL_PTR, and L.
Referenced by _act_folders_relocate().
removes this film and all its images from db.
Definition at line 340 of file film.c.
References dt_control_log(), dt_film_notify_rolls_changed(), dt_film_repository_delete(), dt_film_repository_get_image_ids(), dt_image_cache_remove(), dt_image_local_copy_reset(), dt_image_safe_remove(), dt_mipmap_cache_remove(), FALSE, L, and TRUE.
Referenced by _film_import1(), dt_film_import(), and dt_film_import1_run().
rmdir() every path in dirs. The list is NOT freed. Call once the user has agreed.
Definition at line 253 of file film.c.
References L.
Referenced by _ask_and_delete().
| void dt_film_remove_empty | ( | ) |
removes all empty film rolls.
Definition at line 291 of file film.c.
References _collect_empty_roll(), _confirm_rmdir_handler, dt_conf_get_bool(), dt_control_signal_get_global(), DT_DEBUG_CONTROL_SIGNAL_RAISE, dt_film_repository_delete(), dt_film_repository_foreach_empty(), dt_free_gpointer(), DT_SIGNAL_FILMROLLS_REMOVED, dt_util_is_dir_empty(), f, FALSE, folder, i, L, and TRUE.
Referenced by _generic_dt_control_fileop_images_job_run(), dt_control_delete_images_job_run(), and dt_control_remove_images_job_run().
| void dt_film_set_confirm_rmdir_handler | ( | dt_film_confirm_rmdir_handler_t | handler | ) |
Install the handler that asks the user about empty directories. NULL removes it.
Definition at line 233 of file film.c.
References _confirm_rmdir_handler, and L.
Referenced by dt_film_gui_register_handlers().
| void dt_film_set_folder_status | ( | ) |
Definition at line 409 of file film.c.
References _record_folder_status(), dt_film_repository_folder_status_clear(), dt_film_repository_foreach(), and L.
Referenced by _act_folders_relocate(), _mount_changed(), and dt_init().
constructs the lighttable/query setting for this film, respecting stars and filters.
Definition at line 94 of file film.c.
References DT_COLLECTION_CHANGE_NEW_QUERY, dt_collection_get_global(), DT_COLLECTION_PROP_UNDEF, dt_collection_update_query(), dt_conf_set_int(), dt_conf_set_string(), dt_film_repository_get_folder(), dt_free, folder, and L.
Referenced by dt_film_open().
| void dt_film_set_rolls_changed_handler | ( | dt_film_rolls_changed_handler_t | handler | ) |
Install the handler, or NULL to remove it.
Definition at line 242 of file film.c.
References _rolls_changed_handler, and L.
Referenced by dt_film_gui_register_handlers().