Ejemplo n.º 1
0
        private void OnProcessStarted(object sender, ProcessEventArgs e)
        {
            // Note that it is possible (but unlikely) that we already have an entry for
            // a process with this ID. This can happen if the stopped event was lost.
            ProcessData data;
            if (!this.processes.TryGetValue(e.Id, out data))
            {
                data = new ProcessData();
                this.processes.Add(e.Id, data);
            }

            data.Id = e.Id;
            data.Name = Path.GetFileName(e.ImageName);
            data.StartTime = e.Timestamp;
        }
Ejemplo n.º 2
0
        private void OnProcessStarted(object sender, ProcessEventArgs e)
        {
            // Note that it is possible (but unlikely) that we already have an entry for
            // a process with this ID. This can happen if the stopped event was lost.
            ProcessData data;

            if (!this.processes.TryGetValue(e.Id, out data))
            {
                data = new ProcessData();
                this.processes.Add(e.Id, data);
            }

            data.Id        = e.Id;
            data.Name      = Path.GetFileName(e.ImageName);
            data.StartTime = e.Timestamp;
        }
Ejemplo n.º 3
0
 public ProcessDataEventArgs(ProcessData data)
 {
     this.Data = data;
 }
Ejemplo n.º 4
0
 public ProcessDataEventArgs(ProcessData data)
 {
     this.Data = data;
 }