mirror of
https://github.com/osukey/osukey.git
synced 2025-08-04 23:24:04 +09:00
Fix the MOTHERLOAD of undetected issues that are now visible thanks to net6.0
This commit is contained in:
@ -58,6 +58,8 @@ namespace osu.Game.Screens.Edit.Compose.Components
|
||||
switch (args.Action)
|
||||
{
|
||||
case NotifyCollectionChangedAction.Add:
|
||||
Debug.Assert(args.NewItems != null);
|
||||
|
||||
foreach (object o in args.NewItems)
|
||||
{
|
||||
if (blueprintMap.TryGetValue((T)o, out var blueprint))
|
||||
@ -67,6 +69,8 @@ namespace osu.Game.Screens.Edit.Compose.Components
|
||||
break;
|
||||
|
||||
case NotifyCollectionChangedAction.Remove:
|
||||
Debug.Assert(args.OldItems != null);
|
||||
|
||||
foreach (object o in args.OldItems)
|
||||
{
|
||||
if (blueprintMap.TryGetValue((T)o, out var blueprint))
|
||||
|
@ -4,6 +4,7 @@
|
||||
#nullable disable
|
||||
|
||||
using System.Collections.Specialized;
|
||||
using System.Diagnostics;
|
||||
using System.Linq;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Game.Beatmaps.ControlPoints;
|
||||
@ -33,11 +34,15 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
|
||||
break;
|
||||
|
||||
case NotifyCollectionChangedAction.Add:
|
||||
Debug.Assert(args.NewItems != null);
|
||||
|
||||
foreach (var group in args.NewItems.OfType<ControlPointGroup>())
|
||||
Add(new TimelineControlPointGroup(group));
|
||||
break;
|
||||
|
||||
case NotifyCollectionChangedAction.Remove:
|
||||
Debug.Assert(args.OldItems != null);
|
||||
|
||||
foreach (var group in args.OldItems.OfType<ControlPointGroup>())
|
||||
{
|
||||
var matching = Children.SingleOrDefault(gv => ReferenceEquals(gv.Group, group));
|
||||
|
Reference in New Issue
Block a user