WPF: Possible fix for NullReferenceException in OnTooltipTimerTick

Resolves #2134
This commit is contained in:
Chris
2017-08-31 18:13:01 +02:00
parent bad729ee0d
commit 8a144050ee
+6 -2
View File
@@ -1905,9 +1905,13 @@ namespace CefSharp.Wpf
/// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param>
private void OnTooltipTimerTick(object sender, EventArgs e)
{
tooltipTimer.Stop();
// Checks to see if the control is disposed/disposing
if (Interlocked.CompareExchange(ref disposeCount, 1, 1) != 1)
{
tooltipTimer.Stop();
UpdateTooltip(TooltipText);
UpdateTooltip(TooltipText);
}
}
/// <summary>