Skip to content
This repository was archived by the owner on May 19, 2021. It is now read-only.

Commit 30bd916

Browse files
committed
fix update tab buttons (referenced wrong gridlist), color installed updates as green
1 parent ec591c9 commit 30bd916

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

UnityLauncher/Form1.cs

+6-7
Original file line numberDiff line numberDiff line change
@@ -614,8 +614,8 @@ void LaunchSelectedProject(bool openProject = true)
614614

615615
void LaunchSelectedUnity()
616616
{
617-
FixSelectedRow();
618-
var selected = gridRecent?.CurrentCell?.RowIndex;
617+
618+
var selected = gridUnityList?.CurrentCell?.RowIndex;
619619
if (selected.HasValue && selected > -1)
620620
{
621621
SetStatus("Launching Unity..");
@@ -680,8 +680,7 @@ private void btnRemovePackFolder_Click(object sender, EventArgs e)
680680

681681
private void btnOpenReleasePage_Click(object sender, EventArgs e)
682682
{
683-
FixSelectedRow();
684-
var selected = gridRecent?.CurrentCell?.RowIndex;
683+
var selected = gridUnityList?.CurrentCell?.RowIndex;
685684
if (selected.HasValue && selected > -1)
686685
{
687686
var version = gridUnityList.Rows[(int)selected].Cells["_unityVersion"].Value.ToString();
@@ -703,8 +702,8 @@ private void btnLaunchUnity_Click(object sender, EventArgs e)
703702

704703
private void btnExploreUnity_Click(object sender, EventArgs e)
705704
{
706-
FixSelectedRow();
707-
var selected = gridRecent?.CurrentCell?.RowIndex;
705+
706+
var selected = gridUnityList?.CurrentCell?.RowIndex;
708707
if (selected.HasValue && selected > -1)
709708
{
710709
var unityPath = Path.GetDirectoryName(gridUnityList.Rows[(int)selected].Cells["_unityPath"].Value.ToString());
@@ -1180,7 +1179,7 @@ private void UnityVersionsListDownloaded(object sender, DownloadStringCompletedE
11801179
gridUnityUpdates.Rows.Add(row[3], versionTemp);
11811180

11821181
// set color if we already have it installed
1183-
gridUnityUpdates.Rows[i].Cells[1].Style.ForeColor = unityList.ContainsKey(versionTemp) ? Color.Black : Color.Red;
1182+
gridUnityUpdates.Rows[i].Cells[1].Style.ForeColor = unityList.ContainsKey(versionTemp) ? Color.Green : Color.Black;
11841183
}
11851184
}
11861185

0 commit comments

Comments
 (0)