Code development platform for open source projects from the European Union institutions

Skip to content
Snippets Groups Projects
Commit ffa6230d authored by Franz KOBER josef's avatar Franz KOBER josef
Browse files

changed namespace to VECTO3GUI, started to add PrimaryVehicleBus to the gui

parent b06d72dd
No related branches found
No related tags found
No related merge requests found
Showing
with 61 additions and 52 deletions
......@@ -9,10 +9,10 @@ using Ninject;
using Ninject.Extensions.Factory;
using TUGraz.VectoCommon.InputData;
using TUGraz.VectoCore;
using VECTO3.ViewModel.Adapter;
using VECTO3.ViewModel.Adapter.Declaration;
using VECTO3.ViewModel.Impl;
using VECTO3.ViewModel.Interfaces;
using VECTO3GUI.ViewModel.Adapter;
using VECTO3GUI.ViewModel.Adapter.Declaration;
using VECTO3GUI.ViewModel.Impl;
using VECTO3GUI.ViewModel.Interfaces;
namespace VECTO3GUI
{
......@@ -40,8 +40,10 @@ namespace VECTO3GUI
container.Bind<IMainWindowViewModel>().To<MainWindowViewModel>();
container.Bind<IJoblistViewModel>().To<JoblistViewModel>();
container.Bind<IJobEditViewModel>().To<DeclarationJobViewModel>();
container.Bind<IJobEditViewModel>().To<PrimaryVehicleBusJobViewModel>();
container.Bind<INoneViewModel>().To<NoneViewModel>();
container.Bind<IVehicleViewModel>().To<VehicleViewModel>();
container.Bind<IPrimaryVehicleBusViewModel>().To<PrimaryVehicleBusViewModel>();
container.Bind<IAirdragViewModel>().To<AirdragViewModel>();
container.Bind<IAngledriveViewModel>().To<AngledriveViewModel>();
......
using System;
using System.Windows.Markup;
namespace VECTO3.Helper {
namespace VECTO3GUI.Helper {
public class BaseConverter : MarkupExtension
{
#region Overrides of MarkupExtension
......
......@@ -3,7 +3,7 @@ using System.ComponentModel;
using System.Windows;
using System.Windows.Markup;
namespace VECTO3.Helper
namespace VECTO3GUI.Helper
{
public abstract class DataContextBaseExtension : MarkupExtension
{
......
......@@ -3,7 +3,7 @@ using System.Globalization;
using System.Windows.Controls;
using System.Windows.Data;
namespace VECTO3.Helper
namespace VECTO3GUI.Helper
{
public class JobEntrySelectedConverter : IValueConverter
{
......
using System;
using System.Linq;
using System.Linq.Expressions;
using System.Reflection;
using SIUtils = VECTO3.Util.SIUtils;
using SIUtils = VECTO3GUI.Util.SIUtils;
namespace VECTO3.Helper {
namespace VECTO3GUI.Helper {
public class SIUnit : DataContextBaseExtension
{
......
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Reflection;
using System.Windows;
using System.Windows.Data;
using TUGraz.VectoCommon.Utils;
using Expression = System.Linq.Expressions.Expression;
using SIUtils = VECTO3.Util.SIUtils;
using SIUtils = VECTO3GUI.Util.SIUtils;
namespace VECTO3.Helper
namespace VECTO3GUI.Helper
{
public class SIValueConverter : BaseConverter, IValueConverter
{
......
......@@ -3,7 +3,7 @@ using System.Globalization;
using System.Windows.Data;
using TUGraz.VectoCore.Models.Declaration;
namespace VECTO3.Helper
namespace VECTO3GUI.Helper
{
public class VehicleClassConverter : BaseConverter, IValueConverter
{
......
......@@ -4,7 +4,7 @@
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:VECTO3GUI"
xmlns:interfaces="clr-namespace:VECTO3.ViewModel.Interfaces"
xmlns:interfaces="clr-namespace:VECTO3GUI.ViewModel.Interfaces"
mc:Ignorable="d"
Title="VECTO 3" Height="515.36" Width="972.48" >
......
......@@ -12,7 +12,7 @@ using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using VECTO3.ViewModel.Interfaces;
using VECTO3GUI.ViewModel.Interfaces;
namespace VECTO3GUI
{
......
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:impl="clr-namespace:VECTO3.ViewModel.Impl"
xmlns:views="clr-namespace:VECTO3.Views"
xmlns:engineering="clr-namespace:VECTO3.Views.ComponentViews.Engineering"
xmlns:declaration="clr-namespace:VECTO3.Views.ComponentViews.Declaration"
xmlns:interfaces="clr-namespace:VECTO3.ViewModel.Interfaces">
xmlns:impl="clr-namespace:VECTO3GUI.ViewModel.Impl"
xmlns:views="clr-namespace:VECTO3GUI.Views"
xmlns:engineering="clr-namespace:VECTO3GUI.Views.ComponentViews.Engineering"
xmlns:declaration="clr-namespace:VECTO3GUI.Views.ComponentViews.Declaration"
xmlns:interfaces="clr-namespace:VECTO3GUI.ViewModel.Interfaces">
<DataTemplate DataType="{x:Type impl:JoblistViewModel}">
<views:JoblistView />
......@@ -15,11 +15,19 @@
<DataTemplate DataType="{x:Type impl:EngineOnlyJobViewModel}">
<views:JobEditView/>
</DataTemplate>
<DataTemplate DataType="{x:Type impl:PrimaryVehicleBusJobViewModel}">
<views:JobEditView/>
</DataTemplate>
<DataTemplate DataType="{x:Type impl:NoneViewModel}">
<views:EditComponentNoneView/>
</DataTemplate>
<DataTemplate DataType="{x:Type impl:PrimaryVehicleBusViewModel}">
<declaration:PrimaryVehicleBusView/>
</DataTemplate>
<DataTemplate x:Key="EditAirdragDeclaration">
<declaration:AirdragDeclarationView/>
</DataTemplate>
......@@ -164,6 +172,8 @@
</DataTemplate.Triggers>
</DataTemplate>
<DataTemplate x:Key="EditVehicleDeclaration">
<declaration:VehicleDeclarationView/>
</DataTemplate>
......
namespace VECTO3.Util {
namespace VECTO3GUI.Util {
public class AllowedEntry
{
......
namespace VECTO3.Util {
namespace VECTO3GUI.Util {
public enum Component
{
Vehicle = 1,
PrimaryBusVehicle,
Engine,
Gearbox,
TorqueConverter,
......

using System;
using System;
using System.Diagnostics;
using System.Windows.Input;
namespace VECTO3.Util
namespace VECTO3GUI.Util
{
/// <summary>
/// A command whose sole purpose is to relay its functionality to other objects by invoking delegates. The default return value for the CanExecute method is 'true'.
......
......@@ -4,7 +4,7 @@ using System.Linq.Expressions;
using System.Reflection;
using TUGraz.VectoCommon.Utils;
namespace VECTO3.Util
namespace VECTO3GUI.Util
{
public static class SIUtils
{
......
......@@ -2,9 +2,9 @@ using System.Collections.Generic;
using TUGraz.VectoCommon.InputData;
using TUGraz.VectoCommon.Utils;
using TUGraz.VectoCore.InputData.Reader.ComponentData;
using VECTO3.ViewModel.Interfaces;
using VECTO3GUI.ViewModel.Interfaces;
namespace VECTO3.Util {
namespace VECTO3GUI.Util {
public static class TableDataConverter {
public static TableData Convert(IEnumerable<GearLossMapEntry> viewModelLossMap)
......
using System;
namespace VECTO3.Util {
namespace VECTO3GUI.Util {
[AttributeUsage(AttributeTargets.Property)]
public class VectoParameterAttribute : Attribute
{
......
using System;
using System.Collections.Generic;
using Ninject;
using VECTO3.ViewModel.Impl;
using VECTO3.ViewModel.Interfaces;
using VECTO3GUI.ViewModel.Interfaces;
using VECTO3GUI.ViewModel.Interfaces;
namespace VECTO3.Util
namespace VECTO3GUI.Util
{
public static class ViewModelFactory
{
......@@ -12,6 +11,7 @@ namespace VECTO3.Util
public static Dictionary<Component, Type> ComponentViewModelMapping = new Dictionary<Component, Type>()
{
{ Component.Vehicle, typeof(IVehicleViewModel)},
{ Component.PrimaryBusVehicle, typeof(IPrimaryVehicleBusViewModel) },
{ Component.Engine ,typeof(IEngineViewModel) },
{ Component.Gearbox ,typeof(IGearboxViewModel) },
{ Component.TorqueConverter ,typeof(ITorqueConverterViewModel) },
......
......@@ -109,6 +109,8 @@
<Compile Include="ViewModel\Impl\MainWindowViewModel.cs" />
<Compile Include="ViewModel\Impl\NoneViewModel.cs" />
<Compile Include="ViewModel\Impl\ObservableObject.cs" />
<Compile Include="ViewModel\Impl\PrimaryVehicleBusJobViewModel.cs" />
<Compile Include="ViewModel\Impl\PrimaryVehicleBusViewModel.cs" />
<Compile Include="ViewModel\Impl\RetarderViewModel.cs" />
<Compile Include="ViewModel\Impl\TorqueConverterViewModel.cs" />
<Compile Include="ViewModel\Impl\TyreViewModel.cs" />
......@@ -134,6 +136,7 @@
<Compile Include="ViewModel\Interfaces\IMainView.cs" />
<Compile Include="ViewModel\Interfaces\IMainWindowViewModel.cs" />
<Compile Include="ViewModel\Interfaces\INoneViewModel.cs" />
<Compile Include="ViewModel\Interfaces\IPrimaryVehicleBusViewModel.cs" />
<Compile Include="ViewModel\Interfaces\IRetarderViewModel.cs" />
<Compile Include="ViewModel\Interfaces\ITorqueConverterViewModel.cs" />
<Compile Include="ViewModel\Interfaces\ITyreViewModel.cs" />
......@@ -169,6 +172,9 @@
<Compile Include="Views\ComponentViews\Declaration\GearboxDeclarationView.xaml.cs">
<DependentUpon>GearboxDeclarationView.xaml</DependentUpon>
</Compile>
<Compile Include="Views\ComponentViews\Declaration\PrimaryVehicleBusView.xaml.cs">
<DependentUpon>PrimaryVehicleBusView.xaml</DependentUpon>
</Compile>
<Compile Include="Views\ComponentViews\Declaration\RetarderDeclarationView.xaml.cs">
<DependentUpon>RetarderDeclarationView.xaml</DependentUpon>
</Compile>
......@@ -305,6 +311,10 @@
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="Views\ComponentViews\Declaration\PrimaryVehicleBusView.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="Views\ComponentViews\Declaration\RetarderDeclarationView.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
......
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using Ninject;
using TUGraz.VectoCommon.InputData;
using TUGraz.VectoCommon.Utils;
using TUGraz.VectoCore.InputData.Reader;
using TUGraz.VectoCore.InputData.Reader.ComponentData;
using TUGraz.VectoCore.Models.SimulationComponent.Data.Engine;
using VECTO3.ViewModel.Interfaces;
using TUGraz.VectoCommon.InputData;
using VECTO3GUI.ViewModel.Interfaces;
namespace VECTO3.ViewModel.Adapter.Declaration
namespace VECTO3GUI.ViewModel.Adapter.Declaration
{
public abstract class AbstractDeclarationAdapter
{
......
......@@ -2,10 +2,9 @@
using TUGraz.VectoCommon.InputData;
using TUGraz.VectoCommon.Models;
using TUGraz.VectoCommon.Utils;
using VECTO3.ViewModel.Impl;
using VECTO3.ViewModel.Interfaces;
using VECTO3GUI.ViewModel.Interfaces;
namespace VECTO3.ViewModel.Adapter.Declaration
namespace VECTO3GUI.ViewModel.Adapter.Declaration
{
public class AirdragDeclarationAdapter : AbstractDeclarationAdapter, IAirdragDeclarationInputData
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment