mirror of
https://github.com/ppy/osu.git
synced 2025-01-13 14:12:56 +08:00
Only apply disable rules when in a screen stack.
This commit is contained in:
parent
54f6befd67
commit
04e99d1369
@ -89,8 +89,13 @@ namespace osu.Game.Screens
|
||||
{
|
||||
if (!IsCurrentScreen) return;
|
||||
|
||||
ruleset.Disabled = !AllowBeatmapRulesetChange;
|
||||
beatmap.Disabled = !AllowBeatmapRulesetChange;
|
||||
if (ParentScreen != null)
|
||||
{
|
||||
// we only want to apply these restrictions when we are inside a screen stack.
|
||||
// the use case for not applying is in visual/unit tests.
|
||||
ruleset.Disabled = !AllowBeatmapRulesetChange;
|
||||
beatmap.Disabled = !AllowBeatmapRulesetChange;
|
||||
}
|
||||
}
|
||||
|
||||
protected override void OnResuming(Screen last)
|
||||
|
Loading…
Reference in New Issue
Block a user