Пример #1
0
 private void ProcessCompletionTime_Tick(object sender, EventArgs e)
 {
     if (Processes.Count == 0)
     {
         if (hardIntStatus.Count != 0)
         {
             textBox4.Text = string.Format("{0}", hardIntStatus.ElementAt(0).Data[hardIntStatus.ElementAt(0).QuantumRunned]);
             do
             {
                 Processes.Add(hardIntStatus.ElementAt(0));
                 hardIntStatus.RemoveAt(0);
             }while (hardIntStatus.Count != 0);
             ReadyQueueTextBoxUpdater();
             textBox3.Text = "HardWare interrupt Handled";
         }
         else
         {
             ProcessCompletionTime.Stop();
         }
     }
     else
     {
         Process temp = Processes.ElementAt(0);
         if (processExecuter(temp))
         {
             Processes.RemoveAt(0);
             Processes.Add(temp);
         }
         else
         {
             Processes.RemoveAt(0);
             ReadyQueueTextBoxUpdater();
         }
     }
 }
Пример #2
0
 private void Exe_Click(object sender, EventArgs e)
 {
     if (!initializeStatus)
     {
         ExcutionInitializer(true);
     }
     CreateProcessExcutionBox(0);
     ProcessCompletionTime.Start();
 }
Пример #3
0
 private void button1_Click(object sender, EventArgs e)
 {
     ProcessCompletionTime.Stop();
     for (int i = 0; i < noOfProcess; i++)
     {
         this.Controls.Remove(labels.ElementAt(0));
         this.Controls.Remove(textBoxes.ElementAt(0));
         textBoxes.RemoveAt(0);
         labels.RemoveAt(0);
     }
     textBox1.Text = "";
     textBox3.Text = "";
     //textBox2.Text = "";
     textBox4.Text = "";
     textBox5.Text = "";
     hardIntStatus.Clear();
     softIntProcess.Clear();
     Size = new Size(717, 262);
 }
Пример #4
0
 private void Exe_Click(object sender, EventArgs e)
 {
     ExcutionInitializer();
     ProcessCompletionTime.Start();
 }