GUI components name update

This commit is contained in:
Anton Kasyanov
2017-05-28 23:21:52 +03:00
parent 7ee69bd3ad
commit a3941ee4fa
5 changed files with 33 additions and 30 deletions

View File

@@ -41,7 +41,7 @@ namespace EveOPreview.UI
this.View.ApplicationSettingsChanged = this.SaveApplicationSettings; this.View.ApplicationSettingsChanged = this.SaveApplicationSettings;
this.View.ThumbnailsSizeChanged = this.UpdateThumbnailsSize; this.View.ThumbnailsSizeChanged = this.UpdateThumbnailsSize;
this.View.ThumbnailStateChanged = this.UpdateThumbnailState; this.View.ThumbnailStateChanged = this.UpdateThumbnailState;
this.View.ForumUrlLinkActivated = this.OpenForumUrlLink; this.View.DocumentationLinkActivated = this.OpenDocumentationLink;
this.View.ApplicationExitRequested = this.ExitApplication; this.View.ApplicationExitRequested = this.ExitApplication;
this._thumbnailManager.ThumbnailsAdded = this.ThumbnailsAdded; this._thumbnailManager.ThumbnailsAdded = this.ThumbnailsAdded;
@@ -53,7 +53,7 @@ namespace EveOPreview.UI
private void Activate() private void Activate()
{ {
this.LoadApplicationSettings(); this.LoadApplicationSettings();
this.View.SetForumUrl(MainPresenter.ForumUrl); this.View.SetDocumentationUrl(MainPresenter.ForumUrl);
this.View.SetVersionInfo(this.GetApplicationVersion()); this.View.SetVersionInfo(this.GetApplicationVersion());
if (this._configuration.MinimizeToTray) if (this._configuration.MinimizeToTray)
{ {
@@ -217,7 +217,7 @@ namespace EveOPreview.UI
this._thumbnailManager.SetThumbnailState(thumbnailId, this._thumbnailDescriptionViews[thumbnailId].IsDisabled); this._thumbnailManager.SetThumbnailState(thumbnailId, this._thumbnailDescriptionViews[thumbnailId].IsDisabled);
} }
private void OpenForumUrlLink() private void OpenDocumentationLink()
{ {
ProcessStartInfo processStartInfo = new ProcessStartInfo(new Uri(MainPresenter.ForumUrl).AbsoluteUri); ProcessStartInfo processStartInfo = new ProcessStartInfo(new Uri(MainPresenter.ForumUrl).AbsoluteUri);
Process.Start(processStartInfo); Process.Start(processStartInfo);

View File

@@ -53,6 +53,7 @@ namespace EveOPreview.UI
System.Windows.Forms.Label ThumbnailsListLabel; System.Windows.Forms.Label ThumbnailsListLabel;
System.Windows.Forms.TabPage AboutTabPage; System.Windows.Forms.TabPage AboutTabPage;
System.Windows.Forms.Panel AboutPanel; System.Windows.Forms.Panel AboutPanel;
System.Windows.Forms.Label DocumentationLinkLabel;
System.Windows.Forms.Label DescriptionLabel; System.Windows.Forms.Label DescriptionLabel;
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainForm)); System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainForm));
System.Windows.Forms.Label NameLabel; System.Windows.Forms.Label NameLabel;
@@ -84,9 +85,8 @@ namespace EveOPreview.UI
this.ShowThumbnailOverlaysCheckBox = new System.Windows.Forms.CheckBox(); this.ShowThumbnailOverlaysCheckBox = new System.Windows.Forms.CheckBox();
this.ShowThumbnailFramesCheckBox = new System.Windows.Forms.CheckBox(); this.ShowThumbnailFramesCheckBox = new System.Windows.Forms.CheckBox();
this.ThumbnailsList = new System.Windows.Forms.CheckedListBox(); this.ThumbnailsList = new System.Windows.Forms.CheckedListBox();
this.label1 = new System.Windows.Forms.Label();
this.VersionLabel = new System.Windows.Forms.Label(); this.VersionLabel = new System.Windows.Forms.Label();
this.ForumLinkLabel = new System.Windows.Forms.LinkLabel(); this.DocumentationLink = new System.Windows.Forms.LinkLabel();
this.NotifyIcon = new System.Windows.Forms.NotifyIcon(this.components); this.NotifyIcon = new System.Windows.Forms.NotifyIcon(this.components);
this.TrayMenu = new System.Windows.Forms.ContextMenuStrip(this.components); this.TrayMenu = new System.Windows.Forms.ContextMenuStrip(this.components);
RestoreWindowMenuItem = new System.Windows.Forms.ToolStripMenuItem(); RestoreWindowMenuItem = new System.Windows.Forms.ToolStripMenuItem();
@@ -111,6 +111,7 @@ namespace EveOPreview.UI
ThumbnailsListLabel = new System.Windows.Forms.Label(); ThumbnailsListLabel = new System.Windows.Forms.Label();
AboutTabPage = new System.Windows.Forms.TabPage(); AboutTabPage = new System.Windows.Forms.TabPage();
AboutPanel = new System.Windows.Forms.Panel(); AboutPanel = new System.Windows.Forms.Panel();
DocumentationLinkLabel = new System.Windows.Forms.Label();
DescriptionLabel = new System.Windows.Forms.Label(); DescriptionLabel = new System.Windows.Forms.Label();
NameLabel = new System.Windows.Forms.Label(); NameLabel = new System.Windows.Forms.Label();
ContentTabControl.SuspendLayout(); ContentTabControl.SuspendLayout();
@@ -738,25 +739,25 @@ namespace EveOPreview.UI
// AboutPanel // AboutPanel
// //
AboutPanel.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; AboutPanel.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
AboutPanel.Controls.Add(this.label1); AboutPanel.Controls.Add(DocumentationLinkLabel);
AboutPanel.Controls.Add(DescriptionLabel); AboutPanel.Controls.Add(DescriptionLabel);
AboutPanel.Controls.Add(this.VersionLabel); AboutPanel.Controls.Add(this.VersionLabel);
AboutPanel.Controls.Add(NameLabel); AboutPanel.Controls.Add(NameLabel);
AboutPanel.Controls.Add(this.ForumLinkLabel); AboutPanel.Controls.Add(this.DocumentationLink);
AboutPanel.Dock = System.Windows.Forms.DockStyle.Fill; AboutPanel.Dock = System.Windows.Forms.DockStyle.Fill;
AboutPanel.Location = new System.Drawing.Point(0, 0); AboutPanel.Location = new System.Drawing.Point(0, 0);
AboutPanel.Name = "AboutPanel"; AboutPanel.Name = "AboutPanel";
AboutPanel.Size = new System.Drawing.Size(262, 210); AboutPanel.Size = new System.Drawing.Size(262, 210);
AboutPanel.TabIndex = 2; AboutPanel.TabIndex = 2;
// //
// label1 // DocumentationLinkLabel
// //
this.label1.AutoSize = true; DocumentationLinkLabel.AutoSize = true;
this.label1.Location = new System.Drawing.Point(0, 157); DocumentationLinkLabel.Location = new System.Drawing.Point(0, 157);
this.label1.Name = "label1"; DocumentationLinkLabel.Name = "DocumentationLinkLabel";
this.label1.Size = new System.Drawing.Size(206, 13); DocumentationLinkLabel.Size = new System.Drawing.Size(206, 13);
this.label1.TabIndex = 6; DocumentationLinkLabel.TabIndex = 6;
this.label1.Text = "For more information visit our forum thread:"; DocumentationLinkLabel.Text = "For more information visit our forum thread:";
// //
// DescriptionLabel // DescriptionLabel
// //
@@ -786,16 +787,16 @@ namespace EveOPreview.UI
NameLabel.TabIndex = 3; NameLabel.TabIndex = 3;
NameLabel.Text = "EVE-O Preview"; NameLabel.Text = "EVE-O Preview";
// //
// ForumLinkLabel // DocumentationLink
// //
this.ForumLinkLabel.Location = new System.Drawing.Point(0, 173); this.DocumentationLink.Location = new System.Drawing.Point(0, 173);
this.ForumLinkLabel.Name = "ForumLinkLabel"; this.DocumentationLink.Name = "DocumentationLink";
this.ForumLinkLabel.Size = new System.Drawing.Size(262, 33); this.DocumentationLink.Size = new System.Drawing.Size(262, 33);
this.ForumLinkLabel.TabIndex = 2; this.DocumentationLink.TabIndex = 2;
this.ForumLinkLabel.TabStop = true; this.DocumentationLink.TabStop = true;
this.ForumLinkLabel.Text = "to be set from prresenter to be set from prresenter to be set from prresenter to " + this.DocumentationLink.Text = "to be set from prresenter to be set from prresenter to be set from prresenter to " +
"be set from prresenter"; "be set from prresenter";
this.ForumLinkLabel.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.ForumLinkLabelClicked_Handler); this.DocumentationLink.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.DocumentationLinkClicked_Handler);
// //
// NotifyIcon // NotifyIcon
// //
@@ -894,7 +895,6 @@ namespace EveOPreview.UI
private CheckBox ShowThumbnailFramesCheckBox; private CheckBox ShowThumbnailFramesCheckBox;
private CheckedListBox ThumbnailsList; private CheckedListBox ThumbnailsList;
private LinkLabel DocumentationLink; private LinkLabel DocumentationLink;
private Label label1;
private Label VersionLabel; private Label VersionLabel;
} }
} }

