mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-16 11:46:25 +01:00
Revert "Fix 8061 (partly): Don't scroll down if no further tracks to scroll to"
This reverts commit 81cbf36c56.
Limiting scrolling has other drawbacks. A proper fix for the redraw issue
has to be found.
This commit is contained in:
parent
81cbf36c56
commit
1280360a65
1 changed files with 2 additions and 12 deletions
|
|
@ -1462,8 +1462,6 @@ Editor::select_topmost_track ()
|
||||||
bool
|
bool
|
||||||
Editor::scroll_down_one_track (bool skip_child_views)
|
Editor::scroll_down_one_track (bool skip_child_views)
|
||||||
{
|
{
|
||||||
uint32_t needed_height = 0;
|
|
||||||
|
|
||||||
TrackViewList::reverse_iterator next = track_views.rend();
|
TrackViewList::reverse_iterator next = track_views.rend();
|
||||||
const double top_of_trackviews = vertical_adjustment.get_value();
|
const double top_of_trackviews = vertical_adjustment.get_value();
|
||||||
|
|
||||||
|
|
@ -1472,8 +1470,6 @@ Editor::scroll_down_one_track (bool skip_child_views)
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
needed_height += (*t)->effective_height();
|
|
||||||
|
|
||||||
/* If this is the upper-most visible trackview, we want to display
|
/* If this is the upper-most visible trackview, we want to display
|
||||||
* the one above it (next)
|
* the one above it (next)
|
||||||
*
|
*
|
||||||
|
|
@ -1495,13 +1491,10 @@ Editor::scroll_down_one_track (bool skip_child_views)
|
||||||
TimeAxisView::Children kids = (*t)->get_child_list();
|
TimeAxisView::Children kids = (*t)->get_child_list();
|
||||||
TimeAxisView::Children::reverse_iterator nkid = kids.rend();
|
TimeAxisView::Children::reverse_iterator nkid = kids.rend();
|
||||||
|
|
||||||
uint32_t needed_for_kids = 0;
|
|
||||||
|
|
||||||
for (TimeAxisView::Children::reverse_iterator ci = kids.rbegin(); ci != kids.rend(); ++ci) {
|
for (TimeAxisView::Children::reverse_iterator ci = kids.rbegin(); ci != kids.rend(); ++ci) {
|
||||||
if ((*ci)->hidden()) {
|
if ((*ci)->hidden()) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
needed_for_kids += (*ci)->current_height();
|
|
||||||
|
|
||||||
std::pair<TimeAxisView*,double> dev;
|
std::pair<TimeAxisView*,double> dev;
|
||||||
dev = (*ci)->covers_y_position (top_of_trackviews);
|
dev = (*ci)->covers_y_position (top_of_trackviews);
|
||||||
|
|
@ -1513,15 +1506,12 @@ Editor::scroll_down_one_track (bool skip_child_views)
|
||||||
*/
|
*/
|
||||||
nkid = kids.rend();
|
nkid = kids.rend();
|
||||||
}
|
}
|
||||||
needed_height -= (*t)->effective_height();
|
|
||||||
needed_height += needed_for_kids;
|
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
nkid = ci;
|
nkid = ci;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (nkid != kids.rend() && needed_height > trackviews_height()) {
|
if (nkid != kids.rend()) {
|
||||||
ensure_time_axis_view_is_visible (**nkid, true);
|
ensure_time_axis_view_is_visible (**nkid, true);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
@ -1532,7 +1522,7 @@ Editor::scroll_down_one_track (bool skip_child_views)
|
||||||
|
|
||||||
/* move to the track below the first one that covers the */
|
/* move to the track below the first one that covers the */
|
||||||
|
|
||||||
if (next != track_views.rend() && needed_height > trackviews_height()) {
|
if (next != track_views.rend()) {
|
||||||
ensure_time_axis_view_is_visible (**next, true);
|
ensure_time_axis_view_is_visible (**next, true);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue