![]() |
Ansel 0.0
A darktable fork - bloat + design vision
|
#include "gui/actions/supervisor_window.h"#include "common/darktable.h"#include "common/image_cache.h"#include "common/mipmap_cache.h"#include "common/opencl.h"#include "develop/pixelpipe_cache.h"#include "develop/supervisor.h"#include "gui/gtk.h"#include <gtk/gtk.h>#include <json-glib/json-glib.h>
Include dependency graph for supervisor_window.c:Go to the source code of this file.
Data Structures | |
| struct | _group_t |
Macros | |
| #define | TIMELINE_MAX_ROWS 4000 |
| #define | POLL_INTERVAL_MS 300 |
| #define | MEMORY_MAX_ROWS 500 |
| #define | MEMORY_REFRESH_TICKS 4 |
Typedefs | |
| typedef struct _group_t | _group_t |
Functions | |
| static void | _group_free (gpointer p) |
| static gchar * | _hashhex (const uint64_t h) |
| static const char * | _domain_color (const char *d) |
| static gchar * | _pretty_json (const char *compact) |
| static void | _run_search (const char *query) |
| static void | _scroll_row_into_view (GtkWidget *row) |
| static gboolean | _scroll_target_idle (gpointer u) |
| static gboolean | _on_link (GtkLabel *label, gchar *uri, gpointer user_data) |
| static void | _on_search_this_hash (GtkMenuItem *item, gpointer u) |
| static gboolean | _on_label_button (GtkWidget *label, GdkEventButton *e, gpointer u) |
| static void | _wire_hash_label (GtkWidget *label) |
| static GtkWidget * | _event_body_from (const char *json, GArray *links) |
| static void | _on_toggle (GtkToggleButton *t, gpointer u) |
| static GtkWidget * | _collapsible (const char *header_markup, GtkWidget *body, const gboolean expanded) |
| static gchar * | _header_markup (const dt_sv_logged_event_t *ev) |
| static void | _links_free (gpointer p) |
| static GtkWidget * | _event_widget (const dt_sv_logged_event_t *ev) |
| static void | _timeline_append (const dt_sv_logged_event_t *ev) |
| static void | _timeline_trim (void) |
| static void | _clear_list (GtkWidget *list) |
| static void | _update_count (void) |
| static const char * | _group_key (const dt_sv_logged_event_t *ev, const char *by) |
| static void | _group_set_header (_group_t *g) |
| static void | _grouped_append (const dt_sv_logged_event_t *ev, const char *by) |
| static void | _grouped_catch_up (void) |
| static void | _rebuild_grouped_now (void) |
| static void | _add_usage_bar (GtkWidget *box, const char *title, const size_t cur, const size_t max) |
| static void | _add_mem_item (GtkWidget *box, const char *markup, const char *trailing) |
| static gint | _cmp_pixel_size (gconstpointer a, gconstpointer b) |
| static gint | _cmp_mip_size (gconstpointer a, gconstpointer b) |
| static gint | _cmp_image_imgid (gconstpointer a, gconstpointer b) |
| static void | _rebuild_memory (void) |
| static gboolean | _hex_contains (const uint64_t h, const char *needle) |
| static gboolean | _event_matches (const dt_sv_logged_event_t *ev, const char *hash_needle, const char *text_needle) |
| static void | _on_search_changed (GtkSearchEntry *e, gpointer u) |
| static gboolean | _scroll_bottom_idle (gpointer u) |
| static gboolean | _poll (gpointer u) |
| static void | _full_reload (void) |
| static void | _on_refresh (GtkButton *b, gpointer u) |
| static void | _on_clear (GtkButton *b, gpointer u) |
| static void | _on_groupby_changed (GtkComboBox *c, gpointer u) |
| static void | _on_record_toggled (GtkToggleButton *t, gpointer u) |
| static void | _on_page_changed (GtkNotebook *nb, GtkWidget *page, guint page_num, gpointer u) |
| static void | _on_destroy (GtkWidget *w, gpointer u) |
| void | dt_gui_supervisor_window_show (void) |
Variables | ||
| struct { | ||
| GtkWidget * window | ||
| GtkWidget * notebook | ||
| GtkWidget * timeline_list | ||
| GtkWidget * timeline_scroll | ||
| GtkWidget * grouped_list | ||
| GtkWidget * mem_box | ||
| GtkWidget * search_entry | ||
| GtkWidget * search_list | ||
| GtkWidget * count_label | ||
| GtkWidget * groupby | ||
| GHashTable * decl_map | ||
| GHashTable * group_map | ||
| uint64_t last_seq | ||
| uint64_t grouped_last_seq | ||
| gchar * scroll_target | ||
| guint timer_id | ||
| guint tick | ||
| int page_timeline | ||
| int page_grouped | ||
| int page_memory | ||
| int page_search | ||
| } | _g = { 0 } | |
| #define MEMORY_MAX_ROWS 500 |
Definition at line 35 of file supervisor_window.c.
| #define MEMORY_REFRESH_TICKS 4 |
Definition at line 36 of file supervisor_window.c.
| #define POLL_INTERVAL_MS 300 |
Definition at line 34 of file supervisor_window.c.
| #define TIMELINE_MAX_ROWS 4000 |
Definition at line 33 of file supervisor_window.c.
Definition at line 498 of file supervisor_window.c.
References _wire_hash_label(), FALSE, row, and TRUE.
Referenced by _rebuild_memory().
|
static |
Definition at line 475 of file supervisor_window.c.
References FALSE, max, t, and TRUE.
Referenced by _rebuild_memory().
Definition at line 394 of file supervisor_window.c.
Referenced by _full_reload(), _rebuild_grouped_now(), _rebuild_memory(), and _run_search().
|
static |
|
static |
|
static |
|
static |
Definition at line 233 of file supervisor_window.c.
References _on_toggle(), _wire_hash_label(), FALSE, and TRUE.
Referenced by _event_widget(), and _grouped_append().
|
static |
|
static |
Definition at line 296 of file supervisor_window.c.
References _hashhex(), _pretty_json(), _wire_hash_label(), FALSE, dt_sv_link_t::hash, i, dt_sv_link_t::label, lw, and TRUE.
Referenced by _on_toggle().
|
static |
Definition at line 643 of file supervisor_window.c.
References _hex_contains(), FALSE, dt_sv_logged_event_t::hash, i, dt_sv_logged_event_t::json, dt_sv_logged_event_t::links, m, and TRUE.
Referenced by _run_search().
|
static |
Definition at line 341 of file supervisor_window.c.
References _collapsible(), _hashhex(), _header_markup(), _links_free(), copy(), FALSE, dt_sv_logged_event_t::hash, dt_sv_logged_event_t::json, and dt_sv_logged_event_t::links.
Referenced by _grouped_append(), _run_search(), and _timeline_append().
Definition at line 738 of file supervisor_window.c.
References _clear_list(), _g, _poll(), _rebuild_grouped_now(), _rebuild_memory(), and _run_search().
Referenced by _on_clear(), _on_refresh(), and dt_gui_supervisor_window_show().
|
static |
Definition at line 70 of file supervisor_window.c.
Referenced by dt_gui_supervisor_window_show().
|
static |
Definition at line 408 of file supervisor_window.c.
References dt_sv_logged_event_t::domain, dt_sv_logged_event_t::op, and dt_sv_logged_event_t::thread.
Referenced by _grouped_append().
|
static |
Definition at line 426 of file supervisor_window.c.
References _collapsible(), _event_widget(), _g, _group_key(), _group_set_header(), FALSE, g, k, and row.
Referenced by _grouped_catch_up().
Definition at line 450 of file supervisor_window.c.
References _g, _grouped_append(), dt_supervisor_events_free(), dt_supervisor_events_snapshot_since(), and i.
Referenced by _on_page_changed(), _poll(), and _rebuild_grouped_now().
|
static |
Definition at line 78 of file supervisor_window.c.
Referenced by _event_body_from(), _event_widget(), _header_markup(), _hex_contains(), _rebuild_memory(), and _timeline_append().
|
static |
Definition at line 269 of file supervisor_window.c.
References _domain_color(), _hashhex(), dt_sv_logged_event_t::cache_name, dt_sv_logged_event_t::domain, dt_sv_logged_event_t::hash, dt_sv_logged_event_t::mnemonic, dt_sv_logged_event_t::op, out, dt_sv_logged_event_t::thread, and dt_sv_logged_event_t::ts.
Referenced by _event_widget().
|
static |
Definition at line 629 of file supervisor_window.c.
References _hashhex(), and m.
Referenced by _event_matches().
|
static |
Definition at line 335 of file supervisor_window.c.
Referenced by _event_widget().
|
static |
Definition at line 751 of file supervisor_window.c.
References _full_reload(), and dt_supervisor_events_clear().
Referenced by dt_gui_supervisor_window_show().
Definition at line 777 of file supervisor_window.c.
References _g, dt_supervisor_set_recording(), and FALSE.
Referenced by dt_gui_supervisor_window_show().
|
static |
Definition at line 757 of file supervisor_window.c.
References _rebuild_grouped_now().
Referenced by dt_gui_supervisor_window_show().
|
static |
Definition at line 176 of file supervisor_window.c.
References _on_search_this_hash(), FALSE, and TRUE.
Referenced by _wire_hash_label().
|
static |
Definition at line 145 of file supervisor_window.c.
References _g, _scroll_target_idle(), row, and TRUE.
Referenced by _wire_hash_label().
|
static |
Definition at line 767 of file supervisor_window.c.
References _g, _grouped_catch_up(), _rebuild_memory(), and _run_search().
Referenced by dt_gui_supervisor_window_show().
|
static |
Definition at line 762 of file supervisor_window.c.
References dt_supervisor_set_recording(), and t.
Referenced by dt_gui_supervisor_window_show().
|
static |
Definition at line 749 of file supervisor_window.c.
References _full_reload().
Referenced by dt_gui_supervisor_window_show().
|
static |
Definition at line 689 of file supervisor_window.c.
References _g, and _run_search().
Referenced by dt_gui_supervisor_window_show().
|
static |
Definition at line 165 of file supervisor_window.c.
References _g.
Referenced by _on_label_button().
|
static |
Definition at line 206 of file supervisor_window.c.
References _event_body_from(), and t.
Referenced by _collapsible().
|
static |
Definition at line 705 of file supervisor_window.c.
References _g, _grouped_catch_up(), _rebuild_memory(), _scroll_bottom_idle(), _timeline_append(), _timeline_trim(), _update_count(), dt_supervisor_events_free(), dt_supervisor_events_snapshot_since(), i, and MEMORY_REFRESH_TICKS.
Referenced by _full_reload(), and dt_gui_supervisor_window_show().
|
static |
Definition at line 97 of file supervisor_window.c.
References g, out, p, and TRUE.
Referenced by _event_body_from().
Definition at line 465 of file supervisor_window.c.
References _clear_list(), _g, and _grouped_catch_up().
Referenced by _full_reload(), and _on_groupby_changed().
Definition at line 541 of file supervisor_window.c.
References _add_mem_item(), _add_usage_bar(), _clear_list(), _cmp_image_imgid(), _cmp_mip_size(), _cmp_pixel_size(), _g, _hashhex(), dt_pixel_cache_stats_entry_t::cl_bytes, dt_pixel_cache_stats_entry_t::cl_count, darktable, dt_dev_pixelpipe_cache_get_entries_stats(), dt_dev_pixelpipe_cache_get_usage(), dt_dev_pixelpipe_cache_get_vram_total(), dt_image_cache_get_entries_stats(), dt_image_cache_get_usage(), dt_mipmap_cache_get_entries_stats(), dt_mipmap_cache_get_usage(), dt_opencl_is_enabled(), dt_supervisor_image_key(), dt_supervisor_mipmap_key(), dt_image_cache_stats_entry_t::filename, dt_pixel_cache_stats_entry_t::hash, dt_pixel_cache_stats_entry_t::hits, i, darktable_t::image_cache, dt_image_cache_stats_entry_t::imgid, dt_mipmap_cache_stats_entry_t::imgid, m, max, MEMORY_MAX_ROWS, dt_mipmap_cache_stats_entry_t::mip, darktable_t::mipmap_cache, name, dt_pixel_cache_stats_entry_t::name, darktable_t::pixelpipe_cache, dt_pixel_cache_stats_entry_t::refcount, dt_mipmap_cache_stats_entry_t::size, dt_pixel_cache_stats_entry_t::size, and TRUE.
Referenced by _full_reload(), _on_page_changed(), and _poll().
|
static |
Definition at line 663 of file supervisor_window.c.
References _clear_list(), _event_matches(), _event_widget(), _g, dt_supervisor_events_free(), dt_supervisor_events_snapshot(), and i.
Referenced by _full_reload(), _on_page_changed(), and _on_search_changed().
|
static |
Definition at line 116 of file supervisor_window.c.
References _g, double(), MAX, and row.
Referenced by _scroll_target_idle().
|
static |
Definition at line 133 of file supervisor_window.c.
References _g, _scroll_row_into_view(), and row.
Referenced by _on_link().
|
static |
Definition at line 365 of file supervisor_window.c.
References _event_widget(), _g, _hashhex(), dt_sv_logged_event_t::hash, dt_sv_logged_event_t::op, and row.
Referenced by _poll().
Definition at line 380 of file supervisor_window.c.
References _g, row, and TIMELINE_MAX_ROWS.
Referenced by _poll().
Definition at line 401 of file supervisor_window.c.
References _g, and dt_supervisor_events_count().
Referenced by _poll().
Definition at line 196 of file supervisor_window.c.
References _on_label_button(), _on_link(), and FALSE.
Referenced by _add_mem_item(), _collapsible(), and _event_body_from().
Definition at line 787 of file supervisor_window.c.
References _full_reload(), _g, _group_free(), _on_clear(), _on_destroy(), _on_groupby_changed(), _on_page_changed(), _on_record_toggled(), _on_refresh(), _on_search_changed(), _poll(), darktable, dt_supervisor_set_recording(), dt_ui_main_window(), FALSE, darktable_t::gui, POLL_INTERVAL_MS, TRUE, and dt_gui_gtk_t::ui.
Referenced by supervisor_callback().
| struct { ... } _g |
Referenced by _full_reload(), _grouped_append(), _grouped_catch_up(), _on_destroy(), _on_link(), _on_page_changed(), _on_search_changed(), _on_search_this_hash(), _poll(), _rebuild_grouped_now(), _rebuild_memory(), _run_search(), _scroll_bottom_idle(), _scroll_row_into_view(), _scroll_target_idle(), _timeline_append(), _timeline_trim(), _update_count(), and dt_gui_supervisor_window_show().
| GtkWidget* count_label |
Definition at line 48 of file supervisor_window.c.
| GHashTable* decl_map |
Definition at line 50 of file supervisor_window.c.
| GHashTable* group_map |
Definition at line 51 of file supervisor_window.c.
| GtkWidget* groupby |
Definition at line 49 of file supervisor_window.c.
| uint64_t grouped_last_seq |
Definition at line 53 of file supervisor_window.c.
| GtkWidget* grouped_list |
Definition at line 44 of file supervisor_window.c.
| uint64_t last_seq |
Definition at line 52 of file supervisor_window.c.
| GtkWidget* mem_box |
Definition at line 45 of file supervisor_window.c.
| GtkWidget* notebook |
Definition at line 41 of file supervisor_window.c.
Referenced by _blendop_blending_notebook_switch(), _blendop_create_notebook_page(), _blendop_create_toggle_page(), _channel_tabs_switch_callback(), _notebook_append_full_width_page(), _notebook_motion_notify_callback(), _notebook_size_callback(), create_notebook(), dt_ui_notebook_page(), dt_ui_notebook_set_picker_owner(), gui_init(), and gui_init().
| int page_grouped |
Definition at line 57 of file supervisor_window.c.
| int page_memory |
Definition at line 57 of file supervisor_window.c.
| int page_search |
Definition at line 57 of file supervisor_window.c.
| int page_timeline |
Definition at line 57 of file supervisor_window.c.
| gchar* scroll_target |
Definition at line 54 of file supervisor_window.c.
| GtkWidget* search_entry |
Definition at line 46 of file supervisor_window.c.
Referenced by _find_and_rank_matches(), and dt_accels_search().
| GtkWidget* search_list |
Definition at line 47 of file supervisor_window.c.
| guint tick |
Definition at line 56 of file supervisor_window.c.
| GtkWidget* timeline_list |
Definition at line 42 of file supervisor_window.c.
| GtkWidget* timeline_scroll |
Definition at line 43 of file supervisor_window.c.
| guint timer_id |
Definition at line 55 of file supervisor_window.c.
| GtkWidget* window |
Definition at line 40 of file supervisor_window.c.
Referenced by _activate_callback_to_action_callback(), _control_set_cursor_on_widget(), _darkroom_edge_pan_tick(), _extract_pointer_input(), _gui_styles_dialog_run(), _gui_styles_edit_style_response(), _gui_styles_new_style_response(), _hm_ask_user_constraints_choice(), _hm_show_merge_report_popup(), _hm_show_toposort_cycle_popup(), _hm_warn_missing_raster_producers(), _ioporder_init_popup(), _ioporder_rebuild_graph(), _lib_tagging_tag_show_accel(), _menuitem_delete_preset(), _menuitem_update_preset(), _modulegroups_drag_begin(), _panel_handle_resize(), _popup_coordinates(), _queue_action_from_shortcut(), _sample_axis_from_device_state(), _sample_raw_segment_cubic_param(), _sample_tablet_state_from_devices(), _view_surface_commit_main(), dt_accels_search(), dt_bauhaus_init(), dt_bauhaus_show_popup(), dt_colorspaces_set_display_profile(), dt_drawlayer_paint_rasterize_segment_to_buffer(), dt_gui_hist_dialog_new(), dt_gui_merge_options_dialog(), dt_gui_show_standalone_string_dialog(), dt_gui_show_standalone_three_choice_dialog(), dt_gui_show_standalone_yes_no_dialog(), dt_key_modifier_state(), dt_osx_disable_fullscreen(), edit_preset(), enter(), full_screen_callback(), main_gui(), menuitem_delete_preset(), menuitem_update_preset(), and wavelet_denoise().