aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/default-applications.c25
1 files changed, 18 insertions, 7 deletions
diff --git a/src/default-applications.c b/src/default-applications.c
index 5347b43..6aca047 100644
--- a/src/default-applications.c
+++ b/src/default-applications.c
@@ -6,17 +6,18 @@
struct default_db_t {
const gchar * desktop_file;
const gchar * name;
+ const gchar * setupname;
};
struct default_db_t default_db[] = {
- {"evolution.desktop", N_("Mail")},
- {"empathy.desktop", N_("Chat")},
- {"gwibber.desktop", N_("Microblogging")},
+ {"evolution.desktop", N_("Mail"), N_("Set Up Mail...")},
+ {"empathy.desktop", N_("Chat"), N_("Set Up Chat...")},
+ {"gwibber.desktop", N_("Microblogging"), N_("Set Up Microblogging...")},
{NULL, NULL}
};
-const gchar *
-get_default_name (gchar * desktop_path)
+struct default_db_t *
+get_default_helper (gchar * desktop_path)
{
g_return_val_if_fail(desktop_path != NULL, NULL);
gchar * basename = g_path_get_basename(desktop_path);
@@ -31,9 +32,19 @@ get_default_name (gchar * desktop_path)
g_free(basename);
- if (default_db[i].name != NULL) {
- return default_db[i].name;
+ if (default_db[i].desktop_file != NULL) {
+ return &default_db[i];
}
return NULL;
}
+
+const gchar *
+get_default_name (gchar * desktop_path)
+{
+ struct default_db_t * db = get_default_helper(desktop_path);
+
+ if (db == NULL)
+ return NULL;
+ return db->name;
+}