config/Templates: add attribute "deprecated"

This commit is contained in:
Max Kellermann 2015-06-26 00:10:18 +02:00
parent 9477db2363
commit f415167e59
2 changed files with 10 additions and 5 deletions

View File

@ -70,9 +70,9 @@ const ConfigTemplate config_param_templates[] = {
{ "gapless_mp3_playback" },
{ "auto_update" },
{ "auto_update_depth" },
{ "despotify_user" },
{ "despotify_password" },
{ "despotify_high_bitrate" },
{ "despotify_user", false, true },
{ "despotify_password", false, true },
{ "despotify_high_bitrate", false, true },
};
static constexpr unsigned n_config_param_templates =

View File

@ -24,9 +24,14 @@ struct ConfigTemplate {
const char *const name;
const bool repeatable;
// TODO: print warning when a deprecated option is used
const bool deprecated;
constexpr ConfigTemplate(const char *_name,
bool _repeatable=false)
:name(_name), repeatable(_repeatable) {}
bool _repeatable=false,
bool _deprecated=false)
:name(_name), repeatable(_repeatable),
deprecated(_deprecated) {}
};
extern const ConfigTemplate config_param_templates[];