[dconf] gsettings: handle writability notification
- From: Ryan Lortie <desrt src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [dconf] gsettings: handle writability notification
- Date: Wed, 27 Nov 2013 17:43:54 +0000 (UTC)
commit 615cbd7990f29d70dca33282695b3a0bbeb89cde
Author: Ryan Lortie <desrt desrt ca>
Date: Wed Nov 27 12:30:01 2013 -0500
gsettings: handle writability notification
Wire through the writability notifications from the engine to the
correct signals on GSettingsBackend.
gsettings/dconfsettingsbackend.c | 15 +++++++++++++++
1 files changed, 15 insertions(+), 0 deletions(-)
---
diff --git a/gsettings/dconfsettingsbackend.c b/gsettings/dconfsettingsbackend.c
index 0c908ed..d27d14a 100644
--- a/gsettings/dconfsettingsbackend.c
+++ b/gsettings/dconfsettingsbackend.c
@@ -256,6 +256,21 @@ dconf_engine_change_notify (DConfEngine *engine,
if (changes[0] == NULL)
return;
+ if (is_writability)
+ {
+ /* We know that the engine does it this way... */
+ g_assert (changes[0][0] == '\0' && changes[1] == NULL);
+
+ if (g_str_has_suffix (prefix, "/"))
+ g_settings_backend_path_writable_changed (G_SETTINGS_BACKEND (dcsb), prefix);
+ else
+ g_settings_backend_writable_changed (G_SETTINGS_BACKEND (dcsb), prefix);
+ }
+
+ /* We send the normal change notification even in the event that this
+ * was a writability notification because adding/removing a lock could
+ * impact the value that gets read.
+ */
if (changes[1] == NULL)
{
if (g_str_has_suffix (prefix, "/"))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]