🐞 Duplication of file selector window
Description
This was an issue with welcome window (before the refactor), but it's still an issue when you disable the welcome window and don't have any files open.
To Reproduce
Do this:
- Disable & dismiss the welcome window.
- Click on CodeEdit in the dock.
- File selector should appear.
Now you can do this as many times as you want: 5. Click on CodeEdit in the dock (again). 6. Another file selector should appear.
Expected behavior
The file selector should only open once,
and repeated clicks on the app should only focus whatever window is open.
Version information
CodeEdit: 0.0.1-alpha (21) macOS: 13.1 (22C65) Xcode: 14.2 (14C18)
Additional context
No response
@CodeEditApp/maintainers and all, how would we like to handle this?
The way I see it, we can do any combination of the following:
- When the last window is closed and then the CodeEdit dock icon is clicked
- Open the Welcome window
- Open a blank file
- Include "Open Welcome Window" in the context menu when right clicking the Dock icon.
Alternatively, why doesn’t CodeEdit do nothing if there is already a file selector window open?
That way, it would work / have the same functionality as the welcome window?
I’m personally fine with having the file selector window popup when the welcome window is disabled. The minor issue here, is that CodeEdit doesn’t stop opening file selector windows when you click on the icon 😅