Курсовая работа: Подсистема управления процессами
using System.Threading;
using System.Windows.Forms;
namespace ProcManager
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
public int index = 0;
private ClassProcManager manager = new ClassProcManager();
private EventWaitHandle wh1 = new AutoResetEvent(true);
private RadioGroup processType;
private RadioGroup processPriority;
private ThreadPriority[] ProcessPriorities = new ThreadPriority[30];
ThreadPriority HighestPriority = ThreadPriority.Lowest;
/// <summary>
/// Возвращаетприоритетпроцесса
/// </summary>
/// <param name="priority">Tag </param>
/// <returns>Объектизперечисления ThreadPriority</returns>
private ThreadPriority IndexToPriority(int priority)
{
switch (priority)
{
case 0: return ThreadPriority.Lowest;
case 1: return ThreadPriority.BelowNormal;
case 2: return ThreadPriority.Normal;