19
|
1 using ServerMonitorApp.Properties;
|
|
2 using System;
|
|
3 using System.Diagnostics;
|
|
4 using System.Reflection;
|
|
5 using System.Windows.Forms;
|
|
6
|
|
7 namespace ServerMonitorApp
|
|
8 {
|
|
9 /// <summary>Program About form.</summary>
|
|
10 public partial class AboutForm : Form
|
|
11 {
|
|
12 public AboutForm()
|
|
13 {
|
|
14 InitializeComponent();
|
|
15 }
|
|
16
|
|
17 private void AboutForm_Load(object sender, EventArgs e)
|
|
18 {
|
|
19 Icon = Resources.icon;
|
|
20 NameLabel.Text += " " + Assembly.GetExecutingAssembly().GetName().Version.ToString(2);
|
20
|
21 // Remove initial focus on the first link causing an dotted outline.
|
|
22 ActiveControl = NameLabel;
|
19
|
23 }
|
|
24
|
|
25 /// <summary>Hides the form when ESC is pressed.</summary>
|
|
26 protected override bool ProcessDialogKey(Keys keyData)
|
|
27 {
|
|
28 if (keyData == Keys.Escape)
|
|
29 {
|
|
30 Close();
|
|
31 return true;
|
|
32 }
|
|
33 return base.ProcessDialogKey(keyData);
|
|
34 }
|
|
35
|
|
36 private void HomePageLink_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
|
|
37 {
|
20
|
38 Process.Start("https://bgreco.net/servermonitor");
|
|
39 }
|
|
40
|
|
41 private void SshNetLinkLabel_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
|
|
42 {
|
|
43 Process.Start("https://github.com/sshnet/SSH.NET");
|
|
44 }
|
|
45
|
|
46 private void NAppUpdateLinkLabel_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
|
|
47 {
|
|
48 Process.Start("https://github.com/synhershko/NAppUpdate");
|
19
|
49 }
|
|
50 }
|
|
51 }
|