MCPcopy Create free account
hub / github.com/BespokeSynth/BespokeSynth / FloatSliderUpdated

Method FloatSliderUpdated

Source/UserPrefsEditor.cpp:435–456  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

433}
434
435void UserPrefsEditor::FloatSliderUpdated(FloatSlider* slider, float oldVal, double time)
436{
437 if (!TheSynth->IsLoadingState())
438 {
439 if (slider == UserPrefs.ui_scale.GetSlider())
440 TheSynth->SetUIScale(UserPrefs.ui_scale.Get());
441 if (slider == UserPrefs.lissajous_r.GetSlider() || slider == UserPrefs.lissajous_g.GetSlider() || slider == UserPrefs.lissajous_b.GetSlider())
442 {
443 ModularSynth::sBackgroundLissajousR = UserPrefs.lissajous_r.Get();
444 ModularSynth::sBackgroundLissajousG = UserPrefs.lissajous_g.Get();
445 ModularSynth::sBackgroundLissajousB = UserPrefs.lissajous_b.Get();
446 }
447 if (slider == UserPrefs.background_r.GetSlider() || slider == UserPrefs.background_g.GetSlider() || slider == UserPrefs.background_b.GetSlider())
448 {
449 ModularSynth::sBackgroundR = UserPrefs.background_r.Get();
450 ModularSynth::sBackgroundG = UserPrefs.background_g.Get();
451 ModularSynth::sBackgroundB = UserPrefs.background_b.Get();
452 }
453 if (slider == UserPrefs.cable_alpha.GetSlider())
454 ModularSynth::sCableAlpha = UserPrefs.cable_alpha.Get();
455 }
456}
457
458void UserPrefsEditor::IntSliderUpdated(IntSlider* slider, int oldVal, double time)
459{

Callers

nothing calls this directly

Calls 4

IsLoadingStateMethod · 0.80
SetUIScaleMethod · 0.80
GetMethod · 0.80
GetSliderMethod · 0.45

Tested by

no test coverage detected