You are here

Launcher improvements for local mode?

6 posts / 0 new
Last post
choin
Offline
Last seen: 1 year 7 months ago
Joined: 2023-04-01 23:57
Launcher improvements for local mode?

This might be a difficult matter to agree on, but a lot of people prefer using portable apps on their PCs as local apps. My reason is that it gives me understanding that everything is being saved in one place and not in AppData or elsewhere.

So, people like me find themselves trying to find solutions to issues specific to portable apps, and here is how it went for me:
1. Set up Portable Firefox as a default browser. That worked - there is a good script that does exactly this.
2. Pin to taskbar. This is where the problem lies. At first I thought it worked fine - the icon is there, it launches Firefox with needed command line parameters. But then I saw that it conflicts with the Portable launcher.

- If I first launch Portable Firefox with the launcher then it all works well - the pinned taskbar icon is used, and any URL clicks I do in other apps open correct pages inside existing Portable Firefox windows.
- If I first launch (Portable) Firefox from the pinned taskbar icon - then when I click any URL in any application, I get the error:
Another instance of Firefox is already running. Please close other instances of Firefox before launching Mozilla Firefox, Portable Edition.

Same effect can be achieved if you kill the FirefoxPortable.exe process while Portable Firefox is running and try to run it again.

I think the launcher (FirefoxPortable.exe) could be made smarter than that. If it could detect that Firefox process is already running with the same parameter it would want to launch it with - then it should act like it was launched with it in the first place and proceed to stay running like it normally would, until all Firefox processes are shut down.

John T. Haller
John T. Haller's picture
Offline
Last seen: 6 hours 33 min ago
AdminDeveloperModeratorTranslator
Joined: 2005-11-28 22:21
Platform to Pin To Taskbar

Use the PA.c Platform to pin to taskbar or the Start Menu. It can generate a special shortcut that understands the app id used by Windows. Pinning it by yourself without the PA.c Platform is not supported.

Sometimes, the impossible can become possible, if you're awesome!

choin
Offline
Last seen: 1 year 7 months ago
Joined: 2023-04-01 23:57
Okay I think I found the

Okay I think I found the problem. taskbar.grouping.useprofile was set to true. Setting it to false solves the problem.

There is nothing special about a shortcut the Platform makes.

John T. Haller
John T. Haller's picture
Offline
Last seen: 6 hours 33 min ago
AdminDeveloperModeratorTranslator
Joined: 2005-11-28 22:21
Differences

If you pin Firefox Portable to the taskbar while it is running by right-clicking the taskbar icon and selecting to Pin to taskbar, it will pin firefox.exe directly. If you run this while Firefox Portable is not running, it will run in local mode, bypassing portablization. If you drag FirefoxPortable.exe to the taskbar to pin it, it will pin it. When you run it, it will run in portable mode, but a second taskbar icon will appear alongside it while running.

If you select to pin to taskbar within the PA.c Platform, it will craft a special shortcut to FirefoxPortable.exe with the app id of its contained firefox.exe. This will allow it to run FirefoxPortable.exe and then firefox.exe in portable mode with only a single taskbar icon.

Sometimes, the impossible can become possible, if you're awesome!

choin
Offline
Last seen: 1 year 7 months ago
Joined: 2023-04-01 23:57
Okay, my mistake. Thanks for

Okay, my mistake. Thanks for explanation.
Yes, the shortcut has a special property called System.AppUserModel.ID.

Here is the tool that can do the same, so one could do this without installing Platform: https://code.google.com/archive/p/win7appid/
Usage: Win7AppId1.1.exe handmade-shortcut.lnk FirefoxPortable

John T. Haller
John T. Haller's picture
Offline
Last seen: 6 hours 33 min ago
AdminDeveloperModeratorTranslator
Joined: 2005-11-28 22:21
That works, Location of AppId, mkshortcut.exe

That utility will work. For other folks looking at this thread, you can find the appid for a specific app within AppInfo\appinfo.ini in the Control section called BaseAppID (or with 64 or ARM64 after it). Use the appropriate one for your system. The entry is documented here: https://portableapps.com/development/portableapps.com_format#appinfo The platform uses the open source mkshortcut.exe to create the shortcut with the appid directly.

I recommend using the platform as it's supported, doesn't require the command line, and is in a standard/expected location so the platform can automatically update it later if needed. But advanced users can create it using either utility mentioned here and it should work.

Sometimes, the impossible can become possible, if you're awesome!

Log in or register to post comments