mirror of
https://github.com/AlexandreRouma/SDRPlusPlus.git
synced 2025-05-07 14:16:32 +02:00
final bugfixes to the new source menu
This commit is contained in:
parent
b835d07573
commit
6891d0bb0f
@ -140,7 +140,12 @@ namespace sourcemenu {
|
|||||||
core::configManager.acquire();
|
core::configManager.acquire();
|
||||||
|
|
||||||
// Load custom offsets
|
// Load custom offsets
|
||||||
namedOffsets = (std::map<std::string, double>)core::configManager.conf["offsets"];
|
auto ofs = core::configManager.conf["offsets"].items();
|
||||||
|
for (auto& o : ofs) {
|
||||||
|
namedOffsets[o.key()] = (double)o.value();
|
||||||
|
}
|
||||||
|
|
||||||
|
// Define custom offsets
|
||||||
for (auto& [name, offset] : namedOffsets) {
|
for (auto& [name, offset] : namedOffsets) {
|
||||||
offsets.define(name, offsets.size());
|
offsets.define(name, offsets.size());
|
||||||
}
|
}
|
||||||
@ -349,7 +354,7 @@ namespace sourcemenu {
|
|||||||
if (ImGui::InputDouble("##freq_offset", &manualOffset, 1.0, 100.0)) {
|
if (ImGui::InputDouble("##freq_offset", &manualOffset, 1.0, 100.0)) {
|
||||||
updateOffset();
|
updateOffset();
|
||||||
core::configManager.acquire();
|
core::configManager.acquire();
|
||||||
core::configManager.conf["offset"] = manualOffset;
|
core::configManager.conf["manualOffset"] = manualOffset;
|
||||||
core::configManager.release(true);
|
core::configManager.release(true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user