mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-17 02:22:17 +00:00
Fixed strange behavior of Text- and Spin- control on KillFocus event
This commit is contained in:
@@ -67,6 +67,11 @@ const t_field& OptionsGroup::build_field(const t_config_option_key& id, const Co
|
||||
if (!this->m_disabled)
|
||||
this->on_change_OG(opt_id, value);
|
||||
};
|
||||
field->m_on_kill_focus = [this](){
|
||||
//! This function will be called from Field.
|
||||
if (!this->m_disabled)
|
||||
this->on_kill_focus();
|
||||
};
|
||||
field->m_parent = parent();
|
||||
// assign function objects for callbacks, etc.
|
||||
return field;
|
||||
@@ -194,10 +199,6 @@ void OptionsGroup::on_change_OG(t_config_option_key id, /*config_value*/boost::a
|
||||
m_on_change(id, value);
|
||||
}
|
||||
|
||||
void OptionsGroup::_on_kill_focus (t_config_option_key id) {
|
||||
// do nothing.
|
||||
}
|
||||
|
||||
Option ConfigOptionsGroup::get_option(const std::string opt_key, int opt_index /*= -1*/)
|
||||
{
|
||||
if (!m_config->has(opt_key)) {
|
||||
|
||||
Reference in New Issue
Block a user