maui icon indicating copy to clipboard operation
maui copied to clipboard

[Android] Fix gif animation initial state

Open jsuarezruiz opened this issue 2 years ago • 8 comments

Description of Change

Fix gif animation initial state.

To validate the changes, launch the .NET MAUI Gallery and navigate to the Image samples or, use the existing related tests previously ignored and now passing.

fix-7019 image

Issues Fixed

Fixes #7019

jsuarezruiz avatar Mar 30 '23 14:03 jsuarezruiz

Thank you for your pull request. We are auto-formatting your source code to follow our code guidelines.

github-actions[bot] avatar Mar 30 '23 14:03 github-actions[bot]

/rebase

jfversluis avatar Sep 05 '23 12:09 jfversluis

@mattleibow Could I have your feedback here when you have time? Thanks in advance.

jsuarezruiz avatar Nov 14 '23 11:11 jsuarezruiz

I see windows does have this: https://github.com/dotnet/maui/blob/main/src/Core/src/Platform/Windows/ImageSourcePartExtensions.cs#L46

Should we consolidate in either the image setter or the handler? I like the handler because that is more extensible/custmisable? @PureWeen

mattleibow avatar Jan 25 '24 22:01 mattleibow

Hmmm, maybe windows is separate since it reads gif as NOT animated:

image

mattleibow avatar Jan 25 '24 22:01 mattleibow

Let me try force playing...

mattleibow avatar Jan 25 '24 22:01 mattleibow

Looking at the code, Android does go onto another thread and somehow it still works... We need to await I think to avoid potential threading issues. We can fix Windows separately. Even calling Stop directly does not do anything.

mattleibow avatar Jan 25 '24 22:01 mattleibow

This is why it passes on Windows... They are not even there! image

OK, Windows is a totally separate thing with all sorts of issues.

mattleibow avatar Jan 25 '24 23:01 mattleibow

I have fixed this issue on Windows in #20169 and also enavledenabled the tests in https://github.com/dotnet/maui/pull/20167

mattleibow avatar Jan 26 '24 02:01 mattleibow