本文整理汇总了C#中tscui.Models.System类的典型用法代码示例。如果您正苦于以下问题:C# System类的具体用法?C# System怎么用?C# System使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
System类属于tscui.Models命名空间,在下文中一共展示了System类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: btnRead_Click
private void btnRead_Click(object sender, System.Windows.RoutedEventArgs e)
{
List<Plan> lp = t.ListPlan;
foreach(Plan p in lp)
{
Console.WriteLine(p.usMonthFlag);
}
}
示例2: splLog_Loaded
private void splLog_Loaded(object sender, System.Windows.RoutedEventArgs e)
{
//<SnippetListViewView>
myListView = new ListView();
//<SnippetGridViewColumn>
//<SnippetGridViewAllowsColumnReorder>
myGridView = new GridView();
myGridView.AllowsColumnReorder = true;
myGridView.ColumnHeaderToolTip = "日志信息";
//</SnippetGridViewAllowsColumnReorder>
//<SnippetGridViewColumnProperties>
GridViewColumn gvc1 = new GridViewColumn();
gvc1.DisplayMemberBinding = new Binding("ucEventId");
gvc1.Header = "日志编号";
gvc1.Width = 30;
//</SnippetGridViewColumnProperties>
myGridView.Columns.Add(gvc1);
GridViewColumn gvc2 = new GridViewColumn();
gvc2.DisplayMemberBinding = new Binding("sEventType");
gvc2.Header = "日志类型";
gvc2.Width = 100;
myGridView.Columns.Add(gvc2);
//<SnippetAddToColumns>
GridViewColumn gvc3 = new GridViewColumn();
gvc3.DisplayMemberBinding = new Binding("ulEventTime");
gvc3.Header = "日期时间";
gvc3.Width = 120;
myGridView.Columns.Add(gvc3);
GridViewColumn gvc4 = new GridViewColumn();
gvc4.DisplayMemberBinding = new Binding("sEventDesc");
gvc4.Header = "日志内容";
gvc4.Width = 700;
myGridView.Columns.Add(gvc4);
//</SnippetAddToColumns>
//</SnippetGridViewColumn>
//ItemsSource is ObservableCollection of EmployeeInfo objects
//myListView.ItemsSource = new myTscs();
//Thread thread = new Thread();
myListView.View = myGridView;
myListView.Height = 550;
// myListView.
splLog.Children.Add(myListView);
TscData td = (TscData)Application.Current.Properties[Define.TSC_DATA];
if (td == null)
{
MessageBox.Show("请选择一台信号机后,打开此界面!");
}
else
{
myListView.ItemsSource = td.ListEventLog;
}
}
示例3: Allday_Unchecked
private void Allday_Unchecked(object sender, System.Windows.RoutedEventArgs e)
{
Monday.IsChecked = false;
Thursday.IsChecked = false;
Tuesday.IsChecked = false;
Wednesday.IsChecked = false;
Friday.IsChecked = false;
Saturday.IsChecked = false;
Sunday.IsChecked = false;
}
示例4: UserControl_Loaded
private void UserControl_Loaded(object sender, System.Windows.RoutedEventArgs e)
{
TscData t = Utils.Utils.GetTscDataByApplicationCurrentProperties();
if (t == null)
{
MessageBox.Show("请选择一台信号机,以便进行配置!");
return;
}
ObservableCollection<CntDownDev> occdd = new ObservableCollection<CntDownDev>(t.ListCntDownDev);
dgdVariableSign.ItemsSource = occdd;
}
示例5: Button_Click
private void Button_Click(object sender, System.Windows.RoutedEventArgs e)
{
OpenFileDialog dialog = new OpenFileDialog();
dialog.Filter = "Tsc Program(*.aiton)|*.aiton";
dialog.Multiselect = false;
//TextBox tb = sender as TextBox;
if (dialog.ShowDialog() == true)
{
tbxFileName.Text = dialog.FileName;
}
}
示例6: Button_Click_1
private void Button_Click_1(object sender, System.Windows.RoutedEventArgs e)
{
t = Utils.Utils.GetTscDataByApplicationCurrentProperties();
Udp.sendUdpNoReciveData(t.Node.sIpAddress, t.Node.iPort, Define.UPDATE_TSC_START);
Thread.Sleep(500);
int result = FtpHelper.UploadFtp(tbxFileName.Text, t.Node.sIpAddress, Define.FTP_NAME, Define.FTP_PASSWD);
Thread.Sleep(500);
if(result == 0)
{
Udp.sendUdpNoReciveData(t.Node.sIpAddress, t.Node.iPort, Define.UPDATE_TSC_FINISH);
MessageBox.Show("升级成功!");
}
else if (result == -2)
{
//升级失败后,不要发送完成指令
//Udp.sendUdpNoReciveData(t.Node.sIpAddress, t.Node.iPort, Define.UPDATE_TSC_FINISH);
MessageBox.Show("上传失败");
}
}
示例7: ScrollViewer_MouseDoubleClick
/// <summary>
/// 双击,创建新的stage
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void ScrollViewer_MouseDoubleClick(object sender, System.Windows.Input.MouseButtonEventArgs e)
{
//MessageBox.Show("addd stage");
if (lsi[0] != stage1)
{
lsi.Reverse();
}
foreach(StageItem si in lsi)
{
if (si.Visibility == Visibility.Hidden)
{
si.Visibility = Visibility.Visible;
createStageByInitArllowRed(si);
break;
}
}
}
示例8: ScrollViewer_MouseRightButtonDown
private void ScrollViewer_MouseRightButtonDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
{
// MessageBox.Show("del stage");
TscData t = Utils.Utils.GetTscDataByApplicationCurrentProperties();
if (lsi[0] == stage1)
{
lsi.Reverse();
}
foreach(StageItem si in lsi)
{
if (si.Visibility == Visibility.Visible)
{
si.Visibility = Visibility.Hidden;
clearStageByDeleteStage(t,si);
bigMapInitArllowRed();
break;
}
}
}
示例9: sldScheduleId_ValueChanged
private void sldScheduleId_ValueChanged(object sender, System.Windows.RoutedPropertyChangedEventArgs<double> e)
{
t = Utils.Utils.GetTscDataByApplicationCurrentProperties();
scheduleDataGrid.ItemsSource = initSchedule2DataGrid(t.ListSchedule);
}
示例10: Allday_IsEnabledChanged
private void Allday_IsEnabledChanged(object sender, System.Windows.DependencyPropertyChangedEventArgs e)
{
}
示例11: UserControl_Loaded
private void UserControl_Loaded(object sender, System.Windows.RoutedEventArgs e)
{
try
{
td = (TscData)Application.Current.Properties[Define.TSC_DATA];
initScheduleId();
if (td == null)
{
return;
}
List<Plan> lp = td.ListPlan;
foreach(Plan p in lp)
{
//如果没有数据不会进入
if (p.ucId>=21 && p.ucId <=30)
{
///Summer.IsChecked = true;
lbxPlanId.Items.Add(p.ucId);
//initWeekdayDisplay(p.ucWeekFlag);
}
}
cbxScheduleId.SelectedItem = (byte)1;
}
catch(Exception ex)
{
//MessageBox.Show(ex.ToString());
//ApexBroker.GetShell().ShowPopup(new FailePopup());
}
}
示例12: collision6_MouseDown
private void collision6_MouseDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
{
currentCollision = collision6;
BigMap4SmallMap(currentCollision);
}
示例13: southOther_MouseRightButtonDown
private void southOther_MouseRightButtonDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
{
if (currentCollision == null)
{
MessageBox.Show("请选择一个冲突相位,以便进行设置!");
return;
}
List<PhaseToDirec> lptd = t.ListPhaseToDirec;
List<tscui.Models.Collision> lc = t.ListCollision;
foreach (PhaseToDirec ptd in lptd)
{
if (ptd.ucId == Define.SOUTH_OTHER)
{
//ptd.ucPhase;
byte collisionId = Convert.ToByte(currentCollision.lblId.Content);
foreach (tscui.Models.Collision c in lc)
{
if (collisionId == c.ucPhaseId)
{
collisionFlagResetPhaseBit(c, ptd);
Console.WriteLine(c.ucCollisionFlag);
}
}
}
}
currentCollision.southOther.Source = new BitmapImage(new Uri("/tscui;component/Resources/Images/nolight.png", UriKind.Relative));
southOther.Source = new BitmapImage(new Uri("/tscui;component/Resources/Images/nolight.png", UriKind.Relative));
}
示例14: westStraight_MouseDown
private void westStraight_MouseDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
{
}
示例15: stage16_MouseDown
private void stage16_MouseDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
{
currentStage = stage16;
smallMap4Form(currentStage);
BigMap4SmallMap(currentStage); //MessageBox.Show("stage1");
}