/// <summary> /// 退出并消除图标。 /// </summary> /// <param name="exitCode">退出码。0代表正常。</param> internal static void Exit(int exitCode) { try { icon.Visible = false; icon.Dispose(); InfoCollector.WriteLog("退出:" + exitCode.ToString()); } catch (Exception ex) { InfoCollector.WriteLog("退出错误:" + ex.Message); } Environment.Exit(exitCode); }
/// <summary> /// 冒个泡提示下。 /// </summary> private static void Popup(string MessageText = "虾小米签到中……", bool finished = false) { Console.WriteLine(MessageText); InfoCollector.WriteLog(MessageText); //currentTip = new MessageTip(MessageText, finished); if (tipShow != null) { tipShow(MessageText, finished); } //newTip = true; //icon.ShowBalloonTip(5000, "虾米签到", MessageText, ToolTipIcon.Info); /*icon.Text = MessageText; * if (finished) * { * icon.Icon = XiamiSigLite.Properties.Resources.favicon_finished; * } * else * { * icon.Icon = XiamiSigLite.Properties.Resources.favicon; * }*/ }