summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Hergert <chergert@redhat.com>2023-03-20 22:20:16 -0700
committerChristian Hergert <chergert@redhat.com>2023-03-22 16:44:45 -0700
commitb433c0c8a95f123a825cb8ea40d7e45102e01c7f (patch)
tree58ad4024146cd98d6a4bb97d772dfc83d57f7bf0
parent4db3a25b69b6c6539a089c909f83782e4efba092 (diff)
downloadlibpeas-b433c0c8a95f123a825cb8ea40d7e45102e01c7f.tar.gz
plugin-info: add PeasPluginInfo:builtin property
This can be used to filter plugins using GtkFilterListModel.
-rw-r--r--libpeas/peas-plugin-info.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/libpeas/peas-plugin-info.c b/libpeas/peas-plugin-info.c
index e0d0ea8..95d82a8 100644
--- a/libpeas/peas-plugin-info.c
+++ b/libpeas/peas-plugin-info.c
@@ -69,6 +69,7 @@ G_DEFINE_FINAL_TYPE (PeasPluginInfo, peas_plugin_info, G_TYPE_OBJECT)
enum {
PROP_0,
PROP_AUTHORS,
+ PROP_BUILTIN,
PROP_COPYRIGHT,
PROP_DEPENDENCIES,
PROP_DESCRIPTION,
@@ -126,6 +127,10 @@ peas_plugin_info_get_property (GObject *object,
g_value_set_boxed (value, peas_plugin_info_get_authors (info));
break;
+ case PROP_BUILTIN:
+ g_value_set_boolean (value, peas_plugin_info_is_builtin (info));
+ break;
+
case PROP_COPYRIGHT:
g_value_set_string (value, peas_plugin_info_get_copyright (info));
break;
@@ -183,6 +188,11 @@ peas_plugin_info_class_init (PeasPluginInfoClass *klass)
object_class->finalize = peas_plugin_info_finalize;
object_class->get_property = peas_plugin_info_get_property;
+ properties[PROP_BUILTIN] =
+ g_param_spec_boolean (I_("builtin"), NULL, NULL,
+ FALSE,
+ (G_PARAM_READABLE | G_PARAM_STATIC_STRINGS));
+
properties[PROP_LOADED] =
g_param_spec_boolean (I_("loaded"), NULL, NULL,
FALSE,