add export message box

This commit is contained in:
2018-09-27 16:15:38 +02:00
parent ea25993f55
commit d80c4e6054
5 changed files with 37 additions and 8 deletions

View File

@@ -1051,12 +1051,17 @@ void ui::Canvas::import_equirectangular_thread(std::string file_path)
App::I.async_end();
}
void ui::Canvas::export_equirectangular(std::string file_path)
void ui::Canvas::export_equirectangular(std::string file_path, std::function<void()> on_complete)
{
if (!App::I.check_license())
return;
std::thread t(&ui::Canvas::export_equirectangular_thread, this, file_path);
t.detach();
if (App::I.check_license())
{
std::thread t([=] {
export_equirectangular_thread(App::I.data_path + "/" + App::I.doc_name + ".ppi");
if (on_complete)
on_complete();
});
t.detach();
}
}
void ui::Canvas::export_equirectangular_thread(std::string file_path)