2 ms·
What? 99% of my programs I can open more than one window by just executing the program as normal multiple times, the only ones that enforce a kind of singleton
by annapanna 1mo ago
What?
99% of my programs I can open more than one window by just executing the program as normal multiple times, the only ones that enforce a kind of singleton execution are things that also acts as a kind of server, one example is Everything search, but it has a "Open new Search window" for multiple windows.
And that is the default, you have to explicit code in a lock/global mutex thing to block multiple instances.
vscode, electron app, no problem opening multiple windows.
Geany, gtk app, no problem opening multiple windows.
Can you give an example where this doesn't work?
- hombre_fatal 1mo agoAnything from WhatsApp to the Settings app on macOS where I might want to, say, compare the wifi network settings for two access points. But the point is that the developer has to build the app in a way that lets you do this. Once again, there is no default with the tools I listed. You decide on how you want windowing to work and then build it. At this point, show me examples of needing a mutex to "block" a multi-window default.
- ksbd-pls-finish 1mo agoI don't get it. Let's say you create a game.exe, a windows application with a single window. User double clicks on game.exe icon on their desktop, and the window opens. User double clicks the icon again, and the game window opens again. If the developer want to prevent two instances of game.exe running at once, they need to actively detect and prevent this behaviour. Just like you can start vim several times you can start gvim several times and have a few windows. This is the default behavior, and if the developer wants to change this for some reason, they need to put in some effort. Maybe macOS is special? I'm not familiar with this platform.
- zarzavat 1mo agoNot on Mac OS, opening more than one instance is undefined behaviour. It may work, but it may also corrupt your data.