WPF - Ensure ZoomLevelProperty is updated on UI thread when Visibility Changed

This commit is contained in:
João Neves
2019-10-30 20:45:09 +10:00
committed by amaitland
parent 4163c8c61a
commit 3f285d5525
+6 -4
View File
@@ -2015,11 +2015,13 @@ namespace CefSharp.Wpf
//properly
var zoomLevel = await browser.GetHost().GetZoomLevelAsync();
if (!IsDisposed)
UiThreadRunAsync(() =>
{
SetCurrentValue(ZoomLevelProperty, zoomLevel);
}
if (!IsDisposed)
{
SetCurrentValue(ZoomLevelProperty, zoomLevel);
}
});
}
}
}