";
text += "";
// Format the row header.
- text += std::string("") + (snapshot_active ? _(L("Active: ")) : "") +
+ text += wxString("") + (snapshot_active ? _(L("Active: ")) : "") +
Utils::format_local_date_time(snapshot.time_captured) + ": " + format_reason(snapshot.reason);
if (! snapshot.comment.empty())
text += " (" + snapshot.comment + ")";
text += " ";
// End of row header.
-// text += _(L("ID:")) + " " + snapshot.id + " ";
- // text += _(L("time captured:")) + " " + Utils::format_local_date_time(snapshot.time_captured) + " ";
text += _(L("slic3r version")) + ": " + snapshot.slic3r_version_captured.to_string() + " ";
-// text += "reason: " + snapshot.reason + " ";
text += _(L("print")) + ": " + snapshot.print + " ";
text += _(L("filaments")) + ": " + snapshot.filaments.front() + " ";
text += _(L("printer")) + ": " + snapshot.printer + " ";
+ bool compatible = true;
for (const Config::Snapshot::VendorConfig &vc : snapshot.vendor_configs) {
- text += _(L("vendor")) + ": " + vc.name + ", ver: " + vc.version.to_string() + ", min slic3r ver: " + vc.min_slic3r_version.to_string();
- if (vc.max_slic3r_version != Semver::inf())
- text += ", max slic3r ver: " + vc.max_slic3r_version.to_string();
+ text += _(L("vendor")) + ": " + vc.name +", " + _(L("version")) + ": " + vc.version.config_version.to_string() +
+ ", " + _(L("min slic3r version")) + ": " + vc.version.min_slic3r_version.to_string();
+ if (vc.version.max_slic3r_version != Semver::inf())
+ text += ", " + _(L("max slic3r version")) + ": " + vc.version.max_slic3r_version.to_string();
text += " ";
for (const std::pair> &model : vc.models_variants_installed) {
text += _(L("model")) + ": " + model.first + ", " + _(L("variants")) + ": ";
@@ -61,18 +60,22 @@ static std::string generate_html_row(const Config::Snapshot &snapshot, bool row_
}
text += " ";
}
+ if (! vc.version.is_current_slic3r_supported()) { compatible = false; }
}
- if (! snapshot_active)
+ if (! compatible) {
+ text += "" + _(L("Incompatible with this Slic3r")) + " ";
+ }
+ else if (! snapshot_active)
text += "" + _(L("Activate")) + " ";
text += " | ";
text += "
";
return text;
}
-static std::string generate_html_page(const Config::SnapshotDB &snapshot_db, const std::string &on_snapshot)
+static wxString generate_html_page(const Config::SnapshotDB &snapshot_db, const wxString &on_snapshot)
{
- std::string text =
+ wxString text =
""
""
"