summaryrefslogtreecommitdiffstats
path: root/src/config
diff options
context:
space:
mode:
authorPatrick McDermott <pj@pehjota.net>2017-11-04 15:48:48 (EDT)
committer Patrick McDermott <pj@pehjota.net>2017-11-04 15:48:48 (EDT)
commit605cfeaa6e357f09236e3ba21cefa2cd957464c4 (patch)
tree451c15e68519a9ee37345143be7ad4172fdda8b5 /src/config
parent0bac7d9c5f443cecec79c748e63135e381d82e7c (diff)
downloadmarquee-605cfeaa6e357f09236e3ba21cefa2cd957464c4.zip
marquee-605cfeaa6e357f09236e3ba21cefa2cd957464c4.tar.gz
marquee-605cfeaa6e357f09236e3ba21cefa2cd957464c4.tar.bz2
mq_profiles_is_default(): New function
Diffstat (limited to 'src/config')
-rw-r--r--src/config/profiles.c7
-rw-r--r--src/config/profiles.h3
2 files changed, 10 insertions, 0 deletions
diff --git a/src/config/profiles.c b/src/config/profiles.c
index 23053a0..2829f56 100644
--- a/src/config/profiles.c
+++ b/src/config/profiles.c
@@ -102,6 +102,13 @@ mq_profiles_get_color(MqProfiles *profiles, const gchar *profile)
NULL);
}
+gboolean
+mq_profiles_is_default(MqProfiles *profiles, const gchar *profile)
+{
+ return g_key_file_get_boolean(profiles->key_file, profile, "default",
+ NULL);
+}
+
void
mq_profiles_set_name(MqProfiles *profiles, const gchar *profile,
const gchar *name)
diff --git a/src/config/profiles.h b/src/config/profiles.h
index 0b0a465..fce5209 100644
--- a/src/config/profiles.h
+++ b/src/config/profiles.h
@@ -40,6 +40,9 @@ mq_profiles_get_name(MqProfiles *profiles, const gchar *profile);
gchar *
mq_profiles_get_color(MqProfiles *profiles, const gchar *profile);
+gboolean
+mq_profiles_is_default(MqProfiles *profiles, const gchar *profile);
+
void
mq_profiles_set_name(MqProfiles *profiles, const gchar *profile,
const gchar *name);