<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>520718</bug_id>
          
          <creation_ts>2026-05-27 16:18:28 +0000</creation_ts>
          <short_desc>[5.3.2] Krita doesn&apos;t remember the last chosen layer in your document when switching to another document.</short_desc>
          <delta_ts>2026-05-29 21:20:00 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>2</classification_id>
          <classification>Applications</classification>
          <product>krita</product>
          <component>Layer Stack</component>
          <version>5.3.2</version>
          <rep_platform>Android</rep_platform>
          <op_sys>Android 14.x</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>regression, triaged</keywords>
          <priority>NOR</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Door1">a.pond105</reporter>
          <assigned_to name="Krita Bugs">krita-bugs-null</assigned_to>
          <cc>dra.w.p.il.e+bugskde</cc>
          
          <cf_commitlink>https://invent.kde.org/graphics/krita/-/commit/b1ffdd65d4ff5cb2c34caf6121acf893f2c3e499</cf_commitlink>
          <cf_versionfixedin></cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2518746</commentid>
    <comment_count>0</comment_count>
    <who name="Door1">a.pond105</who>
    <bug_when>2026-05-27 16:18:28 +0000</bug_when>
    <thetext>DESCRIPTION
Krita doesn&apos;t remember the last chosen layer in your document when switching to another document.

The bug first appears in 5.3.2. It is not present in 5.3.1.1 or earlier.



STEPS TO REPRODUCE
1. Create 2 new documents
3. In the first document, in the layer docker, choose the background layer at the bottom
4. Switch to the second document
5. Switch to the first document

OBSERVED RESULT
The chosen layer is the top paint layer

EXPECTED RESULT
The chosen layer is the background layer

SOFTWARE/OS VERSIONS
Android 16
arm64
Krita 5.3.2</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2518761</commentid>
    <comment_count>1</comment_count>
    <who name="">dra.w.p.il.e+bugskde</who>
    <bug_when>2026-05-27 17:35:05 +0000</bug_when>
    <thetext>Also happens on Linux.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2518767</commentid>
    <comment_count>2</comment_count>
    <who name="">dra.w.p.il.e+bugskde</who>
    <bug_when>2026-05-27 17:41:31 +0000</bug_when>
    <thetext>Bug 520723 probably has the same cause.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2518860</commentid>
    <comment_count>3</comment_count>
    <who name="">dra.w.p.il.e+bugskde</who>
    <bug_when>2026-05-28 02:36:01 +0000</bug_when>
    <thetext>Yes, it&apos;s caused by 8965a0dd68ca7a34cd770642499e417a78520b65. It was supposed to select the current layer on the animation timeline when you select a frame, but it also incorrectly reacts to a bunch of other things and messes up the layer selection.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2518862</commentid>
    <comment_count>4</comment_count>
    <who name="Bug Janitor Service">bug-janitor</who>
    <bug_when>2026-05-28 02:49:33 +0000</bug_when>
    <thetext>A possibly relevant merge request was started @ https://invent.kde.org/graphics/krita/-/merge_requests/2803</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2518966</commentid>
    <comment_count>5</comment_count>
    <who name="Dmitry Kazakov">dimula73</who>
    <bug_when>2026-05-28 13:21:11 +0000</bug_when>
    <thetext>Git commit 3713225956c74ba68702a7b57f492f6e6a753d9c by Dmitry Kazakov, on behalf of Carsten Hartenfels.
Committed on 28/05/2026 at 13:20.
Pushed by dkazakov into branch &apos;master&apos;.

Revert keyframe selection changing layer selection

This reverts commit 8965a0dd68ca7a34cd770642499e417a78520b65 because the
logic is broken, it will react to *any* change of the current index, not
just ones that are initiated by the user interacting with the timeline.
That causes all sorts of mayhem, like switching between documents
changing the layer selection, opening a file selecting the wrong layer
and moving through the layer list with the arrow keys causing various
weird effects on the current and selected layer.

This would be fixable by detecting whether the user triggered the change
via the timeline, but that&apos;s sufficiently complicated that it&apos;ll need
more testing first. The bugs this change causes are too major, so just
reverting it for now.
Related: bug 520723, bug 520744

M  +0    -6    plugins/dockers/animation/KisAnimTimelineFramesModel.cpp
M  +0    -2    plugins/dockers/animation/KisAnimTimelineFramesModel.h
M  +0    -4    plugins/dockers/animation/KisAnimTimelineFramesView.cpp

https://invent.kde.org/graphics/krita/-/commit/3713225956c74ba68702a7b57f492f6e6a753d9c</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2518969</commentid>
    <comment_count>6</comment_count>
    <who name="Dmitry Kazakov">dimula73</who>
    <bug_when>2026-05-28 13:23:04 +0000</bug_when>
    <thetext>Git commit 1eb41e5befde48bd69834a7d17536c73ac7ddc6b by Dmitry Kazakov, on behalf of Carsten Hartenfels.
Committed on 28/05/2026 at 13:22.
Pushed by dkazakov into branch &apos;krita/6.0&apos;.

Revert keyframe selection changing layer selection

This reverts commit 8965a0dd68ca7a34cd770642499e417a78520b65 because the
logic is broken, it will react to *any* change of the current index, not
just ones that are initiated by the user interacting with the timeline.
That causes all sorts of mayhem, like switching between documents
changing the layer selection, opening a file selecting the wrong layer
and moving through the layer list with the arrow keys causing various
weird effects on the current and selected layer.

This would be fixable by detecting whether the user triggered the change
via the timeline, but that&apos;s sufficiently complicated that it&apos;ll need
more testing first. The bugs this change causes are too major, so just
reverting it for now.
Related: bug 520723, bug 520744

M  +0    -6    plugins/dockers/animation/KisAnimTimelineFramesModel.cpp
M  +0    -2    plugins/dockers/animation/KisAnimTimelineFramesModel.h
M  +0    -4    plugins/dockers/animation/KisAnimTimelineFramesView.cpp

https://invent.kde.org/graphics/krita/-/commit/1eb41e5befde48bd69834a7d17536c73ac7ddc6b</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2519270</commentid>
    <comment_count>7</comment_count>
    <who name="Dmitry Kazakov">dimula73</who>
    <bug_when>2026-05-29 21:20:00 +0000</bug_when>
    <thetext>Git commit b1ffdd65d4ff5cb2c34caf6121acf893f2c3e499 by Dmitry Kazakov, on behalf of Carsten Hartenfels.
Committed on 29/05/2026 at 21:17.
Pushed by dkazakov into tag &apos;v6.0.2.1&apos;.

Revert keyframe selection changing layer selection

This reverts commit 8965a0dd68ca7a34cd770642499e417a78520b65 because the
logic is broken, it will react to *any* change of the current index, not
just ones that are initiated by the user interacting with the timeline.
That causes all sorts of mayhem, like switching between documents
changing the layer selection, opening a file selecting the wrong layer
and moving through the layer list with the arrow keys causing various
weird effects on the current and selected layer.

This would be fixable by detecting whether the user triggered the change
via the timeline, but that&apos;s sufficiently complicated that it&apos;ll need
more testing first. The bugs this change causes are too major, so just
reverting it for now.
Related: bug 520723, bug 520744

M  +0    -6    plugins/dockers/animation/KisAnimTimelineFramesModel.cpp
M  +0    -2    plugins/dockers/animation/KisAnimTimelineFramesModel.h
M  +0    -4    plugins/dockers/animation/KisAnimTimelineFramesView.cpp

https://invent.kde.org/graphics/krita/-/commit/b1ffdd65d4ff5cb2c34caf6121acf893f2c3e499</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>