Merge branch 'master' into Editor-DrawableRuleset-Dependencies

This commit is contained in:
Dean Herbert
2022-11-30 17:42:46 +09:00
2356 changed files with 4417 additions and 4019 deletions

View File

@ -29,7 +29,7 @@ using osuTK.Input;
namespace osu.Game.Screens.Edit.Compose.Components
{
public class BeatDivisorControl : CompositeDrawable
public partial class BeatDivisorControl : CompositeDrawable
{
private readonly BindableBeatDivisor beatDivisor = new BindableBeatDivisor();
@ -220,7 +220,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
return base.OnKeyDown(e);
}
internal class DivisorDisplay : OsuAnimatedButton, IHasPopover
internal partial class DivisorDisplay : OsuAnimatedButton, IHasPopover
{
public BindableBeatDivisor BeatDivisor { get; } = new BindableBeatDivisor();
@ -270,7 +270,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
};
}
internal class CustomDivisorPopover : OsuPopover
internal partial class CustomDivisorPopover : OsuPopover
{
public BindableBeatDivisor BeatDivisor { get; } = new BindableBeatDivisor();
@ -328,7 +328,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
}
}
private class DivisorTypeText : OsuSpriteText
private partial class DivisorTypeText : OsuSpriteText
{
public BindableBeatDivisor BeatDivisor { get; } = new BindableBeatDivisor();
@ -347,7 +347,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
}
}
internal class ChevronButton : IconButton
internal partial class ChevronButton : IconButton
{
public ChevronButton()
{
@ -370,7 +370,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
}
}
private class TickSliderBar : SliderBar<int>
private partial class TickSliderBar : SliderBar<int>
{
private Marker marker;
@ -485,7 +485,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
private float getMappedPosition(float divisor) => MathF.Pow((divisor - 1) / (beatDivisor.ValidDivisors.Value.Presets.Last() - 1), 0.90f);
private class Tick : Circle
private partial class Tick : Circle
{
public Tick(int divisor)
{
@ -494,7 +494,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
}
}
private class Marker : CompositeDrawable
private partial class Marker : CompositeDrawable
{
[Resolved]
private OverlayColourProvider colourProvider { get; set; }

View File

@ -26,7 +26,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// A container which provides a "blueprint" display of items.
/// Includes selection and manipulation support via a <see cref="Components.SelectionHandler{T}"/>.
/// </summary>
public abstract class BlueprintContainer<T> : CompositeDrawable, IKeyBindingHandler<PlatformAction>
public abstract partial class BlueprintContainer<T> : CompositeDrawable, IKeyBindingHandler<PlatformAction>
where T : class
{
protected DragBox DragBox { get; private set; }

View File

@ -16,7 +16,7 @@ using osuTK.Graphics;
namespace osu.Game.Screens.Edit.Compose.Components
{
public abstract class CircularDistanceSnapGrid : DistanceSnapGrid
public abstract partial class CircularDistanceSnapGrid : DistanceSnapGrid
{
protected CircularDistanceSnapGrid(HitObject referenceObject, Vector2 startPosition, double startTime, double? endTime = null)
: base(referenceObject, startPosition, startTime, endTime)
@ -117,7 +117,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
return (snappedPosition, snappedTime);
}
private class Ring : CircularProgress
private partial class Ring : CircularProgress
{
[Resolved]
private IDistanceSnapProvider snapProvider { get; set; }

View File

@ -31,7 +31,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// <summary>
/// A blueprint container generally displayed as an overlay to a ruleset's playfield.
/// </summary>
public class ComposeBlueprintContainer : EditorBlueprintContainer
public partial class ComposeBlueprintContainer : EditorBlueprintContainer
{
private readonly Container<PlacementBlueprint> placementBlueprintContainer;

View File

@ -21,7 +21,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// <summary>
/// A grid which takes user input and returns a quantized ("snapped") position and time.
/// </summary>
public abstract class DistanceSnapGrid : CompositeDrawable
public abstract partial class DistanceSnapGrid : CompositeDrawable
{
/// <summary>
/// The spacing between each tick of the beat snapping grid.

View File

@ -18,7 +18,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// <summary>
/// A box that displays the drag selection and provides selection events for users to handle.
/// </summary>
public class DragBox : CompositeDrawable, IStateful<Visibility>
public partial class DragBox : CompositeDrawable, IStateful<Visibility>
{
public Drawable Box { get; private set; }
@ -71,7 +71,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
public event Action<Visibility> StateChanged;
public class BoxWithBorders : CompositeDrawable
public partial class BoxWithBorders : CompositeDrawable
{
private readonly LayoutValue cache = new LayoutValue(Invalidation.RequiredParentSizeToFit);

View File

@ -16,7 +16,7 @@ using osu.Game.Rulesets.Objects.Drawables;
namespace osu.Game.Screens.Edit.Compose.Components
{
public class EditorBlueprintContainer : BlueprintContainer<HitObject>
public partial class EditorBlueprintContainer : BlueprintContainer<HitObject>
{
[Resolved]
protected EditorClock EditorClock { get; private set; }

View File

@ -18,7 +18,7 @@ using osu.Game.Rulesets.Objects.Types;
namespace osu.Game.Screens.Edit.Compose.Components
{
public class EditorSelectionHandler : SelectionHandler<HitObject>
public partial class EditorSelectionHandler : SelectionHandler<HitObject>
{
[Resolved]
protected EditorBeatmap EditorBeatmap { get; private set; }

View File

@ -15,7 +15,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// <summary>
/// A container for <see cref="SelectionBlueprint{HitObject}"/> ordered by their <see cref="HitObject"/> start times.
/// </summary>
public sealed class HitObjectOrderedSelectionContainer : Container<SelectionBlueprint<HitObject>>
public sealed partial class HitObjectOrderedSelectionContainer : Container<SelectionBlueprint<HitObject>>
{
[Resolved]
private EditorBeatmap editorBeatmap { get; set; }

View File

@ -15,7 +15,7 @@ using osuTK;
namespace osu.Game.Screens.Edit.Compose.Components
{
public class RectangularPositionSnapGrid : CompositeDrawable
public partial class RectangularPositionSnapGrid : CompositeDrawable
{
/// <summary>
/// The position of the origin of this <see cref="RectangularPositionSnapGrid"/> in local coordinates.

View File

@ -11,7 +11,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// <summary>
/// A <see cref="DragBox"/> that scrolls along with the scrolling playfield.
/// </summary>
public class ScrollingDragBox : DragBox
public partial class ScrollingDragBox : DragBox
{
public double MinTime { get; private set; }

View File

@ -18,7 +18,7 @@ using osuTK.Input;
namespace osu.Game.Screens.Edit.Compose.Components
{
[Cached]
public class SelectionBox : CompositeDrawable
public partial class SelectionBox : CompositeDrawable
{
public const float BORDER_RADIUS = 3;

View File

@ -15,7 +15,7 @@ using osuTK.Graphics;
namespace osu.Game.Screens.Edit.Compose.Components
{
public sealed class SelectionBoxButton : SelectionBoxControl, IHasTooltip
public sealed partial class SelectionBoxButton : SelectionBoxControl, IHasTooltip
{
private SpriteIcon icon;

View File

@ -17,7 +17,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// Represents the base appearance for UI controls of the <see cref="SelectionBox"/>,
/// such as scale handles, rotation handles, buttons, etc...
/// </summary>
public abstract class SelectionBoxControl : CompositeDrawable
public abstract partial class SelectionBoxControl : CompositeDrawable
{
public const double TRANSFORM_DURATION = 100;

View File

@ -8,7 +8,7 @@ using osu.Framework.Input.Events;
namespace osu.Game.Screens.Edit.Compose.Components
{
public abstract class SelectionBoxDragHandle : SelectionBoxControl
public abstract partial class SelectionBoxDragHandle : SelectionBoxControl
{
protected override bool OnDragStart(DragStartEvent e)
{

View File

@ -15,7 +15,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// <summary>
/// Represents a display composite containing and managing the visibility state of the selection box's drag handles.
/// </summary>
public class SelectionBoxDragHandleContainer : CompositeDrawable
public partial class SelectionBoxDragHandleContainer : CompositeDrawable
{
private Container<SelectionBoxScaleHandle> scaleHandles;
private Container<SelectionBoxRotationHandle> rotationHandles;

View File

@ -18,7 +18,7 @@ using osuTK.Graphics;
namespace osu.Game.Screens.Edit.Compose.Components
{
public class SelectionBoxRotationHandle : SelectionBoxDragHandle, IHasTooltip
public partial class SelectionBoxRotationHandle : SelectionBoxDragHandle, IHasTooltip
{
public Action<float> HandleRotate { get; set; }

View File

@ -11,7 +11,7 @@ using osuTK;
namespace osu.Game.Screens.Edit.Compose.Components
{
public class SelectionBoxScaleHandle : SelectionBoxDragHandle
public partial class SelectionBoxScaleHandle : SelectionBoxDragHandle
{
public Action<Vector2, Anchor> HandleScale { get; set; }

View File

@ -30,7 +30,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// <summary>
/// A component which outlines items and handles movement of selections.
/// </summary>
public abstract class SelectionHandler<T> : CompositeDrawable, IKeyBindingHandler<PlatformAction>, IKeyBindingHandler<GlobalAction>, IHasContextMenu
public abstract partial class SelectionHandler<T> : CompositeDrawable, IKeyBindingHandler<PlatformAction>, IKeyBindingHandler<GlobalAction>, IHasContextMenu
{
/// <summary>
/// The currently selected blueprints.

View File

@ -12,7 +12,7 @@ using osuTK;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class CentreMarker : CompositeDrawable
public partial class CentreMarker : CompositeDrawable
{
private const float triangle_width = 15;
private const float triangle_height = 10;

View File

@ -22,7 +22,7 @@ using osuTK;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class DifficultyPointPiece : HitObjectPointPiece, IHasPopover
public partial class DifficultyPointPiece : HitObjectPointPiece, IHasPopover
{
public readonly HitObject HitObject;
@ -51,7 +51,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
public Popover GetPopover() => new DifficultyEditPopover(HitObject);
public class DifficultyEditPopover : OsuPopover
public partial class DifficultyEditPopover : OsuPopover
{
private readonly HitObject hitObject;

View File

@ -14,7 +14,7 @@ using osuTK.Graphics;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class HitObjectPointPiece : CircularContainer
public partial class HitObjectPointPiece : CircularContainer
{
private readonly ControlPoint point;

View File

@ -20,7 +20,7 @@ using osuTK;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class SamplePointPiece : HitObjectPointPiece, IHasPopover
public partial class SamplePointPiece : HitObjectPointPiece, IHasPopover
{
public readonly HitObject HitObject;
@ -55,7 +55,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
public Popover GetPopover() => new SampleEditPopover(HitObject);
public class SampleEditPopover : OsuPopover
public partial class SampleEditPopover : OsuPopover
{
private readonly HitObject hitObject;

View File

@ -22,7 +22,7 @@ using osuTK.Input;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
[Cached]
public class Timeline : ZoomableScrollContainer, IPositionSnapProvider
public partial class Timeline : ZoomableScrollContainer, IPositionSnapProvider
{
private const float timeline_height = 72;
private const float timeline_expanded_height = 94;

View File

@ -14,7 +14,7 @@ using osuTK;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class TimelineArea : CompositeDrawable
public partial class TimelineArea : CompositeDrawable
{
public Timeline Timeline;

View File

@ -24,7 +24,7 @@ using osuTK.Graphics;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
internal class TimelineBlueprintContainer : EditorBlueprintContainer
internal partial class TimelineBlueprintContainer : EditorBlueprintContainer
{
[Resolved(CanBeNull = true)]
private Timeline timeline { get; set; }
@ -198,7 +198,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
timeline.ScrollBy((float)((mouseX - timelineQuad.TopLeft.X) / 10 * Clock.ElapsedFrameTime));
}
private class SelectableAreaBackground : CompositeDrawable
private partial class SelectableAreaBackground : CompositeDrawable
{
[Resolved]
private OsuColour colours { get; set; }
@ -246,7 +246,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
}
}
protected class TimelineSelectionBlueprintContainer : Container<SelectionBlueprint<HitObject>>
protected partial class TimelineSelectionBlueprintContainer : Container<SelectionBlueprint<HitObject>>
{
protected override Container<SelectionBlueprint<HitObject>> Content { get; }

View File

@ -10,7 +10,7 @@ using osu.Game.Screens.Edit.Timing;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class TimelineButton : IconButton
public partial class TimelineButton : IconButton
{
[BackgroundDependencyLoader]
private void load(OverlayColourProvider colourProvider)

View File

@ -14,7 +14,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
/// <summary>
/// The part of the timeline that displays the control points.
/// </summary>
public class TimelineControlPointDisplay : TimelinePart<TimelineControlPointGroup>
public partial class TimelineControlPointDisplay : TimelinePart<TimelineControlPointGroup>
{
private readonly IBindableList<ControlPointGroup> controlPointGroups = new BindableList<ControlPointGroup>();

View File

@ -10,7 +10,7 @@ using osu.Game.Beatmaps.ControlPoints;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class TimelineControlPointGroup : CompositeDrawable
public partial class TimelineControlPointGroup : CompositeDrawable
{
public readonly ControlPointGroup Group;

View File

@ -11,7 +11,7 @@ using osu.Framework.Input.Events;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class TimelineDragBox : DragBox
public partial class TimelineDragBox : DragBox
{
public double MinTime { get; private set; }

View File

@ -27,7 +27,7 @@ using osuTK.Graphics;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class TimelineHitObjectBlueprint : SelectionBlueprint<HitObject>
public partial class TimelineHitObjectBlueprint : SelectionBlueprint<HitObject>
{
private const float circle_size = 38;
@ -262,7 +262,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
public override Vector2 ScreenSpaceSelectionPoint => ScreenSpaceDrawQuad.TopLeft;
private class Tick : Circle
private partial class Tick : Circle
{
public Tick()
{
@ -273,7 +273,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
}
}
public class DragArea : Circle
public partial class DragArea : Circle
{
private readonly HitObject? hitObject;
@ -444,7 +444,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
}
}
public class Border : ExtendableCircle
public partial class Border : ExtendableCircle
{
[BackgroundDependencyLoader]
private void load(OsuColour colours)
@ -460,7 +460,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
/// <summary>
/// A circle with externalised end caps so it can take up the full width of a relative width area.
/// </summary>
public class ExtendableCircle : CompositeDrawable
public partial class ExtendableCircle : CompositeDrawable
{
protected readonly Circle Content;

View File

@ -16,7 +16,7 @@ using osuTK.Input;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
internal class TimelineSelectionHandler : EditorSelectionHandler
internal partial class TimelineSelectionHandler : EditorSelectionHandler
{
// for now we always allow movement. snapping is provided by the Timeline's "distance" snap implementation
public override bool HandleMovement(MoveSelectionEvent<HitObject> moveEvent) => true;

View File

@ -18,7 +18,7 @@ using osuTK;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class TimelineTickDisplay : TimelinePart<PointVisualisation>
public partial class TimelineTickDisplay : TimelinePart<PointVisualisation>
{
[Resolved]
private EditorBeatmap beatmap { get; set; }

View File

@ -9,7 +9,7 @@ using osu.Game.Beatmaps.ControlPoints;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class TimingPointPiece : TopPointPiece
public partial class TimingPointPiece : TopPointPiece
{
private readonly BindableNumber<double> beatLength;

View File

@ -13,7 +13,7 @@ using osu.Game.Graphics.Sprites;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class TopPointPiece : CompositeDrawable
public partial class TopPointPiece : CompositeDrawable
{
private readonly ControlPoint point;

View File

@ -17,7 +17,7 @@ using osuTK;
namespace osu.Game.Screens.Edit.Compose.Components.Timeline
{
public class ZoomableScrollContainer : OsuScrollContainer
public partial class ZoomableScrollContainer : OsuScrollContainer
{
/// <summary>
/// The time to zoom into/out of a point.