better attachment between labels and tracks
This commit is contained in:
@@ -52,6 +52,8 @@ void TimelineLabel::SetTrack(Track *track)
|
||||
connect(mute_button_, SIGNAL(toggled(bool)), track_, SLOT(SetMuted(bool)));
|
||||
connect(solo_button_, SIGNAL(toggled(bool)), track_, SLOT(SetSoloed(bool)));
|
||||
connect(lock_button_, SIGNAL(toggled(bool)), track_, SLOT(SetLocked(bool)));
|
||||
|
||||
connect(track_, SIGNAL(HeightChanged(int)), this, SLOT(UpdateHeight(int)));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -59,6 +61,8 @@ void TimelineLabel::UpdateState()
|
||||
{
|
||||
label_->setText(track_->name());
|
||||
|
||||
UpdateHeight(track_->height());
|
||||
|
||||
mute_button_->setChecked(track_->IsMuted());
|
||||
solo_button_->setChecked(track_->IsSoloed());
|
||||
lock_button_->setChecked(track_->IsLocked());
|
||||
@@ -79,3 +83,8 @@ void TimelineLabel::RenameTrack()
|
||||
UpdateState();
|
||||
}
|
||||
}
|
||||
|
||||
void TimelineLabel::UpdateHeight(int h)
|
||||
{
|
||||
setFixedHeight(h);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user