Fix active state after text entry in a ParamSlider
This commit is contained in:
parent
a2b39d9281
commit
4e09491dd5
|
@ -307,7 +307,8 @@ impl View for ParamSlider {
|
||||||
if let Some(param_slider_event) = event.message.downcast() {
|
if let Some(param_slider_event) = event.message.downcast() {
|
||||||
match param_slider_event {
|
match param_slider_event {
|
||||||
ParamSliderEvent::CancelTextInput => {
|
ParamSliderEvent::CancelTextInput => {
|
||||||
cx.emit(ParamSliderInternalEvent::SetTextInputActive(false))
|
cx.emit(ParamSliderInternalEvent::SetTextInputActive(false));
|
||||||
|
cx.current.set_active(cx, false);
|
||||||
}
|
}
|
||||||
ParamSliderEvent::TextInput(string) => {
|
ParamSliderEvent::TextInput(string) => {
|
||||||
if let Some(normalized_value) =
|
if let Some(normalized_value) =
|
||||||
|
@ -318,7 +319,7 @@ impl View for ParamSlider {
|
||||||
cx.emit(RawParamEvent::EndSetParameter(self.param_ptr));
|
cx.emit(RawParamEvent::EndSetParameter(self.param_ptr));
|
||||||
}
|
}
|
||||||
|
|
||||||
cx.emit(ParamSliderInternalEvent::SetTextInputActive(false))
|
cx.emit(ParamSliderInternalEvent::SetTextInputActive(false));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue