private void load(LyricCheckerManager lyricCheckerManager, NoteManager noteManager) { bindableReports = lyricCheckerManager.BindableReports.GetBoundCopy(); bindableReports.BindCollectionChanged((a, b) => { var hasTimeTagIssue = bindableReports.Values.SelectMany(x => x) .OfType <TimeTagIssue>().Any(); if (hasTimeTagIssue) { Children = new[] { new OsuSpriteText { Text = "Seems there's some time-tag issue in lyric. \nGo to time-tag edit mode then clear those issues." } }; } else { Children = new[] { new AutoGenerateButton { Text = "Generate", Action = () => { // todo : should be able to apply only selected lyric. var lyrics = beatmap.HitObjects.OfType <Lyric>().ToArray(); noteManager.AutoGenerateNotes(lyrics); } }, }; } }, true); }