Use GetAsync for all samples

This commit is contained in:
smoogipoo
2018-08-27 17:30:16 +09:00
parent 1b279d383f
commit e7a5816d27
19 changed files with 58 additions and 44 deletions

View File

@ -2,6 +2,7 @@
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using System;
using System.Threading.Tasks;
using Microsoft.EntityFrameworkCore.Internal;
using osu.Framework.Allocation;
using osu.Framework.Audio;
@ -80,7 +81,7 @@ namespace osu.Game.Screens
private SampleChannel sampleExit;
[BackgroundDependencyLoader(true)]
private void load(BindableBeatmap beatmap, OsuGame osu, AudioManager audio, Bindable<RulesetInfo> ruleset)
private async Task load(BindableBeatmap beatmap, OsuGame osu, AudioManager audio, Bindable<RulesetInfo> ruleset)
{
Beatmap.BindTo(beatmap);
Ruleset.BindTo(ruleset);
@ -98,7 +99,7 @@ namespace osu.Game.Screens
};
}
sampleExit = audio.Sample.Get(@"UI/screen-back");
sampleExit = await audio.Sample.GetAsync(@"UI/screen-back");
}
public virtual bool OnPressed(GlobalAction action)