Also add an Editor::param_modulation_changed()
This commit is contained in:
parent
922d2de603
commit
08c6729ed1
|
@ -107,6 +107,8 @@ where
|
||||||
// that boolean is set.
|
// that boolean is set.
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fn param_modulation_changed(&self, _id: &str, _modulation_offset: f32) {}
|
||||||
|
|
||||||
fn param_values_changed(&self) {
|
fn param_values_changed(&self) {
|
||||||
// Same
|
// Same
|
||||||
}
|
}
|
||||||
|
|
|
@ -109,6 +109,10 @@ impl<E: IcedEditor> Editor for IcedEditorWrapper<E> {
|
||||||
let _ = self.parameter_updates_sender.try_send(ParameterUpdate);
|
let _ = self.parameter_updates_sender.try_send(ParameterUpdate);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fn param_modulation_changed(&self, _id: &str, _modulation_offset: f32) {
|
||||||
|
let _ = self.parameter_updates_sender.try_send(ParameterUpdate);
|
||||||
|
}
|
||||||
|
|
||||||
fn param_values_changed(&self) {
|
fn param_values_changed(&self) {
|
||||||
let _ = self.parameter_updates_sender.try_send(ParameterUpdate);
|
let _ = self.parameter_updates_sender.try_send(ParameterUpdate);
|
||||||
}
|
}
|
||||||
|
|
|
@ -131,6 +131,11 @@ impl Editor for ViziaEditor {
|
||||||
.store(true, Ordering::Relaxed);
|
.store(true, Ordering::Relaxed);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fn param_modulation_changed(&self, _id: &str, _modulation_offset: f32) {
|
||||||
|
self.emit_parameters_changed_event
|
||||||
|
.store(true, Ordering::Relaxed);
|
||||||
|
}
|
||||||
|
|
||||||
fn param_values_changed(&self) {
|
fn param_values_changed(&self) {
|
||||||
self.emit_parameters_changed_event
|
self.emit_parameters_changed_event
|
||||||
.store(true, Ordering::Relaxed);
|
.store(true, Ordering::Relaxed);
|
||||||
|
|
|
@ -58,9 +58,14 @@ pub trait Editor: Send {
|
||||||
/// new value for a parameter or when a parameter change sent to the host gets processed.
|
/// new value for a parameter or when a parameter change sent to the host gets processed.
|
||||||
fn param_value_changed(&self, id: &str, normalized_value: f32);
|
fn param_value_changed(&self, id: &str, normalized_value: f32);
|
||||||
|
|
||||||
/// Called whenever one or more parameter values changed while the editor is open. This may be
|
/// Called whenever a specific parameter's monophonic modulation value has changed while the
|
||||||
/// called in place of [`param_value_changed()`][Self::param_value_changed()] when multiple
|
/// editor is open.
|
||||||
/// parameter values hcange at the same time. For example, when a preset is loaded.
|
fn param_modulation_changed(&self, id: &str, modulation_offset: f32);
|
||||||
|
|
||||||
|
/// Called whenever one or more parameter values or modulations have changed while the editor is
|
||||||
|
/// open. This may be called in place of [`param_value_changed()`][Self::param_value_changed()]
|
||||||
|
/// when multiple parameter values hcange at the same time. For example, when a preset is
|
||||||
|
/// loaded.
|
||||||
fn param_values_changed(&self);
|
fn param_values_changed(&self);
|
||||||
|
|
||||||
// TODO: Reconsider adding a tick function here for the Linux `IRunLoop`. To keep this platform
|
// TODO: Reconsider adding a tick function here for the Linux `IRunLoop`. To keep this platform
|
||||||
|
|
Loading…
Reference in a new issue