Katteker/Example/MainWindow.xaml.cs
Holger Boerchers d383f0ef1c Initial commit
2018-03-21 20:07:40 +01:00

33 lines
931 B
C#

using System;
using System.Reflection;
using System.Windows;
using Katteker.Gui;
namespace Example
{
/// <summary>
/// Interaction logic for MainWindow.xaml
/// </summary>
public partial class MainWindow
{
public MainWindow()
{
InitializeComponent();
var version = GetType().Assembly.GetName().Version.ToString();
var a = Assembly.GetExecutingAssembly();
a.ManifestModule.GetPEKind(out var peKind, out var machine);
Title = $"{version} | {peKind} | {machine}";
}
private async void MainWindow_OnContentRendered(object sender, EventArgs e)
{
await Wrapper.CheckForUpdateAsync(true).ConfigureAwait(false);
}
private async void ButtonBase_OnClick(object sender, RoutedEventArgs e)
{
await Wrapper.CheckForUpdateAsync().ConfigureAwait(false);
}
}
}