2 using System.Collections.Generic;
8 public enum UpdateEventType
14 BaseDevicePhysicalAddress,
24 public class UpdateEvent : EventArgs
26 public UpdateEvent(UpdateEventType type, bool value)
32 public UpdateEvent(UpdateEventType type, int value)
38 public UpdateEvent(UpdateEventType type, string value)
44 public UpdateEvent(LibCECConfiguration config)
46 Type = UpdateEventType.Configuration;
50 public UpdateEventType Type;
51 public bool BoolValue = false;
52 public int IntValue = -1;
53 public string StringValue = String.Empty;
54 public LibCECConfiguration ConfigValue = null;
57 public abstract class UpdateProcess
59 public UpdateProcess()
63 public void SendEvent(UpdateEventType type, bool value)
65 EventHandler<UpdateEvent> temp = EventHandler;
67 temp(this, new UpdateEvent(type, value));
70 public void SendEvent(UpdateEventType type, int value)
72 EventHandler<UpdateEvent> temp = EventHandler;
74 temp(this, new UpdateEvent(type, value));
77 public void SendEvent(UpdateEventType type, string value)
79 EventHandler<UpdateEvent> temp = EventHandler;
81 temp(this, new UpdateEvent(type, value));
84 public void SendEvent(LibCECConfiguration config)
86 EventHandler<UpdateEvent> temp = EventHandler;
88 temp(this, new UpdateEvent(config));
94 SendEvent(UpdateEventType.ProcessCompleted, true);
97 public abstract void Process();
98 public event EventHandler<UpdateEvent> EventHandler;