What's the status of the WebExtensions' background page implementations by browser/OS - google-chrome-extension

In Chrome for Win/Mac/Linux it is possible to have browser addon scripts running before the user launches the browser and after they shut the last browser window. In Chrome this is done by claiming the background permission - see the Chrome extensions API docs on background. Other browsers don't seem to support this permission. So my questions:
Is this also possible with other browsers (e.g. by using some other permission/API...) and with other operating systems (specifically Android/iOS)?
What is the behavior of this feature across different operating systems? (I have tried it with Chrome on Ubuntu and while Chrome does continue running and the script keeps performing its task, it doesn't automatically start in background after restarting the OS - I guess one would have to manually add an autostart script for that)
What I'm trying to accomplish is something similar as to what as been asked here: Display a Chrome desktop notification every day at specific time. But I want to learn about cross-browser-and-OS-compatibility before putting too much effort into it. Also an outlook for what's going to be possible in the near future would be nice. :)
(I am aware that something like this could be done using push notifications, but I would also like my app to work offline, so that's not an option.)

Related

How Mirror webpages as Web Video Wall into another browser?

We have a video wall with some monitors. each one is plugged into a Raspberry PI 3.
Mostly we just are showing webpages into the video wall (reports, status etc)
Today we control the content of each raspberry using VNC. I was wondering if is there a web service or plugin that allows me to just configure the URL that I wish to show on each screen. Plus, Sometimes we split the each screen into 2 or more webpages.
Is there any web app, chrome plugin or web service that allows me do that?
Thanks
OBS, I don't know if here is the right place to this kind of question. If is there another community where i could ask this, i will be glad to know.
I can not give a complete and exhaustive answer, since you do not provide any description of how it should look and how you want to control it.
Let's start with the fact that almost every browser at startup you can specify URL and start the browser like this:
# firefox https://google.com
Then the browser opens with the page you need.
To close the page, you can kill the browser with a command like this
# killall firefox
You can run commands on the Raspberry PI using ssh, it's much easier than running the VNC session.
Most likely you may encounter a problem when you receive a message stating that the browser can not connect to the display. This is easily correctable with something like:
# export DISPLAY=:0
In order for the browser to always be in full-screen mode and not to lose its settings, you can configure it correctly, close all the tabs and save its configuration from ~/.mozilla/ (for firefox), and then restore it from backup every time you start it.

multi monitor public information display (4 monitor / each with one chrome/firefox window)

I've 4 monitors connected to a pc running CentOS 7. Each physical monitor/display should show a website in full screen and auto refresh it every x seconds.
I've tried:
opening from bash and moving with xdotool -> how can I distinguish between the 4 chrome or firefox windows? If I don't do it and apply to the last active this might become unreliable with other programs open.
researched devilspie, seems it has the same problem (can't distinguish between multiple chrome/firefox windows)
using DISPLAY variable -> does only find one display 0.0
https://addons.mozilla.org/de/firefox/addon/monitor-master/ -> does not work with extended workspace, contacted developer
I've only a xrandr bash script to rearrange the displays when they become connected (three of four may be switched off to save power).
I would use a firefox/chrome add on for the auto refresh functionality.
Maybe someone can give me a hint how to reliably do this?
In addition to the "easy auto refresh" chrome plugin. I have another idea for you, why not use a chrome extension for handling the positioning.
It is of course, only for chrome(maybe thats fine for you).
Background: We had related difficulties. Internal webapp that opens multiple documents in windows, and need to be placed in other monitors.
The javascript does not support this, for security reasons and only a native extension can properly work with the tabs/windows objects.
Therefore, we have created an open source chrome extension for doing exactly that: flexible windows position across multi-monitor setups.
In your case you can define for each monitor a website-rule that the window would appear there.
The chrome extension is called "MultiWindow Positioner" and its complete free. You can get it at the chrome store here
The actual source code you find in github in the project chrome-multiwindow-positioner
Disclaimer: I am the maintainer of the open source (MIT) github project. If there any interesting idea, or comments feel free to share them here.

Way to launch a browser w/ specific webpage without using ShellExecute? (Visual C++)

I want to add a button to my visual C++ form that will open with a specific browser. So far for links I've been using:
System::Diagnostics::Process::Start("UrlHere")
Which, as standard, opens with whatever your default browser is.
I'm wondering what the process would be to force the URL to open with a specific browser and if it's possible without the use of ShellExecute?
Edit - You are correct, this is C++/CLI. Removed the C++ Tag.
Edit Edit - Apologies if it came across as misleading. Some slight elaboration;
The buttons will launch to application URL's, some of which can only be used in Internet Explorer, others that CAN (and should) be used in Chrome. This is why I need to avoid using the default browser and have different buttons using different browsers when launching URLs
Before answering the 'how', I'd like to ask the question "should you be implementing this?"
By not launching the user's default browser, you are subverting the user's decision.
Perhaps the user prefers a particular interface, and is willing to live with the incorrect renderings that come with it.
Perhaps the user has a browser addon that they really need, such as a screen reader for the blind.
You are requiring additional software installed that the user may or may not want.
Perhaps the user doesn't want Chrome. Perhaps the user prefers FireFox.
You are saying that you know which browser is best, now and forever.
What if the next version of IE makes it work with the sites that are currently Chrome-only? What if the next version of Chrome fixes the sites that are currently IE-only?
What if the site changes so that it works in more browsers?
Do you go back and release a new version of your software that changes the browser for particular sites?
You're trying to solve a problem that may already be fixed.
Both Chrome and Firefox support a addon that will render a tab using the IE engine. It can be set to automatically activate when certain URLs are seen.
Perhaps there is a browser that already works with all your sites, that you don't know about.
Therefore, my recommendation is no, do not do this. The user has decided which browser they want to use, respect that decision and use the default browser.
That said, here's how you would do it: You could use the CreateProcess method, but you're in managed-land, so you might as well use it. Use the Process class to launch the new process for you.
Process^ browserProcess = gcnew Process();
browserProcess->StartInfo->UseShellExecute = false;
browserProcess->StartInfo->FileName = "C:\\Program Files (x86)\\Internet Explorer\\iexplore.exe";
browserProcess->StartInfo->Arguments = "http://www.google.com";
browserProcess->Start();

Chrome extension to change Desktop wallpaper

I'm diving into the world of Chrome Extension development, primarily because there is a very small feature that is missing in Chrome that I miss dearly. The context-menu option to "Set as background/wallpaper" like that found in Firefox. Sounds trivial, but it's convenient.
I have most of the "basic" stuff worked out with the manifest file, am able to install it, even managed to get it to show up as a context menu item.
The problem obviously is that I am wanting to mess with a user's OS-level settings which is extremely difficult because of security issues (fully understand this).
I found an extension that allowed this in older versions of Chrome, and it looked like the developer used some type of .dll and C++ to accomplish this.
I'm not really sure how to make this work.
Since that Chrome doesn't allow these kind of manipulations (such as your PC's settings), you will need to create a native application that will run beside your extension. When the user chooses the image from your extension and selects "use as wallpaper", you will use the native messaging API to send a message to your desktop application, that will set the wallpaper (and do whatever else you can't do within a chrome extension) for you.
You can use the chrome.wallpaper app api to set the wallpaper after using the messaging api to send the image from your extension.

Web Browser Boot-Only Operating System

Is it possible to create an operating system that loads a web browser without menu bars, tabs etc. and that is all it loads.
I do not mean like Chrome OS but I mean all it loads is a html page which can be interacted with like an ordinary web page e.g. google.com, youtube.com.
Also, if this is possible, I would prefer it to be a Linux based OS and Webkit based browser.
You might have to roll your own for something like that...my recommendation would be a small linux distribution and then figure out how to run the surf browser, possibly with the tabbed extension, exclusively. When the x environment starts up just execute those programs. You'd honestly never know the difference.
Here is a screenshot of what this all looks like on my computer, running dwm for window management, and surf + tabbed. This browser is controlled via the keyboard, so you'd have to get use to that.
You don't need to create an operating system, you can use Linux.
A simple implementation would be creating an application using Qt Embedded (qws) with a Widget containing a QWebView only (it's WebKit based), that would load a predefined address.
You could spawn that app from the init scripts (rcS for example) in an endless loop (simple bash script, so if the app crashes it gets loaded again)
You can prototype it with a simple hardware like beagleboard.org or friendlyarm.net boards.

Resources