summaryrefslogtreecommitdiff
path: root/daemon/gdm-display-store.c
diff options
context:
space:
mode:
Diffstat (limited to 'daemon/gdm-display-store.c')
-rw-r--r--daemon/gdm-display-store.c16
1 files changed, 13 insertions, 3 deletions
diff --git a/daemon/gdm-display-store.c b/daemon/gdm-display-store.c
index fd24334e..910468cd 100644
--- a/daemon/gdm-display-store.c
+++ b/daemon/gdm-display-store.c
@@ -146,6 +146,16 @@ find_func (const char *id,
closure->user_data);
}
+static void
+foreach_func (const char *id,
+ StoredDisplay *stored_display,
+ FindClosure *closure)
+{
+ (void) closure->predicate (id,
+ stored_display->display,
+ closure->user_data);
+}
+
void
gdm_display_store_foreach (GdmDisplayStore *store,
GdmDisplayStoreFunc func,
@@ -159,9 +169,9 @@ gdm_display_store_foreach (GdmDisplayStore *store,
closure.predicate = func;
closure.user_data = user_data;
- g_hash_table_find (store->priv->displays,
- (GHRFunc) find_func,
- &closure);
+ g_hash_table_foreach (store->priv->displays,
+ (GHFunc) foreach_func,
+ &closure);
}
GdmDisplay *