Use a List instead of a Dictionary.

This commit is contained in:
naoey
2017-09-09 09:51:37 +05:30
parent 20becbe576
commit 5f5dd54f9d
2 changed files with 15 additions and 14 deletions

View File

@ -8,17 +8,17 @@ namespace osu.Game.Online.API.Requests
{
public class DownloadBeatmapSetRequest : APIDownloadRequest
{
private readonly BeatmapSetInfo beatmapSet;
public readonly BeatmapSetInfo BeatmapSet;
public Action<float> DownloadProgressed;
public DownloadBeatmapSetRequest(BeatmapSetInfo beatmapSet)
public DownloadBeatmapSetRequest(BeatmapSetInfo set)
{
this.beatmapSet = beatmapSet;
BeatmapSet = set;
Progress += (current, total) => DownloadProgressed?.Invoke((float) current / total);
}
protected override string Target => $@"beatmapsets/{beatmapSet.OnlineBeatmapSetID}/download";
protected override string Target => $@"beatmapsets/{BeatmapSet.OnlineBeatmapSetID}/download";
}
}