Make from_get_set
public (#34)
This allows the slider value to be obtained from anywhere that can be accessed from a closure and not just a `&'a mut` reference. An example would be a state that is shared via an Arc<Rw<T>> or Atomic value with a background thread
This commit is contained in:
parent
07a32793d6
commit
fe585e48e9
1 changed files with 1 additions and 1 deletions
|
@ -49,7 +49,7 @@ pub struct Slider<'a> {
|
|||
}
|
||||
|
||||
impl<'a> Slider<'a> {
|
||||
fn from_get_set(
|
||||
pub fn from_get_set(
|
||||
range: RangeInclusive<f64>,
|
||||
get_set_value: impl 'a + FnMut(Option<f64>) -> f64,
|
||||
) -> Self {
|
||||
|
|
Loading…
Reference in a new issue