timeline: show tooltip
I don't know when this was removed but now it's back. Tooltips have a chance of getting in the way so this may switch to the status bar at some point.
This commit is contained in:
@@ -88,6 +88,19 @@ void TimelineView::mouseMoveEvent(QMouseEvent *event)
|
||||
return;
|
||||
}
|
||||
|
||||
if (event->buttons() == Qt::NoButton) {
|
||||
Block* b = GetItemAtScenePos(timeline_event.GetFrame(), timeline_event.GetTrack().index());
|
||||
if (b) {
|
||||
setToolTip(tr("In: %1\nOut: %2\nDuration: %3").arg(
|
||||
Timecode::time_to_timecode(b->in(), timebase(), Core::instance()->GetTimecodeDisplay()),
|
||||
Timecode::time_to_timecode(b->out(), timebase(), Core::instance()->GetTimecodeDisplay()),
|
||||
Timecode::time_to_timecode(b->length(), timebase(), Core::instance()->GetTimecodeDisplay())
|
||||
));
|
||||
} else {
|
||||
setToolTip(QString());
|
||||
}
|
||||
}
|
||||
|
||||
emit MouseMoved(&timeline_event);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user