diff options
Diffstat (limited to 'src/config.c')
-rw-r--r-- | src/config.c | 32 |
1 files changed, 19 insertions, 13 deletions
diff --git a/src/config.c b/src/config.c index dd444fe..94afb20 100644 --- a/src/config.c +++ b/src/config.c @@ -263,11 +263,6 @@ cb_mailer (enum gconf_callback_command cmd, if (assert_string_arg (locus, cmd, value)) return 1; - if (cmd != gconf_callback_set_value) - { - gconf_error (locus, 0, _("Unexpected block statement")); - return 1; - } rc = mu_mailer_create (&mailer, value->v.string); if (rc) gconf_error (locus, 0, _("cannot create mailer `%s': %s"), @@ -1085,7 +1080,7 @@ cb_access_method (enum gconf_callback_command cmd, } static int -cb_destination_url (enum gconf_callback_command cmd, +cb_url (enum gconf_callback_command cmd, gconf_locus_t *locus, void *varptr, gconf_value_t *value, @@ -1096,11 +1091,6 @@ cb_destination_url (enum gconf_callback_command cmd, if (assert_string_arg (locus, cmd, value)) return 1; - if (cmd != gconf_callback_set_value) - { - gconf_error (locus, 0, _("Unexpected block statement")); - return 1; - } rc = mu_url_create (&url, value->v.string); if (rc) { @@ -1122,11 +1112,15 @@ cb_destination_url (enum gconf_callback_command cmd, static struct gconf_keyword spool_kw[] = { + { "url", N_("arg"), N_("URL corresponding to this spool"), + gconf_type_string, NULL, offsetof(struct spool, url) }, + { "alias", N_("arg"), N_("Aliases"), + gconf_type_string|GCONF_LIST, NULL, offsetof(struct spool, aliases) }, { "source", N_("dir"), N_("Source directory"), gconf_type_string, NULL, offsetof(struct spool, source_dir) }, { "destination", N_("dir"), N_("Destination directory"), gconf_type_string, NULL, offsetof(struct spool, dest_url), - cb_destination_url }, + cb_url }, { "file-sweep-time", N_("interval"), N_("Define file sweep time"), gconf_type_string, NULL, offsetof(struct spool, file_sweep_time), cb_interval }, @@ -1164,7 +1158,7 @@ cb_spool (enum gconf_callback_command cmd, return 1; } spool = xzalloc (sizeof (*spool)); - spool->url = xstrdup (value->v.string); + spool->tag = xstrdup (value->v.string); spool->file_sweep_time = file_sweep_time; for (i = 0; i < NITEMS (spool->access_method); i++) spool->access_method[i] = default_access_method[i]; @@ -1233,6 +1227,18 @@ cb_spool (enum gconf_callback_command cmd, static struct gconf_keyword wydawca_kw[] = { + { "daemon", NULL, N_("Enable daemon mode"), + gconf_type_bool, &daemon_mode }, + { "foreground", NULL, N_("Start in foreground even in daemon mode"), + gconf_type_bool, &foreground }, + { "single-process", NULL, N_("Do not spawn subprocesses"), + gconf_type_bool, &single_process }, + { "wakeup-interval", N_("time"), N_("Set wake-up interval"), + gconf_type_string, &wakeup_interval, 0, cb_interval }, + { "pidfile", N_("file"), N_("Set pid file name"), + gconf_type_string, &pidfile }, + { "listen", N_("socket"), N_("Listen on this address"), + gconf_type_sockaddr, &listen_sockaddr, }, { "mailer", N_("url"), N_("Set mailer URL"), gconf_type_string, &mailer, 0, cb_mailer }, { "admin-address", N_("email"), N_("Set admin email address"), |