This commit is contained in:
2026-04-17 14:55:32 -04:00
commit bc3ac1d4c9
18017 changed files with 4371742 additions and 0 deletions

View File

@@ -0,0 +1 @@
12

View File

@@ -0,0 +1 @@
12

View File

@@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("DTS.Viewer.GraphProperties")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("DTS.Viewer.GraphProperties")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2017")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("d076086a-82c6-4c14-a8d6-ce0eea28e3cb")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

View File

@@ -0,0 +1,133 @@
using System;
using System.ComponentModel.Composition;
using System.Windows.Media.Imaging;
using DTS.Common.Interface;
using DTS.Common.Property;
using Microsoft.Practices.Prism.Modularity;
using Microsoft.Practices.Unity;
[assembly: PropertiesName()]
[assembly: PropertiesImage()]
namespace DTS.Common.Property
{
[Export(typeof(IModule))]
[Module(ModuleName = "Property")]
public class PropertyModule : IModule
{
/// <summary>
/// Injected unity container
/// </summary>
private readonly IUnityContainer _unityContainer;
/// <summary>
/// Initializes a new instance of the <see cref="PropertiesModule"/> class.
/// </summary>
/// <param name="unityContainer">Obtained reference of the unity container by using dependency injection.</param>
public PropertyModule(IUnityContainer unityContainer)
{
_unityContainer = unityContainer;
}
public void Initialize()
{
// Register View & View-Model with Unity dependency injection container as a singleton.
_unityContainer.RegisterType<IPropertyView, PropertyView>();
_unityContainer.RegisterType<IPropertyViewModel, PropertyViewModel>();
}
}
/// <summary>
/// Attribute class contains assembly name
/// </summary>
[AttributeUsage(AttributeTargets.Assembly, AllowMultiple = false)]
public class PropertiesNameAttribute : TextAttribute
{
private readonly string _assemblyName;
public PropertiesNameAttribute() : this(null) { }
public PropertiesNameAttribute(string s)
{
_assemblyName = "PropertiesAsssembly";
}
public override string AssemblyName
{
get { return _assemblyName; }
}
public override Type GetAttributeType()
{
return typeof(TextAttribute);
}
public override string GetAssemblyName()
{
return AssemblyName;
}
}
/// <summary>
/// Attribute class contains assembly image and name - used on the Main screen to display available components
/// </summary>
[AttributeUsage(AttributeTargets.Assembly, AllowMultiple = false)]
public class PropertiesImageAttribute : ImageAttribute
{
private BitmapImage _img;
public PropertiesImageAttribute() : this(null) { }
public override BitmapImage AssemblyImage
{
get { _img = AssemblyInfo.GetImage(AssemblyNames.Property.ToString()); return _img; }
}
public PropertiesImageAttribute(string s)
{
_img = AssemblyInfo.GetImage(AssemblyNames.Property.ToString());
}
public override Type GetAttributeType()
{
return typeof(ImageAttribute);
}
public override BitmapImage GetAssemblyImage()
{
return AssemblyImage;
}
public override string GetAssemblyName()
{
return AssemblyName;
}
public override eAssemblyRegion GetAssemblyRegion()
{
return AssemblyRegion;
}
public override string GetAssemblyGroup()
{
return AssemblyGroup;
}
private string _name;
public override string AssemblyName
{
get { _name = AssemblyNames.Property.ToString(); return _name; }
}
private string _group;
public override string AssemblyGroup
{
get { _group = eAssemblyGroups.Viewer.ToString(); return _group; }
}
private eAssemblyRegion _region;
public override eAssemblyRegion AssemblyRegion
{
get { _region = eAssemblyRegion.PropertyRegion; return _region; }
}
}
}

View File

