diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2012-12-27 14:08:38 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2012-12-27 14:08:38 +0000 |
commit | 4481cca74a6003cdcc982e5677adcbbdbf1e617d (patch) | |
tree | f2e605ca9fdbb8416115664114805b4991c64e5a /gtk2_ardour/route_time_axis.cc | |
parent | 3b8b088bd8ee5864fb12a279b9ed607712db2b0e (diff) |
do not start editing track/bus names on a single click in the name entry of the track header - require double click; show name label rather than name entry when rec-enabled, to allow using the name area for track selection (name entry would have been visually still available for editing, which is misleading
git-svn-id: svn://localhost/ardour2/branches/3.0@13738 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/route_time_axis.cc')
-rw-r--r-- | gtk2_ardour/route_time_axis.cc | 23 |
1 files changed, 18 insertions, 5 deletions
diff --git a/gtk2_ardour/route_time_axis.cc b/gtk2_ardour/route_time_axis.cc index a8f6782262..2c9f61b718 100644 --- a/gtk2_ardour/route_time_axis.cc +++ b/gtk2_ardour/route_time_axis.cc @@ -246,7 +246,8 @@ RouteTimeAxisView::set_route (boost::shared_ptr<Route> rt) /* pick up the correct freeze state */ map_frozen (); - } + + } _editor.ZoomChanged.connect (sigc::mem_fun(*this, &RouteTimeAxisView::reset_samples_per_unit)); _editor.HorizontalPositionChanged.connect (sigc::mem_fun (*this, &RouteTimeAxisView::horizontal_position_changed)); @@ -263,9 +264,6 @@ RouteTimeAxisView::set_route (boost::shared_ptr<Route> rt) gm.get_gain_slider().set_name ("GainFader"); gm.get_level_meter().signal_scroll_event().connect (sigc::mem_fun (*this, &RouteTimeAxisView::controls_ebox_scroll), false); - - show_name_entry (); - hide_name_label (); } RouteTimeAxisView::~RouteTimeAxisView () @@ -2174,11 +2172,26 @@ RouteTimeAxisView::reset_processor_automation_curves () } } +bool +RouteTimeAxisView::can_edit_name () const +{ + /* we do not allow track name changes if it is record enabled + */ + return !_route->record_enabled(); +} + void RouteTimeAxisView::update_rec_display () { RouteUI::update_rec_display (); - name_entry.set_sensitive (!_route->record_enabled()); + + if (_route->record_enabled()) { + hide_name_entry (); + show_name_label (); + } else { + hide_name_label (); + show_name_entry (); + } } void |