public NewTask() { InitializeComponent(); singleton = Singleton.Instance; singleton.exitApp += closeThis; formatter = new MessageFormatter(); Activated += changeFocusParams; Deactivated += changeFocusParams; }
public EditTask() { InitializeComponent(); singleton = Singleton.Instance; singleton.exitApp += closeThis; formatter = new MessageFormatter(); Activated += changeFocusParams; Deactivated += changeFocusParams; RemoveTaskBtn.Click += removeTaskAction; SaveTaskBtn.Click += editTaskAction; }
public Client(string ip, int port) : base() { singleton = Singleton.Instance; singleton.login += loginAction; singleton.loginCompleted += getTasks; singleton.newTaskEvent += submitTask; singleton.removeTaskEvent += removeTask; singleton.editTaskEvent += editTask; singleton.registerEvent += registerAction; encoder = new ASCIIEncoding(); messageFormatter = new MessageFormatter(); Connect(IPAddress.Parse(ip), port); clientStream = this.GetStream(); }