@@ -0,0 +1,47 @@
using System.ComponentModel;
using Xceed.Wpf.Toolkit.PropertyGrid.Attributes;
namespace DTS.Common.Property
{
//http://brianlagunas.com/extended-wpf-toolkitthe-updated-propertygrid/
//https://wpftoolkit.codeplex.com/wikipage?title=PropertyGrid&referringTitle=Home
public class GraphPropertyObject
{
public GraphPropertyObject() { }
#region Display Properties
[Category("Action")]
[DisplayName("Description")]
[Description("This property uses a TextBox as the default editor.")]
public string Description { get; set; }
[Category("Action")]
[DisplayName("Filter")]
[Description("This property uses a TextBox as the default editor.")]
[ItemsSource(typeof(CFCFilterItemSource))]
public string Filter { get; set; }
[Category("Information")]
[DisplayName("Data Flag")]
[Description("This property uses a TextBox as the default editor.")]
public string DataFlag { get; set; }
[Category("Information")]
[DisplayName("Shift T0 (ms)")]
[Description("This property uses a TextBox as the default editor.")]
public double ShiftT0 { get; set; }
[Category("Information")]
[DisplayName("EU Multiplier")]
[Description("This property uses a TextBox as the default editor.")]
public double EuMultiplier { get; set; }
[Category("Information")]
[DisplayName("EU Offset")]
[Description("This property uses a TextBox as the default editor.")]
public double EuOffset { get; set; }
#endregion
}
}

View File

@@ -0,0 +1,15 @@
using DTS.Common.Interface;
namespace DTS.Common.Property
{
/// <summary>
/// Interaction logic for GraphPropertyView.xaml
/// </summary>
public partial class PropertyView : IPropertyView
{
public PropertyView()
{
InitializeComponent();
}
}
}

View File

@@ -0,0 +1,110 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{53D908E1-8F00-4F7A-A313-EE0B6D98BE91}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>DTS.Common.Property</RootNamespace>
<AssemblyName>DTS.Common.Property</AssemblyName>
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<SccProjectName>SAK</SccProjectName>
<SccLocalPath>SAK</SccLocalPath>
<SccAuxPath>SAK</SccAuxPath>
<SccProvider>SAK</SccProvider>
<TargetFrameworkProfile />
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.Expression.Interactions, Version=4.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\DTS.Common\lib\PrismLibrary\Microsoft.Expression.Interactions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Prism, Version=4.0.0.0, Culture=neutral, PublicKeyToken=c8fa4079b73712d6, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\DTS.Common\lib\PrismLibrary\Microsoft.Practices.Prism.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Prism.Interactivity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=c8fa4079b73712d6, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\DTS.Common\lib\PrismLibrary\Microsoft.Practices.Prism.Interactivity.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Prism.UnityExtensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=c8fa4079b73712d6, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\DTS.Common\lib\PrismLibrary\Microsoft.Practices.Prism.UnityExtensions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.ServiceLocation, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\DTS.Common\lib\PrismLibrary\Microsoft.Practices.ServiceLocation.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity, Version=1.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\DTS.Common\lib\PrismLibrary\Microsoft.Practices.Unity.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity.Interception, Version=2.1.505.0, Culture=neutral, PublicKeyToken=6ccbc87945fa0721, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\DTS.Common\lib\PrismLibrary\Microsoft.Practices.Unity.Interception.dll</HintPath>
</Reference>
<Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" />
<Reference Include="System" />
<Reference Include="System.ComponentModel.Composition" />
<Reference Include="System.Core" />
<Reference Include="System.Drawing" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Windows.Interactivity, Version=4.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\DTS.Common\lib\System.Windows.Interactivity.dll</HintPath>
</Reference>
<Reference Include="System.Xaml" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
<Reference Include="WindowsBase" />
<Reference Include="Xceed.Wpf.Toolkit">
<HintPath>..\DTS.Common\lib\Xceed.Wpf.Toolkit\Xceed.Wpf.Toolkit.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="PropertyModule.cs" />
<Compile Include="Model\GraphPropertyObject.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="ViewModel\PropertyViewModel.cs" />
<Compile Include="View\PropertyView.xaml.cs">
<DependentUpon>PropertyView.xaml</DependentUpon>
</Compile>
</ItemGroup>
<ItemGroup>
<Page Include="View\PropertyView.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
</ItemGroup>
<ItemGroup>
<Folder Include="Classes\" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\DTS.Common.Core\DTS.Common.Core.csproj">
<Project>{fab1f470-1574-4301-b56e-d3364aa93679}</Project>
<Name>DTS.Common.Core</Name>
</ProjectReference>
<ProjectReference Include="..\DTS.Common\DTS.Common.csproj">
<Project>{114edc77-f3b5-4576-a91b-40818d503b55}</Project>
<Name>DTS.Common</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<PropertyGroup>
<PostBuildEvent>copy "$(TargetPath)" "$(SolutionDir)..\RunTimeModules\$(TargetFileName)"</PostBuildEvent>
</PropertyGroup>
<!-- 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.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>

