[libadwaita/wip/exalm/inspector: 27/29] main: Add adw_is_initialized()




commit 6f38ae6da67a56a7bbc2a57968f896ff4b0ab19f
Author: Alexander Mikhaylenko <alexm gnome org>
Date:   Wed Sep 15 03:32:33 2021 +0500

    main: Add adw_is_initialized()

 src/adw-main.c | 15 +++++++++++++++
 src/adw-main.h |  3 +++
 2 files changed, 18 insertions(+)
---
diff --git a/src/adw-main.c b/src/adw-main.c
index cab52c65..0d50bff7 100644
--- a/src/adw-main.c
+++ b/src/adw-main.c
@@ -48,3 +48,18 @@ adw_init (void)
 
   adw_initialized = TRUE;
 }
+
+/**
+ * adw_is_initialized:
+ *
+ * Use this function to check if libadwaita has been initialized with
+ * adw_init().
+ *
+ * Returns: the initialization status
+ */
+gboolean
+adw_is_initialized (void)
+{
+  return adw_initialized;
+}
+
diff --git a/src/adw-main.h b/src/adw-main.h
index 672ffee3..c2a7835b 100644
--- a/src/adw-main.h
+++ b/src/adw-main.h
@@ -18,4 +18,7 @@ G_BEGIN_DECLS
 ADW_AVAILABLE_IN_ALL
 void adw_init (void);
 
+ADW_AVAILABLE_IN_ALL
+gboolean adw_is_initialized (void);
+
 G_END_DECLS


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]