Bug 444310 - Next Key, Prev Key (And other transport buttons?) retrigger when pressing space to pan over canvas.
Summary: Next Key, Prev Key (And other transport buttons?) retrigger when pressing spa...
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Animation (show other bugs)
Version: git master (please specify the git hash!)
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Eoin O'Neill
URL:
Keywords: release_blocker
Depends on:
Blocks:
 
Reported: 2021-10-24 06:02 UTC by Eoin O'Neill
Modified: 2021-10-26 20:39 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Eoin O'Neill 2021-10-24 06:02:08 UTC
STEPS TO REPRODUCE
1. Press next or previous key button when there's two keys ahead or behind.
2. Press space to try to pan when mouse is over canvas.
3. The button will reactivate, causing it to jump ahead another frame.

EXPECTED RESULT
No extra frames should be jumped ahead or behind. Space key should not retrigger toolbutton.
Comment 1 tomtomtomreportingin 2021-10-24 06:10:08 UTC
This issue or at least related issues have kinda existed for a while, could be a duplicate of https://bugs.kde.org/show_bug.cgi?id=431682 and/or https://bugs.kde.org/show_bug.cgi?id=440399 (could be a duplicate of the former)
Comment 2 Eoin O'Neill 2021-10-25 22:00:15 UTC
Yeah this is an issue in multiple parts of Krita for sure. I just tested it around the place and it's definitely an issue.

However, in this case, we can solve this a little more easily since we can just remove the focus taking element of these QToolButtons. Since we already have hotkeys for people who want key-driven behavior, we can just ignore keyboard focus altogether.

So I have a quick fix ready for this specific issue, but it's really just kicking the can down the road atm.
Comment 3 Eoin O'Neill 2021-10-25 22:03:34 UTC
Git commit de5fdf8ba4cbab6d84abbbd019617adef2863ec6 by Eoin O'Neill.
Committed on 25/10/2021 at 22:00.
Pushed by eoinoneill into branch 'master'.

Removed focus from KisTransportControl's QToolButtons.

Should solve some usability issues when navigating keyframes
where pressing space to pan the canvas would cause an erroneous
next key / prev key call (or other transport button actions.)

Since we have hotkeys to allow the user to trigger these based
on key presses, we can simply remove this behavior altogether.
However, this issue exists in other parts of Krita and will need
a more robust solution to solve the issue globally across all
widgets.

M  +6    -0    libs/ui/widgets/kis_transport_controls.cpp

https://invent.kde.org/graphics/krita/commit/de5fdf8ba4cbab6d84abbbd019617adef2863ec6
Comment 4 Eoin O'Neill 2021-10-26 20:39:16 UTC
Git commit 84eaf3c8672d53bab461ce8d96e90816392eb669 by Eoin O'Neill.
Committed on 26/10/2021 at 20:38.
Pushed by eoinoneill into branch 'krita/5.0'.

Removed focus from KisTransportControl's QToolButtons.

Should solve some usability issues when navigating keyframes
where pressing space to pan the canvas would cause an erroneous
next key / prev key call (or other transport button actions.)

Since we have hotkeys to allow the user to trigger these based
on key presses, we can simply remove this behavior altogether.
However, this issue exists in other parts of Krita and will need
a more robust solution to solve the issue globally across all
widgets.
(cherry picked from commit de5fdf8ba4cbab6d84abbbd019617adef2863ec6)

M  +6    -0    libs/ui/widgets/kis_transport_controls.cpp

https://invent.kde.org/graphics/krita/commit/84eaf3c8672d53bab461ce8d96e90816392eb669