@@ -70,8 +70,6 @@ class OscilloscopeDisplay
7070 bool _useDefaultSettings = false )
7171 : apvts(_apvts)
7272 , ringBuffer(2 , 4096 )
73- : apvts(_apvts)
74- , ringBuffer(2 , 4096 )
7573 , fifoBuffer(_fifoBuffer)
7674 , leftOscilloscope(ringBuffer, 0 , size)
7775 , rightOscilloscope(ringBuffer, 1 , size)
@@ -92,21 +90,6 @@ class OscilloscopeDisplay
9290 }
9391 }
9492
95- ~OscilloscopeDisplay () override
96- {
97- // Remove parameter listeners
98- if (!useDefaultSettings) {
99- // Assuming you have access to the AudioProcessorValueTreeState instance
100- // here, you would remove the listeners. This is just a placeholder.
101- apvts.removeParameterListener (" OscilloscopeZoom" , this );
102- apvts.removeParameterListener (" OscilloscopeThickness" , this );
103- apvts.removeParameterListener (" OscilloscopeGain" , this );
104- }
105-
106- // Stop the repaint timer
107- stopRepaintTimer ();
108- }
109-
11093 ~OscilloscopeDisplay () override
11194 {
11295 // Remove parameter listeners
@@ -178,11 +161,10 @@ class OscilloscopeDisplay
178161 rightBounds.getHeight ());
179162
180163 // Draw oscilloscope images
181- g.drawImageAt (leftOscilloscope.getFrontImage (),
182164 g.drawImageAt (leftOscilloscope.getFrontImage (),
183165 leftOscilloscope.getBounds ().getX (),
184166 leftOscilloscope.getBounds ().getY ());
185- g. drawImageAt (rightOscilloscope. getFrontImage (),
167+
186168 g.drawImageAt (rightOscilloscope.getFrontImage (),
187169 rightOscilloscope.getBounds ().getX (),
188170 rightOscilloscope.getBounds ().getY ());
@@ -276,7 +258,6 @@ class OscilloscopeDisplay
276258 }
277259 // ==============================================================================
278260private:
279- AudioProcessorValueTreeState& apvts;
280261 AudioProcessorValueTreeState& apvts;
281262 RingAudioBuffer ringBuffer;
282263 FifoAudioBuffer& fifoBuffer;
0 commit comments