-
Notifications
You must be signed in to change notification settings - Fork 48
/
data.h
80 lines (50 loc) · 1.34 KB
/
data.h
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
79
80
#pragma once
#include <gtk/gtk.h>
#include <jansson.h>
#define DBUS_SERVICES 4
G_BEGIN_DECLS
typedef struct db_data_t {
gchar *db_path;
gchar *key;
json_t *json_data;
GSList *objects_hash;
GSList *data_to_add;
gint32 max_file_size_from_memlock;
gchar *last_hotp;
GDateTime *last_hotp_update;
gboolean key_stored;
} DatabaseData;
typedef struct app_data_t {
GtkBuilder *builder;
GtkBuilder *add_popover_builder;
GtkBuilder *settings_popover_builder;
GtkWidget *main_window;
GtkWidget *info_bar;
GtkTreeView *tree_view;
GtkClipboard *clipboard;
gboolean show_next_otp;
gboolean disable_notifications;
gint search_column;
gboolean auto_lock;
gint inactivity_timeout;
GtkCssProvider *delbtn_css_provider;
GtkCssProvider *tv_css_provider;
GNotification *notification;
guint source_id;
guint source_id_last_activity;
DatabaseData *db_data;
GDBusConnection *connection;
guint subscription_ids[DBUS_SERVICES];
gboolean app_locked;
gboolean use_dark_theme;
gboolean is_reorder_active;
gboolean use_secret_service;
GDateTime *last_user_activity;
GtkWidget *diag_rcdb;
GtkFileChooserAction open_db_file_action;
} AppData;
typedef struct node_info_t {
guint hash;
guint newpos;
} NodeInfo;
G_END_DECLS