/// <summary> /// Displays the icon in the system tray. /// </summary> public void Display() { // Put the icon in the system tray and allow it react to mouse clicks. ni.MouseClick += new MouseEventHandler(ni_MouseClick); ni.Icon = Resources.clock1; ni.Text = "GMT+0 : " + DateTime.Now.ToUniversalTime().ToString("HH:mm:ss"); ni.Visible = true; #if !DEBUG ni.BalloonTipIcon = ToolTipIcon.Info; ni.BalloonTipTitle = ConfigHelper.RetornaVersao(); ni.BalloonTipText = "Aplicativo de relógios iniciado"; ni.ShowBalloonTip(1500); #endif // Attach a context menu. ni.ContextMenuStrip = new ContextMenus().Create(); ConfigXML configXML = ConfigHelper.CarregarConfig(); foreach (RelogioXML relogio in configXML.Relogios) { formRelogio form = new formRelogio(); form.relogioXML = relogio; form.Show(); } }