Skip to content

Commit c0ebff2

Browse files
committed
qml: Set OptionQmlModel initial property values
1 parent c3fb557 commit c0ebff2

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/qml/models/options_model.cpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
#include <common/settings.h>
99
#include <common/system.h>
1010
#include <interfaces/node.h>
11+
#include <mapport.h>
1112
#include <qt/guiconstants.h>
1213
#include <qt/guiutil.h>
1314
#include <qt/optionsmodel.h>
@@ -28,11 +29,19 @@ OptionsQmlModel::OptionsQmlModel(interfaces::Node& node)
2829
{
2930
m_dbcache_size_mib = SettingToInt(m_node.getPersistentSetting("dbcache"), nDefaultDbCache);
3031

32+
m_listen = SettingToBool(m_node.getPersistentSetting("listen"), DEFAULT_LISTEN);
33+
34+
m_natpmp = SettingToBool(m_node.getPersistentSetting("natpmp"), DEFAULT_NATPMP);
35+
3136
int64_t prune_value{SettingToInt(m_node.getPersistentSetting("prune"), 0)};
3237
m_prune = (prune_value > 1);
3338
m_prune_size_gb = m_prune ? PruneMiBtoGB(prune_value) : DEFAULT_PRUNE_TARGET_GB;
3439

3540
m_script_threads = SettingToInt(m_node.getPersistentSetting("par"), DEFAULT_SCRIPTCHECK_THREADS);
41+
42+
m_server = SettingToBool(m_node.getPersistentSetting("server"), false);
43+
44+
m_upnp = SettingToBool(m_node.getPersistentSetting("upnp"), DEFAULT_UPNP);
3645
}
3746

3847
void OptionsQmlModel::setDbcacheSizeMiB(int new_dbcache_size_mib)

0 commit comments

Comments
 (0)