diff --git a/VECTO3GUI/MainWindow.xaml b/VECTO3GUI/MainWindow.xaml index 01a895cf106f2cb51ab8013f5e9dd4b747f7a217..d32e48dd507f614ec259b31bd73b03ab65968c43 100644 --- a/VECTO3GUI/MainWindow.xaml +++ b/VECTO3GUI/MainWindow.xaml @@ -10,7 +10,7 @@ xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks" xmlns:views="clr-namespace:VECTO3GUI.Views" mc:Ignorable="d" - Title="{Binding Version}" Height="515.36" Width="972.48" WindowStartupLocation="CenterScreen" + Title="{Binding Version}" Icon="Resources/Icon2.ico" Height="515.36" Width="972.48" WindowStartupLocation="CenterScreen" d:DataContext="{d:DesignInstance Type=impl:MainWindowViewModel, IsDesignTimeCreatable=False}"> <Grid> diff --git a/VECTO3GUI/Model/JobListModel.cs b/VECTO3GUI/Model/JobListModel.cs index cd5f825bdb216cb0e3ee91ec466e5cc5efe32032..ebfb93345d010cb3688e70131d0b7ed9c08ed69e 100644 --- a/VECTO3GUI/Model/JobListModel.cs +++ b/VECTO3GUI/Model/JobListModel.cs @@ -17,7 +17,7 @@ namespace VECTO3GUI.Model public class JobListModel { private const string ConfigFolderName = "Config"; - private const string JobListFileName = "JobList.txt"; + private const string JobListFileName = "JobList.json"; private string _jobListFilePath = Path.Combine(".", ConfigFolderName, JobListFileName); diff --git a/VECTO3GUI/Resources/Icon2.ico b/VECTO3GUI/Resources/Icon2.ico new file mode 100644 index 0000000000000000000000000000000000000000..6de7e5cd7ef1e97f70d64cb3eeaa2b7fcc8d604f Binary files /dev/null and b/VECTO3GUI/Resources/Icon2.ico differ diff --git a/VECTO3GUI/Util/RelayCommand.cs b/VECTO3GUI/Util/RelayCommand.cs index 108264ef1d12c17aad5d466c07e3d81671203f9c..f93026a572a7c4a864c623a1180ca0a5337086e2 100644 --- a/VECTO3GUI/Util/RelayCommand.cs +++ b/VECTO3GUI/Util/RelayCommand.cs @@ -1,5 +1,6 @@ using System; using System.Diagnostics; +using System.Windows; using System.Windows.Input; namespace VECTO3GUI.Util @@ -72,7 +73,11 @@ namespace VECTO3GUI.Util public void Execute(object parameter) { - _execute((T)parameter); + try { + _execute((T)parameter); + } catch (Exception e) { + MessageBox.Show(e.Message, "Exception", MessageBoxButton.OK, MessageBoxImage.Error); + } } #endregion diff --git a/VECTO3GUI/VECTO3GUI.csproj b/VECTO3GUI/VECTO3GUI.csproj index cc8bb460cf0728d5b42e9ff1e67a62e986f674f6..9b074022a87764c6da4c7ec0a031dd19f7c753ea 100644 --- a/VECTO3GUI/VECTO3GUI.csproj +++ b/VECTO3GUI/VECTO3GUI.csproj @@ -8,7 +8,7 @@ <OutputType>WinExe</OutputType> <AppDesignerFolder>Properties</AppDesignerFolder> <RootNamespace>VECTO3GUI</RootNamespace> - <AssemblyName>VECTO3GUI</AssemblyName> + <AssemblyName>VECTO3</AssemblyName> <TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion> <FileAlignment>512</FileAlignment> <ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids> @@ -34,6 +34,9 @@ <ErrorReport>prompt</ErrorReport> <WarningLevel>4</WarningLevel> </PropertyGroup> + <PropertyGroup> + <ApplicationIcon>Resources\Icon2.ico</ApplicationIcon> + </PropertyGroup> <ItemGroup> <Reference Include="Castle.Core, Version=4.0.0.0, Culture=neutral, PublicKeyToken=407dd0808d44fbdc, processorArchitecture=MSIL"> <HintPath>..\packages\Castle.Core.4.2.0\lib\net45\Castle.Core.dll</HintPath> @@ -632,6 +635,9 @@ <ItemGroup> <Resource Include="Resources\AirdragLoadTestFile.xml" /> </ItemGroup> + <ItemGroup> + <Resource Include="Resources\Icon2.ico" /> + </ItemGroup> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> <!-- To modify your build process, add your task inside one of the targets below and uncomment it. Other similar extension points exist, see Microsoft.Common.targets. diff --git a/VECTO3GUI/ViewModel/Impl/JoblistViewModel.cs b/VECTO3GUI/ViewModel/Impl/JoblistViewModel.cs index d9bfa4d9a8f5559372a893c60aa68a521977042b..9b7ca1fc202c09038ee9841441d11464c25a8bcd 100644 --- a/VECTO3GUI/ViewModel/Impl/JoblistViewModel.cs +++ b/VECTO3GUI/ViewModel/Impl/JoblistViewModel.cs @@ -335,11 +335,13 @@ namespace VECTO3GUI.ViewModel.Impl { var jobEntry = SerializeHelper.DeserializeToObject<JobEntry>(filePath.First()); jobEntry.JobEntryFilePath = filePath.First(); + jobEntry.Selected = true; _jobs.Add(jobEntry); } else if(IsXmlFile(filePath.First())) { var jobEntry = GetAdditionalJobEntry(filePath.First()); + jobEntry.Selected = true; _jobs.Add(jobEntry); } } diff --git a/VECTO3GUI/Views/OutputWindow.xaml b/VECTO3GUI/Views/OutputWindow.xaml index e81d0b388d0fca3afff9ae36a1c18ea005ed89b3..306595579869838e4c0e8166e7b8e112199b05cf 100644 --- a/VECTO3GUI/Views/OutputWindow.xaml +++ b/VECTO3GUI/Views/OutputWindow.xaml @@ -11,7 +11,7 @@ xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity" xmlns:helper="clr-namespace:VECTO3GUI.Helper" mc:Ignorable="d" - Title="{Binding WindowTitle}" Height="450" Width="800" WindowStartupLocation="CenterScreen" TitleCharacterCasing="Normal" + Title="{Binding WindowTitle}" Icon="../Resources/Icon2.ico" Height="450" Width="800" WindowStartupLocation="CenterScreen" TitleCharacterCasing="Normal" d:DataContext="{d:DesignInstance Type=impl:OutputWindowViewModel, IsDesignTimeCreatable=False}"> <mah:MetroWindow.TitleTemplate>