mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-12 17:27:52 -06:00
Apply printer model / variant preferences when loading presets
This commit is contained in:
parent
57e47a3296
commit
e53949f2c8
17 changed files with 218 additions and 64 deletions
|
@ -135,7 +135,7 @@ void AppConfig::save()
|
|||
|
||||
bool AppConfig::get_variant(const std::string &vendor, const std::string &model, const std::string &variant) const
|
||||
{
|
||||
std::cerr << "AppConfig::get_variant(" << vendor << ", " << model << ", " << variant << ") ";
|
||||
// std::cerr << "AppConfig::get_variant(" << vendor << ", " << model << ", " << variant << ") " << std::endl;
|
||||
|
||||
const auto it_v = m_vendors.find(vendor);
|
||||
if (it_v == m_vendors.end()) { return false; }
|
||||
|
@ -161,6 +161,12 @@ void AppConfig::set_variant(const std::string &vendor, const std::string &model,
|
|||
m_dirty = true;
|
||||
}
|
||||
|
||||
void AppConfig::set_vendors(const AppConfig &from)
|
||||
{
|
||||
m_vendors = from.m_vendors;
|
||||
m_dirty = true;
|
||||
}
|
||||
|
||||
std::string AppConfig::get_last_dir() const
|
||||
{
|
||||
const auto it = m_storage.find("recent");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue