Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposal: Have WinUI Desktop support the UWP Jumplist API #2005

Open
Felix-Dev opened this issue Feb 20, 2020 · 7 comments
Open

Proposal: Have WinUI Desktop support the UWP Jumplist API #2005

Felix-Dev opened this issue Feb 20, 2020 · 7 comments
Labels
area-External Not owned by the WinUI team, not actionable in this repository. feature proposal New feature proposal

Comments

@Felix-Dev
Copy link
Contributor

Copied from the WinUI February Community Call thread to be used for tracking.

Currently, MSIX packaged desktop apps cannot effectively use the UWP Jumplist API because the app cannot be activated via jumplist tasks (see Windows Terminal issue microsoft/terminal#576 for a brief overview of the problem). Full support of this API for WinUI Desktop apps would be quite nice as they are much easier to work with than the Win32/WPF APIs. For example, jumplist task icons can be easily set using the ms-appx:/// or ms-appdata:/// URI schemes instead of having to create an .exe or .dll containing the images, then set the path to that file and also an offset into the file for the specific icon.

The docs summarize the advantages of the UWP Jumplist API:

Alternatively, use the UWP Windows.UI.StartScreen.JumpList APIs instead, which allow you to reference string and image assets using the package-relative ms-resource URI scheme (which is also language, DPI, and high contrast aware).

@Felix-Dev Felix-Dev added the feature proposal New feature proposal label Feb 20, 2020
@msft-github-bot msft-github-bot added the needs-triage Issue needs to be triaged by the area owners label Feb 20, 2020
@ranjeshj ranjeshj added the area-External Not owned by the WinUI team, not actionable in this repository. label Feb 20, 2020
@ranjeshj
Copy link
Contributor

@jesbis Can you please route this ? It looks like it might be part of the shell.

@Felix-Dev
Copy link
Contributor Author

@jesbis This seems like a good fit for Project Reunion. Should we transfer this issue (and update it to include all Win32 apps)?

@mdtauk
Copy link
Contributor

mdtauk commented Jul 17, 2020

Taskbar APIs like badging and preview buttons - as well as Context Menus etc - should be wrapped so Fluent WinUI controls can replace Win32 controls one at a time.

@grork
Copy link

grork commented Jul 17, 2020

Surely they should be separate from any UI stack? E.g. They’re a service of the shell, not the app platform.

@Felix-Dev
Copy link
Contributor Author

This issue should be moved to Project Reunion (and extended to cover all Win32 apps and not just WinUI Desktop apps). Pinging @stevewri as they assigned themself to another UWP Jumplist API request.

@mattleibow
Copy link

mattleibow commented Apr 2, 2021

I am having a look at getting Xamarin.Essentials / Microsoft MAUI running on WinUI and I notice that although the JumpList items are set, they do not have the args that I set when it launches the instance of the app. When the next instance of the app is launched, the JumpList still has the items with my args set. Just the OnLaunched event args do not have it.

When I added breakpoint in the generated static void Main(string[] args), I actually did get the args there. I also notice that it never does anything with it. I can also see it on Environment.GetCommandLineArgs() and Environment.CommandLine.

@mattleibow
Copy link

I added a hacky thing for my stuff:

            var args = e?.Arguments;
#if !WINDOWS_UWP
            if (string.IsNullOrEmpty(args))
            {
                var cliArgs = Environment.GetCommandLineArgs();
                if (cliArgs?.Length > 1)
                    args = cliArgs[1];
            }
#endif

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-External Not owned by the WinUI team, not actionable in this repository. feature proposal New feature proposal
Projects
None yet
Development

No branches or pull requests

6 participants