mirror of
https://github.com/ppy/osu.git
synced 2026-05-17 19:44:22 +08:00
Use the specifically created progress action, add license header.
This commit is contained in:
@@ -1,4 +1,7 @@
|
||||
using osu.Game.Beatmaps;
|
||||
// Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
|
||||
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
||||
|
||||
using osu.Game.Beatmaps;
|
||||
using System;
|
||||
|
||||
namespace osu.Game.Online.API.Requests
|
||||
|
||||
@@ -60,13 +60,7 @@ namespace osu.Game.Overlays.Direct
|
||||
Logger.Error(e, "Failed to get beatmap download information");
|
||||
};
|
||||
|
||||
downloadRequest.Progress += (current, total) =>
|
||||
{
|
||||
float progress = (float)current / total;
|
||||
|
||||
progressBar.Current.Value = progress;
|
||||
|
||||
};
|
||||
downloadRequest.DownloadProgressed += progress => progressBar.Current.Value = progress;
|
||||
|
||||
downloadRequest.Success += data =>
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user