mirror of
https://github.com/ppy/osu.git
synced 2025-02-21 20:53:04 +08:00
Move out test ongoing operation tracker to higher level
This commit is contained in:
parent
c2eeb822b8
commit
ff60d652ed
@ -15,7 +15,6 @@ using osu.Game.Graphics.UserInterface;
|
|||||||
using osu.Game.Online.Multiplayer;
|
using osu.Game.Online.Multiplayer;
|
||||||
using osu.Game.Online.Rooms;
|
using osu.Game.Online.Rooms;
|
||||||
using osu.Game.Rulesets;
|
using osu.Game.Rulesets;
|
||||||
using osu.Game.Screens.OnlinePlay;
|
|
||||||
using osu.Game.Screens.OnlinePlay.Multiplayer.Match;
|
using osu.Game.Screens.OnlinePlay.Multiplayer.Match;
|
||||||
using osu.Game.Tests.Resources;
|
using osu.Game.Tests.Resources;
|
||||||
using osu.Game.Users;
|
using osu.Game.Users;
|
||||||
@ -31,9 +30,6 @@ namespace osu.Game.Tests.Visual.Multiplayer
|
|||||||
private BeatmapManager beatmaps;
|
private BeatmapManager beatmaps;
|
||||||
private RulesetStore rulesets;
|
private RulesetStore rulesets;
|
||||||
|
|
||||||
[Cached]
|
|
||||||
private OngoingOperationTracker ongoingOperationTracker = new OngoingOperationTracker();
|
|
||||||
|
|
||||||
private IDisposable readyClickOperation;
|
private IDisposable readyClickOperation;
|
||||||
|
|
||||||
[BackgroundDependencyLoader]
|
[BackgroundDependencyLoader]
|
||||||
@ -66,7 +62,7 @@ namespace osu.Game.Tests.Visual.Multiplayer
|
|||||||
},
|
},
|
||||||
OnReadyClick = async () =>
|
OnReadyClick = async () =>
|
||||||
{
|
{
|
||||||
readyClickOperation = ongoingOperationTracker.BeginOperation();
|
readyClickOperation = OngoingOperationTracker.BeginOperation();
|
||||||
|
|
||||||
if (Client.IsHost && Client.LocalUser?.State == MultiplayerUserState.Ready)
|
if (Client.IsHost && Client.LocalUser?.State == MultiplayerUserState.Ready)
|
||||||
{
|
{
|
||||||
|
@ -23,6 +23,9 @@ namespace osu.Game.Tests.Visual.Multiplayer
|
|||||||
[Cached]
|
[Cached]
|
||||||
public Bindable<FilterCriteria> Filter { get; }
|
public Bindable<FilterCriteria> Filter { get; }
|
||||||
|
|
||||||
|
[Cached]
|
||||||
|
public OngoingOperationTracker OngoingOperationTracker { get; } = new OngoingOperationTracker();
|
||||||
|
|
||||||
protected override Container<Drawable> Content => content;
|
protected override Container<Drawable> Content => content;
|
||||||
private readonly TestMultiplayerRoomContainer content;
|
private readonly TestMultiplayerRoomContainer content;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user