I am working on electron app where i open a child window which i want to be above all the windows (not above fullscreen windows though), I managed to do it by using
win.setAlwaysOnTop(true, "screen-saver");
It now stays on top of all other open apps and keynote app presentation mode, i want user to be able to click buttons inside my window but now the issue is as soon as user clicks on button or just window in my child window, keynote window minimizes (as focus shifts to my window).
What i tried : I tried almost all available window option given in electron docs with different variations, I also tried playing with modals, but obviously modals stay in window itself, i want to keep main app minimized and keep child window on top of other apps. I also found electron-modal package, but that also behaves same.
working example
I was trying different application to check is any other application is able to do it, and i found that zoom app window (in screen share mode) is able to stay on top of keynote app and you can click buttons inside that app, you can move window, and keynote app keeps running in the background with no issues. I am trying to achieve exactly same behaviour.
This is something that you won't be able to recreate with electron currently, except through a native node module that manipulates your window related OS flags.
You can follow this issue on the Electron repository, since the flags introduced there should resolve your issue, or at least give you a point of entry to make your own PR or node_module.
https://github.com/electron/electron/issues/10078
Related
I created a Safari Web Extension using the script that generates the project from a Chrome extension.
My users are confused by the process of buying the app and then running it which just opens a window that does nothing (they keep asking for refunds saying the app doesn't work). So I want to add some more text into the app window that tells them they have to look for the extension in Safari.
I can see how to add the text in the html file called "Main". But in my Mac app this means that the content no longer fits within the apps window. I'm trying to figure out how to change the size of the app window.
Also, the script generates a Mac app with a help menu but it just says that help is not available. How do I go about adding some help to explain that this App does nothing and that the extension is in Safari?
It seems like the script does a lot of the work for you but you still have to learn a bit about developing an App (rather than an extension) to make it a polished experience.
In the new Microsoft Flight Simulator you can pop different cockpit displays out into their own external windows, like this:
However, none of the buttons needed to interact with the displays get "popped out" as well.
I'd like to build a web app that can embed (the continuously updating image of) one of these windows that I can surround with buttons, etc, for interaction to have, say, running on a tablet next to you.
My question is, is it possible with Node to embed the continuously updating image of a native Windows window within a webpage?
Stumbled upon the Screen Capture API. This is what I was looking for.
https://developer.mozilla.org/en-US/docs/Web/API/Screen_Capture_API
I've developed an app based on NodeJS with Electron for a web agency and try to extend it to the touch bar functionality of the MacBook Pro.
Developers launch the app once, which then automatically starts various processes in the background, such as compiling SASS files, optimizing images, etc.
Typically, these developers work with programs such as SublimeText or Atom. However, it often happens that the app expects user input during programming or inserts hints to optimize the code. I would like to display these things in the Touch Bar so that the user does not have to switch between the apps during programming. Unfortunately, the touch bar view of my app is hidden when switching to SublimeText or another app and replaced by the current app in the foreground.
Is there a way to display an app's specific touch bar while the app is running (even hidden) permanently without replacing it? I wonder if that is at least natively possible?
I couldn't find any information about this on the Electron documentary or somewhere elseā¦
Thank you in advance!
I am developing a desktop widget which shows current system status. But the problem is when any user clicks outside of browser window the app get hide/not visible on the desktop. The same thing happens when user press key windows key +D. Is there anything that we can do for preventing this or catch this event and call window.show(). Because lots of desktop widget support this kind of feature.
Edit: I have tried alwaysOnTop property of browserWindow, but I don't want to show my app above the other apps. Like any desktop widget which always shows on the desktop.
I've been trying to create a proper Restart feature within my app, which doesn't work (Orientation is meshing up badly) so since this is a prototype I figure it will be easier if I just crash my app and the user taps again the icon.
Is there a way I could kill my application from code within 1-2 sec.?
Thank you!
You mean you want to quit your app when user taps on home button instead of going the app into background? If yes you can quit the app when user presses home button by adding a key into your info.plist file application does not run in background and set it's value to true. Here is the original key name UIKeySuspendOnExit I don't remember excatly but it should be like this. Find on google you will get easily.