Bug 437029 - timeline scroll issues with "show in timeline"
Summary: timeline scroll issues with "show in timeline"
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Animation (show other bugs)
Version: 4.4.3
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Eoin O'Neill
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-05-13 10:48 UTC by Bollebib
Modified: 2021-05-17 21:47 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bollebib 2021-05-13 10:48:12 UTC
if a layer on top or on the bottom of the layer stack does not have "show in timeline" activated then the timeline doesnt scroll down or up completely to show the full range of the timeline. 


the timeline layer stack should follow the active layers when used with shortcuts, even on layers without "show in timeline"
Comment 1 Eoin O'Neill 2021-05-13 20:16:18 UTC
Yeah, this should always scroll all the way up when selecting non-pinned layers.
Comment 2 Emmet O'Neill 2021-05-14 02:35:11 UTC
Git commit 95e096dd346ad05ac3a43c64035ea0f0fb3ac246 by Emmet O'Neill.
Committed on 14/05/2021 at 02:27.
Pushed by emmetoneill into branch 'master'.

KisAnimTimeline: Fixed inconsistent scrollTo behavior.

When switching active layer there is a brief window of time where
two unpinned layers simultaneously exist on the timeline, causing
indexing issues that result in improper scrollTo behavior for the
last layer.

This commit adds a workaround by delaying the scrollTo for 1/60
of a second to give the timeline model enough time to have correct
indexing.

M  +8    -1    plugins/dockers/animation/KisAnimTimelineFramesView.cpp

https://invent.kde.org/graphics/krita/commit/95e096dd346ad05ac3a43c64035ea0f0fb3ac246
Comment 3 Emmet O'Neill 2021-05-14 02:41:21 UTC
I've added a workaround that will hopefully fix this bug.

Basically there is a short period of time when adding an unpinned layer where the internal numbering of the layers is incorrect. There doesn't seem to be a great way to solve this that I can think of yet, so what we've done is add a 1/60 sec delay in the scrolling to give Qt time to get the numbering right. It's a pretty tiny delay (about 1 frame of a 60 fps video game) so it shouldn't feel noticeably worse.

Admittedly, this is a bit of a hacky fix, so there may be situations where this bug still occurs. Though, it seems to work pretty solidly for me right now.
Comment 4 Eoin O'Neill 2021-05-17 21:47:30 UTC
Git commit 329f429e864f1572d72d684e44800118c6ae9255 by Eoin O'Neill.
Committed on 17/05/2021 at 21:46.
Pushed by eoinoneill into branch 'master'.

KisAnimTimelineView: Fixed edge-case where scrollTo still wasn't working as intended for unpinned layers.

M  +2    -0    plugins/dockers/animation/KisAnimTimelineFramesModel.cpp

https://invent.kde.org/graphics/krita/commit/329f429e864f1572d72d684e44800118c6ae9255