From 8ca53c4497c6e1c3e18bec8c3338fbf6ce38c4f8 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Sat, 28 Jan 2017 11:16:50 +0100 Subject: make editor respond to track seleciton change again --- gtk2_ardour/editor.cc | 10 ++++++++++ gtk2_ardour/editor.h | 6 ++++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/gtk2_ardour/editor.cc b/gtk2_ardour/editor.cc index c9dab0a0e5..62ad00a1d9 100644 --- a/gtk2_ardour/editor.cc +++ b/gtk2_ardour/editor.cc @@ -828,6 +828,8 @@ Editor::Editor () BasicUI::AccessAction.connect (*this, invalidator (*this), boost::bind (&Editor::access_action, this, _1, _2), gui_context()); + PresentationInfo::Change.connect (*this, invalidator (*this), boost::bind (&Editor::presentation_info_changed, this, _1), gui_context()); + /* handle escape */ ARDOUR_UI::instance()->Escape.connect (*this, invalidator (*this), boost::bind (&Editor::escape, this), gui_context()); @@ -906,6 +908,14 @@ Editor::~Editor() } } +void +Editor::presentation_info_changed (PropertyChange const & what_changed) +{ + if (what_changed.contains (Properties::selected)) { + track_selection_changed (); + } +} + XMLNode* Editor::button_settings () const { diff --git a/gtk2_ardour/editor.h b/gtk2_ardour/editor.h index 2cf7f569fb..8ff19580c6 100644 --- a/gtk2_ardour/editor.h +++ b/gtk2_ardour/editor.h @@ -366,8 +366,8 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD /* fades */ - void toggle_region_fades (int dir); - void update_region_fade_visibility (); + void toggle_region_fades (int dir); + void update_region_fade_visibility (); /* redirect shared ops menu. caller must free returned menu */ @@ -1830,6 +1830,8 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD void setup_midi_toolbar (); + void presentation_info_changed (PBD::PropertyChange const &); + /* selection process */ Selection* selection; -- cgit v1.2.3