mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-06-17 17:33:14 +00:00
Introducing Orca Cloud: https://cloud.orcaslicer.com (#13414)
* Add OrcaCloud sync platform and preset bundle sharing system Introduce OrcaCloud, a cloud sync platform for user presets, alongside a preset bundle system that enables sharing printer/filament/process profiles as local exportable bundles or subscribed cloud bundles. OrcaCloud platform: - Auth to Orca Cloud - Encrypted token storage (file-based or system keychain) - User preset sync with - Profile migration from default/bambu folders on first login - Homepage integration with entrance to cloud.orcaslicer.com Preset bundles: - Local bundle import/export with bundle_structure.json metadata - Subscribed cloud bundles with version-based update checking - Thread-safe concurrent bundle access with read-write mutex - Canonical bundle preset naming (_local/<id>/... and _subscribed/<id>/...) - Bundle presets are read-only; grouped under subheaders in combo boxes - PresetBundleDialog with auto-sync toggle, refresh, update notifications - Hyperlinked bundle names to cloud bundle pages Co-authored-by: Sabriel Koh <sabrielkcr@gmail.com> Co-authored-by: Derrick <derrick992110@gmail.com> Co-authored-by: Mykola Nahirnyi <mnahirnyi@amcbridge.com> Co-authored-by: Ian Chua <iancrb00@gmail.com> Co-authored-by: Draginraptor <draginraptor@gmail.com> Co-authored-by: ExPikaPaka <112851715+ExPikaPaka@users.noreply.github.com> Co-authored-by: Ian Bassi <ian.bassi@outlook.com> Co-authored-by: Ocraftyone <Ocraftyone@users.noreply.github.com> Co-authored-by: yw4z <ywsyildiz@gmail.com> Co-authored-by: peterm-m <101202951+peterm-m@users.noreply.github.com> * Fixed an issue on Windows it failed to login Orca Cloud with Google account
This commit is contained in:
@@ -36,7 +36,7 @@ SavePresetDialog::Item::Item(Preset::Type type, const std::string &suffix, wxBox
|
||||
m_presets = tab->get_presets();
|
||||
|
||||
const Preset &sel_preset = m_presets->get_selected_preset();
|
||||
std::string preset_name = sel_preset.is_default ? "Untitled" : sel_preset.is_system ? (boost::format(("%1% - %2%")) % sel_preset.name % suffix).str() : sel_preset.name;
|
||||
std::string preset_name = sel_preset.is_default ? "Untitled" : sel_preset.is_system ? (boost::format(("%1% - %2%")) % sel_preset.name % suffix).str() : sel_preset.is_from_bundle() && !sel_preset.alias.empty() ? sel_preset.alias : sel_preset.name;
|
||||
|
||||
// if name contains extension
|
||||
if (boost::iends_with(preset_name, ".ini")) {
|
||||
@@ -162,7 +162,7 @@ void SavePresetDialog::Item::update()
|
||||
}
|
||||
|
||||
const Preset *existing = m_presets->find_preset(m_preset_name, false);
|
||||
if (m_valid_type == Valid && existing && (existing->is_default || existing->is_system)) {
|
||||
if (m_valid_type == Valid && existing && !existing->can_overwrite()) {
|
||||
info_line = _L("Overwriting a system profile is not allowed.");
|
||||
m_valid_type = NoValid;
|
||||
}
|
||||
@@ -230,13 +230,11 @@ void SavePresetDialog::Item::update_valid_bmp()
|
||||
void SavePresetDialog::Item::accept()
|
||||
{
|
||||
if (m_valid_type == Warning) {
|
||||
// BBS add sync info
|
||||
auto it = m_presets->find_preset(m_preset_name, false);
|
||||
Preset ¤t_preset = *it;
|
||||
current_preset.sync_info = "delete";
|
||||
if (!current_preset.setting_id.empty()) {
|
||||
BOOST_LOG_TRIVIAL(info) << "delete preset = " << current_preset.name << ", setting_id = " << current_preset.setting_id;
|
||||
wxGetApp().delete_preset_from_cloud(current_preset.setting_id);
|
||||
wxGetApp().delete_preset_from_cloud(current_preset.setting_id, current_preset.file);
|
||||
}
|
||||
m_presets->delete_preset(m_preset_name);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user