mirror of
https://github.com/ppy/osu
synced 2025-02-25 15:11:46 +00:00
Make EditorScreen abstract
This commit is contained in:
parent
10c7fc139e
commit
3dd2b18ff0
@ -19,13 +19,13 @@ using osu.Framework.Timing;
|
||||
using osu.Game.Graphics.UserInterface;
|
||||
using osu.Game.Screens.Edit.Components;
|
||||
using osu.Game.Screens.Edit.Components.Menus;
|
||||
using osu.Game.Screens.Edit.Compose;
|
||||
using osu.Game.Screens.Edit.Design;
|
||||
using osuTK.Input;
|
||||
using System.Collections.Generic;
|
||||
using osu.Framework;
|
||||
using osu.Framework.Input.Bindings;
|
||||
using osu.Game.Input.Bindings;
|
||||
using osu.Game.Screens.Edit.Compose;
|
||||
using osu.Game.Screens.Edit.Setup;
|
||||
using osu.Game.Screens.Edit.Timing;
|
||||
using osu.Game.Users;
|
||||
@ -275,10 +275,6 @@ namespace osu.Game.Screens.Edit
|
||||
case EditorScreenMode.Timing:
|
||||
currentScreen = new TimingScreen();
|
||||
break;
|
||||
|
||||
default:
|
||||
currentScreen = new EditorScreen();
|
||||
break;
|
||||
}
|
||||
|
||||
LoadComponentAsync(currentScreen, screenContainer.Add);
|
||||
|
@ -10,16 +10,17 @@ using osu.Game.Beatmaps;
|
||||
namespace osu.Game.Screens.Edit
|
||||
{
|
||||
/// <summary>
|
||||
/// TODO: eventually make this inherit Screen and add a local scren stack inside the Editor.
|
||||
/// TODO: eventually make this inherit Screen and add a local screen stack inside the Editor.
|
||||
/// </summary>
|
||||
public class EditorScreen : Container
|
||||
public abstract class EditorScreen : Container
|
||||
{
|
||||
protected readonly IBindable<WorkingBeatmap> Beatmap = new Bindable<WorkingBeatmap>();
|
||||
[Resolved]
|
||||
protected IBindable<WorkingBeatmap> Beatmap { get; private set; }
|
||||
|
||||
protected override Container<Drawable> Content => content;
|
||||
private readonly Container content;
|
||||
|
||||
public EditorScreen()
|
||||
protected EditorScreen()
|
||||
{
|
||||
Anchor = Anchor.Centre;
|
||||
Origin = Anchor.Centre;
|
||||
@ -28,12 +29,6 @@ namespace osu.Game.Screens.Edit
|
||||
InternalChild = content = new Container { RelativeSizeAxes = Axes.Both };
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(IBindable<WorkingBeatmap> beatmap)
|
||||
{
|
||||
Beatmap.BindTo(beatmap);
|
||||
}
|
||||
|
||||
protected override void LoadComplete()
|
||||
{
|
||||
base.LoadComplete();
|
||||
|
Loading…
Reference in New Issue
Block a user