maui icon indicating copy to clipboard operation
maui copied to clipboard

What's going on with the splash-screen?

Open a-einstein opened this issue 2 years ago • 8 comments

Description

I am converting from XamarinForms to MAUI, for platforms Android and Windows. I am trying to get the splash screen working again on Windows.

Depending of my setup, I get several problems, none of them leading to a desired result.

What's going on? How to get this working?

Steps to Reproduce

In the central project-file there is a property like below. I found this described as being the only splash-screen needed. But this only works for Android. <MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#58ACFA" BaseSize="350,350" />

Then I tried to recreate the setupfor Windows as on XamarinForms.

  • Start from scratch in Package.appxmanifest.
  • In Visual Assets generate from a png file to Platforms\Windows\Assets and name it 'SplashScreen'. The files get generated, but there are no previews to be seen.
  • When starting I get: "error 0x80070003: Cannot install or update package ... because the splash screen image [SplashScreen.png] cannot be located"
  • Analogous to XamarinForms I set the build actions to 'Content'. (Why isn't this generated?) Now I get previews. but as later turns out I also get "Warning XA0101 @(Content) build action is not supported".
  • Setting build actions to 'Embedded Resource" takes the latter away, but does not solve the main problem.
  • After a clean, rebuild and even needed restart of VS, the application runs, but without a splash-screen.
  • Analogous to XamarinForms I set the entry point to 'RCS.PortableShop.WinUI.App' instead of '$targetentrypoint$'. (How useful are those placeholders anyway?) Now I get the splash-screen, but the application crashes with "application called an interface that was marshalled for a different thread"

So, not getting anywhere yet.

All these attempts seem futile, as I would assume that MauiSplashScreen should suffice.

By the way, even VS crashes sometimes when working on the Visual Assets.

Link to public reproduction project repository

Current commit: https://github.com/a-einstein/PortableShop/commit/e32e23f00fd0cb25fa68e9c4d521941a0887b344

Version with bug

7.0 (current)

Last version that worked well

Unknown/Other

Affected platforms

Windows

Affected platform versions

windows 10.0.17763.0

Did you find any workaround?

No.

Relevant log output

No response

Depends on

  • [ ] https://github.com/microsoft/microsoft-ui-xaml/issues/4055

a-einstein avatar Jan 03 '23 18:01 a-einstein

We've moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process.

ghost avatar Jan 03 '23 19:01 ghost

I've also been struggling with this. Turns out it is not implemented in WinUI yet. Doesn't seem to be high up on the agenda, either. None of the suggested workarounds work like how you'd expect, and are a bit trickier to implement in a Maui WinUI application. Very disappointing.

See: https://github.com/dotnet/maui/issues/3870 https://github.com/microsoft/microsoft-ui-xaml/issues/4055

breenbob avatar Jan 06 '23 14:01 breenbob

Any update for splash screen to support in UWP?

Sofiya2696 avatar Mar 15 '23 05:03 Sofiya2696

any update for splash screen in UWP?

AhsanAli2546 avatar Oct 18 '23 01:10 AhsanAli2546

Visual Studio Enterprise 17.8.0 Preview 3.0. Can repro on windows platform.

Zhanglirong-Winnie avatar Oct 18 '23 07:10 Zhanglirong-Winnie

Its been more than an year and still not worked upon. The another issue without a spalsh screen is that if user click on the app icon on Windows - it can launch more than 1 app in parallel.

NeerajGulia avatar May 09 '24 04:05 NeerajGulia

We agree that this is an important issue. As our roadmap indicates, for the near future, we are focused on:

  • Issues impacting Xamarin.Forms upgrades to .NET MAUI
  • CollectionView
  • Layout

I am marking this as a p/2 issue because it does not meet our focus areas right now, but we are constantly revisiting the backlog for important issues to address as time allows. Thank you for your patience and understanding!

samhouts avatar Jun 18 '24 23:06 samhouts

Have any solution Cannot install or update package O24Toolkit_qcvtrzgcjzrs0 because the splash screen image [O24Toolkit.png] cannot be located

nguyenvuhoang avatar Jun 30 '24 12:06 nguyenvuhoang

Just a not, WinUI does not have splash screen support: https://github.com/microsoft/microsoft-ui-xaml/issues/4055

You can maybe have a look at some of the comments if you really need to have a splash as there may be some ideas. Otherwise, we have to wait for the WASDK and OS team to come up with something.

mattleibow avatar Jul 01 '24 13:07 mattleibow