clamp timeline time for highlighted desktop
BUG: 327539 FIXED-IN: 4.11.4
This commit is contained in:
parent
54a4a4547d
commit
c003baee1e
1 changed files with 5 additions and 0 deletions
|
@ -914,7 +914,12 @@ void DesktopGridEffect::setHighlightedDesktop(int d)
|
|||
{
|
||||
if (d == highlightedDesktop || d <= 0 || d > effects->numberOfDesktops())
|
||||
return;
|
||||
if (highlightedDesktop > 0 && highlightedDesktop <= hoverTimeline.count())
|
||||
hoverTimeline[highlightedDesktop-1]->setCurrentTime(qMin(hoverTimeline[highlightedDesktop-1]->currentTime(),
|
||||
hoverTimeline[highlightedDesktop-1]->duration()));
|
||||
highlightedDesktop = d;
|
||||
if (highlightedDesktop <= hoverTimeline.count())
|
||||
hoverTimeline[highlightedDesktop-1]->setCurrentTime(qMax(hoverTimeline[highlightedDesktop-1]->currentTime(), 0));
|
||||
effects->addRepaintFull();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue