140 lines
3.3 KiB
C#
140 lines
3.3 KiB
C#
|
|
using JiangsuEarthquake.Common;
|
|||
|
|
using JiangsuEarthquake.ViewModels;
|
|||
|
|
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 JiangsuEarthquake.Views
|
|||
|
|
{
|
|||
|
|
/// <summary>
|
|||
|
|
/// SystemControlView.xaml 的交互逻辑
|
|||
|
|
/// </summary>
|
|||
|
|
public partial class SystemControlView : UserControl
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
public SystemControlView()
|
|||
|
|
{
|
|||
|
|
InitializeComponent();
|
|||
|
|
this.DataContext = MainWindow.mainViewModel;
|
|||
|
|
//SYZBTL2.DataContext = MainWindow.mainViewModel;
|
|||
|
|
|
|||
|
|
////串口号赋值
|
|||
|
|
//for (int i = 0; i < Tools.GetSerialPort().Length; i++)
|
|||
|
|
//{
|
|||
|
|
// this.SYZCHK1.Items.Add(Tools.GetSerialPort()[i]);
|
|||
|
|
// this.SYZCHK2.Items.Add(Tools.GetSerialPort()[i]);
|
|||
|
|
//}
|
|||
|
|
|
|||
|
|
////波特率赋值
|
|||
|
|
//string[] btl = new string[] { "2400", "4800", "9600", "19200", "38400", "56000", "115200" };
|
|||
|
|
//for (int i = 0; i < btl.Length; i++)
|
|||
|
|
//{
|
|||
|
|
// this.SYZBTL1.Items.Add(btl[i]);
|
|||
|
|
// this.SYZBTL2.Items.Add(btl[i]);
|
|||
|
|
//}
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
|
|||
|
|
private void Button_MouseEnter(object sender, MouseEventArgs e)
|
|||
|
|
{
|
|||
|
|
Button button = (Button)sender;
|
|||
|
|
if (button != null)
|
|||
|
|
{
|
|||
|
|
button.Background = new SolidColorBrush(Color.FromRgb(50, 101, 143));
|
|||
|
|
}
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void Button_MouseLeave(object sender, MouseEventArgs e)
|
|||
|
|
{
|
|||
|
|
Button button = (Button)sender;
|
|||
|
|
if (button != null)
|
|||
|
|
{
|
|||
|
|
button.Background = Brushes.Transparent;
|
|||
|
|
}
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void SocketButton1_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
|
|||
|
|
private void SocketButton2_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void FTPButton1_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void FTPButton2_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
|
|||
|
|
private void ECCPowerOpenButton_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void ECCPowerCloseButton_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void MainSeisPowerOpenButton_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void MainSeisPowerCloseButton_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void BackupSeisPowerOpenButton_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void BackupSeisPowerCloseButton_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void SeisZeroSetStartButton_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void SeisZeroSetStopButton_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void SeisLevelSetStartButton_Click(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private void Switch_ClickAsync(object sender, RoutedEventArgs e)
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
}
|
|||
|
|
}
|