View File

@@ -0,0 +1,16 @@
<base:BaseView x:Class="DTS.Common.Property.PropertyView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:toolkit="http://schemas.xceed.com/wpf/xaml/toolkit"
xmlns:base="clr-namespace:DTS.Common.Base;assembly=DTS.Common">
<Grid DataContext="{Binding}">
<StackPanel Orientation="Vertical">
<ScrollViewer VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Hidden" >
<toolkit:PropertyGrid VerticalAlignment="Stretch" MinWidth="250" SelectedObject="{Binding Properties}" />
</ScrollViewer>
<StackPanel Orientation="Horizontal">
<Button ></Button>
</StackPanel>
</StackPanel>
</Grid>
</base:BaseView>

View File

@@ -0,0 +1,146 @@
using System;
using System.ComponentModel;
using System.Threading.Tasks;
using DTS.Common.Base;
using DTS.Common.Events;
using DTS.Common.Interface;
using Microsoft.Practices.Prism.Events;
using Microsoft.Practices.Prism.Interactivity.InteractionRequest;
using Microsoft.Practices.Prism.Regions;
using Microsoft.Practices.Unity;
namespace DTS.Common.Property
{
public class PropertyViewModel : BaseViewModel<IGraphPropertyViewModel>, IPropertyViewModel
{
public IPropertyView View { get; private set; }
private IBaseWindowModel Parent { get; set; }
private IEventAggregator EventAggregator { get; set; }
private new IRegionManager _regionManager;
private IUnityContainer UnityContainer { get; set; }
public InteractionRequest<Notification> NotificationRequest { get; private set; }
public new InteractionRequest<Confirmation> ConfirmationRequest { get; private set; }
public PropertyViewModel(IPropertyView view, IRegionManager regionManager, IEventAggregator eventAggregator, IUnityContainer unityContainer)
: base(regionManager, eventAggregator, unityContainer)
{
View = view;
View.DataContext = this;
NotificationRequest = new InteractionRequest<Notification>();
ConfirmationRequest = new InteractionRequest<Confirmation>();
EventAggregator = eventAggregator;
UnityContainer = unityContainer;
_regionManager = regionManager;
EventAggregator.GetEvent<RaiseNotification>().Subscribe(OnRaiseNotification);
}
#region Methods
/// <summary>
/// Private Event handler for RaiseNotification event.
/// </summary>
private void OnRaiseNotification(NotificationContentEventArgs eventArgsWithTitle)
{
// Notification object expects a NotificationContentEventArgsWithoutTitle object and a Title string.
var eventArgsWithoutTitle = new NotificationContentEventArgs(eventArgsWithTitle.Message, eventArgsWithTitle.MessageDetails, eventArgsWithTitle.Image);
NotificationRequest.Raise(new Notification
{
Content = eventArgsWithoutTitle,
Title = eventArgsWithTitle.Title
});
}
public override void Initialize()
{
}
public override void Initialize(object parameter)
{
Parent = (IBaseWindowModel)parameter;
}
public void Initialize(object parameter, object properties)
{
Parent = (IBaseWindowModel)parameter;
_properties = properties;
}
public override void Activated()
{
throw new NotImplementedException();
}
public override void Cleanup()
{
throw new NotImplementedException();
}
public new Task CleanupAsync()
{
throw new NotImplementedException();
}
public override Task InitializeAsync()
{
throw new NotImplementedException();
}
public override Task InitializeAsync(object parameter)
{
throw new NotImplementedException();
}
#endregion
#region ContextRegion
#endregion
#region Properties
private object _properties;
public object Properties {
get { return _properties; }
set { _properties = value; OnPropertyChanged("Properties"); }
}
///<summary>
///Occurs when a property value changes.
///</summary>
public new event PropertyChangedEventHandler PropertyChanged;
private new void OnPropertyChanged(string propertyName)
{
var eventHandler = PropertyChanged;
if (eventHandler != null)
{
eventHandler(this, new PropertyChangedEventArgs(propertyName));
}
}
/// <summary>
/// Gets the HeaderInfo.
/// </summary>
public string HeaderInfo
{
get { return "Graph Property"; }
}
public new bool IsBusy
{
get { throw new NotImplementedException(); }
set { throw new NotImplementedException(); }
}
public new bool IsDirty
{
get { throw new NotImplementedException(); }
}
#endregion
}
}

Binary file not shown.