mirror of
https://github.com/ppy/osu.git
synced 2025-02-07 01:43:25 +08:00
Make debug section only visible on debug builds
This commit is contained in:
parent
f83ec721fb
commit
7ab16a55e5
@ -5,6 +5,7 @@
|
|||||||
|
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
|
using osu.Framework.Development;
|
||||||
using osu.Framework.Graphics;
|
using osu.Framework.Graphics;
|
||||||
using osu.Framework.Graphics.Containers;
|
using osu.Framework.Graphics.Containers;
|
||||||
using osu.Framework.Localisation;
|
using osu.Framework.Localisation;
|
||||||
@ -90,11 +91,13 @@ namespace osu.Game.Overlays.FirstRunSetup
|
|||||||
new GraphicsSection(),
|
new GraphicsSection(),
|
||||||
new OnlineSection(),
|
new OnlineSection(),
|
||||||
new MaintenanceSection(),
|
new MaintenanceSection(),
|
||||||
new DebugSection(),
|
|
||||||
},
|
},
|
||||||
SearchTerm = SettingsItem<bool>.CLASSIC_DEFAULT_SEARCH_TERM,
|
SearchTerm = SettingsItem<bool>.CLASSIC_DEFAULT_SEARCH_TERM,
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if (DebugUtils.IsDebugBuild)
|
||||||
|
searchContainer.Add(new DebugSection());
|
||||||
}
|
}
|
||||||
|
|
||||||
private void applyClassic()
|
private void applyClassic()
|
||||||
|
@ -7,6 +7,7 @@ using System.Collections.Generic;
|
|||||||
using System.Linq;
|
using System.Linq;
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
using osu.Framework.Bindables;
|
using osu.Framework.Bindables;
|
||||||
|
using osu.Framework.Development;
|
||||||
using osu.Framework.Graphics;
|
using osu.Framework.Graphics;
|
||||||
using osu.Framework.Graphics.Containers;
|
using osu.Framework.Graphics.Containers;
|
||||||
using osu.Framework.Graphics.Sprites;
|
using osu.Framework.Graphics.Sprites;
|
||||||
@ -27,7 +28,9 @@ namespace osu.Game.Overlays
|
|||||||
public LocalisableString Title => SettingsStrings.HeaderTitle;
|
public LocalisableString Title => SettingsStrings.HeaderTitle;
|
||||||
public LocalisableString Description => SettingsStrings.HeaderDescription;
|
public LocalisableString Description => SettingsStrings.HeaderDescription;
|
||||||
|
|
||||||
protected override IEnumerable<SettingsSection> CreateSections() => new SettingsSection[]
|
protected override IEnumerable<SettingsSection> CreateSections()
|
||||||
|
{
|
||||||
|
var sections = new List<SettingsSection>
|
||||||
{
|
{
|
||||||
// This list should be kept in sync with ScreenBehaviour.
|
// This list should be kept in sync with ScreenBehaviour.
|
||||||
new GeneralSection(),
|
new GeneralSection(),
|
||||||
@ -40,9 +43,14 @@ namespace osu.Game.Overlays
|
|||||||
new GraphicsSection(),
|
new GraphicsSection(),
|
||||||
new OnlineSection(),
|
new OnlineSection(),
|
||||||
new MaintenanceSection(),
|
new MaintenanceSection(),
|
||||||
new DebugSection(),
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if (DebugUtils.IsDebugBuild)
|
||||||
|
sections.Add(new DebugSection());
|
||||||
|
|
||||||
|
return sections;
|
||||||
|
}
|
||||||
|
|
||||||
private readonly List<SettingsSubPanel> subPanels = new List<SettingsSubPanel>();
|
private readonly List<SettingsSubPanel> subPanels = new List<SettingsSubPanel>();
|
||||||
|
|
||||||
private SettingsSubPanel lastOpenedSubPanel;
|
private SettingsSubPanel lastOpenedSubPanel;
|
||||||
|
Loading…
Reference in New Issue
Block a user