From 95dfa95562ec9d0a3bf27ae1df5697c4810ce0bb Mon Sep 17 00:00:00 2001 From: Daniel Kraus Date: Sun, 6 Sep 2015 12:06:39 +0200 Subject: [PATCH] Add respository link to AboutView and AboutViewModel. --- zaaReloaded2/Properties/Settings.Designer.cs | 9 ++++++++ zaaReloaded2/Properties/Settings.settings | 3 +++ zaaReloaded2/ViewModels/AboutViewModel.cs | 22 ++++++++++++++++++++ zaaReloaded2/Views/AboutView.xaml | 12 +++++++++-- zaaReloaded2/app.config | 3 +++ 5 files changed, 47 insertions(+), 2 deletions(-) diff --git a/zaaReloaded2/Properties/Settings.Designer.cs b/zaaReloaded2/Properties/Settings.Designer.cs index 61a49df..82402a5 100755 --- a/zaaReloaded2/Properties/Settings.Designer.cs +++ b/zaaReloaded2/Properties/Settings.Designer.cs @@ -255,5 +255,14 @@ namespace zaaReloaded2.Properties { return ((string)(this["ManualCommentPrompt"])); } } + + [global::System.Configuration.ApplicationScopedSettingAttribute()] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Configuration.DefaultSettingValueAttribute("http://git.bovender.de")] + public string Repository { + get { + return ((string)(this["Repository"])); + } + } } } diff --git a/zaaReloaded2/Properties/Settings.settings b/zaaReloaded2/Properties/Settings.settings index 59e93fd..c4bb743 100755 --- a/zaaReloaded2/Properties/Settings.settings +++ b/zaaReloaded2/Properties/Settings.settings @@ -74,5 +74,8 @@ BITTE_ERGÄNZEN + + http://git.bovender.de + \ No newline at end of file diff --git a/zaaReloaded2/ViewModels/AboutViewModel.cs b/zaaReloaded2/ViewModels/AboutViewModel.cs index f9e25f5..6403a19 100755 --- a/zaaReloaded2/ViewModels/AboutViewModel.cs +++ b/zaaReloaded2/ViewModels/AboutViewModel.cs @@ -79,6 +79,14 @@ namespace zaaReloaded2.ViewModels } } + public string Repository + { + get + { + return Properties.Settings.Default.Repository.ToString(); + } + } + public string LicenseUrl { get @@ -104,6 +112,19 @@ namespace zaaReloaded2.ViewModels } } + public DelegatingCommand GotoRepositoryCommand + { + get + { + if (_gotoRepositoryCommand == null) + { + _gotoRepositoryCommand = new DelegatingCommand( + param => { Process.Start(new ProcessStartInfo(Repository)); }); + } + return _gotoRepositoryCommand; + } + } + public DelegatingCommand GotoLicenseCommand { get @@ -131,6 +152,7 @@ namespace zaaReloaded2.ViewModels #region Fields DelegatingCommand _gotoHomepageCommand; + DelegatingCommand _gotoRepositoryCommand; DelegatingCommand _gotoLicenseCommand; #endregion diff --git a/zaaReloaded2/Views/AboutView.xaml b/zaaReloaded2/Views/AboutView.xaml index 8d4b0b6..149c863 100755 --- a/zaaReloaded2/Views/AboutView.xaml +++ b/zaaReloaded2/Views/AboutView.xaml @@ -20,7 +20,7 @@ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:b="clr-namespace:Bovender.Mvvm.Views.Settings;assembly=Bovender" - Width="360" Height="320" ResizeMode="NoResize" ShowInTaskbar="False" + Width="360" SizeToContent="Height" ResizeMode="NoResize" ShowInTaskbar="False" b:WindowState.CenterScreen="True" Title="Über..." > @@ -30,7 +30,10 @@ - + + Version + + Homepage: @@ -38,6 +41,11 @@ + Quellcode: + + + + Lizenz: diff --git a/zaaReloaded2/app.config b/zaaReloaded2/app.config index dcc98ae..edf22de 100755 --- a/zaaReloaded2/app.config +++ b/zaaReloaded2/app.config @@ -83,6 +83,9 @@ BITTE_ERGÄNZEN + + http://git.bovender.de +