mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-16 10:25:55 +08:00
App updater path fixes
This commit is contained in:
parent
6a9bcf8405
commit
3fb1e8a35f
@ -3401,12 +3401,7 @@ void GUI_App::app_updater(bool from_user)
|
|||||||
if (dialog_result != wxID_OK) {
|
if (dialog_result != wxID_OK) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (dwnld_dlg.get_download_path().parent_path().empty() || !boost::filesystem::exists(dwnld_dlg.get_download_path().parent_path())) {
|
|
||||||
show_error(nullptr,GUI::format_wxstr(_L("Download can't proceed. Target directory doesn't exists: %1%"), dwnld_dlg.get_download_path().parent_path().string()));
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
app_data.target_path =dwnld_dlg.get_download_path();
|
app_data.target_path =dwnld_dlg.get_download_path();
|
||||||
|
|
||||||
// start download
|
// start download
|
||||||
this->plater_->get_notification_manager()->push_download_progress_notification(_utf8("Download"), std::bind(&AppUpdater::cancel_callback, this->m_app_updater.get()));
|
this->plater_->get_notification_manager()->push_download_progress_notification(_utf8("Download"), std::bind(&AppUpdater::cancel_callback, this->m_app_updater.get()));
|
||||||
app_data.start_after = dwnld_dlg.run_after_download();
|
app_data.start_after = dwnld_dlg.run_after_download();
|
||||||
|
@ -257,7 +257,7 @@ bool AppUpdateDownloadDialog::run_after_download() const
|
|||||||
boost::filesystem::path AppUpdateDownloadDialog::get_download_path() const
|
boost::filesystem::path AppUpdateDownloadDialog::get_download_path() const
|
||||||
{
|
{
|
||||||
boost::system::error_code ec;
|
boost::system::error_code ec;
|
||||||
std::string input = GUI::format(txtctrl_path->GetValue());
|
std::string input = GUI::into_u8(txtctrl_path->GetValue());
|
||||||
boost::filesystem::path dir = boost::filesystem::absolute(boost::filesystem::path(input), ec);
|
boost::filesystem::path dir = boost::filesystem::absolute(boost::filesystem::path(input), ec);
|
||||||
if (ec)
|
if (ec)
|
||||||
dir = boost::filesystem::path(input);
|
dir = boost::filesystem::path(input);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user