View File

@@ -195,9 +195,9 @@ namespace EveOPreview.UI
this.WindowState = FormWindowState.Minimized; this.WindowState = FormWindowState.Minimized;
} }
public void SetForumUrl(string url) public void SetVersionInfo(string version)
{ {
this.ForumLinkLabel.Text = url; this.VersionLabel.Text = version;
} }
public void SetDocumentationUrl(string url) public void SetDocumentationUrl(string url)
@@ -269,7 +269,7 @@ namespace EveOPreview.UI
public Action<IntPtr> ThumbnailStateChanged { get; set; } public Action<IntPtr> ThumbnailStateChanged { get; set; }
public Action ForumUrlLinkActivated { get; set; } public Action DocumentationLinkActivated { get; set; }
#region UI events #region UI events
private void ContentTabControl_DrawItem(object sender, DrawItemEventArgs e) private void ContentTabControl_DrawItem(object sender, DrawItemEventArgs e)
@@ -354,9 +354,9 @@ namespace EveOPreview.UI
this.ThumbnailStateChanged?.Invoke(selectedItem.Id); this.ThumbnailStateChanged?.Invoke(selectedItem.Id);
} }
private void ForumLinkLabelClicked_Handler(object sender, LinkLabelLinkClickedEventArgs e) private void DocumentationLinkClicked_Handler(object sender, LinkLabelLinkClickedEventArgs e)
{ {
this.ForumUrlLinkActivated?.Invoke(); this.DocumentationLinkActivated?.Invoke();
} }
private void MainFormResize_Handler(object sender, EventArgs e) private void MainFormResize_Handler(object sender, EventArgs e)

