private void CloseForm() { JobTask.Interrupt(); NotifyTask.Interrupt(); if (TaskbarNotifier != default(NotifyIcon)) { TaskbarNotifier.Visible = false; TaskbarNotifier.Icon = null; TaskbarNotifier.Dispose(); } }
/// /// Close the Toast object and calculate, if needed the new coordinates. /// /// TaskbarNotifier object to close and dispose. /// Nothing public void KillWindow(TaskbarNotifier toast) { nToastCount -= 1; if (nToastCount == 0) { nBaseWindowBottom = 0; nBaseWindowRight = 0; } toast.Close(); toast.Dispose(); }