Firefox OS - How to awap the homescreen app for another app - firefox-os

From this diagram I understand that the last step of the bootup process has the window manager launching the Gaia home screen.
I want to experiment and change the the first app that is booted and whatever launches when the home button is pressed, but I have not been able to figure out exactly where is that the homescreen app first launched.
Any pointers would be greatly appreciated.

There is a setting called homescreen.manifestURL that points to the manifest URL of the application that is used as homescreen. You can grep this string to know where exactly it's used.
This setting is set at build time in build/settings.js. You can try to change it there.
You can also install a separate homescreen app (see https://github.com/KevinGrandon/firefoxos-homescreen-boilerplate for a boilerplate for a homescreen -- I'm not sure how uptodate it is) and enable it from the Settings app. It has a "role": "homescreen" property in its manifest.

Related

Why does my SDL Linux application have the correct icon in the app menu, but not in the taskbar?

I am trying to debug a weird icon problem for my Linux app. When I search for the app in the application menu it shows the right icon but when I run the app itself the icon is broken (it shows the default icon, which is that square gear icon).
Here is the app's desktop file, which is installed to /usr/local/share/applications/com.example.Xjump.desktop
[Desktop Entry]
Version=1.0
Type=Application
Name=XJump
Comment=A jumping game
Exec=xjump
Icon=com.example.Xjump
Terminal=false
Categories=Game;ArcadeGame;
The application is implemented using SDL. The PNG icons are installed to /usr/local/share in 32x32, 64x64, and 128x128 versions. (e.g. /usr/local/share/icons/hicolor/32x32/apps/com.example.Xjump.png).
Another thing that I noticed is that if I change the icon name to xjump, matching the executable name, then the taskbar icon works correctly! That is, if I change the desktop file to say Icon=xjump and rename the pngs to xjump.png then the icon works correctly on both the app menu and the taskbar. However, I don't think I can do that for real, because Linux packaging guidelines prefer if the app and icon name follow that "reverse URL" convention.
Once the application is running, GNOME looks at the windows's window class to determine the right icon, because it no longer knows what desktop file was responsible for launching it. It is the responsibility of the application to correctly initialize the window class during startup.
For SDL applications, the default behavior seems to be get the window class from environment variables and, if those are unset, use the executable name as the default. This is why I could get the icon to show when I gave my icon the same name as the executable.
The fix that ended up working for me was to set the environment variables. One way to do it is to call setenv before SDL_Init.
setenv("SDL_VIDEO_WAYLAND_WMCLASS", "com.example.Xjump", 0);
setenv("SDL_VIDEO_X11_WMCLASS", "com.example.Xjump", 0);

Listen for linux command in a Qt app running in background?

I wonder if there is a way to send data from an OS command (Linux to begin with, but I would be interested about Windows too) to a Qt app working in background.
My use case would be to right click in a context menu in a file explorer and then send the path of the selected file(s) to the already running Qt app to trigger an action inside that app.
Can anyone provide some explanations or a link to an example achieving that ?
I already read about adding right click in Nemo/Nautilus with some custom config files, I am more interested by the Qt part.
AFAIK, there is no such component available with QT. (Don't know if anything added recently, I haven't used qt from long time)
But what you can do is write some code in qt app like server ( May be socket server OR pipe), when some data comes on that you can take action based on that data value.
On other side write some small utility which will get called, which send data to you server, with path of selected file when clicked via context menu.

Blueprism Application Modeller showing Launch instead of Identify when spying

I am using BluePrism v6.1.0 and I am trying to identify elements from a launched application in Application Modeller. (I used the Windows application type in the modeler configuration)
From some tutorials I saw, the launch button changes to Identify button after the app is launched, however, mine is still showing "Launch". Please see screenshot below
screenshot
You need to launch the application from the application modeller, not on your own.
Since you are using Windows 10, the built in applications are use differently than normal in windows 7. Here is how you can add the code to make it work with your system Screenshot. Also for future applications use this code in Windows Power Shell to get information about the application you wanted to work with in Window 10 : "Get-AppxPackage"
Not fully explained here but this can also mean not only is the app not launched but blueprism can't "see" the app is launched. Two ways to solve this so close the application and relaunch it then it will change to identify, OR you can attach the current instance of the object to the running application.
Either way the outcome is you're making blueprism see the active application so it will change the launch to an identify option.
Edit: watch out as well, if you connect your application to blue prism and then detach it blue prism will no longer see the running application hence will revert the identify option into a launch option.

How can I make the changes of Gaia apply to device

I edit the system app(homescreen) in the gaia folder,
and flash the device,
but it doesn't work, not thing change at all.
I've already try it on the simulator,
it runs as well.
Could somebody tell me how to make the changes apply to the real device ?
thanks.
So there is two ways you can do it. If all you want is change the homescreen, you can now create a homescreen app and set it as the homescreen in Settings (push via the app manager like any app). There is a nice example here.
If you want to flash the gaia homescreen to your phone, there is a couple of things you need to do:
Update the phone to the correct version (nightly if you're editing master, 1.4 if you're editing upstream/v1.4 branch). This is because gaia & gecko version are tightly coupled.
Enable Remote debugging in Settings
Verify that you can talk to the phone via the app manager
In the terminal, run adb root and adb remount to make sure you have to right permissions (this is probably where it goes wrong)
In the gaia directory run: make reset-gaia
This should flash all of gaia now. If you continue editing you can make incremental changes to homescreen and push them via:
APP=homescreen make install-gaia && adb shell stop b2g && adb shell start b2g
If this doesn't work, please write the output of make reset-gaia to a log file and add it as a comment to your question.

Launching a web page in a different process

I want to launch the browser in a different process when a particular link is clicked on the page. When I checked the net I found the following tip: http://www.dslreports.com/faq/3849 . But there we have to change the registry. Is there any simple way of doing this without touching the registry?
If you use the Google Chrome browser, each new window or tab runs in a separate process. Internet Explorer version 8 will do the same (it's currently in the second beta round).
Earlier versions of IE will run a new window in a separate process if it is launched from, say, the Start menu or the command line, or a link in an email (but not by clicking a link within IE). I imagine you could create a proxy that the client would run through, which would intercept the links you care about and launch them by running a command line request. That seems like more trouble than mucking with the registry though (assuming that registry change still works -- looks like your link is from 2002).
I don't believe this is possible unless you change the client computer setup or software it's running.
Why do you want to do this?

Resources