Electron prompt support - macos

I am looking for a native (OS X) prompt module when working on Electron, something like the window popped up when I click 'Join Other Network...':
This offers the ability to get inputs and process the data returned. So Dialog in Electron may not work here (at least I did not figure it out). I found this issue, but I cannot understand it.
Right now my approach is to open up a browserWindow to to ipc with main thread, but the most critical issue is that, it does not feel like native!
Any help is appreciated!

Electron currently does not have this functionality built in. As far as I know this UI is fully custom, the OS API does not have a direct way to create this UI. For this reason it is likely Electron will never have this functionality.
Your only options are to mimic the native UI in CSS or create a node module that accesses the OS APIs to build your desired UI.

Related

UI Automation for AppleTV system using XCode

Is UI automation available for the main menu of the Apple TV and not a specific application? I already setup the whole UI testing thing using XCode and tried using the remote control but it is only available for the application that was defined using XCUIApplication.
So is it possible to control the whole system rather than a specific application? I was thinking of something similar to pyatv but using XCode since I might be able to get more information concerning the current focused apps and so on.
There is an API XCUIApplication(bundleIdentifier: ) to interact with not-AUT apps. You need to substitute the right identifier for this Springboard-like interface. Maybe it is a Headboard, but I'm not sure.
Bundle identifiers of tvOS apps https://github.com/rzakhar/XCTApps/blob/master/Sources/XCTApps/tvOS.swift

How can I use Go to make a GUI window?

I am in need to make a simple window in Go to display some text,
there is no need for a real GUI like interface.
How can I make a window like this using Go?
walk is the most common library used for basic GUI development.
You can import the package using:
go get github.com/lxn/walk
I assume you are working at windows OS so create an exe and run it.
More Information about this can be gathered from its source.
Visit https://github.com/lxn/walk
A nice-looking cross-platform UI can be created using HTML5/CSS/JS. You may open a native window with a full-screen browser engine (webview) in it showing your UI.
There is a tiny wrapper library for webviews on Windows, MacOS and Linux - https://github.com/zserge/webview
You can connectyour UI and the core app parts using Go-to-JS bindings (webview library provides those) or a websocket.

Wrapper around web-app under Windows

I have an application with web interface. Unfortunately, it has all disadvantages of being a web page:
It doesn't have a standalone window, so users cannot manage it via the taskbar.
Users see the address line with something like 'http://localhost:8080' that is not a good idea for home users.
If users click on a tray icon, there is no way to activate the tab in a browser, which contain the application interface.
So, it would be nice to have a wrapper application with a browser within.
In case of IE I know it's possible to create a window with Trident ActiveX component. But what if it's Windows XP with IE6 but installed latest Chrome? I'd like to prefer Chrome since it supports a lot more features which the user will never see.
So, is there a way to wrap a page into Chrome/Firefox and make it look like a standalone application, if one of them is presented in the user's system? (The application shouldn't install anything large, so Chromium build is not an option).
P.S. I'm not interested in supporting other platforms than Windows.
Regards,
Take a look at Chrome Apps.
I hope helps you.

Recording X windows events

I am a novice when it comes to X windows but have some knowledge of Unix as such.
My project requires me to track user input and output on X window system. For instance, if the GUI is used to configure a route, I would like to know what application is used and what route has been configured. So far, I have explored the following options with partial success.
1)Tried to hook functions like XDrawString and XDrawText using LD_PRELOAD.
2)Used xwininfo to obtain window id and tools like xev.
3)Looked through similar discussions in this forum especially on xev and xinput
1)May not work with if X11 is statically linked? Not sure.
2)xev does not record key press events for a file edited with gedit or attempting to rename a file from the GUI
3)I am trying to go through X windows system internals.
I am pretty discouraged so far. Any input/pointer will be appreciated.
I think you want the cnee program from the Xnee project, which uses the X window system Record extension. The examples that I see for cnee are almost always about recording input events, but, according to the Xnee manual at https://xnee.files.wordpress.com/2012/10/xnee1.pdf, section 3.2.1 ("Record"), "Xnee can record the whole X11 protocol, not just mouse and keyboard events."
Regarding font operations, I believe that X font facilities, mostly through the X font server, evolved over time too, so it might be the case that the applications that you care about are doing X font operations which you can trace.

Building an Application like Chrome App Launcher

How would one go about building an Application like the Google Chrome App launcher like the one they released for windows, it seems like a simple application that just appears over its taskbar icon, however I wanted to know more about what could be used to make such an app.
Chrome and its app launcher are all open source, so you can have a look. However there is probably a lot of Chromium knowledge required to be able to navigate the code.
Some details:
the launcher is native c++
it runs in the same process as the Chrome browser
there is no practical way to get the location of the taskbar button, so it is faked using the cursor.
Some trivia:
the app launcher is called the app list internally
the launcher was originally implemented on ChromeOS, and was first ported to work on Windows. That was simple. It was later ported to Mac OS X (just released!) which was more complicated

Resources