-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Correct issues with system tray icon #5948
Conversation
774f726
to
d8aaa08
Compare
* Close #5780 - Show window title as system tray icon tooltip * Fix #5943 - Try to show system tray icon up to 5 times, waiting 5 seconds between attempts, if the system tray is not available. This works around observed startup issues on Linux. * Change function of "isTrayIconEnabled()" to return true if the tray icon is created and visible. This may correct some long standing bugs with the window hiding forever unexpectedly.
d8aaa08
to
7a94aa5
Compare
|
||
m_trayIcon->setToolTip(windowTitle().replace("[*]", isWindowModified() ? "*" : "")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we somehow construct the tooltip from the original raw title + an asterisk? Updating the existing title will replace any asterisks appearing in the database name. We should never read anything back from the UI.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is the explicit placeholder for the modified indicator. It's a stupid qt convention and they keep the placeholder intact for some reason.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm. I really don't like it, but so be it.
|
||
if (!isTrayIconEnabled() || !QSystemTrayIcon::isSystemTrayAvailable()) { | ||
// Try to show tray icon after 5 seconds, try 5 times | ||
// This can happen if KeePassXC starts before the system tray is available |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if there are DBus signals we can listen for.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is Qt's job which it is failing at doing (that's actually their bug as reported). This works and isn't too bothersome.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's definitely Qt's job to do it right, but we might find a more elegant workaround in the future perhaps.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd agree to that :-)
Added - Automatically adapt to light/dark system theme changes (Windows/macOS only) [#6034] Changed - Show window title as tooltip on system tray [#5948] - Compress Snap release as LZO for faster initial startup [#5877] - Password generator: Set maximum selectable password length to 999 [#5937] Fixed - Fix crash on app close when using SSH agent [#5935] - Fix KDF selection showing wrong item when using Argon2id [#5923] - Automatically close About dialog on database lock if it is still open [#5947] - Linux: Fix automatic launch at system startup with AppImages [#5901] - Linux: Fix click-to-move on empty area activating when using menus [#5971] - Linux: Try multiple times to show tray icon if tray is not ready yet [#5948] - macOS: Fix KeePassXC blocking clean shutdown [#6002]
Release 2.6.4 Added - Automatically adapt to light/dark system theme changes (Windows/macOS only) [keepassxreboot#6034] Changed - Show window title as tooltip on system tray [keepassxreboot#5948] - Compress Snap release as LZO for faster initial startup [keepassxreboot#5877] - Password generator: Set maximum selectable password length to 999 [keepassxreboot#5937] Fixed - Fix crash on app close when using SSH agent [keepassxreboot#5935] - Fix KDF selection showing wrong item when using Argon2id [keepassxreboot#5923] - Automatically close About dialog on database lock if it is still open [keepassxreboot#5947] - Linux: Fix automatic launch at system startup with AppImages [keepassxreboot#5901] - Linux: Fix click-to-move on empty area activating when using menus [keepassxreboot#5971] - Linux: Try multiple times to show tray icon if tray is not ready yet [keepassxreboot#5948] - macOS: Fix KeePassXC blocking clean shutdown [keepassxreboot#6002]
Screenshots
Testing strategy
Tested on Windows and XFCE
Type of change