From d4c3e43b03eed7cffffda0e5059072fd06421118 Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Thu, 18 Mar 2021 04:06:46 +0100 Subject: [PATCH] Address another -Wunused-private-field TrackSelection is just a different name for TrackViewList the private _editor is no longer needed nor used. --- gtk2_ardour/editor_drag.cc | 1 - gtk2_ardour/selection.cc | 3 +-- gtk2_ardour/track_selection.cc | 18 +----------------- gtk2_ardour/track_selection.h | 12 ++---------- 4 files changed, 4 insertions(+), 30 deletions(-) diff --git a/gtk2_ardour/editor_drag.cc b/gtk2_ardour/editor_drag.cc index e2e22bf604..9f0405882b 100644 --- a/gtk2_ardour/editor_drag.cc +++ b/gtk2_ardour/editor_drag.cc @@ -5481,7 +5481,6 @@ SelectionDrag::SelectionDrag (Editor* e, ArdourCanvas::Item* i, Operation o) : Drag (e, i) , _operation (o) , _add (false) - , _track_selection_at_start (e) , _time_selection_at_start (!_editor->get_selection().time.empty()) { DEBUG_TRACE (DEBUG::Drags, "New SelectionDrag\n"); diff --git a/gtk2_ardour/selection.cc b/gtk2_ardour/selection.cc index e4397199f5..c4630b4df6 100644 --- a/gtk2_ardour/selection.cc +++ b/gtk2_ardour/selection.cc @@ -64,8 +64,7 @@ struct AudioRangeComparator { }; Selection::Selection (const PublicEditor* e, bool mls) - : tracks (e) - , editor (e) + : editor (e) , next_time_id (0) , manage_libardour_selection (mls) { diff --git a/gtk2_ardour/track_selection.cc b/gtk2_ardour/track_selection.cc index db28ce7a5d..14672a02d1 100644 --- a/gtk2_ardour/track_selection.cc +++ b/gtk2_ardour/track_selection.cc @@ -18,25 +18,9 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ -#include - -#include "ardour/route_group.h" -#include "control_protocol/control_protocol.h" - #include "track_selection.h" -#include "time_axis_view.h" -#include "public_editor.h" -#include "vca_time_axis.h" -using namespace std; - -TrackSelection::TrackSelection (PublicEditor const * e, TrackViewList const &t) +TrackSelection::TrackSelection (TrackViewList const& t) : TrackViewList (t) - , _editor (e) { } - -TrackSelection::~TrackSelection () -{ -} - diff --git a/gtk2_ardour/track_selection.h b/gtk2_ardour/track_selection.h index 7fdfaadd10..97ed46cf19 100644 --- a/gtk2_ardour/track_selection.h +++ b/gtk2_ardour/track_selection.h @@ -23,19 +23,11 @@ #include "track_view_list.h" -class PublicEditor; - class TrackSelection : public TrackViewList { public: - TrackSelection (PublicEditor const * e) : _editor (e) {} - TrackSelection (PublicEditor const *, TrackViewList const &); - - virtual ~TrackSelection (); - - -private: - PublicEditor const * _editor; + TrackSelection () {} + TrackSelection (TrackViewList const &); }; #endif /* __ardour_gtk_track_selection_h__ */