Skip to content

Commit

Permalink
WPF: Possible fix for NullReferenceException in OnTooltipTimerTick
Browse files Browse the repository at this point in the history
Resolves #2134
  • Loading branch information
merceyz committed Aug 31, 2017
1 parent bad729e commit 8a14405
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions CefSharp.Wpf/ChromiumWebBrowser.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1905,9 +1905,13 @@ private void SetPopupSizeAndPositionImpl(int width, int height, int x, int y)
/// <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>
Expand Down

0 comments on commit 8a14405

Please sign in to comment.