From 138ea74b88f64e2977482583b9e4042d68567b24 Mon Sep 17 00:00:00 2001 From: Dan Walmsley Date: Fri, 22 Nov 2019 19:32:09 +0000 Subject: [PATCH] Add code to show desired syntax. --- samples/ControlCatalog/App.xaml | 5 +++++ samples/ControlCatalog/App.xaml.cs | 14 ++++++++++++++ 2 files changed, 19 insertions(+) diff --git a/samples/ControlCatalog/App.xaml b/samples/ControlCatalog/App.xaml index e40509dfda..813a043b01 100644 --- a/samples/ControlCatalog/App.xaml +++ b/samples/ControlCatalog/App.xaml @@ -17,4 +17,9 @@ + + + + + diff --git a/samples/ControlCatalog/App.xaml.cs b/samples/ControlCatalog/App.xaml.cs index 958729e2e8..b713c3dfd6 100644 --- a/samples/ControlCatalog/App.xaml.cs +++ b/samples/ControlCatalog/App.xaml.cs @@ -1,18 +1,32 @@ using System; +using System.Reactive; using Avalonia; using Avalonia.Controls; using Avalonia.Controls.ApplicationLifetimes; using Avalonia.Markup.Xaml; +using ReactiveUI; namespace ControlCatalog { public class App : Application { + public App() + { + DataContext = this; + + AboutCommand = ReactiveCommand.Create(() => + { + + }); + } + public override void Initialize() { AvaloniaXamlLoader.Load(this); } + public ReactiveCommand AboutCommand { get; } + public override void OnFrameworkInitializationCompleted() { if (ApplicationLifetime is IClassicDesktopStyleApplicationLifetime desktopLifetime)