Lincoln's patch to fix #3343 (excessively small track heights on zoom out)

git-svn-id: svn://localhost/ardour2/branches/3.0@7488 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Carl Hetherington 2010-07-25 01:17:54 +00:00
parent 637bca1423
commit b06421c7e6
1 changed files with 8 additions and 25 deletions

View File

@ -396,36 +396,19 @@ TimeAxisView::step_height (bool bigger)
if ( height == preset_height(HeightSmall)){
return;
}
if (height == preset_height (HeightSmaller)) {
if (height <= preset_height (HeightSmaller) && height > preset_height (HeightSmall)) {
set_height (preset_height(HeightSmall));
}
else if (height > step) {
if ( height <= preset_height (HeightNormal) && height > preset_height (HeightSmaller)){
set_height (preset_height(HeightSmaller));
}
else {
set_height (height - step);
}
else if ( height <= preset_height (HeightNormal) && height > preset_height (HeightSmaller)){
set_height (preset_height(HeightSmaller));
}
else {
set_height (height - step);
}
}
}
/*
switch (h) {
case HeightLargest:
return extra_height + 48 + 250;
case HeightLarger:
return extra_height + 48 + 150;
case HeightLarge:
return extra_height + 48 + 50;
case HeightNormal:
return extra_height + 48;
case HeightSmall:
return 27;
case HeightSmaller:
return smaller_height;
}
*/
void
TimeAxisView::set_heights (uint32_t h)
{