Add xmldoc and address some code quality concerns

This commit is contained in:
Dean Herbert 2020-05-19 23:05:08 +09:00
parent c28a9bdb80
commit 85156c62ef
1 changed files with 18 additions and 15 deletions

View File

@ -21,12 +21,27 @@
namespace osu.Game.Rulesets.Mania.Edit
{
/// <summary>
/// A grid which displays coloured beat divisor lines in proximity to the selection or placement cursor.
/// </summary>
public class ManiaBeatSnapGrid : Component
{
private const double visible_range = 750;
[Resolved]
private IManiaHitObjectComposer composer { get; set; }
/// <summary>
/// The range of time values of the current selection.
/// </summary>
public (double start, double end)? SelectionTimeRange
{
set
{
if (value == selectionTimeRange)
return;
selectionTimeRange = value;
lineCache.Invalidate();
}
}
[Resolved]
private EditorBeatmap beatmap { get; set; }
@ -49,20 +64,8 @@ public class ManiaBeatSnapGrid : Component
private (double start, double end)? selectionTimeRange;
public (double start, double end)? SelectionTimeRange
{
set
{
if (value == selectionTimeRange)
return;
selectionTimeRange = value;
lineCache.Invalidate();
}
}
[BackgroundDependencyLoader]
private void load()
private void load(IManiaHitObjectComposer composer)
{
foreach (var stage in composer.Playfield.Stages)
{