summaryrefslogtreecommitdiff
path: root/src/glibext
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2025-02-10 22:45:51 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2025-02-10 22:45:51 (GMT)
commitfd2f458abac21ceefa55468e1cb072ed16224a8e (patch)
treec2e9560d21659c4771d31723fa891b7c7dfbe2ee /src/glibext
parent607cd5420f847618d4cad66e7e168b6955ab4b6a (diff)
Track secret storage lock updates in the status bar.
Diffstat (limited to 'src/glibext')
-rw-r--r--src/glibext/secstorage-int.h4
-rw-r--r--src/glibext/secstorage.c10
2 files changed, 13 insertions, 1 deletions
diff --git a/src/glibext/secstorage-int.h b/src/glibext/secstorage-int.h
index 310fbbc..bbac133 100644
--- a/src/glibext/secstorage-int.h
+++ b/src/glibext/secstorage-int.h
@@ -45,6 +45,10 @@ struct _GSecretStorageClass
{
GObjectClass parent; /* A laisser en premier */
+ /* Signaux */
+
+ void (* lock_update) (GSecretStorage *);
+
};
diff --git a/src/glibext/secstorage.c b/src/glibext/secstorage.c
index 84fc10c..ed2e4e6 100644
--- a/src/glibext/secstorage.c
+++ b/src/glibext/secstorage.c
@@ -111,6 +111,14 @@ static void g_secret_storage_class_init(GSecretStorageClass *klass)
object->dispose = g_secret_storage_dispose;
object->finalize = g_secret_storage_finalize;
+ g_signal_new("lock-update",
+ G_TYPE_SECRET_STORAGE,
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET(GSecretStorageClass, lock_update),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
+
}
@@ -237,7 +245,7 @@ bool g_secret_storage_create(GSecretStorage *storage, GSettings *settings)
storage->settings = settings;
}
else
- result = false; // TODO
+ storage->settings = g_settings_new("re.chrysalide.framework.secstorage");
return result;