Skip to content
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

Setting MinimizeOnStartup=true won't allow the main window to ever show on MacOS #2280

Closed
ChristopherSchultz opened this issue Sep 10, 2018 · 21 comments · Fixed by #2402
Closed

Comments

@ChristopherSchultz
Copy link

ChristopherSchultz commented Sep 10, 2018

Title is summary. Details below.

Expected Behavior

When launching KeePassXC, its main window is visible.

Current Behavior

When launching KeePassXC, its main window is not visible.

Steps to Reproduce (for bugs)

  1. Launch KeePassXC under MacOS High Sierra (not sure if the specific version is important)
  2. Close the main window by clicking the red "X" button in the window's titlebar in the upper-left hand corner of the window
  3. Main window disappears

Actually... no windows are showing. Launching KeePassXC from the dock or the command-line causes the main window to show briefly, then disappear. Clicking the dock icon does nothing. Right-clicking the dock-icon gives no options for any windows. Clicking "Show All Windows" gives the message "No available windows". Clicking on the application menu and selecting "About KeePassXC" does nothing. SHIFT-Click on the dock to launch in "safe mode" (which must be supported by the application) doesn't do anything.

Interestingly... using the global hotkey for auto-type works! So the database is indeed open and I can interact with it... I just can't see it, find entries, add/edit/remove entries, etc.

Debug Info

KeePassXC - 2.3.4

@ChristopherSchultz
Copy link
Author

Looks like this is a mis-implementation of the "minimize on startup" feature.

Changing:

MinimizeOnStartup=true to MinimizeOnStartup=false in my .../Application Support/keepassxc/keepassxc.ini file restored the window.

@ChristopherSchultz
Copy link
Author

This may be related to issue #1727

@ChristopherSchultz ChristopherSchultz changed the title [bug] I closed my main window (using X window icon) on MacOS and now the main window is gone for good [bug] Setting MinimizeOnStartup=true won't allow the main window to ever show on MacOS Sep 10, 2018
@ChristopherSchultz ChristopherSchultz changed the title [bug] Setting MinimizeOnStartup=true won't allow the main window to ever show on MacOS [bug] Setting MinimizeOnStartup=true won't allow the main window to ever show on MacOS Sep 10, 2018
@droidmonkey droidmonkey changed the title [bug] Setting MinimizeOnStartup=true won't allow the main window to ever show on MacOS Setting MinimizeOnStartup=true won't allow the main window to ever show on MacOS Sep 11, 2018
@droidmonkey
Copy link
Member

@weslly can you confirm?

@weslly
Copy link
Contributor

weslly commented Sep 11, 2018

I can reproduce #1727, but not this issue.

Close the main window by clicking the red "X" button in the window's titlebar in the upper-left hand corner of the window

Currently this button quits the application instead of closing the window, unlike the regular OSX behavior, but this would be another bug.

@ChristopherSchultz
Copy link
Author

I did end up upgrading from 2.3.3 to 2.3.4 in an effort to see if any issue I was seeing had been resolved in the later version. I can confirm that X button closes the app which is only slightly unexpected given Mac application semantics.

It was setting the "minimize on startup" that caused a problem for me. I will try to get better steps-to-reproduce now that I know what the "fix" was (and thus reverse-engineered the root problem... it had nothing to do with closing the main window).

@ChristopherSchultz
Copy link
Author

