Browse Source

Use Window.Opened event for rxui activation.

pull/2266/head
Steven Kirk 7 years ago
parent
commit
6a167a6882
  1. 6
      src/Avalonia.ReactiveUI/AvaloniaActivationForViewFetcher.cs

6
src/Avalonia.ReactiveUI/AvaloniaActivationForViewFetcher.cs

@ -29,8 +29,8 @@ namespace Avalonia
{ {
var windowLoaded = Observable var windowLoaded = Observable
.FromEventPattern( .FromEventPattern(
x => window.Initialized += x, x => window.Opened += x,
x => window.Initialized -= x) x => window.Opened -= x)
.Select(args => true); .Select(args => true);
var windowUnloaded = Observable var windowUnloaded = Observable
.FromEventPattern( .FromEventPattern(
@ -59,4 +59,4 @@ namespace Avalonia
.DistinctUntilChanged(); .DistinctUntilChanged();
} }
} }
} }

Loading…
Cancel
Save