FFImageLoading CachedImage没有显示gif图像

时间:2018-09-14 07:44:29

标签: xamarin.forms

我正在使用xamarin表单进行应用程序开发。我正在使用FFimageloading查看gif文件。我在xaml文件中使用以下代码:

<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
             x:Class="myproject.View.MasterDetailPage1Detail"
             Icon="UEmlogotiny.png"
             xmlns:ff="clr-namespace:FFImageLoading.Forms;assembly=FFImageLoading.Forms"  
             xmlns:ffSvg="clr-namespace:FFImageLoading.Svg.Forms;assembly=FFImageLoading.Svg.Forms"  
             xmlns:ffTransformations="clr-namespace:FFImageLoading.Transformations;assembly=FFImageLoading.Transformations"
             >

....

<ff:CachedImage x:Name="Gif" Source="resource://UETrack.Beats.App.loader.gif" VerticalOptions="CenterAndExpand"
                         HorizontalOptions="CenterAndExpand"
                            WidthRequest="75" HeightRequest="75"
                            DownsampleToViewSize="True" IsVisible="True"/>

将“图像构建”操作更改为“嵌入式资源”

gif图片已显示在Orio上。但未显示在Oreo下面。

任何人都可以帮助我解决此问题。

1 个答案:

答案 0 :(得分:0)

您在哪里添加了图片?到Drawable文件夹? xxhdpi等?

如果是这样,您可以简单地执行以下操作:

Source="loader.gif"