avoid crash after removing a VCA

This commit is contained in:
Paul Davis 2016-06-14 16:10:32 -04:00
parent a843013165
commit 351b43d51b
1 changed files with 2 additions and 2 deletions

View File

@ -308,13 +308,13 @@ VCATimeAxisView::set_height (uint32_t h, TrackHeightMode m)
bool
VCATimeAxisView::marked_for_display () const
{
return !_vca->presentation_info().hidden();
return _vca && !_vca->presentation_info().hidden();
}
bool
VCATimeAxisView::set_marked_for_display (bool yn)
{
if (yn == _vca->presentation_info().hidden()) {
if (_vca && (yn == _vca->presentation_info().hidden())) {
_vca->presentation_info().set_hidden (!yn);
return true; // things changed
}