Remove `public` prefixes from interface type and add `Components` list for future use

This commit is contained in:
Dean Herbert 2021-05-12 15:58:21 +09:00
parent 96d4011de2
commit 29e6f6b6b6
2 changed files with 14 additions and 5 deletions

View File

@ -12,7 +12,6 @@
using osu.Game.Rulesets.Edit;
using osu.Game.Screens;
using osu.Game.Screens.Edit.Compose.Components;
using osu.Game.Screens.Play.HUD;
namespace osu.Game.Skinning.Editor
{
@ -38,7 +37,7 @@ protected override void LoadComplete()
base.LoadComplete();
// track each target container on the current screen.
var targetContainers = target.ChildrenOfType<SkinnableElementTargetContainer>().ToArray();
var targetContainers = target.ChildrenOfType<ISkinnableTarget>().ToArray();
if (targetContainers.Length == 0)
{

View File

@ -1,6 +1,8 @@
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Bindables;
namespace osu.Game.Skinning
{
/// <summary>
@ -8,16 +10,24 @@ namespace osu.Game.Skinning
/// </summary>
public interface ISkinnableTarget
{
public SkinnableTarget Target { get; }
/// <summary>
/// The definition of this target.
/// </summary>
SkinnableTarget Target { get; }
/// <summary>
/// A bindable list of components which are being tracked by this skinnable target.
/// </summary>
IBindableList<ISkinnableComponent> Components { get; }
/// <summary>
/// Reload this target from the current skin.
/// </summary>
public void Reload();
void Reload();
/// <summary>
/// Add the provided item to this target.
/// </summary>
public void Add(ISkinnableComponent drawable);
void Add(ISkinnableComponent drawable);
}
}