mirror of
https://github.com/ciphervance/supercell-wx.git
synced 2025-10-30 22:40:05 +00:00
Add anti-aliasing to settings
This commit is contained in:
parent
3a754c01c5
commit
c5a56680ea
6 changed files with 32 additions and 6 deletions
|
|
@ -29,6 +29,7 @@ public:
|
|||
boost::to_lower(defaultDefaultAlertActionValue);
|
||||
boost::to_lower(defaultMapProviderValue);
|
||||
|
||||
antiAliasingEnabled_.SetDefault(true);
|
||||
debugEnabled_.SetDefault(false);
|
||||
defaultAlertAction_.SetDefault(defaultDefaultAlertActionValue);
|
||||
defaultRadarSite_.SetDefault("KLSX");
|
||||
|
|
@ -104,6 +105,7 @@ public:
|
|||
|
||||
~Impl() {}
|
||||
|
||||
SettingsVariable<bool> antiAliasingEnabled_ {"anti_aliasing_enabled"};
|
||||
SettingsVariable<bool> debugEnabled_ {"debug_enabled"};
|
||||
SettingsVariable<std::string> defaultAlertAction_ {"default_alert_action"};
|
||||
SettingsVariable<std::string> defaultRadarSite_ {"default_radar_site"};
|
||||
|
|
@ -122,7 +124,8 @@ public:
|
|||
GeneralSettings::GeneralSettings() :
|
||||
SettingsCategory("general"), p(std::make_unique<Impl>())
|
||||
{
|
||||
RegisterVariables({&p->debugEnabled_,
|
||||
RegisterVariables({&p->antiAliasingEnabled_,
|
||||
&p->debugEnabled_,
|
||||
&p->defaultAlertAction_,
|
||||
&p->defaultRadarSite_,
|
||||
&p->fontSizes_,
|
||||
|
|
@ -143,6 +146,11 @@ GeneralSettings::GeneralSettings(GeneralSettings&&) noexcept = default;
|
|||
GeneralSettings&
|
||||
GeneralSettings::operator=(GeneralSettings&&) noexcept = default;
|
||||
|
||||
SettingsVariable<bool>& GeneralSettings::anti_aliasing_enabled() const
|
||||
{
|
||||
return p->antiAliasingEnabled_;
|
||||
}
|
||||
|
||||
SettingsVariable<bool>& GeneralSettings::debug_enabled() const
|
||||
{
|
||||
return p->debugEnabled_;
|
||||
|
|
@ -229,7 +237,8 @@ GeneralSettings& GeneralSettings::Instance()
|
|||
|
||||
bool operator==(const GeneralSettings& lhs, const GeneralSettings& rhs)
|
||||
{
|
||||
return (lhs.p->debugEnabled_ == rhs.p->debugEnabled_ &&
|
||||
return (lhs.p->antiAliasingEnabled_ == rhs.p->antiAliasingEnabled_ &&
|
||||
lhs.p->debugEnabled_ == rhs.p->debugEnabled_ &&
|
||||
lhs.p->defaultAlertAction_ == rhs.p->defaultAlertAction_ &&
|
||||
lhs.p->defaultRadarSite_ == rhs.p->defaultRadarSite_ &&
|
||||
lhs.p->fontSizes_ == rhs.p->fontSizes_ &&
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue