OrcaSlicer latest
OrcaSlicer
Loading...
Searching...
No Matches
Slic3r::GUI::web_hosting Namespace Reference

Namespaces

namespace  anonymous_namespace{WebHosting.cpp}

Functions

wxString bootstrap_url ()
wxString content_base_url ()
bool is_content_url (const wxString &url)
const char * orca_bridge_script ()

Variables

constexpr const char * BOOTSTRAP_PAGE = "web/dialog/WebDialog/blank.html"

Function Documentation

◆ bootstrap_url()

wxString Slic3r::GUI::web_hosting::bootstrap_url ( )
51{
52 return file_url_from_path(boost::filesystem::path(resources_dir()) / BOOTSTRAP_PAGE);
53}
constexpr const char * BOOTSTRAP_PAGE
Definition WebHosting.hpp:10
wxString file_url_from_path(const boost::filesystem::path &path)
Definition GUI.cpp:569
const std::string & resources_dir()
Definition utils.cpp:296

References BOOTSTRAP_PAGE, Slic3r::GUI::file_url_from_path(), and Slic3r::resources_dir().

Referenced by Slic3r::GUI::WebPanel::WebPanel().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ content_base_url()

wxString Slic3r::GUI::web_hosting::content_base_url ( )
56{
57 return file_url_from_path(boost::filesystem::path(resources_dir()) / "web") + "/";
58}

References Slic3r::GUI::file_url_from_path(), and Slic3r::resources_dir().

Referenced by is_content_url(), Slic3r::GUI::WebDialog::load_page_html(), and Slic3r::GUI::WebPanel::load_page_html().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ is_content_url()

bool Slic3r::GUI::web_hosting::is_content_url ( const wxString & url)
61{
62 // The web view reports the URL it parsed, which may escape the resources path differently
63 // from content_base_url().
64 return wxURI::Unescape(url.BeforeFirst('#')) == wxURI::Unescape(content_base_url());
65}
wxString content_base_url()
Definition WebHosting.cpp:55

References content_base_url().

Referenced by Slic3r::GUI::WebDialog::on_bootstrap_event(), Slic3r::GUI::WebPanel::on_load_event(), Slic3r::GUI::WebDialog::on_navigated(), and Slic3r::GUI::WebPanel::on_navigated().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ orca_bridge_script()

const char * Slic3r::GUI::web_hosting::orca_bridge_script ( )
67{ return ORCA_BRIDGE_JS; }

Referenced by Slic3r::GUI::WebDialog::add_user_scripts().

Here is the caller graph for this function:

Variable Documentation

◆ BOOTSTRAP_PAGE

const char* Slic3r::GUI::web_hosting::BOOTSTRAP_PAGE = "web/dialog/WebDialog/blank.html"
constexpr