Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions cmake/modules/MacOSXBundleInfo.plist.in
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
<key>CFBundleURLSchemes</key>
<array>
<string>orcaslicer</string>
<string>orcaflashforge</string>
</array>
</dict>
<dict>
Expand All @@ -46,6 +47,14 @@
<string>bambustudioopen</string>
</array>
</dict>
<dict>
<key>CFBundleURLName</key>
<string>Orca-Flashforge Downloads</string>
<key>CFBundleURLSchemes</key>
<array>
<string>orcaflashforgeopen</string>
</array>
</dict>
</array>
<key>CFBundleDocumentTypes</key>
<array>
Expand Down
3 changes: 2 additions & 1 deletion src/libslic3r/Utils.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -218,10 +218,11 @@ extern bool is_json_file(const std::string& path);

// Orca: custom protocal support utils
inline bool is_orca_open(const std::string& url) { return boost::starts_with(url, "orcaslicer://open"); }
inline bool is_orcaflashforge_open(const std::string& url) { return boost::starts_with(url, "orcaflashforge://open") || boost::starts_with(url, "orcaflashforgeopen://"); }
inline bool is_prusaslicer_open(const std::string& url) { return boost::starts_with(url, "prusaslicer://open"); }
inline bool is_bambustudio_open(const std::string& url) { return boost::starts_with(url, "bambustudio://open") || boost::starts_with(url, "bambustudioopen://"); }
inline bool is_cura_open(const std::string& url) { return boost::starts_with(url, "cura://open"); }
inline bool is_supported_open_protocol(const std::string& url) { return is_orca_open(url) || is_prusaslicer_open(url) || is_bambustudio_open(url) || is_cura_open(url); }
inline bool is_supported_open_protocol(const std::string& url) { return is_orca_open(url) || is_orcaflashforge_open(url) || is_prusaslicer_open(url) || is_bambustudio_open(url) || is_cura_open(url); }
inline bool is_printables_link(const std::string& url) {
const std::regex url_regex("(http|https)://printables.com", std::regex_constants::icase);
return std::regex_match(url, url_regex);
Expand Down
2 changes: 2 additions & 0 deletions src/platform/osx/Info.plist.in
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@
<string>orcasliceropen</string>
<string>orcaslicer</string>
<string>bambustudioopen</string>
<string>orcaflashforgeopen</string>
<string>orcaflashforge</string>
</array>
</dict>
</array>
Expand Down
2 changes: 1 addition & 1 deletion src/platform/unix/Orca-Flashforge.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Icon=Orca-Flashforge
Exec=flash-slicer %F
Terminal=false
Type=Application
MimeType=model/stl;model/3mf;application/vnd.ms-3mfdocument;application/prs.wavefront-obj;application/x-amf;x-scheme-handler/orcaslicer;
MimeType=model/stl;model/3mf;application/vnd.ms-3mfdocument;application/prs.wavefront-obj;application/x-amf;x-scheme-handler/orcaslicer;x-scheme-handler/orcaflashforge;
Categories=Graphics;3DGraphics;Engineering;
Keywords=3D;Printing;Slicer;slice;3D;printer;convert;gcode;stl;obj;amf;SLA
StartupNotify=false
Expand Down
2 changes: 2 additions & 0 deletions src/slic3r/GUI/GUI_App.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2569,6 +2569,7 @@ bool GUI_App::on_init_inner()
associate_files(L"stp");
}
associate_url(L"orcaslicer");
associate_url(L"orcaflashforge");

if (app_config->get("associate_gcode") == "true")
associate_files(L"gcode");
Expand Down Expand Up @@ -6497,6 +6498,7 @@ void GUI_App::open_preferences(size_t open_on_tab, const std::string& highlight_
associate_files(L"stp");
}
associate_url(L"orcaslicer");
associate_url(L"orcaflashforge");
}
else {
if (app_config->get("associate_gcode") == "true")
Expand Down