mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 11:07:52 +08:00
Allow editor change handler to be null
This commit is contained in:
parent
190c6ef45e
commit
94a8784e04
@ -25,7 +25,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
|
||||
[Resolved]
|
||||
private BindableBeatDivisor beatDivisor { get; set; }
|
||||
|
||||
[Resolved]
|
||||
[Resolved(CanBeNull = true)]
|
||||
private IEditorChangeHandler changeHandler { get; set; }
|
||||
|
||||
[Resolved]
|
||||
@ -43,8 +43,9 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
|
||||
{
|
||||
beatDivisor.BindValueChanged(_ => invalidateTicks());
|
||||
|
||||
// currently this is the best way to handle any kind of timing changes.
|
||||
changeHandler.OnStateChange += invalidateTicks;
|
||||
if (changeHandler != null)
|
||||
// currently this is the best way to handle any kind of timing changes.
|
||||
changeHandler.OnStateChange += invalidateTicks;
|
||||
}
|
||||
|
||||
private void invalidateTicks()
|
||||
|
Loading…
Reference in New Issue
Block a user