public static void ExecuteOnClosed(this ISupportClosing source, Action action) { IDisposable supportClosingClosed = null; supportClosingClosed = source.Closed .Subscribe(x => { action(); if (supportClosingClosed != null) { supportClosingClosed.Dispose(); } }); }
public static IDisposable SyncViewModelClose(this ISupportClosing destination, ISupportClosing source) { return(source.ClosingStrategy.Closed .Subscribe(x => destination.ClosingStrategy.Close())); }
public static IDisposable SyncViewModelClose(this ISupportClosing destination, ISupportClosing source) { return source.ClosingStrategy.Closed .Subscribe(x => destination.ClosingStrategy.Close()); }