X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Fwx%2Faudio_plot.cc;h=c4e5d992fe2c11a3dbc107b287a1462e8437ca54;hb=4616b19fb5241a54c9d57f7a91bb975f41aed14b;hp=69faf127e2db0404fa5192cf9f12d8a74510ec5b;hpb=5eacf5f4805181617e486805ab5d07ccf5e21cde;p=dcpomatic.git diff --git a/src/wx/audio_plot.cc b/src/wx/audio_plot.cc index 69faf127e..c4e5d992f 100644 --- a/src/wx/audio_plot.cc +++ b/src/wx/audio_plot.cc @@ -40,7 +40,6 @@ AudioPlot::AudioPlot (wxWindow* parent) : wxPanel (parent, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxFULL_REPAINT_ON_RESIZE) , _gain (0) , _smoothing (max_smoothing / 2) - , _message (_("Please wait; audio is being analysed...")) { #ifndef __WXOSX__ SetDoubleBuffered (true); @@ -67,6 +66,8 @@ AudioPlot::AudioPlot (wxWindow* parent) _colours.push_back (wxColour (255, 0, 139)); _colours.push_back (wxColour (139, 0, 255)); + set_analysis (shared_ptr ()); + #if MAX_DCP_AUDIO_CHANNELS != 12 #warning AudioPlot::AudioPlot is expecting the wrong MAX_DCP_AUDIO_CHANNELS #endif @@ -81,14 +82,10 @@ AudioPlot::set_analysis (shared_ptr a) { _analysis = a; - for (int i = 0; i < MAX_DCP_AUDIO_CHANNELS; ++i) { - _channel_visible[i] = false; + if (!a) { + _message = _("Please wait; audio is being analysed..."); } - for (int i = 0; i < AudioPoint::COUNT; ++i) { - _type_visible[i] = false; - } - Refresh (); }