mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-10-14 22:41:41 -04:00
Merge branch 'release/2.3.2' into develop
This commit is contained in:
commit
e92d5e80ee
18 changed files with 180 additions and 70 deletions
|
@ -899,7 +899,7 @@ void MainWindow::updateTrayIcon()
|
|||
|
||||
m_trayIcon->setContextMenu(menu);
|
||||
|
||||
m_trayIcon->setIcon(filePath()->applicationIcon());
|
||||
m_trayIcon->setIcon(filePath()->trayIcon());
|
||||
m_trayIcon->show();
|
||||
}
|
||||
if (m_ui->tabWidget->hasLockableDatabases()) {
|
||||
|
@ -971,7 +971,11 @@ void MainWindow::trayIconTriggered(QSystemTrayIcon::ActivationReason reason)
|
|||
void MainWindow::hideWindow()
|
||||
{
|
||||
saveWindowInformation();
|
||||
#ifndef Q_OS_MAC
|
||||
#if !defined(Q_OS_LINUX) && !defined(Q_OS_MAC)
|
||||
// On some Linux systems, the window should NOT be minimized and hidden (i.e. not shown), at
|
||||
// the same time (which would happen if both minimize on startup and minimize to tray are set)
|
||||
// since otherwise it causes problems on restore as seen on issue #1595. Hiding it is enough.
|
||||
// TODO: Add an explanation for why this is also not done on Mac (or remove the check)
|
||||
setWindowState(windowState() | Qt::WindowMinimized);
|
||||
#endif
|
||||
QTimer::singleShot(0, this, SLOT(hide()));
|
||||
|
@ -983,7 +987,7 @@ void MainWindow::hideWindow()
|
|||
|
||||
void MainWindow::toggleWindow()
|
||||
{
|
||||
if ((QApplication::activeWindow() == this) && isVisible() && !isMinimized()) {
|
||||
if (isVisible() && !isMinimized()) {
|
||||
hideWindow();
|
||||
} else {
|
||||
bringToFront();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue