mirror of
https://github.com/ppy/osu.git
synced 2024-11-13 21:27:54 +08:00
Fix nullability
This commit is contained in:
parent
b6dc483fc1
commit
abfcac7466
@ -105,7 +105,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
|
|||||||
background.FadeColour(IsHovered ? colours.Gray6 : colours.Gray5, 400, Easing.OutQuint);
|
background.FadeColour(IsHovered ? colours.Gray6 : colours.Gray5, 400, Easing.OutQuint);
|
||||||
}
|
}
|
||||||
|
|
||||||
public MenuItem[]? ContextMenuItems => new MenuItem[]
|
public MenuItem[] ContextMenuItems => new MenuItem[]
|
||||||
{
|
{
|
||||||
new OsuMenuItem(CommonStrings.ButtonsDelete, MenuItemType.Destructive, () => OnDeleted?.Invoke(Break.Value)),
|
new OsuMenuItem(CommonStrings.ButtonsDelete, MenuItemType.Destructive, () => OnDeleted?.Invoke(Break.Value)),
|
||||||
};
|
};
|
||||||
|
@ -16,7 +16,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
|
|||||||
private Timeline timeline { get; set; } = null!;
|
private Timeline timeline { get; set; } = null!;
|
||||||
|
|
||||||
[Resolved]
|
[Resolved]
|
||||||
private IEditorChangeHandler editorChangeHandler { get; set; } = null!;
|
private IEditorChangeHandler? editorChangeHandler { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The visible time/position range of the timeline.
|
/// The visible time/position range of the timeline.
|
||||||
@ -78,9 +78,9 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
|
|||||||
{
|
{
|
||||||
OnDeleted = b =>
|
OnDeleted = b =>
|
||||||
{
|
{
|
||||||
editorChangeHandler.BeginChange();
|
editorChangeHandler?.BeginChange();
|
||||||
breaks.Remove(b);
|
breaks.Remove(b);
|
||||||
editorChangeHandler.EndChange();
|
editorChangeHandler?.EndChange();
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user