brush settings reset button, hook crash handler on every thread, update changelog

This commit is contained in:
2019-03-13 10:08:13 +01:00
parent 5a6f6f524a
commit 3d625567aa
14 changed files with 59 additions and 10 deletions

View File

@@ -25,6 +25,8 @@ void NodePanelStroke::init()
bool NodePanelStroke::import_abr(const std::string& path)
{
BT_SetTerminate();
ABR abr;
LOG("ABR detected");
@@ -285,8 +287,8 @@ void NodePanelStroke::init_controls()
// init main brush
auto b = std::make_shared<Brush>();
b->load_tip(m_brush_popup->get_texture_path(br_idx), m_brush_popup->get_thumb_path(br_idx));
b->load_dual(m_brush_popup->get_texture_path(br_idx), m_brush_popup->get_thumb_path(br_idx));
b->load_pattern(m_pattern_popup->get_texture_path(0), m_pattern_popup->get_thumb_path(0));
//b->load_dual(m_brush_popup->get_texture_path(br_idx), m_brush_popup->get_thumb_path(br_idx));
//b->load_pattern(m_pattern_popup->get_texture_path(0), m_pattern_popup->get_thumb_path(0));
b->m_tip_size = 30;
b->m_tip_flow = .9f;
b->m_tip_spacing = .1f;
@@ -635,6 +637,21 @@ void NodePanelStroke::init_controls()
};
}
m_brush_settings_reset = find<NodeButton>("brush-settings-reset");
m_brush_settings_reset->on_click = [br_idx,this](Node*) {
auto b = std::make_shared<Brush>();
b->load_tip(m_brush_popup->get_texture_path(br_idx), m_brush_popup->get_thumb_path(br_idx));
//b->load_dual(m_brush_popup->get_texture_path(br_idx), m_brush_popup->get_thumb_path(br_idx));
//b->load_pattern(m_pattern_popup->get_texture_path(0), m_pattern_popup->get_thumb_path(0));
b->m_tip_size = 30;
b->m_tip_flow = .9f;
b->m_tip_spacing = .1f;
b->m_tip_opacity = 1.f;
Canvas::I->m_current_brush = b;
update_controls();
App::I.brush_update();
};
update_controls();
}