Clean up ported vs hawk core handling in BizBoxInfoControl

This commit is contained in:
YoshiRulz 2021-05-07 00:11:43 +10:00
parent 54301e9616
commit 796d0652e4
No known key found for this signature in database
GPG Key ID: C4DE31C245353FB7
2 changed files with 6 additions and 10 deletions

View File

@ -58,7 +58,7 @@
this.CorePortedLabel.Location = new System.Drawing.Point(140, 0);
this.CorePortedLabel.Name = "CorePortedLabel";
this.CorePortedLabel.Padding = new System.Windows.Forms.Padding(5, 5, 0, 0);
this.CorePortedLabel.Text = "label3";
this.CorePortedLabel.Text = "";
//
// CoreUrlLink
//
@ -71,6 +71,7 @@
this.CoreUrlLink.TabIndex = 3;
this.CoreUrlLink.TabStop = true;
this.CoreUrlLink.Text = "linkLabel1";
this.CoreUrlLink.Visible = false;
this.CoreUrlLink.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.CoreUrlLink_LinkClicked);
//
// BizBoxInfoControl

View File

@ -21,17 +21,12 @@ namespace BizHawk.Client.EmuHawk
CoreAuthorLabel.Visible = false;
}
CorePortedLabel.Text = attributes.Ported ? " (Ported)" : "";
if (!attributes.Ported)
if (attributes.Ported)
{
CoreUrlLink.Visible = false;
}
else
{
CoreUrlLink.Visible = true;
CoreUrlLink.Text = attributes.PortedVersion;
CorePortedLabel.Text = " (Ported)";
_url = attributes.PortedUrl;
CoreUrlLink.Text = attributes.PortedVersion;
CoreUrlLink.Visible = true;
}
}