重新添加客户端wpf版本项目
This commit is contained in:
@@ -9,7 +9,7 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "软件系统客户端模版
|
|||||||
EndProject
|
EndProject
|
||||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "软件系统服务端模版", "软件系统服务端模版\软件系统服务端模版.csproj", "{2AFB749C-A6CE-4B2A-B02D-4FC7BB8ADA30}"
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "软件系统服务端模版", "软件系统服务端模版\软件系统服务端模版.csproj", "{2AFB749C-A6CE-4B2A-B02D-4FC7BB8ADA30}"
|
||||||
EndProject
|
EndProject
|
||||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "软件系统服务端Wpf", "软件系统服务端Wpf\软件系统服务端Wpf.csproj", "{9B5A13FF-8483-4BB8-B0E7-2CF9A8E01C45}"
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "软件系统客户端Wpf", "软件系统客户端Wpf\软件系统客户端Wpf.csproj", "{DB8977DD-F909-449D-B58E-08B8A6A78F2F}"
|
||||||
EndProject
|
EndProject
|
||||||
Global
|
Global
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
@@ -29,10 +29,10 @@ Global
|
|||||||
{2AFB749C-A6CE-4B2A-B02D-4FC7BB8ADA30}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
{2AFB749C-A6CE-4B2A-B02D-4FC7BB8ADA30}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
{2AFB749C-A6CE-4B2A-B02D-4FC7BB8ADA30}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
{2AFB749C-A6CE-4B2A-B02D-4FC7BB8ADA30}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
{2AFB749C-A6CE-4B2A-B02D-4FC7BB8ADA30}.Release|Any CPU.Build.0 = Release|Any CPU
|
{2AFB749C-A6CE-4B2A-B02D-4FC7BB8ADA30}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
{9B5A13FF-8483-4BB8-B0E7-2CF9A8E01C45}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
{DB8977DD-F909-449D-B58E-08B8A6A78F2F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
{9B5A13FF-8483-4BB8-B0E7-2CF9A8E01C45}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
{DB8977DD-F909-449D-B58E-08B8A6A78F2F}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
{9B5A13FF-8483-4BB8-B0E7-2CF9A8E01C45}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
{DB8977DD-F909-449D-B58E-08B8A6A78F2F}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
{9B5A13FF-8483-4BB8-B0E7-2CF9A8E01C45}.Release|Any CPU.Build.0 = Release|Any CPU
|
{DB8977DD-F909-449D-B58E-08B8A6A78F2F}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
GlobalSection(SolutionProperties) = preSolution
|
GlobalSection(SolutionProperties) = preSolution
|
||||||
HideSolutionNode = FALSE
|
HideSolutionNode = FALSE
|
||||||
|
|||||||
6
软件系统客户端Wpf/App.config
Normal file
6
软件系统客户端Wpf/App.config
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" ?>
|
||||||
|
<configuration>
|
||||||
|
<startup>
|
||||||
|
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
|
||||||
|
</startup>
|
||||||
|
</configuration>
|
||||||
18
软件系统客户端Wpf/App.xaml
Normal file
18
软件系统客户端Wpf/App.xaml
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
<Application x:Class="软件系统客户端Wpf.App"
|
||||||
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
|
xmlns:local="clr-namespace:软件系统客户端Wpf"
|
||||||
|
ShutdownMode="OnExplicitShutdown">
|
||||||
|
<Application.Resources>
|
||||||
|
<ResourceDictionary>
|
||||||
|
<ResourceDictionary.MergedDictionaries>
|
||||||
|
|
||||||
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Light.xaml" />
|
||||||
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Defaults.xaml" />
|
||||||
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignColors;component/Themes/Recommended/Primary/MaterialDesignColor.DeepPurple.xaml" />
|
||||||
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignColors;component/Themes/Recommended/Accent/MaterialDesignColor.Lime.xaml" />
|
||||||
|
|
||||||
|
</ResourceDictionary.MergedDictionaries>
|
||||||
|
</ResourceDictionary>
|
||||||
|
</Application.Resources>
|
||||||
|
</Application>
|
||||||
86
软件系统客户端Wpf/App.xaml.cs
Normal file
86
软件系统客户端Wpf/App.xaml.cs
Normal file
@@ -0,0 +1,86 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Configuration;
|
||||||
|
using System.Data;
|
||||||
|
using System.Diagnostics;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Runtime.InteropServices;
|
||||||
|
using System.Threading;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows;
|
||||||
|
|
||||||
|
namespace 软件系统客户端Wpf
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// App.xaml 的交互逻辑
|
||||||
|
/// </summary>
|
||||||
|
public partial class App : Application
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 指示了应用程序退出时的代码
|
||||||
|
/// </summary>
|
||||||
|
public static int QuitCode { get; set; } = 0;
|
||||||
|
|
||||||
|
|
||||||
|
protected override void OnStartup(StartupEventArgs e)
|
||||||
|
{
|
||||||
|
base.OnStartup(e);
|
||||||
|
//捕获未处理的异常
|
||||||
|
AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException;
|
||||||
|
|
||||||
|
Process process = Process.GetCurrentProcess();
|
||||||
|
//遍历应用程序的同名进程组
|
||||||
|
foreach (Process p in Process.GetProcessesByName(process.ProcessName))
|
||||||
|
{
|
||||||
|
//不是同一进程则关闭刚刚创建的进程
|
||||||
|
if (p.Id != process.Id)
|
||||||
|
{
|
||||||
|
//此处显示原先的窗口需要一定的时间,不然无法显示
|
||||||
|
ShowWindowAsync(p.MainWindowHandle, 9);
|
||||||
|
SetForegroundWindow(p.MainWindowHandle);
|
||||||
|
Thread.Sleep(10);
|
||||||
|
Current.Shutdown();//关闭当前的应用程序
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
P1:
|
||||||
|
LoginWindow lw = new LoginWindow();
|
||||||
|
bool? result = lw.ShowDialog();
|
||||||
|
if (result.Value == true)
|
||||||
|
{
|
||||||
|
MainWindow mw = new MainWindow();
|
||||||
|
MainWindow = mw;
|
||||||
|
|
||||||
|
mw.ShowDialog();
|
||||||
|
if (QuitCode == 1)
|
||||||
|
{
|
||||||
|
//继续显示登录窗口
|
||||||
|
QuitCode = 0;
|
||||||
|
goto P1;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Current.Shutdown();//关闭当前的应用程序
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Environment.Exit(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
[DllImport("User32.dll")]
|
||||||
|
private static extern bool ShowWindowAsync(IntPtr hWnd, int cmdShow);
|
||||||
|
|
||||||
|
[DllImport("User32.dll")]
|
||||||
|
private static extern bool SetForegroundWindow(IntPtr hWnd);
|
||||||
|
}
|
||||||
|
}
|
||||||
85
软件系统客户端Wpf/BasicSupport/UserClient.cs
Normal file
85
软件系统客户端Wpf/BasicSupport/UserClient.cs
Normal file
@@ -0,0 +1,85 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using HslCommunication.Enthernet;
|
||||||
|
using HslCommunication.BasicFramework;
|
||||||
|
using CommonLibrary;
|
||||||
|
|
||||||
|
namespace 软件系统客户端Wpf
|
||||||
|
{
|
||||||
|
|
||||||
|
//====================================================================================================
|
||||||
|
// 模版说明:
|
||||||
|
//====================================================================================================
|
||||||
|
|
||||||
|
|
||||||
|
public class UserClient
|
||||||
|
{
|
||||||
|
public static JsonSettings JsonSettings = new JsonSettings();
|
||||||
|
/// <summary>
|
||||||
|
/// 本软件的当前版本,用来验证更新的关键依据
|
||||||
|
/// </summary>
|
||||||
|
public static SystemVersion CurrentVersion { get; } = new SystemVersion("1.0.0");
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 服务器的IP地址,默认为127.0.0.1,可用于单机调试
|
||||||
|
/// </summary>
|
||||||
|
public static string ServerIp { get; } = "127.0.0.1";
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 所有版本更新信息的对象
|
||||||
|
/// </summary>
|
||||||
|
public static List<VersionInfo> HistoryVersions { get; } = new List<VersionInfo>
|
||||||
|
{
|
||||||
|
//写入所有的历史版本信息,这样就能在更新日志的界面查看到信息
|
||||||
|
new VersionInfo()
|
||||||
|
{
|
||||||
|
VersionNum=new SystemVersion("1.0.0"),
|
||||||
|
ReleaseDate=new DateTime(2017,1,1),//该版本发布的日期
|
||||||
|
UpdateDetails=new StringBuilder("1.本系统第一版本正式发布使用。"+Environment.NewLine+
|
||||||
|
"2.提供了多客户端用时在线的功能。"+Environment.NewLine+
|
||||||
|
"3.需要用户自行添加"),
|
||||||
|
},
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设置或获取系统的公告
|
||||||
|
/// </summary>
|
||||||
|
public static string Announcement { get; set; } = "";
|
||||||
|
/// <summary>
|
||||||
|
/// 当前系统的登录账户
|
||||||
|
/// </summary>
|
||||||
|
public static UserAccount UserAccount { get; set; } = new UserAccount();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 服务器的时间,该时间与服务器同步,每隔10秒钟,防止客户端串改单机时间,可以作为各种时间条件判定
|
||||||
|
/// </summary>
|
||||||
|
public static DateTime DateTimeServer { get; set; } = DateTime.Now;
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 用于访问服务器数据的网络对象类,必须修改这个端口参数,否则运行失败
|
||||||
|
/// </summary>
|
||||||
|
public static Net_Simplify_Client Net_simplify_client = new Net_Simplify_Client(
|
||||||
|
new System.Net.IPEndPoint(System.Net.IPAddress.Parse(ServerIp),
|
||||||
|
CommonLibrary.CommonLibrary.Port_Second_Net))
|
||||||
|
{
|
||||||
|
KeyToken = CommonHeadCode.KeyToken,
|
||||||
|
ConnectTimeout = 5000,
|
||||||
|
};
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 用于使用udp向服务器进行发送即时可丢失数据的对象
|
||||||
|
/// </summary>
|
||||||
|
public static Net_Udp_Client Net_Udp_Client = new Net_Udp_Client(
|
||||||
|
new System.Net.IPEndPoint(System.Net.IPAddress.Parse(ServerIp),
|
||||||
|
CommonLibrary.CommonLibrary.Port_Udp_Server))
|
||||||
|
{
|
||||||
|
KeyToken = CommonHeadCode.KeyToken,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
92
软件系统客户端Wpf/LoginWindow.xaml
Normal file
92
软件系统客户端Wpf/LoginWindow.xaml
Normal file
@@ -0,0 +1,92 @@
|
|||||||
|
<Window x:Class="软件系统客户端Wpf.LoginWindow"
|
||||||
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||||
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||||
|
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
|
||||||
|
mc:Ignorable="d"
|
||||||
|
Title="系统登录" Height="300" Width="500" WindowStartupLocation="CenterScreen" ResizeMode="NoResize" Loaded="Window_Loaded">
|
||||||
|
<Window.Resources>
|
||||||
|
<ResourceDictionary>
|
||||||
|
<ResourceDictionary.MergedDictionaries>
|
||||||
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Button.xaml" />
|
||||||
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.CheckBox.xaml" />
|
||||||
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.ListBox.xaml" />
|
||||||
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.PopupBox.xaml" />
|
||||||
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.RadioButton.xaml" />
|
||||||
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.TextBlock.xaml" />
|
||||||
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.ToggleButton.xaml" />
|
||||||
|
</ResourceDictionary.MergedDictionaries>
|
||||||
|
<Style TargetType="TextBlock" BasedOn="{StaticResource MaterialDesignCaptionTextBlock}" x:Key="Caption">
|
||||||
|
<Setter Property="Opacity" Value=".68"></Setter>
|
||||||
|
</Style>
|
||||||
|
</ResourceDictionary>
|
||||||
|
</Window.Resources>
|
||||||
|
<Grid>
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="*"></RowDefinition>
|
||||||
|
<RowDefinition Height="auto"></RowDefinition>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<StackPanel>
|
||||||
|
<materialDesign:Card Padding="24" Margin="8">
|
||||||
|
<TextBlock x:Name="TextBlockSoftName" TextAlignment="Center" Style="{DynamicResource MaterialDesignTitleTextBlock}">[您的软件系统]</TextBlock>
|
||||||
|
</materialDesign:Card>
|
||||||
|
|
||||||
|
<Grid Margin="100,8,8,8">
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="auto"></RowDefinition>
|
||||||
|
<RowDefinition Height="auto"></RowDefinition>
|
||||||
|
<RowDefinition Height="auto"></RowDefinition>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||||||
|
<ColumnDefinition Width="200"></ColumnDefinition>
|
||||||
|
<ColumnDefinition Width="*"></ColumnDefinition>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<materialDesign:PackIcon Grid.Row="0" Grid.Column="0" Kind="Account" Foreground="{Binding ElementName=NameTextBox, Path=BorderBrush}" />
|
||||||
|
<TextBox Grid.Row="0" Grid.Column="1"
|
||||||
|
x:Name="NameTextBox"
|
||||||
|
materialDesign:HintAssist.Hint="请输入名称">
|
||||||
|
<TextBox.Text>
|
||||||
|
<Binding Path="Name" UpdateSourceTrigger="PropertyChanged">
|
||||||
|
</Binding>
|
||||||
|
</TextBox.Text>
|
||||||
|
</TextBox>
|
||||||
|
<materialDesign:PackIcon Grid.Row="1" Grid.Column="0" Kind="Key" Foreground="{Binding ElementName=PasswordBox, Path=BorderBrush}" HorizontalAlignment="Right" />
|
||||||
|
<PasswordBox Grid.Row="1" Grid.Column="1"
|
||||||
|
x:Name="PasswordBox"
|
||||||
|
materialDesign:HintAssist.Hint="请输入密码" />
|
||||||
|
<Button Grid.Column="2" Grid.RowSpan="2" VerticalAlignment="Center" Style="{StaticResource MaterialDesignRaisedLightButton}" Width="100" Height="35"
|
||||||
|
ToolTip="随便测试下" Click="Button_Click">
|
||||||
|
登录系统
|
||||||
|
</Button>
|
||||||
|
|
||||||
|
</Grid>
|
||||||
|
|
||||||
|
|
||||||
|
<StackPanel Orientation="Horizontal" Margin="100,2,8,8">
|
||||||
|
<ToggleButton Style="{StaticResource MaterialDesignSwitchToggleButton}" VerticalAlignment="Center"
|
||||||
|
ToolTip="向右划可以记住密码" Checked="ToggleButton_Checked" Unchecked="ToggleButton_Unchecked"/>
|
||||||
|
<TextBlock Grid.Column="1" Style="{StaticResource Caption}">是否记住密码</TextBlock>
|
||||||
|
</StackPanel>
|
||||||
|
|
||||||
|
<TextBlock x:Name="WindowToolTip" TextAlignment="Center" Visibility="Hidden" Margin="0,10,0,0" Style="{StaticResource Caption}">正在连接服务器...</TextBlock>
|
||||||
|
</StackPanel>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!--版本号及版权声明-->
|
||||||
|
|
||||||
|
<Grid Grid.Row="1" Margin="8">
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||||||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||||||
|
<ColumnDefinition Width="*"></ColumnDefinition>
|
||||||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<TextBlock Grid.Column="0" Style="{StaticResource Caption}">版本号:</TextBlock>
|
||||||
|
<TextBlock x:Name="TextBlockSoftVersion" Grid.Column="1" Style="{StaticResource Caption}">V1.0.0</TextBlock>
|
||||||
|
<TextBlock x:Name="TextBlockSoftCopyright" Grid.Column="3" Style="{StaticResource Caption}">本软件著作权归某某所有</TextBlock>
|
||||||
|
</Grid>
|
||||||
|
</Grid>
|
||||||
|
</Window>
|
||||||
49
软件系统客户端Wpf/LoginWindow.xaml.cs
Normal file
49
软件系统客户端Wpf/LoginWindow.xaml.cs
Normal file
@@ -0,0 +1,49 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows;
|
||||||
|
using System.Windows.Controls;
|
||||||
|
using System.Windows.Data;
|
||||||
|
using System.Windows.Documents;
|
||||||
|
using System.Windows.Input;
|
||||||
|
using System.Windows.Media;
|
||||||
|
using System.Windows.Media.Imaging;
|
||||||
|
using System.Windows.Shapes;
|
||||||
|
|
||||||
|
namespace 软件系统客户端Wpf
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// LoginWindow.xaml 的交互逻辑
|
||||||
|
/// </summary>
|
||||||
|
public partial class LoginWindow : Window
|
||||||
|
{
|
||||||
|
public LoginWindow()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Button_Click(object sender, RoutedEventArgs e)
|
||||||
|
{
|
||||||
|
this.DialogResult = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void ToggleButton_Checked(object sender, RoutedEventArgs e)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void ToggleButton_Unchecked(object sender, RoutedEventArgs e)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Window_Loaded(object sender, RoutedEventArgs e)
|
||||||
|
{
|
||||||
|
TextBlockSoftName.Text = CommonLibrary.Resource.StringResouce.SoftName;
|
||||||
|
TextBlockSoftVersion.Text = UserClient.CurrentVersion.ToString();
|
||||||
|
TextBlockSoftCopyright.Text = $"本软件著作权归{CommonLibrary.Resource.StringResouce.SoftCopyRight}所有";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
12
软件系统客户端Wpf/MainWindow.xaml
Normal file
12
软件系统客户端Wpf/MainWindow.xaml
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
<Window x:Class="软件系统客户端Wpf.MainWindow"
|
||||||
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||||
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||||
|
xmlns:local="clr-namespace:软件系统客户端Wpf"
|
||||||
|
mc:Ignorable="d"
|
||||||
|
Title="MainWindow" Height="350" Width="525" WindowState="Maximized">
|
||||||
|
<Grid>
|
||||||
|
|
||||||
|
</Grid>
|
||||||
|
</Window>
|
||||||
28
软件系统客户端Wpf/MainWindow.xaml.cs
Normal file
28
软件系统客户端Wpf/MainWindow.xaml.cs
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows;
|
||||||
|
using System.Windows.Controls;
|
||||||
|
using System.Windows.Data;
|
||||||
|
using System.Windows.Documents;
|
||||||
|
using System.Windows.Input;
|
||||||
|
using System.Windows.Media;
|
||||||
|
using System.Windows.Media.Imaging;
|
||||||
|
using System.Windows.Navigation;
|
||||||
|
using System.Windows.Shapes;
|
||||||
|
|
||||||
|
namespace 软件系统客户端Wpf
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// MainWindow.xaml 的交互逻辑
|
||||||
|
/// </summary>
|
||||||
|
public partial class MainWindow : Window
|
||||||
|
{
|
||||||
|
public MainWindow()
|
||||||
|
{
|
||||||
|
InitializeComponent();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
55
软件系统客户端Wpf/Properties/AssemblyInfo.cs
Normal file
55
软件系统客户端Wpf/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
using System.Reflection;
|
||||||
|
using System.Resources;
|
||||||
|
using System.Runtime.CompilerServices;
|
||||||
|
using System.Runtime.InteropServices;
|
||||||
|
using System.Windows;
|
||||||
|
|
||||||
|
// 有关程序集的一般信息由以下
|
||||||
|
// 控制。更改这些特性值可修改
|
||||||
|
// 与程序集关联的信息。
|
||||||
|
[assembly: AssemblyTitle("软件系统客户端Wpf")]
|
||||||
|
[assembly: AssemblyDescription("")]
|
||||||
|
[assembly: AssemblyConfiguration("")]
|
||||||
|
[assembly: AssemblyCompany("")]
|
||||||
|
[assembly: AssemblyProduct("软件系统客户端Wpf")]
|
||||||
|
[assembly: AssemblyCopyright("Copyright © 2017")]
|
||||||
|
[assembly: AssemblyTrademark("")]
|
||||||
|
[assembly: AssemblyCulture("")]
|
||||||
|
|
||||||
|
// 将 ComVisible 设置为 false 会使此程序集中的类型
|
||||||
|
//对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型
|
||||||
|
//请将此类型的 ComVisible 特性设置为 true。
|
||||||
|
[assembly: ComVisible(false)]
|
||||||
|
|
||||||
|
//若要开始生成可本地化的应用程序,请设置
|
||||||
|
//.csproj 文件中的 <UICulture>CultureYouAreCodingWith</UICulture>
|
||||||
|
//例如,如果您在源文件中使用的是美国英语,
|
||||||
|
//使用的是美国英语,请将 <UICulture> 设置为 en-US。 然后取消
|
||||||
|
//对以下 NeutralResourceLanguage 特性的注释。 更新
|
||||||
|
//以下行中的“en-US”以匹配项目文件中的 UICulture 设置。
|
||||||
|
|
||||||
|
//[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.Satellite)]
|
||||||
|
|
||||||
|
|
||||||
|
[assembly: ThemeInfo(
|
||||||
|
ResourceDictionaryLocation.None, //主题特定资源词典所处位置
|
||||||
|
//(未在页面中找到资源时使用,
|
||||||
|
//或应用程序资源字典中找到时使用)
|
||||||
|
ResourceDictionaryLocation.SourceAssembly //常规资源词典所处位置
|
||||||
|
//(未在页面中找到资源时使用,
|
||||||
|
//、应用程序或任何主题专用资源字典中找到时使用)
|
||||||
|
)]
|
||||||
|
|
||||||
|
|
||||||
|
// 程序集的版本信息由下列四个值组成:
|
||||||
|
//
|
||||||
|
// 主版本
|
||||||
|
// 次版本
|
||||||
|
// 生成号
|
||||||
|
// 修订号
|
||||||
|
//
|
||||||
|
// 可以指定所有值,也可以使用以下所示的 "*" 预置版本号和修订号
|
||||||
|
// 方法是按如下所示使用“*”: :
|
||||||
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
[assembly: AssemblyVersion("1.0.0.0")]
|
||||||
|
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||||
71
软件系统客户端Wpf/Properties/Resources.Designer.cs
generated
Normal file
71
软件系统客户端Wpf/Properties/Resources.Designer.cs
generated
Normal file
@@ -0,0 +1,71 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// <auto-generated>
|
||||||
|
// 此代码由工具生成。
|
||||||
|
// 运行时版本: 4.0.30319.42000
|
||||||
|
//
|
||||||
|
// 对此文件的更改可能导致不正确的行为,如果
|
||||||
|
// 重新生成代码,则所做更改将丢失。
|
||||||
|
// </auto-generated>
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
namespace 软件系统客户端Wpf.Properties
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 强类型资源类,用于查找本地化字符串等。
|
||||||
|
/// </summary>
|
||||||
|
// 此类是由 StronglyTypedResourceBuilder
|
||||||
|
// 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
|
||||||
|
// 若要添加或删除成员,请编辑 .ResX 文件,然后重新运行 ResGen
|
||||||
|
// (以 /str 作为命令选项),或重新生成 VS 项目。
|
||||||
|
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
|
||||||
|
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||||
|
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||||
|
internal class Resources
|
||||||
|
{
|
||||||
|
|
||||||
|
private static global::System.Resources.ResourceManager resourceMan;
|
||||||
|
|
||||||
|
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||||
|
|
||||||
|
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||||
|
internal Resources()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 返回此类使用的缓存 ResourceManager 实例。
|
||||||
|
/// </summary>
|
||||||
|
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||||
|
internal static global::System.Resources.ResourceManager ResourceManager
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if ((resourceMan == null))
|
||||||
|
{
|
||||||
|
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("软件系统客户端Wpf.Properties.Resources", typeof(Resources).Assembly);
|
||||||
|
resourceMan = temp;
|
||||||
|
}
|
||||||
|
return resourceMan;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 覆盖当前线程的 CurrentUICulture 属性
|
||||||
|
/// 使用此强类型的资源类的资源查找。
|
||||||
|
/// </summary>
|
||||||
|
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||||
|
internal static global::System.Globalization.CultureInfo Culture
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return resourceCulture;
|
||||||
|
}
|
||||||
|
set
|
||||||
|
{
|
||||||
|
resourceCulture = value;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
117
软件系统客户端Wpf/Properties/Resources.resx
Normal file
117
软件系统客户端Wpf/Properties/Resources.resx
Normal file
@@ -0,0 +1,117 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<root>
|
||||||
|
<!--
|
||||||
|
Microsoft ResX Schema
|
||||||
|
|
||||||
|
Version 2.0
|
||||||
|
|
||||||
|
The primary goals of this format is to allow a simple XML format
|
||||||
|
that is mostly human readable. The generation and parsing of the
|
||||||
|
various data types are done through the TypeConverter classes
|
||||||
|
associated with the data types.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
... ado.net/XML headers & schema ...
|
||||||
|
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||||
|
<resheader name="version">2.0</resheader>
|
||||||
|
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||||
|
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||||
|
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||||
|
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||||
|
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||||
|
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||||
|
</data>
|
||||||
|
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
|
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||||
|
<comment>This is a comment</comment>
|
||||||
|
</data>
|
||||||
|
|
||||||
|
There are any number of "resheader" rows that contain simple
|
||||||
|
name/value pairs.
|
||||||
|
|
||||||
|
Each data row contains a name, and value. The row also contains a
|
||||||
|
type or mimetype. Type corresponds to a .NET class that support
|
||||||
|
text/value conversion through the TypeConverter architecture.
|
||||||
|
Classes that don't support this are serialized and stored with the
|
||||||
|
mimetype set.
|
||||||
|
|
||||||
|
The mimetype is used for serialized objects, and tells the
|
||||||
|
ResXResourceReader how to depersist the object. This is currently not
|
||||||
|
extensible. For a given mimetype the value must be set accordingly:
|
||||||
|
|
||||||
|
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||||
|
that the ResXResourceWriter will generate, however the reader can
|
||||||
|
read any of the formats listed below.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.binary.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Serialization.Formatters.Binary.BinaryFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.soap.base64
|
||||||
|
value : The object must be serialized with
|
||||||
|
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
|
||||||
|
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||||
|
value : The object must be serialized into a byte array
|
||||||
|
: using a System.ComponentModel.TypeConverter
|
||||||
|
: and then encoded with base64 encoding.
|
||||||
|
-->
|
||||||
|
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||||
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:choice maxOccurs="unbounded">
|
||||||
|
<xsd:element name="metadata">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="assembly">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:attribute name="alias" type="xsd:string" />
|
||||||
|
<xsd:attribute name="name" type="xsd:string" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="data">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
|
||||||
|
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||||
|
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
<xsd:element name="resheader">
|
||||||
|
<xsd:complexType>
|
||||||
|
<xsd:sequence>
|
||||||
|
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||||
|
</xsd:sequence>
|
||||||
|
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:choice>
|
||||||
|
</xsd:complexType>
|
||||||
|
</xsd:element>
|
||||||
|
</xsd:schema>
|
||||||
|
<resheader name="resmimetype">
|
||||||
|
<value>text/microsoft-resx</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="version">
|
||||||
|
<value>2.0</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="reader">
|
||||||
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
<resheader name="writer">
|
||||||
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||||
|
</resheader>
|
||||||
|
</root>
|
||||||
30
软件系统客户端Wpf/Properties/Settings.Designer.cs
generated
Normal file
30
软件系统客户端Wpf/Properties/Settings.Designer.cs
generated
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// <auto-generated>
|
||||||
|
// This code was generated by a tool.
|
||||||
|
// Runtime Version:4.0.30319.42000
|
||||||
|
//
|
||||||
|
// Changes to this file may cause incorrect behavior and will be lost if
|
||||||
|
// the code is regenerated.
|
||||||
|
// </auto-generated>
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
namespace 软件系统客户端Wpf.Properties
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||||
|
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")]
|
||||||
|
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
|
||||||
|
{
|
||||||
|
|
||||||
|
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
|
||||||
|
|
||||||
|
public static Settings Default
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return defaultInstance;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
7
软件系统客户端Wpf/Properties/Settings.settings
Normal file
7
软件系统客户端Wpf/Properties/Settings.settings
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?xml version='1.0' encoding='utf-8'?>
|
||||||
|
<SettingsFile xmlns="uri:settings" CurrentProfile="(Default)">
|
||||||
|
<Profiles>
|
||||||
|
<Profile Name="(Default)" />
|
||||||
|
</Profiles>
|
||||||
|
<Settings />
|
||||||
|
</SettingsFile>
|
||||||
6
软件系统客户端Wpf/packages.config
Normal file
6
软件系统客户端Wpf/packages.config
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<packages>
|
||||||
|
<package id="MaterialDesignColors" version="1.1.3" targetFramework="net45" />
|
||||||
|
<package id="MaterialDesignThemes" version="2.3.0.823" targetFramework="net45" />
|
||||||
|
<package id="Newtonsoft.Json" version="10.0.3" targetFramework="net45" />
|
||||||
|
</packages>
|
||||||
120
软件系统客户端Wpf/软件系统客户端Wpf.csproj
Normal file
120
软件系统客户端Wpf/软件系统客户端Wpf.csproj
Normal file
@@ -0,0 +1,120 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Project ToolsVersion="15.0" 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>{DB8977DD-F909-449D-B58E-08B8A6A78F2F}</ProjectGuid>
|
||||||
|
<OutputType>WinExe</OutputType>
|
||||||
|
<RootNamespace>软件系统客户端Wpf</RootNamespace>
|
||||||
|
<AssemblyName>软件系统客户端Wpf</AssemblyName>
|
||||||
|
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
|
||||||
|
<FileAlignment>512</FileAlignment>
|
||||||
|
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
||||||
|
<WarningLevel>4</WarningLevel>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<Optimize>false</Optimize>
|
||||||
|
<OutputPath>bin\Debug\</OutputPath>
|
||||||
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
<WarningLevel>4</WarningLevel>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||||
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<OutputPath>bin\Release\</OutputPath>
|
||||||
|
<DefineConstants>TRACE</DefineConstants>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
<WarningLevel>4</WarningLevel>
|
||||||
|
</PropertyGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Reference Include="CommonLibrary">
|
||||||
|
<HintPath>..\CommonLibrary\bin\Debug\CommonLibrary.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="HslCommunication">
|
||||||
|
<HintPath>..\Public\HslCommunication.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="MaterialDesignColors, Version=1.1.3.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\MaterialDesignColors.1.1.3\lib\net45\MaterialDesignColors.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="MaterialDesignThemes.Wpf, Version=2.3.0.823, Culture=neutral, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\MaterialDesignThemes.2.3.0.823\lib\net45\MaterialDesignThemes.Wpf.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="System" />
|
||||||
|
<Reference Include="System.Data" />
|
||||||
|
<Reference Include="System.Xml" />
|
||||||
|
<Reference Include="Microsoft.CSharp" />
|
||||||
|
<Reference Include="System.Core" />
|
||||||
|
<Reference Include="System.Xml.Linq" />
|
||||||
|
<Reference Include="System.Data.DataSetExtensions" />
|
||||||
|
<Reference Include="System.Net.Http" />
|
||||||
|
<Reference Include="System.Xaml">
|
||||||
|
<RequiredTargetFramework>4.0</RequiredTargetFramework>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="WindowsBase" />
|
||||||
|
<Reference Include="PresentationCore" />
|
||||||
|
<Reference Include="PresentationFramework" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ApplicationDefinition Include="App.xaml">
|
||||||
|
<Generator>MSBuild:Compile</Generator>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</ApplicationDefinition>
|
||||||
|
<Page Include="LoginWindow.xaml">
|
||||||
|
<Generator>MSBuild:Compile</Generator>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</Page>
|
||||||
|
<Page Include="MainWindow.xaml">
|
||||||
|
<Generator>MSBuild:Compile</Generator>
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</Page>
|
||||||
|
<Compile Include="App.xaml.cs">
|
||||||
|
<DependentUpon>App.xaml</DependentUpon>
|
||||||
|
<SubType>Code</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="BasicSupport\UserClient.cs" />
|
||||||
|
<Compile Include="LoginWindow.xaml.cs">
|
||||||
|
<DependentUpon>LoginWindow.xaml</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="MainWindow.xaml.cs">
|
||||||
|
<DependentUpon>MainWindow.xaml</DependentUpon>
|
||||||
|
<SubType>Code</SubType>
|
||||||
|
</Compile>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Compile Include="Properties\AssemblyInfo.cs">
|
||||||
|
<SubType>Code</SubType>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Properties\Resources.Designer.cs">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DesignTime>True</DesignTime>
|
||||||
|
<DependentUpon>Resources.resx</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Properties\Settings.Designer.cs">
|
||||||
|
<AutoGen>True</AutoGen>
|
||||||
|
<DependentUpon>Settings.settings</DependentUpon>
|
||||||
|
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||||
|
</Compile>
|
||||||
|
<EmbeddedResource Include="Properties\Resources.resx">
|
||||||
|
<Generator>ResXFileCodeGenerator</Generator>
|
||||||
|
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
|
||||||
|
</EmbeddedResource>
|
||||||
|
<None Include="packages.config" />
|
||||||
|
<None Include="Properties\Settings.settings">
|
||||||
|
<Generator>SettingsSingleFileGenerator</Generator>
|
||||||
|
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||||
|
</None>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<None Include="App.config" />
|
||||||
|
</ItemGroup>
|
||||||
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
|
</Project>
|
||||||
@@ -1,7 +1,8 @@
|
|||||||
<Application x:Class="软件系统服务端Wpf.App"
|
<Application x:Class="软件系统客户端Wpf.App"
|
||||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
xmlns:local="clr-namespace:软件系统服务端Wpf">
|
xmlns:local="clr-namespace:软件系统客户端Wpf"
|
||||||
|
ShutdownMode="OnExplicitShutdown">
|
||||||
<Application.Resources>
|
<Application.Resources>
|
||||||
<ResourceDictionary>
|
<ResourceDictionary>
|
||||||
<ResourceDictionary.MergedDictionaries>
|
<ResourceDictionary.MergedDictionaries>
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ using System.Threading;
|
|||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using System.Windows;
|
using System.Windows;
|
||||||
|
|
||||||
namespace 软件系统服务端Wpf
|
namespace 软件系统客户端Wpf
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// App.xaml 的交互逻辑
|
/// App.xaml 的交互逻辑
|
||||||
@@ -46,12 +46,13 @@ namespace 软件系统服务端Wpf
|
|||||||
|
|
||||||
|
|
||||||
P1:
|
P1:
|
||||||
|
|
||||||
LoginWindow lw = new LoginWindow();
|
LoginWindow lw = new LoginWindow();
|
||||||
if (lw.ShowDialog().Value == true)
|
bool? result = lw.ShowDialog();
|
||||||
|
if (result.Value == true)
|
||||||
{
|
{
|
||||||
MainWindow mw=new MainWindow();
|
MainWindow mw = new MainWindow();
|
||||||
MainWindow = mw;
|
MainWindow = mw;
|
||||||
|
|
||||||
mw.ShowDialog();
|
mw.ShowDialog();
|
||||||
if (QuitCode == 1)
|
if (QuitCode == 1)
|
||||||
{
|
{
|
||||||
@@ -59,6 +60,10 @@ namespace 软件系统服务端Wpf
|
|||||||
QuitCode = 0;
|
QuitCode = 0;
|
||||||
goto P1;
|
goto P1;
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Current.Shutdown();//关闭当前的应用程序
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -66,6 +71,8 @@ namespace 软件系统服务端Wpf
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e)
|
private void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e)
|
||||||
{
|
{
|
||||||
|
|||||||
85
软件系统服务端Wpf/BasicSupport/UserClient.cs
Normal file
85
软件系统服务端Wpf/BasicSupport/UserClient.cs
Normal file
@@ -0,0 +1,85 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using HslCommunication.Enthernet;
|
||||||
|
using HslCommunication.BasicFramework;
|
||||||
|
using CommonLibrary;
|
||||||
|
|
||||||
|
namespace 软件系统客户端wpf
|
||||||
|
{
|
||||||
|
|
||||||
|
//====================================================================================================
|
||||||
|
// 模版说明:
|
||||||
|
//====================================================================================================
|
||||||
|
|
||||||
|
|
||||||
|
public class UserClient
|
||||||
|
{
|
||||||
|
public static JsonSettings JsonSettings = new JsonSettings();
|
||||||
|
/// <summary>
|
||||||
|
/// 本软件的当前版本,用来验证更新的关键依据
|
||||||
|
/// </summary>
|
||||||
|
public static SystemVersion CurrentVersion { get; } = new SystemVersion("1.0.0");
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 服务器的IP地址,默认为127.0.0.1,可用于单机调试
|
||||||
|
/// </summary>
|
||||||
|
public static string ServerIp { get; } = "127.0.0.1";
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 所有版本更新信息的对象
|
||||||
|
/// </summary>
|
||||||
|
public static List<VersionInfo> HistoryVersions { get; } = new List<VersionInfo>
|
||||||
|
{
|
||||||
|
//写入所有的历史版本信息,这样就能在更新日志的界面查看到信息
|
||||||
|
new VersionInfo()
|
||||||
|
{
|
||||||
|
VersionNum=new SystemVersion("1.0.0"),
|
||||||
|
ReleaseDate=new DateTime(2017,1,1),//该版本发布的日期
|
||||||
|
UpdateDetails=new StringBuilder("1.本系统第一版本正式发布使用。"+Environment.NewLine+
|
||||||
|
"2.提供了多客户端用时在线的功能。"+Environment.NewLine+
|
||||||
|
"3.需要用户自行添加"),
|
||||||
|
},
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设置或获取系统的公告
|
||||||
|
/// </summary>
|
||||||
|
public static string Announcement { get; set; } = "";
|
||||||
|
/// <summary>
|
||||||
|
/// 当前系统的登录账户
|
||||||
|
/// </summary>
|
||||||
|
public static UserAccount UserAccount { get; set; } = new UserAccount();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 服务器的时间,该时间与服务器同步,每隔10秒钟,防止客户端串改单机时间,可以作为各种时间条件判定
|
||||||
|
/// </summary>
|
||||||
|
public static DateTime DateTimeServer { get; set; } = DateTime.Now;
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 用于访问服务器数据的网络对象类,必须修改这个端口参数,否则运行失败
|
||||||
|
/// </summary>
|
||||||
|
public static Net_Simplify_Client Net_simplify_client = new Net_Simplify_Client(
|
||||||
|
new System.Net.IPEndPoint(System.Net.IPAddress.Parse(ServerIp),
|
||||||
|
CommonLibrary.CommonLibrary.Port_Second_Net))
|
||||||
|
{
|
||||||
|
KeyToken = CommonHeadCode.KeyToken,
|
||||||
|
ConnectTimeout = 5000,
|
||||||
|
};
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 用于使用udp向服务器进行发送即时可丢失数据的对象
|
||||||
|
/// </summary>
|
||||||
|
public static Net_Udp_Client Net_Udp_Client = new Net_Udp_Client(
|
||||||
|
new System.Net.IPEndPoint(System.Net.IPAddress.Parse(ServerIp),
|
||||||
|
CommonLibrary.CommonLibrary.Port_Udp_Server))
|
||||||
|
{
|
||||||
|
KeyToken = CommonHeadCode.KeyToken,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,10 +1,11 @@
|
|||||||
<Window x:Class="软件系统服务端Wpf.LoginWindow"
|
<Window x:Class="软件系统客户端Wpf.LoginWindow"
|
||||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||||
|
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
|
||||||
mc:Ignorable="d"
|
mc:Ignorable="d"
|
||||||
Title="LoginWindow" Height="300" Width="500" WindowStartupLocation="CenterScreen">
|
Title="系统登录" Height="300" Width="500" WindowStartupLocation="CenterScreen" ResizeMode="NoResize" Loaded="Window_Loaded">
|
||||||
<Window.Resources>
|
<Window.Resources>
|
||||||
<ResourceDictionary>
|
<ResourceDictionary>
|
||||||
<ResourceDictionary.MergedDictionaries>
|
<ResourceDictionary.MergedDictionaries>
|
||||||
@@ -16,14 +17,76 @@
|
|||||||
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.TextBlock.xaml" />
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.TextBlock.xaml" />
|
||||||
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.ToggleButton.xaml" />
|
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.ToggleButton.xaml" />
|
||||||
</ResourceDictionary.MergedDictionaries>
|
</ResourceDictionary.MergedDictionaries>
|
||||||
|
<Style TargetType="TextBlock" BasedOn="{StaticResource MaterialDesignCaptionTextBlock}" x:Key="Caption">
|
||||||
|
<Setter Property="Opacity" Value=".68"></Setter>
|
||||||
|
</Style>
|
||||||
</ResourceDictionary>
|
</ResourceDictionary>
|
||||||
</Window.Resources>
|
</Window.Resources>
|
||||||
<Grid>
|
<Grid>
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="*"></RowDefinition>
|
||||||
|
<RowDefinition Height="auto"></RowDefinition>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
<StackPanel>
|
<StackPanel>
|
||||||
<Button Style="{StaticResource MaterialDesignRaisedLightButton}" Margin="0 12 8 0" Width="100"
|
<materialDesign:Card Padding="24" Margin="8">
|
||||||
|
<TextBlock x:Name="TextBlockSoftName" TextAlignment="Center" Style="{DynamicResource MaterialDesignTitleTextBlock}">[您的软件系统]</TextBlock>
|
||||||
|
</materialDesign:Card>
|
||||||
|
|
||||||
|
<Grid Margin="100,8,8,8">
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="auto"></RowDefinition>
|
||||||
|
<RowDefinition Height="auto"></RowDefinition>
|
||||||
|
<RowDefinition Height="auto"></RowDefinition>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||||||
|
<ColumnDefinition Width="200"></ColumnDefinition>
|
||||||
|
<ColumnDefinition Width="*"></ColumnDefinition>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<materialDesign:PackIcon Grid.Row="0" Grid.Column="0" Kind="Account" Foreground="{Binding ElementName=NameTextBox, Path=BorderBrush}" />
|
||||||
|
<TextBox Grid.Row="0" Grid.Column="1"
|
||||||
|
x:Name="NameTextBox"
|
||||||
|
materialDesign:HintAssist.Hint="请输入名称">
|
||||||
|
<TextBox.Text>
|
||||||
|
<Binding Path="Name" UpdateSourceTrigger="PropertyChanged">
|
||||||
|
</Binding>
|
||||||
|
</TextBox.Text>
|
||||||
|
</TextBox>
|
||||||
|
<materialDesign:PackIcon Grid.Row="1" Grid.Column="0" Kind="Key" Foreground="{Binding ElementName=PasswordBox, Path=BorderBrush}" HorizontalAlignment="Right" />
|
||||||
|
<PasswordBox Grid.Row="1" Grid.Column="1"
|
||||||
|
x:Name="PasswordBox"
|
||||||
|
materialDesign:HintAssist.Hint="请输入密码" />
|
||||||
|
<Button Grid.Column="2" Grid.RowSpan="2" VerticalAlignment="Center" Style="{StaticResource MaterialDesignRaisedLightButton}" Width="100" Height="35"
|
||||||
ToolTip="随便测试下" Click="Button_Click">
|
ToolTip="随便测试下" Click="Button_Click">
|
||||||
点击进入
|
登录系统
|
||||||
</Button>
|
</Button>
|
||||||
|
|
||||||
|
</Grid>
|
||||||
|
|
||||||
|
|
||||||
|
<StackPanel Orientation="Horizontal" Margin="100,2,8,8">
|
||||||
|
<ToggleButton Style="{StaticResource MaterialDesignSwitchToggleButton}" VerticalAlignment="Center"
|
||||||
|
ToolTip="向右划可以记住密码" Checked="ToggleButton_Checked" Unchecked="ToggleButton_Unchecked"/>
|
||||||
|
<TextBlock Grid.Column="1" Style="{StaticResource Caption}">是否记住密码</TextBlock>
|
||||||
|
</StackPanel>
|
||||||
|
|
||||||
|
<TextBlock x:Name="WindowToolTip" TextAlignment="Center" Visibility="Hidden" Margin="0,10,0,0" Style="{StaticResource Caption}">正在连接服务器...</TextBlock>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!--版本号及版权声明-->
|
||||||
|
|
||||||
|
<Grid Grid.Row="1" Margin="8">
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||||||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||||||
|
<ColumnDefinition Width="*"></ColumnDefinition>
|
||||||
|
<ColumnDefinition Width="auto"></ColumnDefinition>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<TextBlock Grid.Column="0" Style="{StaticResource Caption}">版本号:</TextBlock>
|
||||||
|
<TextBlock x:Name="TextBlockSoftVersion" Grid.Column="1" Style="{StaticResource Caption}">V1.0.0</TextBlock>
|
||||||
|
<TextBlock x:Name="TextBlockSoftCopyright" Grid.Column="3" Style="{StaticResource Caption}">本软件著作权归某某所有</TextBlock>
|
||||||
|
</Grid>
|
||||||
</Grid>
|
</Grid>
|
||||||
</Window>
|
</Window>
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ using System.Windows.Media;
|
|||||||
using System.Windows.Media.Imaging;
|
using System.Windows.Media.Imaging;
|
||||||
using System.Windows.Shapes;
|
using System.Windows.Shapes;
|
||||||
|
|
||||||
namespace 软件系统服务端Wpf
|
namespace 软件系统客户端Wpf
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// LoginWindow.xaml 的交互逻辑
|
/// LoginWindow.xaml 的交互逻辑
|
||||||
@@ -28,5 +28,21 @@ namespace 软件系统服务端Wpf
|
|||||||
{
|
{
|
||||||
this.DialogResult = true;
|
this.DialogResult = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void ToggleButton_Checked(object sender, RoutedEventArgs e)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void ToggleButton_Unchecked(object sender, RoutedEventArgs e)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Window_Loaded(object sender, RoutedEventArgs e)
|
||||||
|
{
|
||||||
|
TextBlockSoftName.Text = CommonLibrary.Resource.StringResouce.SoftName;
|
||||||
|
TextBlockSoftVersion.Text=
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
<Window x:Class="软件系统服务端Wpf.MainWindow"
|
<Window x:Class="软件系统客户端Wpf.MainWindow"
|
||||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||||
xmlns:local="clr-namespace:软件系统服务端Wpf"
|
xmlns:local="clr-namespace:软件系统客户端Wpf"
|
||||||
mc:Ignorable="d"
|
mc:Ignorable="d"
|
||||||
Title="MainWindow" Height="350" Width="525">
|
Title="MainWindow" Height="350" Width="525" WindowState="Maximized">
|
||||||
<Grid>
|
<Grid>
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ using System.Windows.Media.Imaging;
|
|||||||
using System.Windows.Navigation;
|
using System.Windows.Navigation;
|
||||||
using System.Windows.Shapes;
|
using System.Windows.Shapes;
|
||||||
|
|
||||||
namespace 软件系统服务端Wpf
|
namespace 软件系统客户端Wpf
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// MainWindow.xaml 的交互逻辑
|
/// MainWindow.xaml 的交互逻辑
|
||||||
|
|||||||
@@ -7,11 +7,11 @@ using System.Windows;
|
|||||||
// 有关程序集的一般信息由以下
|
// 有关程序集的一般信息由以下
|
||||||
// 控制。更改这些特性值可修改
|
// 控制。更改这些特性值可修改
|
||||||
// 与程序集关联的信息。
|
// 与程序集关联的信息。
|
||||||
[assembly: AssemblyTitle("软件系统服务端Wpf")]
|
[assembly: AssemblyTitle("软件系统客户端Wpf")]
|
||||||
[assembly: AssemblyDescription("")]
|
[assembly: AssemblyDescription("")]
|
||||||
[assembly: AssemblyConfiguration("")]
|
[assembly: AssemblyConfiguration("")]
|
||||||
[assembly: AssemblyCompany("")]
|
[assembly: AssemblyCompany("")]
|
||||||
[assembly: AssemblyProduct("软件系统服务端Wpf")]
|
[assembly: AssemblyProduct("软件系统客户端Wpf")]
|
||||||
[assembly: AssemblyCopyright("Copyright © 2017")]
|
[assembly: AssemblyCopyright("Copyright © 2017")]
|
||||||
[assembly: AssemblyTrademark("")]
|
[assembly: AssemblyTrademark("")]
|
||||||
[assembly: AssemblyCulture("")]
|
[assembly: AssemblyCulture("")]
|
||||||
|
|||||||
60
软件系统服务端Wpf/Properties/Resources.Designer.cs
generated
60
软件系统服务端Wpf/Properties/Resources.Designer.cs
generated
@@ -1,69 +1,61 @@
|
|||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
// <auto-generated>
|
// <auto-generated>
|
||||||
// 此代码由工具生成。
|
// 此代码由工具生成。
|
||||||
// 运行时版本: 4.0.30319.42000
|
// 运行时版本:4.0.30319.42000
|
||||||
//
|
//
|
||||||
// 对此文件的更改可能导致不正确的行为,如果
|
// 对此文件的更改可能会导致不正确的行为,并且如果
|
||||||
// 重新生成代码,则所做更改将丢失。
|
// 重新生成代码,这些更改将会丢失。
|
||||||
// </auto-generated>
|
// </auto-generated>
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
namespace 软件系统服务端Wpf.Properties
|
namespace 软件系统客户端Wpf.Properties {
|
||||||
{
|
using System;
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 强类型资源类,用于查找本地化字符串等。
|
/// 一个强类型的资源类,用于查找本地化的字符串等。
|
||||||
/// </summary>
|
/// </summary>
|
||||||
// 此类是由 StronglyTypedResourceBuilder
|
// 此类是由 StronglyTypedResourceBuilder
|
||||||
// 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
|
// 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
|
||||||
// 若要添加或删除成员,请编辑 .ResX 文件,然后重新运行 ResGen
|
// 若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen
|
||||||
// (以 /str 作为命令选项),或重新生成 VS 项目。
|
// (以 /str 作为命令选项),或重新生成 VS 项目。
|
||||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
|
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
|
||||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||||
internal class Resources
|
internal class Resources {
|
||||||
{
|
|
||||||
|
|
||||||
private static global::System.Resources.ResourceManager resourceMan;
|
private static global::System.Resources.ResourceManager resourceMan;
|
||||||
|
|
||||||
private static global::System.Globalization.CultureInfo resourceCulture;
|
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||||
|
|
||||||
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||||
internal Resources()
|
internal Resources() {
|
||||||
{
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 返回此类使用的缓存 ResourceManager 实例。
|
/// 返回此类使用的缓存的 ResourceManager 实例。
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||||
internal static global::System.Resources.ResourceManager ResourceManager
|
internal static global::System.Resources.ResourceManager ResourceManager {
|
||||||
{
|
get {
|
||||||
get
|
if (object.ReferenceEquals(resourceMan, null)) {
|
||||||
{
|
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("软件系统客户端Wpf.Properties.Resources", typeof(Resources).Assembly);
|
||||||
if ((resourceMan == null))
|
|
||||||
{
|
|
||||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("软件系统服务端Wpf.Properties.Resources", typeof(Resources).Assembly);
|
|
||||||
resourceMan = temp;
|
resourceMan = temp;
|
||||||
}
|
}
|
||||||
return resourceMan;
|
return resourceMan;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 覆盖当前线程的 CurrentUICulture 属性
|
/// 使用此强类型资源类,为所有资源查找
|
||||||
/// 使用此强类型的资源类的资源查找。
|
/// 重写当前线程的 CurrentUICulture 属性。
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||||
internal static global::System.Globalization.CultureInfo Culture
|
internal static global::System.Globalization.CultureInfo Culture {
|
||||||
{
|
get {
|
||||||
get
|
|
||||||
{
|
|
||||||
return resourceCulture;
|
return resourceCulture;
|
||||||
}
|
}
|
||||||
set
|
set {
|
||||||
{
|
|
||||||
resourceCulture = value;
|
resourceCulture = value;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
30
软件系统服务端Wpf/Properties/Settings.Designer.cs
generated
30
软件系统服务端Wpf/Properties/Settings.Designer.cs
generated
@@ -1,28 +1,24 @@
|
|||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
// <auto-generated>
|
// <auto-generated>
|
||||||
// This code was generated by a tool.
|
// 此代码由工具生成。
|
||||||
// Runtime Version:4.0.30319.42000
|
// 运行时版本:4.0.30319.42000
|
||||||
//
|
//
|
||||||
// Changes to this file may cause incorrect behavior and will be lost if
|
// 对此文件的更改可能会导致不正确的行为,并且如果
|
||||||
// the code is regenerated.
|
// 重新生成代码,这些更改将会丢失。
|
||||||
// </auto-generated>
|
// </auto-generated>
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
namespace 软件系统服务端Wpf.Properties
|
namespace 软件系统客户端Wpf.Properties {
|
||||||
{
|
|
||||||
|
|
||||||
|
|
||||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")]
|
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.1.0.0")]
|
||||||
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
|
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
|
||||||
{
|
|
||||||
|
|
||||||
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
|
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
|
||||||
|
|
||||||
public static Settings Default
|
public static Settings Default {
|
||||||
{
|
get {
|
||||||
get
|
|
||||||
{
|
|
||||||
return defaultInstance;
|
return defaultInstance;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,8 +6,8 @@
|
|||||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||||
<ProjectGuid>{9B5A13FF-8483-4BB8-B0E7-2CF9A8E01C45}</ProjectGuid>
|
<ProjectGuid>{9B5A13FF-8483-4BB8-B0E7-2CF9A8E01C45}</ProjectGuid>
|
||||||
<OutputType>WinExe</OutputType>
|
<OutputType>WinExe</OutputType>
|
||||||
<RootNamespace>软件系统服务端Wpf</RootNamespace>
|
<RootNamespace>软件系统客户端Wpf</RootNamespace>
|
||||||
<AssemblyName>软件系统服务端Wpf</AssemblyName>
|
<AssemblyName>软件系统客户端Wpf</AssemblyName>
|
||||||
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
|
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
|
||||||
<FileAlignment>512</FileAlignment>
|
<FileAlignment>512</FileAlignment>
|
||||||
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
||||||
@@ -33,12 +33,21 @@
|
|||||||
<WarningLevel>4</WarningLevel>
|
<WarningLevel>4</WarningLevel>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<Reference Include="CommonLibrary">
|
||||||
|
<HintPath>..\CommonLibrary\bin\Debug\CommonLibrary.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="HslCommunication">
|
||||||
|
<HintPath>..\Public\HslCommunication.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
<Reference Include="MaterialDesignColors, Version=1.1.3.0, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="MaterialDesignColors, Version=1.1.3.0, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\MaterialDesignColors.1.1.3\lib\net45\MaterialDesignColors.dll</HintPath>
|
<HintPath>..\packages\MaterialDesignColors.1.1.3\lib\net45\MaterialDesignColors.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="MaterialDesignThemes.Wpf, Version=2.3.0.823, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="MaterialDesignThemes.Wpf, Version=2.3.0.823, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\MaterialDesignThemes.2.3.0.823\lib\net45\MaterialDesignThemes.Wpf.dll</HintPath>
|
<HintPath>..\packages\MaterialDesignThemes.2.3.0.823\lib\net45\MaterialDesignThemes.Wpf.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
|
<Reference Include="Newtonsoft.Json">
|
||||||
|
<HintPath>..\Public\Newtonsoft.Json.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Data" />
|
<Reference Include="System.Data" />
|
||||||
<Reference Include="System.Xml" />
|
<Reference Include="System.Xml" />
|
||||||
@@ -71,6 +80,7 @@
|
|||||||
<DependentUpon>App.xaml</DependentUpon>
|
<DependentUpon>App.xaml</DependentUpon>
|
||||||
<SubType>Code</SubType>
|
<SubType>Code</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="BasicSupport\UserClient.cs" />
|
||||||
<Compile Include="LoginWindow.xaml.cs">
|
<Compile Include="LoginWindow.xaml.cs">
|
||||||
<DependentUpon>LoginWindow.xaml</DependentUpon>
|
<DependentUpon>LoginWindow.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
@@ -104,7 +114,10 @@
|
|||||||
</None>
|
</None>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<None Include="App.config" />
|
<None Include="App.config">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
</None>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
<ItemGroup />
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
</Project>
|
</Project>
|
||||||
Reference in New Issue
Block a user