*/
+#include <cmath>
+
+#include <gtkmm2ext/utils.h>
+
#include "pbd/memento_command.h"
#include "pbd/stateful_diff_command.h"
#include "pbd/pthread_utils.h"
-#include "ardour/session.h"
#include "ardour/audioregion.h"
-#include "ardour/playlist.h"
-#include "ardour/utils.h"
+#include "ardour/session_event.h"
#include "ardour/dB.h"
-#include <gtkmm2ext/utils.h>
-#include <cmath>
#include "audio_region_editor.h"
#include "audio_region_view.h"
b->set_spacing (6);
b->pack_start (_peak_amplitude);
b->pack_start (*Gtk::manage (new Gtk::Label (_("dBFS"))), false, false);
-
+
_peak_amplitude_label.set_name ("AudioRegionEditorLabel");
_peak_amplitude_label.set_text (_("Peak amplitude:"));
_peak_amplitude_label.set_alignment (1, 0.5);
_table.attach (_peak_amplitude_label, 0, 1, _table_row, _table_row + 1, Gtk::FILL, Gtk::FILL);
_table.attach (*b, 1, 2, _table_row, _table_row + 1, Gtk::FILL, Gtk::FILL);
++_table_row;
-
+
gain_changed ();
gain_adjustment.signal_value_changed().connect (sigc::mem_fun (*this, &AudioRegionEditor::gain_adjustment_changed));
AudioRegionEditor::~AudioRegionEditor ()
{
- pthread_cancel_one (_peak_amplitude_thread_handle);
void* v;
- int const r = pthread_join (_peak_amplitude_thread_handle, &v);
- assert (r == 0);
+ pthread_cancel_one (_peak_amplitude_thread_handle);
+ pthread_join (_peak_amplitude_thread_handle, &v);
}
void
AudioRegionEditor::region_changed (const PBD::PropertyChange& what_changed)
{
RegionEditor::region_changed (what_changed);
-
+
if (what_changed.contains (ARDOUR::Properties::scale_amplitude)) {
gain_changed ();
}