mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 11:37:28 +08:00
Use standard switch syntax (preferred for now)
This commit is contained in:
parent
0c36a3c263
commit
809caaa44c
@ -302,14 +302,21 @@ namespace osu.Game.Tests.Visual.Gameplay
|
||||
TimeRange.Value = time_range;
|
||||
}
|
||||
|
||||
public override DrawableHitObject<TestHitObject> CreateDrawableRepresentation(TestHitObject h) =>
|
||||
h switch
|
||||
public override DrawableHitObject<TestHitObject> CreateDrawableRepresentation(TestHitObject h)
|
||||
{
|
||||
switch (h)
|
||||
{
|
||||
TestPooledHitObject _ => null,
|
||||
TestPooledParentHitObject _ => null,
|
||||
TestParentHitObject p => new DrawableTestParentHitObject(p),
|
||||
_ => new DrawableTestHitObject(h),
|
||||
};
|
||||
case TestPooledHitObject _:
|
||||
case TestPooledParentHitObject _:
|
||||
return null;
|
||||
|
||||
case TestParentHitObject p:
|
||||
return new DrawableTestParentHitObject(p);
|
||||
|
||||
default:
|
||||
return new DrawableTestHitObject(h);
|
||||
}
|
||||
}
|
||||
|
||||
protected override PassThroughInputManager CreateInputManager() => new PassThroughInputManager();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user