Bug 506401

Summary: After opening a new ledger in a tab the ledger should have focus
Product: [Applications] kmymoney Reporter: Ingo Klöcker <kloecker>
Component: generalAssignee: KMyMoney Devel Mailing List <kmymoney-devel>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version First Reported In: 5.2.0   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In: 5.2.1
Sentry Crash Report:

Description Ingo Klöcker 2025-06-30 17:30:59 UTC
After opening a new ledger in a tab the ledger should have focus

STEPS TO REPRODUCE
1. Go to Ledgers
2. Click the + button to open a not yet open ledger
3. Select the ledger to open

OBSERVED RESULT
The ledger is opened in a new tab. OK
The Open... button in the tool bar has input focus. Not OK 

EXPECTED RESULT
The last entry in the just opened ledger has keyboard focus so that I can immediately interact with the ledger, e.g. to add a new entry.
Comment 1 Thomas Baumgart 2025-07-02 16:08:28 UTC
I can only reproduce this for the very first ledger to be opened. If at least one account is open in the ledger, the logic is as described: the ledger has the focus. Can you confirm that?
Comment 2 Thomas Baumgart 2025-07-02 17:21:41 UTC
Git commit 7ed5639205fa67a225ebba04792d0e488e1dd3d7 by Thomas Baumgart.
Committed on 02/07/2025 at 16:28.
Pushed by tbaumgart into branch '5.2'.

Set keyboard focus to newly opened ledger
FIXED-IN: 5.2.1

M  +5    -0    kmymoney/views/simpleledgerview.cpp

https://invent.kde.org/office/kmymoney/-/commit/7ed5639205fa67a225ebba04792d0e488e1dd3d7
Comment 3 Thomas Baumgart 2025-07-02 18:20:47 UTC
Git commit a4708059b598a50f3481aba09d254ecd07ffd1bc by Thomas Baumgart.
Committed on 02/07/2025 at 17:22.
Pushed by tbaumgart into branch 'master'.

Set keyboard focus to newly opened ledger
FIXED-IN: 5.2.1
(cherry picked from commit 7ed5639205fa67a225ebba04792d0e488e1dd3d7)

M  +5    -0    kmymoney/views/simpleledgerview.cpp

https://invent.kde.org/office/kmymoney/-/commit/a4708059b598a50f3481aba09d254ecd07ffd1bc