From 351bde38f38dbb18bbc439e2bb8a9c3348c43aa6 Mon Sep 17 00:00:00 2001 From: NaBian <836904362@qq.com> Date: Fri, 25 Sep 2020 23:19:53 +0800 Subject: [PATCH] fixed #481 --- src/Shared/HandyControl_Shared/Controls/Image/ImageViewer.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Shared/HandyControl_Shared/Controls/Image/ImageViewer.cs b/src/Shared/HandyControl_Shared/Controls/Image/ImageViewer.cs index abee79dd..dedf47c0 100644 --- a/src/Shared/HandyControl_Shared/Controls/Image/ImageViewer.cs +++ b/src/Shared/HandyControl_Shared/Controls/Image/ImageViewer.cs @@ -512,6 +512,8 @@ namespace HandyControl.Controls private void Dispatcher_Tick(object sender, EventArgs e) { + if (_dispatcher == null) return; + if (ImageSource == null || !IsLoaded) { _dispatcher.Stop();