diff --git a/osu.Game/Screens/Play/HUD/IDefaultSkinnableTarget.cs b/osu.Game/Screens/Play/HUD/IDefaultSkinnableTarget.cs new file mode 100644 index 0000000000..208d920dec --- /dev/null +++ b/osu.Game/Screens/Play/HUD/IDefaultSkinnableTarget.cs @@ -0,0 +1,12 @@ +// Copyright (c) ppy Pty Ltd . Licensed under the MIT Licence. +// See the LICENCE file in the repository root for full licence text. + +namespace osu.Game.Screens.Play.HUD +{ + /// + /// The default placement location for new s. + /// + public interface IDefaultSkinnableTarget : ISkinnableTarget + { + } +} diff --git a/osu.Game/Screens/Play/HUD/ISkinnableTarget.cs b/osu.Game/Screens/Play/HUD/ISkinnableTarget.cs new file mode 100644 index 0000000000..61a173ed02 --- /dev/null +++ b/osu.Game/Screens/Play/HUD/ISkinnableTarget.cs @@ -0,0 +1,15 @@ +// Copyright (c) ppy Pty Ltd . Licensed under the MIT Licence. +// See the LICENCE file in the repository root for full licence text. + +using osu.Framework.Graphics; +using osu.Framework.Graphics.Containers; + +namespace osu.Game.Screens.Play.HUD +{ + /// + /// Denotes a container which can house s. + /// + public interface ISkinnableTarget : IContainerCollection + { + } +} diff --git a/osu.Game/Screens/Play/HUDOverlay.cs b/osu.Game/Screens/Play/HUDOverlay.cs index 669c920017..eb6e599a19 100644 --- a/osu.Game/Screens/Play/HUDOverlay.cs +++ b/osu.Game/Screens/Play/HUDOverlay.cs @@ -22,7 +22,7 @@ using osuTK; namespace osu.Game.Screens.Play { [Cached] - public class HUDOverlay : Container, IKeyBindingHandler + public class HUDOverlay : Container, IKeyBindingHandler, IDefaultSkinnableTarget { public const float FADE_DURATION = 300; diff --git a/osu.Game/Skinning/Editor/SkinEditor.cs b/osu.Game/Skinning/Editor/SkinEditor.cs index 885d41043c..6d189dc027 100644 --- a/osu.Game/Skinning/Editor/SkinEditor.cs +++ b/osu.Game/Skinning/Editor/SkinEditor.cs @@ -11,7 +11,7 @@ using osu.Framework.Testing; using osu.Game.Graphics; using osu.Game.Graphics.Containers; using osu.Game.Graphics.Cursor; -using osu.Game.Screens.Play; +using osu.Game.Screens.Play.HUD; namespace osu.Game.Skinning.Editor { @@ -70,7 +70,7 @@ namespace osu.Game.Skinning.Editor { var instance = (Drawable)Activator.CreateInstance(type); - var targetContainer = target.ChildrenOfType().FirstOrDefault(); + var targetContainer = target.ChildrenOfType().FirstOrDefault(); targetContainer?.Add(instance); }