Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitbbf6a64

Browse files
- Add support for Alpah Release Notes on .f version of 6000 Unity.
- Fix an issue with the alpha release notes website where the list included changes of the closest version, even though the user wants a strict diff.Thisi is done by adding a string list representation of the updatelist so as to be able to use Tools.FindNeatestVersion on that.
1 parent8056e1e commitbbf6a64

File tree

3 files changed

+17
-6
lines changed

3 files changed

+17
-6
lines changed

‎UnityLauncherPro/GetUnityUpdates.cs‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,12 @@ public static async Task<string> Scan()
4444
returnresult;
4545
}
4646

47-
publicstaticUpdates[]Parse(stringitems)
47+
publicstaticUpdates[]Parse(stringitems,refList<string>updatesAsString)
4848
{
49+
if(updatesAsString==null)
50+
updatesAsString=newList<string>();
51+
updatesAsString.Clear();
52+
4953
isDownloadingUnityList=false;
5054
//SetStatus("Downloading list of Unity versions ... done");
5155
varreceivedList=items.Split(new[]{Environment.NewLine},StringSplitOptions.None);
@@ -68,6 +72,7 @@ public static Updates[] Parse(string items)
6872
u.ReleaseDate=DateTime.ParseExact(row[3],"MM/dd/yyyy",CultureInfo.InvariantCulture);
6973
u.Version=versionTemp;
7074
releases.Add(versionTemp,u);
75+
updatesAsString.Add(versionTemp);
7176
}
7277

7378
prevVersion=versionTemp;

‎UnityLauncherPro/MainWindow.xaml.cs‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ public partial class MainWindow : Window
4646
System.Windows.Forms.NotifyIconnotifyIcon;
4747

4848
Updates[]updatesSource;
49+
publicstaticList<string>updatesAsStrings;
4950

5051
string_filterString=null;
5152
boolmultiWordSearch=false;
@@ -744,7 +745,7 @@ async Task CallGetUnityUpdates()
744745
varitems=awaittask;
745746
//Console.WriteLine("CallGetUnityUpdates=" + items == null);
746747
if(items==null)return;
747-
updatesSource=GetUnityUpdates.Parse(items);
748+
updatesSource=GetUnityUpdates.Parse(items,refupdatesAsStrings);
748749
if(updatesSource==null)return;
749750
dataGridUpdates.ItemsSource=updatesSource;
750751
}
@@ -1034,7 +1035,7 @@ private async void OnTabSelectionChanged(object sender, SelectionChangedEventArg
10341035
varitems=awaittask;
10351036
if(task.IsCompleted==false||task.IsFaulted==true)return;
10361037
if(items==null)return;
1037-
updatesSource=GetUnityUpdates.Parse(items);
1038+
updatesSource=GetUnityUpdates.Parse(items,refupdatesAsStrings);
10381039
if(updatesSource==null)return;
10391040
dataGridUpdates.ItemsSource=updatesSource;
10401041
}

‎UnityLauncherPro/Tools.cs‎

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -593,12 +593,17 @@ public static bool OpenReleaseNotes(string version)
593593

594594
//var url = Tools.GetUnityReleaseURL(version);
595595
stringurl=null;
596-
if(Properties.Settings.Default.useAlphaReleaseNotes&&!version.Contains("6000"))
596+
boolnoAlphaReleaseNotesPage=version.Contains("6000")&&!version.Contains("f");
597+
if(Properties.Settings.Default.useAlphaReleaseNotes&&!noAlphaReleaseNotesPage)
597598
{
599+
//with the alpha release notes, we want a diff between the 2 versions, but the site just shows all the changes inclusive of from
600+
// so we need to compare the currently selected version to the one right after it that is available (installed or not)
601+
598602
varclosestVersion=Tools.FindNearestVersion(version,MainWindow.unityInstalledVersions.Keys.ToList(),true);
599-
if(closestVersion==null)closestVersion=version;
603+
vargetNextVersionToClosest=closestVersion==null?null:Tools.FindNearestVersion(version,MainWindow.updatesAsStrings);
604+
if(getNextVersionToClosest==null)getNextVersionToClosest=version;
600605

601-
url="https://alpha.release-notes.ds.unity3d.com/search?fromVersion="+closestVersion+"&toVersion="+version;
606+
url="https://alpha.release-notes.ds.unity3d.com/search?fromVersion="+getNextVersionToClosest+"&toVersion="+version;
602607
}
603608
else
604609
{

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp