diff options
author | Bent Bisballe Nyeng <deva@aasimon.org> | 2017-03-12 14:28:21 +0100 |
---|---|---|
committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2017-03-23 20:17:52 +0100 |
commit | bc661e52f925cdf5fe1effdbae2f81bd796eac32 (patch) | |
tree | 75c18f5d0c1c250e09d7d7565870d08f3efe5a10 | |
parent | 889070f5c84f67cb52a5038fe93aca6234bbc360 (diff) |
Store new settings in plugin config.
-rw-r--r-- | plugin/drumgizmo_plugin.cc | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/plugin/drumgizmo_plugin.cc b/plugin/drumgizmo_plugin.cc index 3db72c1..f31db98 100644 --- a/plugin/drumgizmo_plugin.cc +++ b/plugin/drumgizmo_plugin.cc @@ -497,6 +497,10 @@ std::string DrumGizmoPlugin::ConfigStringIO::get() bool2str(settings.enable_velocity_randomiser.load()) + "</value>\n" " <value name=\"velocity_randomiser_weight\">" + float2str(settings.velocity_randomiser_weight.load()) + "</value>\n" + " <value name=\"disk_cache_upper_limit\">" + + float2str(settings.disk_cache_upper_limit.load()) + "</value>\n" + " <value name=\"disk_cache_enable\">" + + bool2str(settings.disk_cache_enable.load()) + "</value>\n" "</config>"; } @@ -541,6 +545,16 @@ bool DrumGizmoPlugin::ConfigStringIO::set(std::string config_string) settings.enable_resampling.store(p.value("enable_resampling") == "true"); } + if(p.value("disk_cache_upper_limit") != "") + { + settings.disk_cache_upper_limit.store(str2float(p.value("disk_cache_upper_limit"))); + } + + if(p.value("disk_cache_enable") != "") + { + settings.disk_cache_enable.store(p.value("disk_cache_enable") == "true"); + } + std::string newkit = p.value("drumkitfile"); if(newkit != "") { |