View File

@@ -183,6 +183,9 @@
<metadata name="AboutPanel.GenerateMember" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="AboutPanel.GenerateMember" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value> <value>False</value>
</metadata> </metadata>
<metadata name="DocumentationLinkLabel.GenerateMember" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value>
</metadata>
<metadata name="DescriptionLabel.GenerateMember" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="DescriptionLabel.GenerateMember" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value> <value>False</value>
</metadata> </metadata>

View File

@@ -32,7 +32,7 @@ namespace EveOPreview.UI
bool EnableActiveClientHighlight { get; set; } bool EnableActiveClientHighlight { get; set; }
Color ActiveClientHighlightColor { get; set; } Color ActiveClientHighlightColor { get; set; }
void SetForumUrl(string url); void SetDocumentationUrl(string url);
void SetVersionInfo(string version); void SetVersionInfo(string version);
void SetThumbnailSizeLimitations(Size minimumSize, Size maximumSize); void SetThumbnailSizeLimitations(Size minimumSize, Size maximumSize);
@@ -50,6 +50,6 @@ namespace EveOPreview.UI
Action ApplicationSettingsChanged { get; set; } Action ApplicationSettingsChanged { get; set; }
Action ThumbnailsSizeChanged { get; set; } Action ThumbnailsSizeChanged { get; set; }
Action<IntPtr> ThumbnailStateChanged { get; set; } Action<IntPtr> ThumbnailStateChanged { get; set; }
Action ForumUrlLinkActivated { get; set; } Action DocumentationLinkActivated { get; set; }
} }
} }