Split Select-All-Tracks into 2 appropriately named actions
Existing function select-all-tracks is now renamed select-all-visible-lanes, to match its behavior. New function select-all-tracks will select all Tracks, as the name implies. To maintain consistency for those users who actively used select-all-tracks, the default shortcut ctrl+t will continue calling select-all-visible-lanes.
This commit is contained in:
parent
61e7f3176b
commit
142ce953da
@ -162,7 +162,7 @@ This mode provides many different operations on both regions and control points,
|
||||
@edit|Editor/redo|<@PRIMARY@>r|redo
|
||||
@trans|Transport/Record|<@TERTIARY@>r|engage record
|
||||
@mmode|MouseMode/set-mouse-mode-timefx|t|timefx mode
|
||||
@gselect|Common/select-all-tracks|<@PRIMARY@>t|select all tracks
|
||||
@gselect|Common/select-all-visible-lanes|<@PRIMARY@>t|select all visible lanes
|
||||
@edit|Editor/alternate-redo|<@PRIMARY@>y|redo
|
||||
@select|Editor/select-all-between-cursors|<@PRIMARY@>u|all enclosed by edit range
|
||||
@select|Editor/select-all-within-cursors|u|all present in edit range
|
||||
|
@ -185,6 +185,7 @@
|
||||
<menu action="SelectMenu">
|
||||
<menuitem action='select-all-objects'/>
|
||||
<menuitem action='select-all-tracks'/>
|
||||
<menuitem action='select-all-visible-lanes'/>
|
||||
<menuitem action='deselect-all'/>
|
||||
<menuitem action='invert-selection'/>
|
||||
<separator/>
|
||||
|
@ -645,6 +645,8 @@ ARDOUR_UI::install_dependent_actions ()
|
||||
act = ActionManager::register_action (common_actions, "alt-finish-range", _("Finish Range"), sigc::bind (sigc::mem_fun(editor, &PublicEditor::keyboard_selection_finish), false, Editing::EDIT_IGNORE_NONE));
|
||||
ActionManager::session_sensitive_actions.push_back (act);
|
||||
|
||||
act = ActionManager::register_action (common_actions, "select-all-visible-lanes", _("Select All Visible Lanes"), sigc::mem_fun(editor, &PublicEditor::select_all_visible_lanes));
|
||||
ActionManager::session_sensitive_actions.push_back (act);
|
||||
act = ActionManager::register_action (common_actions, "select-all-tracks", _("Select All Tracks"), sigc::mem_fun(editor, &PublicEditor::select_all_tracks));
|
||||
ActionManager::session_sensitive_actions.push_back (act);
|
||||
act = ActionManager::register_action (common_actions, "deselect-all", _("Deselect All"), sigc::mem_fun(editor, &PublicEditor::deselect_all));
|
||||
|
@ -772,6 +772,7 @@ private:
|
||||
void catch_vanishing_regionview (RegionView*);
|
||||
|
||||
void set_selected_track (TimeAxisView&, Selection::Operation op = Selection::Set, bool no_remove=false);
|
||||
void select_all_visible_lanes ();
|
||||
void select_all_tracks ();
|
||||
bool select_all_internal_edit (Selection::Operation);
|
||||
|
||||
|
@ -58,7 +58,7 @@ Editor::keyboard_selection_finish (bool /*add*/, Editing::EditIgnoreOption ign)
|
||||
|
||||
//if no tracks are selected and we're working from the keyboard, enable all tracks (_something_ has to be selected for any range selection)
|
||||
if ( (_edit_point == EditAtPlayhead) && selection->tracks.empty() )
|
||||
select_all_tracks();
|
||||
select_all_visible_lanes();
|
||||
|
||||
selection->set (start.sample, end);
|
||||
|
||||
@ -95,7 +95,7 @@ Editor::keyboard_selection_begin (Editing::EditIgnoreOption ign)
|
||||
|
||||
//if no tracks are selected and we're working from the keyboard, enable all tracks (_something_ has to be selected for any range selection)
|
||||
if ( selection->tracks.empty() )
|
||||
select_all_tracks();
|
||||
select_all_visible_lanes();
|
||||
|
||||
selection->set (start.sample, end.sample);
|
||||
|
||||
|
@ -176,6 +176,20 @@ Editor::extend_selection_to_track (TimeAxisView& view)
|
||||
|
||||
void
|
||||
Editor::select_all_tracks ()
|
||||
{
|
||||
TrackViewList tracks;
|
||||
for (TrackViewList::iterator i = track_views.begin(); i != track_views.end(); ++i) {
|
||||
RouteTimeAxisView* rtv = dynamic_cast<RouteTimeAxisView*>(*i);
|
||||
if ( rtv && rtv->route()->is_track() ) {
|
||||
tracks.push_back (*i);
|
||||
}
|
||||
}
|
||||
PBD::Unwinder<bool> uw (_track_selection_change_without_scroll, true);
|
||||
selection->set (tracks);
|
||||
}
|
||||
|
||||
void
|
||||
Editor::select_all_visible_lanes ()
|
||||
{
|
||||
TrackViewList visible_views;
|
||||
for (TrackViewList::iterator i = track_views.begin(); i != track_views.end(); ++i) {
|
||||
@ -1893,7 +1907,7 @@ Editor::set_selection_from_range (Location& loc)
|
||||
// if no tracks are selected, enable all tracks
|
||||
// (_something_ has to be selected for any range selection, otherwise the user won't see anything)
|
||||
if (selection->tracks.empty()) {
|
||||
select_all_tracks();
|
||||
select_all_visible_lanes();
|
||||
}
|
||||
|
||||
commit_reversible_selection_op ();
|
||||
|
@ -945,6 +945,7 @@ LuaInstance::register_classes (lua_State* L)
|
||||
.addFunction ("copy_playlists", &PublicEditor::copy_playlists)
|
||||
.addFunction ("clear_playlists", &PublicEditor::clear_playlists)
|
||||
|
||||
.addFunction ("select_all_visible_lanes", &PublicEditor::select_all_visible_lanes)
|
||||
.addFunction ("select_all_tracks", &PublicEditor::select_all_tracks)
|
||||
.addFunction ("deselect_all", &PublicEditor::deselect_all)
|
||||
|
||||
|
@ -291,6 +291,7 @@ public:
|
||||
virtual void new_playlists (TimeAxisView*) = 0;
|
||||
virtual void copy_playlists (TimeAxisView*) = 0;
|
||||
virtual void clear_playlists (TimeAxisView*) = 0;
|
||||
virtual void select_all_visible_lanes () = 0;
|
||||
virtual void select_all_tracks () = 0;
|
||||
virtual void deselect_all () = 0;
|
||||
virtual void invert_selection () = 0;
|
||||
|
@ -1256,7 +1256,7 @@ RouteTimeAxisView::selection_click (GdkEventButton* ev)
|
||||
if (_editor.get_selection().selected (this)) {
|
||||
_editor.get_selection().clear_tracks ();
|
||||
} else {
|
||||
_editor.select_all_tracks ();
|
||||
_editor.select_all_visible_lanes ();
|
||||
}
|
||||
|
||||
_editor.commit_reversible_selection_op ();
|
||||
|
Loading…
Reference in New Issue
Block a user