Show correct toggle state in effect components when effects are disabled and enabled from a DAW

pull/249/head
James H Ball 2024-08-21 10:53:44 +01:00 zatwierdzone przez James H Ball
rodzic b630a1b7cb
commit bed8997a2a
4 zmienionych plików z 17 dodań i 13 usunięć

Wyświetl plik

@ -16,17 +16,16 @@
height: 100%;
width: 100%;
overflow: hidden;
}
canvas {
width: min(100vw, 100vh);
height: min(100vw, 100vh);
position: absolute;
top: calc(calc(100vh - min(100vw, 100vh)) / 2);
left: calc(calc(100vw - min(100vw, 100vh)) / 2);
display: block;
margin: auto;
z-index: -1;
}
canvas {
width: min(100vw, 100vh);
height: min(100vw, 100vh);
position: absolute;
top: calc(calc(100vh - min(100vw, 100vh)) / 2);
left: calc(calc(100vw - min(100vw, 100vh)) / 2);
display: block;
margin: auto;
}
#overlay {
@ -38,6 +37,7 @@
justify-content: center;
align-items: center;
cursor: default;
z-index: 100;
}
table {
@ -50,6 +50,7 @@
bottom: 0;
right: 0;
display: none;
z-index: 99;
}
#buttonRow button {

Wyświetl plik

@ -166,6 +166,7 @@ void EffectComponent::parameterGestureChanged(int parameterIndex, bool gestureIs
void EffectComponent::handleAsyncUpdate() {
setupComponent();
getParentComponent()->repaint();
juce::SpinLock::ScopedLockType lock1(audioProcessor.parsersLock);
juce::SpinLock::ScopedLockType lock2(audioProcessor.effectsLock);
if (effect.getId().contains("lua")) {

Wyświetl plik

@ -158,7 +158,7 @@ protected:
Effect& effect;
ComponentListModel listModel;
juce::ListBox list;
jux::SwitchButton selected = { "switchButton", false };
jux::SwitchButton selected = { effect.enabled };
private:
OscirenderAudioProcessor& audioProcessor;
OscirenderAudioProcessorEditor& editor;

Wyświetl plik

@ -343,7 +343,9 @@ void VisualiserComponent::resized() {
}
void VisualiserComponent::childChanged() {
browser->emitEventIfBrowserIsVisible("childPresent", child != nullptr);
if (!oldVisualiser) {
browser->emitEventIfBrowserIsVisible("childPresent", child != nullptr);
}
}
void VisualiserComponent::popoutWindow() {