show cursor on picking and other modes than draw/erase, sanity check on presets file

This commit is contained in:
2019-03-08 12:47:06 +01:00
parent 440abb7049
commit bfe5c3541d
5 changed files with 52 additions and 9 deletions

View File

@@ -22,17 +22,19 @@ std::shared_ptr<NodeProgressBar> App::show_progress(const std::string& title)
return pb;
}
void App::message_box(const std::string &title, const std::string& text)
NodeMessageBox* App::message_box(const std::string &title, const std::string& text, bool cancel_button)
{
async_start();
auto* m = layout[main_id]->add_child<NodeMessageBox>();
m->m_title->set_text(title.c_str());
m->m_message->set_text(text.c_str());
m->btn_ok->m_text->set_text("Ok");
m->btn_cancel->destroy();
if (!cancel_button)
m->btn_cancel->destroy();
layout[main_id]->update();
async_redraw();
async_end();
return m;
}
void App::dialog_usermanual()