diff --git a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/BeatmapEditorRoundedScreen.cs b/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/BeatmapEditorRoundedScreen.cs deleted file mode 100644 index 392b7b495..000000000 --- a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/BeatmapEditorRoundedScreen.cs +++ /dev/null @@ -1,56 +0,0 @@ -// Copyright (c) andy840119 . Licensed under the GPL Licence. -// See the LICENCE file in the repository root for full licence text. - -using osu.Framework.Allocation; -using osu.Framework.Graphics; -using osu.Framework.Graphics.Containers; -using osu.Framework.Graphics.Shapes; -using osu.Game.Overlays; - -namespace osu.Game.Rulesets.Karaoke.Screens.Edit.Beatmaps; - -/// -/// Copied from EditorRoundedScreen -/// todo: will remove this screen eventually because new editor design not have round screen style. -/// -public partial class BeatmapEditorRoundedScreen : BeatmapEditorScreen -{ - public const int HORIZONTAL_PADDING = 100; - - private Container roundedContent = null!; - - protected override Container Content => roundedContent; - - public BeatmapEditorRoundedScreen(KaraokeBeatmapEditorScreenMode type) - : base(type) - { - } - - [BackgroundDependencyLoader] - private void load(OverlayColourProvider colourProvider) - { - base.Content.Add(new Container - { - RelativeSizeAxes = Axes.Both, - Padding = new MarginPadding(50), - Child = new Container - { - RelativeSizeAxes = Axes.Both, - Masking = true, - CornerRadius = 10, - Children = new Drawable[] - { - new Box - { - Colour = colourProvider.Background3, - RelativeSizeAxes = Axes.Both, - }, - roundedContent = new Container - { - RelativeSizeAxes = Axes.Both, - }, - }, - }, - }); - } -} diff --git a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Pages/PageScreen.cs b/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Pages/PageScreen.cs index 246649af2..2efbc4843 100644 --- a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Pages/PageScreen.cs +++ b/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Pages/PageScreen.cs @@ -16,7 +16,7 @@ namespace osu.Game.Rulesets.Karaoke.Screens.Edit.Beatmaps.Pages; [Cached(typeof(IPageStateProvider))] -public partial class PageScreen : BeatmapEditorRoundedScreen, IPageStateProvider +public partial class PageScreen : BeatmapEditorScreen, IPageStateProvider { [Cached(typeof(IBeatmapPagesChangeHandler))] private readonly BeatmapPagesChangeHandler beatmapPagesChangeHandler; diff --git a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Singers/SingerScreen.cs b/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Singers/SingerScreen.cs index 40815e4cf..f3a52b41f 100644 --- a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Singers/SingerScreen.cs +++ b/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Singers/SingerScreen.cs @@ -5,6 +5,7 @@ using osu.Framework.Bindables; using osu.Framework.Graphics; using osu.Framework.Graphics.Containers; +using osu.Framework.Graphics.Shapes; using osu.Game.Graphics.Containers; using osu.Game.Overlays; using osu.Game.Rulesets.Karaoke.Edit.ChangeHandlers.Beatmaps; @@ -17,7 +18,7 @@ namespace osu.Game.Rulesets.Karaoke.Screens.Edit.Beatmaps.Singers; [Cached(typeof(ISingerScreenScrollingInfoProvider))] -public partial class SingerScreen : BeatmapEditorRoundedScreen, ISingerScreenScrollingInfoProvider +public partial class SingerScreen : BeatmapEditorScreen, ISingerScreenScrollingInfoProvider { [Cached(typeof(IBeatmapSingersChangeHandler))] private readonly BeatmapSingersChangeHandler beatmapSingersChangeHandler; @@ -43,25 +44,33 @@ public SingerScreen() } [BackgroundDependencyLoader] - private void load(EditorClock editorClock) + private void load(EditorClock editorClock, OverlayColourProvider colourProvider) { // initialize scroll zone. BindableZoom.MaxValue = ZoomableScrollContainerUtils.GetZoomLevelForVisibleMilliseconds(editorClock, 8000); BindableZoom.MinValue = ZoomableScrollContainerUtils.GetZoomLevelForVisibleMilliseconds(editorClock, 80000); BindableZoom.Value = BindableZoom.Default = ZoomableScrollContainerUtils.GetZoomLevelForVisibleMilliseconds(editorClock, 40000); - Add(new FixedSectionsContainer + Children = new Drawable[] { - FixedHeader = new SingerScreenHeader(), - RelativeSizeAxes = Axes.Both, - Children = new[] + new Box { - new SingerEditSection + Colour = colourProvider.Background3, + RelativeSizeAxes = Axes.Both, + }, + new FixedSectionsContainer + { + FixedHeader = new SingerScreenHeader(), + RelativeSizeAxes = Axes.Both, + Children = new[] { - RelativeSizeAxes = Axes.Both, + new SingerEditSection + { + RelativeSizeAxes = Axes.Both, + }, }, }, - }); + }; } protected override void LoadComplete() diff --git a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Translate/TranslateScreen.cs b/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Translate/TranslateScreen.cs index 9cf594792..ac6aa0676 100644 --- a/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Translate/TranslateScreen.cs +++ b/osu.Game.Rulesets.Karaoke/Screens/Edit/Beatmaps/Translate/TranslateScreen.cs @@ -4,6 +4,7 @@ using osu.Framework.Allocation; using osu.Framework.Graphics; using osu.Framework.Graphics.Containers; +using osu.Framework.Graphics.Shapes; using osu.Game.Graphics.Containers; using osu.Game.Overlays; using osu.Game.Rulesets.Karaoke.Edit.ChangeHandlers.Beatmaps; @@ -11,7 +12,7 @@ namespace osu.Game.Rulesets.Karaoke.Screens.Edit.Beatmaps.Translate; -public partial class TranslateScreen : BeatmapEditorRoundedScreen +public partial class TranslateScreen : BeatmapEditorScreen { [Cached(typeof(IBeatmapLanguagesChangeHandler))] private readonly BeatmapLanguagesChangeHandler beatmapLanguagesChangeHandler; @@ -27,21 +28,29 @@ public TranslateScreen() } [BackgroundDependencyLoader] - private void load() + private void load(OverlayColourProvider colourProvider) { - Add(new SectionsContainer + Children = new Drawable[] { - FixedHeader = new TranslateScreenHeader(), - RelativeSizeAxes = Axes.Both, - Children = new Container[] + new Box { - new TranslateEditSection + Colour = colourProvider.Background3, + RelativeSizeAxes = Axes.Both, + }, + new SectionsContainer + { + FixedHeader = new TranslateScreenHeader(), + RelativeSizeAxes = Axes.Both, + Children = new Container[] { - RelativeSizeAxes = Axes.X, - AutoSizeAxes = Axes.Y, + new TranslateEditSection + { + RelativeSizeAxes = Axes.X, + AutoSizeAxes = Axes.Y, + }, }, }, - }); + }; } internal partial class TranslateScreenHeader : OverlayHeader diff --git a/osu.Game.Rulesets.Karaoke/Screens/Edit/GenericEditorScreen.cs b/osu.Game.Rulesets.Karaoke/Screens/Edit/GenericEditorScreen.cs index a5959313a..76879ba64 100644 --- a/osu.Game.Rulesets.Karaoke/Screens/Edit/GenericEditorScreen.cs +++ b/osu.Game.Rulesets.Karaoke/Screens/Edit/GenericEditorScreen.cs @@ -1,7 +1,6 @@ // Copyright (c) andy840119 . Licensed under the GPL Licence. // See the LICENCE file in the repository root for full licence text. -using osu.Framework.Graphics; using osu.Game.Screens.Edit; namespace osu.Game.Rulesets.Karaoke.Screens.Edit; @@ -18,16 +17,4 @@ protected GenericEditorScreen(TType type) { Type = type; } - - protected override void PopIn() - { - this.ScaleTo(1f, 200, Easing.OutQuint) - .FadeIn(200, Easing.OutQuint); - } - - protected override void PopOut() - { - this.ScaleTo(0.98f, 200, Easing.OutQuint) - .FadeOut(200, Easing.OutQuint); - } }