Example #1
0
 static void Main()
 {
     Application.EnableVisualStyles();
     Application.SetCompatibleTextRenderingDefault(false);
     try {
         Application.Run(new ExclusiveForm());
     } catch (Exception e) {
         CurlingMessageBox.Show(string.Format("Error \"{0}\" was detected", e.Message), "Exception Detected", Properties.Resources.Alert);
     }
 }
Example #2
0
        public static int Show(string stMessage, string stTitle, Stream soundStream)
        {
            CurlingMessageBox cm = new CurlingMessageBox();

            cm.textBoxText.Text = stMessage;
            cm.Text             = stTitle;
            TimerUtil.PlaySound(soundStream);
            cm.ShowDialog();
            return(0);
        }
Example #3
0
        private void ProcessTimeOutDuringEndEvents()
        {
            pbTeam1Status.Image     = ResGraphic.YellowDot;
            pbTeam2Status.Image     = ResGraphic.YellowDot;
            textBoxTOLeftTeam1.Text = m_timeOutLeftTeam1.ToString();
            textBoxTOLeftTeam2.Text = m_timeOutLeftTeam2.ToString();
//			Opacity = .50;
//			Refresh();
//			{
//			}
            CurlingMessageBox.Show("Press OK when the umpire signals start", "Waiting", Properties.Resources.StartAgain);
//			ChronometerForm f = new ChronometerForm(new TimeSpan(0, 0, 1, 0));
//			f.ShowDialog();
//			Opacity = 1.0;
            Refresh();
            m_rockCount--;
            m_stateMachine.Send((int)CurlingTimmerStateMachine.EventID.StartTiming);
        }
Example #4
0
 private void SendStartTiming()
 {
     KeyPress           -= new System.Windows.Forms.KeyPressEventHandler(this.Form1_KeyPress);
     buttonTimeIn.Click -= new System.EventHandler(this.buttonTimeIn_Click);
     backgroundWorker2.RunWorkerAsync();
     if (radioButtonTeam1.Checked || radioButtonTeam2.Checked)
     {
         optionsToolStripMenuItem.Enabled    = false;
         stopTimingToolStripMenuItem.Enabled = true;
         if (m_stateMachine == null)
         {
             SetHammer();
         }
         SetCursorPos(0, 0);
         TimerUtil.TraceAndDebugMessage("Sending StartTiming Event to state machine", 1);
         m_stateMachine.Send((int)CurlingTimmerStateMachine.EventID.StartTiming, null);
     }
     else
     {
         CurlingMessageBox.Show("Please select the team throwing the last rock", "Operator error", Properties.Resources.SelectLastRock);
     }
 }