internal TaskbarGui(int status = 1) { _externalIP = Network.GetExternalIP(); _speak = new Speak(); _contextMenu = new NetOnContextMenu(ref _speak, ref _externalIP); _notifyIcon = GetNotifyIcon(_contextMenu.ContextMenu); _notifyIcon.Click += NotifyIcon_Click; UpdateIcon(status, ref _notifyIcon); StateStatus(); }
internal static void Show(string text, Speak speak) { speak?.Sentence(Resources.ClearThroat + _caption); MessageBox.Show(text, _caption, MessageBoxButtons.OK, MessageBoxIcon.Information); }
internal NetOnContextMenu(ref Speak speak, ref string externalIP) { _speak = speak; _externalIP = externalIP; CreateContextMenu(); }
internal static void Show(string text, Exception ex = null, Speak speak = null) { speak?.Sentence(Resources.ClearThroat + text); MessageBox.Show(ex is null ? text : $"{text}\r\n{ex}", _caption, MessageBoxButtons.OK, ex is null ? MessageBoxIcon.Information : MessageBoxIcon.Error); }