diff options
Diffstat (limited to 'Xamarin.Forms.Platform.Android/Renderers/FormsImageView.cs')
-rw-r--r-- | Xamarin.Forms.Platform.Android/Renderers/FormsImageView.cs | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/Xamarin.Forms.Platform.Android/Renderers/FormsImageView.cs b/Xamarin.Forms.Platform.Android/Renderers/FormsImageView.cs new file mode 100644 index 00000000..ae32e16c --- /dev/null +++ b/Xamarin.Forms.Platform.Android/Renderers/FormsImageView.cs @@ -0,0 +1,36 @@ +using System; +using Android.Content; +using Android.Runtime; +using Android.Widget; + +namespace Xamarin.Forms.Platform.Android +{ + internal class FormsImageView : ImageView + { + bool _skipInvalidate; + + public FormsImageView(Context context) : base(context) + { + } + + protected FormsImageView(IntPtr javaReference, JniHandleOwnership transfer) : base(javaReference, transfer) + { + } + + public override void Invalidate() + { + if (_skipInvalidate) + { + _skipInvalidate = false; + return; + } + + base.Invalidate(); + } + + public void SkipInvalidate() + { + _skipInvalidate = true; + } + } +}
\ No newline at end of file |