Bug 482316

Summary: Close to system tray not working after program start
Product: [Applications] konversation Reporter: Bernd Steinhauser <linux>
Component: generalAssignee: Konversation Developers <konversation-devel>
Status: RESOLVED FIXED    
Severity: normal CC: jshand2013, mrjoeharris
Priority: NOR Keywords: qt6
Version: 1.10.24020   
Target Milestone: ---   
Platform: Exherbo   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Bernd Steinhauser 2024-03-03 15:03:35 UTC
SUMMARY
***
One the new kf6-based version, when having the system tray enabled in the options, it will not work properly initially after the program start. Clicking on the x to "close" the window, will not minimize the program to the system tray, but instead nothing will happen. (Also not closing of konversation)
Left click on the system tray icon will also not do anything.
***


STEPS TO REPRODUCE
1. Install the specified version from KDE apps 24.02
2. Open konversation, enable system tray
3. Close konversation
4. Open konversation again, click on the x to close the window

OBSERVED RESULT
Nothing happens.

EXPECTED RESULT
konversation should minimize to system tray

SOFTWARE/OS VERSIONS
Operating System: Exherbo 
KDE Plasma Version: 6.0.0
KDE Frameworks Version: 6.0.0
Qt Version: 6.6.2
Kernel Version: 6.7.8-amdgpu (64-bit)
Graphics Platform: Wayland
Processors: 32 × AMD Ryzen 9 5950X 16-Core Processor
Memory: 62.7 GiB of RAM
Graphics Processor: AMD Radeon RX 6600
Manufacturer: Micro-Star International Co., Ltd.
Product Name: MS-7C90
System Version: 1.0

ADDITIONAL INFORMATION
A possible workaround is to deactivate system tray in the options and then activate it again afterwards. Then it will work until the program is restarted. Thus step 3 and 4 in the list above. However, this doesn't seem to work every time, so at least once I had to deactivate/activate the system try twice for it to work again. In that case, clicking on the icon works to minimize, too.
Comment 1 Bernd Steinhauser 2024-03-03 15:04:19 UTC
I should note that I had a friend test this, too. So it's verified on at least 2 computers. However, both were running Exherbo Linux.
Comment 2 argonel 2024-03-03 22:44:22 UTC
Git commit 1d554cb2c29e57bfd58b9aed7643dcb60fbf8659 by Eli MacKenzie.
Committed on 03/03/2024 at 22:33.
Pushed by argonel into branch 'release/24.02'.

Delay tray setup until mainwindow state restored

Otherwise the the KSNI appears to lose track of the main window.

M  +3    -3    src/mainwindow.cpp

https://invent.kde.org/network/konversation/-/commit/1d554cb2c29e57bfd58b9aed7643dcb60fbf8659
Comment 3 Albert Astals Cid 2024-03-06 20:51:17 UTC
Git commit 5667f017b73c18d17cd6cffd822352626a0a89c6 by Albert Astals Cid, on behalf of Eli MacKenzie.
Committed on 06/03/2024 at 20:50.
Pushed by aacid into branch 'master'.

Delay tray setup until mainwindow state restored

Otherwise the the KSNI appears to lose track of the main window.
(cherry picked from commit 1d554cb2c29e57bfd58b9aed7643dcb60fbf8659)

M  +3    -3    src/mainwindow.cpp

https://invent.kde.org/network/konversation/-/commit/5667f017b73c18d17cd6cffd822352626a0a89c6
Comment 4 argonel 2024-03-07 00:31:58 UTC
*** Bug 482617 has been marked as a duplicate of this bug. ***
Comment 5 Heiko Becker 2024-03-07 17:51:49 UTC
*** Bug 482622 has been marked as a duplicate of this bug. ***
Comment 6 Christophe Marin 2024-03-21 08:17:03 UTC
*** Bug 484106 has been marked as a duplicate of this bug. ***