Browse Source

Merge pull request #6807 from YohDeadfall/fix-event-debugging

Added lost lines in event debugging
pull/6823/head
Tako 5 years ago
committed by GitHub
parent
commit
26f61e0033
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      src/Avalonia.Diagnostics/Diagnostics/ViewModels/EventTreeNode.cs
  2. 2
      src/Avalonia.Diagnostics/Diagnostics/ViewModels/FiredEvent.cs

5
src/Avalonia.Diagnostics/Diagnostics/ViewModels/EventTreeNode.cs

@ -117,6 +117,11 @@ namespace Avalonia.Diagnostics.ViewModels
_currentEvent.HandledBy = link;
}
}
if (!Dispatcher.UIThread.CheckAccess())
Dispatcher.UIThread.Post(handler);
else
handler();
}
private static bool BelongsToDevTool(IVisual v)

2
src/Avalonia.Diagnostics/Diagnostics/ViewModels/FiredEvent.cs

@ -64,7 +64,7 @@ namespace Avalonia.Diagnostics.ViewModels
if (EventChain.Count > 0)
{
var prevLink = EventChain[EventChain.Count - 1];
if (prevLink.Route != link.Route)
{
link.BeginsNewRoute = true;

Loading…
Cancel
Save