Bug 413035

Summary: Magnetic selection tool doesn't remove half-finished paths when switching away from the tool
Product: [Applications] krita Reporter: wolthera <griffinvalley>
Component: Tools/SelectionAssignee: Kuntal Majumder <hellozee>
Status: RESOLVED FIXED    
Severity: normal CC: ahab.greybeard, halla
Priority: NOR    
Version: git master (please specify the git hash!)   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:

Description wolthera 2019-10-16 14:35:41 UTC
SUMMARY
When you make a path with the magnetic selection but don't finish it to create a selection, and switch away to a different tool, and then back, the path is still there. This is dangerous when you want to make a magnetic selection at the other end of the image, and you don't realise there's nodes already.

STEPS TO REPRODUCE
1. Make a magnetic selection path, don't finish it.
2. Switch to a different tool
3. Switch back, observe path being there.
4. [bonus] try to add points at the other end of the image, and observe Krita freezing up.

Part of the issue is this, but part of the issue is also Krita not giving feedback while processing the path, giving the impression krita froze for no good reason.
Comment 1 Kuntal Majumder 2019-10-17 16:20:02 UTC
ahh, seems like I forgot another corner case, :D
Comment 2 Kuntal Majumder 2019-10-17 16:44:47 UTC
Git commit e444d22a159adca7a4d6b2e2d98f4af390d045b8 by Kuntal Majumder.
Committed on 17/10/2019 at 16:44.
Pushed by kuntalmajumder into branch 'master'.

Resets the state of magnetic lasso when deactivated

M  +1    -3    plugins/tools/selectiontools/KisToolSelectMagnetic.cc

https://invent.kde.org/kde/krita/commit/e444d22a159adca7a4d6b2e2d98f4af390d045b8
Comment 3 Kuntal Majumder 2019-10-18 12:52:50 UTC
*** Bug 413089 has been marked as a duplicate of this bug. ***