Simplify code a bit more

This commit is contained in:
ExPikaPaka
2026-06-17 09:17:07 +02:00
committed by SoftFever
parent 273d325066
commit 1d19e39625
5 changed files with 127 additions and 135 deletions

View File

@@ -94,7 +94,7 @@ int main(int argc, char* argv[])
const std::string ver_str = ver.valid() ? ver.to_string() : "";
const bool is_orca_lib = (vendor_name == PresetBundle::ORCA_FILAMENT_LIBRARY);
Slic3r::VendorCache vc;
Slic3r::PresetBundle::VendorCache vc;
vc.capture(*preset_bundle, vendor_name, ver_str, is_orca_lib);
const std::string cache_path =
@@ -102,7 +102,7 @@ int main(int argc, char* argv[])
vc.save(cache_path);
// Verify the file was written and can be reloaded.
Slic3r::VendorCache verify;
Slic3r::PresetBundle::VendorCache verify;
if (!verify.load(cache_path) || !verify.is_valid(ver_str)) {
std::cerr << "WARNING: verification failed for " << cache_path << "\n";
++failed;

View File

@@ -13,7 +13,7 @@ static void print_bar(char c, int n) { std::cout << std::string(n, c) << "\n"; }
static void inspect_one(const std::string& path, const po::variables_map& vm)
{
Slic3r::VendorCache vc;
Slic3r::PresetBundle::VendorCache vc;
if (!vc.load(path)) {
std::cerr << "Failed to load cache: " << path << "\n"
<< " (wrong format version, truncated file, CRC mismatch, or not a .cache file)\n";