[libdazzle] actions: set initial out parameter state
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libdazzle] actions: set initial out parameter state
- Date: Fri, 21 Dec 2018 22:51:26 +0000 (UTC)
commit e426c2cfa09aecc92c7c7bf0fb162a93fab60d10
Author: Christian Hergert <chergert redhat com>
Date: Fri Dec 21 14:51:16 2018 -0800
actions: set initial out parameter state
src/actions/dzl-action-group.h | 5 +++++
1 file changed, 5 insertions(+)
---
diff --git a/src/actions/dzl-action-group.h b/src/actions/dzl-action-group.h
index 7d94067..c5f1129 100644
--- a/src/actions/dzl-action-group.h
+++ b/src/actions/dzl-action-group.h
@@ -168,6 +168,11 @@ _##prefix##_query_action (GActionGroup *group,
GVariant **state_hint, \
GVariant **state) \
{ \
+ if (enabled) *enabled = FALSE; \
+ if (parameter_type) *parameter_type = NULL ; \
+ if (state_type) *state_type = NULL ; \
+ if (state_hint) *state_hint = NULL ; \
+ if (state) *state = NULL ; \
for (guint i = 0; i < G_N_ELEMENTS(prefix##_actions); i++) \
{ \
if (g_strcmp0 (name, prefix##_actions[i].name) == 0) \
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]