Yes, this reproduces the issue for me in 2.3.4:

  1. Launch KeePassXC (or leave it open if it's already open)
  2. Go to app preferences (KeePassX -> Preferences, or CMD-,)
  3. Under "General -> Basic Settings", check the "Minimize window at application startup" setting
  4. Quit KeePassXC
  5. Launch KeePassXC

Result: application window shows, then disappears. I haven't found a way to bring it back.

Expected: application window starts minimized (it's okay to show, then minimize), but can be brought back up by clicking on the dock icon

The only way I was able to get the application window to come back was to hand-edit the keepassxc.ini file and change MinimizeOnStartup=true to MinimizeOnStartup=false and re-launch the application.

@droidmonkey
Copy link
Member

Do you have any third party software installed that modifies the behavior of the dock or tray in any way?

@ChristopherSchultz
Copy link
Author

Not that I know of. This is a 3-week-old laptop so I haven't had a lot of time to break it, yet :)

@martijnjanssen
Copy link

I have the same issues on a brand new installation of OSX Mojave. I am also seeing some strange window behavior. The 'minimize window at application startup' is checked, but it always starts maximized. So my behavior is even different from @ChristopherSchultz' behavior.

When invoking the auto-type function, the KeepassXC window focusses if it was minimized, then the auto-type window opens, causing the auto-type function to use the KeepassXC window title to find entries.

@ChristopherSchultz
Copy link
Author

@martijnjanssen The auto-type issue is documented elsewhere several times: #2326, #1982, #1216, #947

@pawel-tomkiel
Copy link

I can confirm that this bug still persists in 2.4.0. Fortunately @ChristopherSchultz workaround still works 😉

@droidmonkey
Copy link
Member

I disagree, I cannot replicate this issue at all. As a matter of fact, for me minimize on startup doesn't work at all on MacOS.

@pawel-tomkiel
Copy link

I stumbled upon this right after update to 2.4.0 (MacOS Mojave 10.14.4, installed via brew cask). Same behaviour as described. I had in config:

MinimizeOnStartup=true

and changing to false resolved the issue.

@ChristopherSchultz
Copy link
Author

Begging your pardon, but I can reproduce this every time using KeePassXC 2.4.1 and I'd like to reopen this bug report.

Steps to reproduce:
0. MacOS 10.14.4, KeePassXC 2.4.1 installed from vanilla DMG bundle

  1. Edit keepassxc.ini, set MinimizeOnStartup=true
  2. Launch KeePassXC (I used 5-finger-pinch, type "kee", press RETURN)

Result: KeePass main window is not possible to view. Clicking the icon in the dock causes KeePassCX application to gain focus; menubar is visible when the application is active, but the main window is always hidden.

I have a single display (MacBook Pro internal) and no funny window management in play. Four-finger-upward-swipe to show all windows does not show KeePassXC's main window anywhere. My dock happens to be on the right side of the screen and not the bottom. Everything else is pretty standard MacOS.

Version/debug info:
KeePassXC - Version 2.4.1
Revision: 7bafe65

Qt 5.12.2
Debugging mode is disabled.

Operating system: macOS Mojave (10.14)
CPU architecture: x86_64
Kernel: darwin 18.5.0

Enabled extensions:

  • Auto-Type
  • Browser Integration
  • SSH Agent
  • KeeShare (only unsigned sharing)
  • YubiKey
  • TouchID

Cryptographic libraries:
libgcrypt 1.8.4

@droidmonkey
Copy link
Member

I'll take a look

@hmueller01
Copy link

I had this issue with v2.5.3 too. I reported in a duplicate issue #4266 (sorry!). In my case it happened because I set the dock behavior of KeePassXC to show on all desktops (right click on the dock icon, options, show on all desktops). If I switch back to "without", window to unlock database shows up but does not minimize after unlock (this happens only if I set MinimizeAfterUnlock=true which I do not like).

With "show on all desktops" I can use autotype (unlock screen appears, selection what to paste), but I am unable to open the main window (as reported here).

@droidmonkey
Copy link
Member

Thank you for the tip, that might be the differentiating factor.

@ChristopherSchultz
Copy link
Author

Yes, that might be it. I definitely have mine set to "appear on all desktops" as well, and probabyl have had that since initial installation.

@droidmonkey
Copy link
Member

How is that set? I tried doing this on my Mac mini and couldn't figure it out. Screenshot or guide would be appreciated.

@hmueller01
Copy link

Right click or long click on the dock icon. Then choose options, show on all desktops.

@droidmonkey
Copy link
Member

Fixed in 2.6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants