1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-06 12:17:46 +08:00

Merge branch 'master' of https://github.com/ppy/osu into ipc-directory-regression

This commit is contained in:
Shivam 2021-03-29 15:03:24 +02:00
commit c110c24924
2 changed files with 8 additions and 2 deletions

View File

@ -71,7 +71,13 @@ namespace osu.Game.Screens.Edit.Compose.Components
// Put earlier blueprints towards the end of the list, so they handle input first // Put earlier blueprints towards the end of the list, so they handle input first
int i = yObj.HitObject.StartTime.CompareTo(xObj.HitObject.StartTime); int i = yObj.HitObject.StartTime.CompareTo(xObj.HitObject.StartTime);
return i == 0 ? CompareReverseChildID(x, y) : i;
if (i != 0) return i;
// Fall back to end time if the start time is equal.
i = yObj.HitObject.GetEndTime().CompareTo(xObj.HitObject.GetEndTime());
return i == 0 ? CompareReverseChildID(y, x) : i;
} }
} }
} }

View File

@ -138,7 +138,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
Stack<HitObject> currentConcurrentObjects = new Stack<HitObject>(); Stack<HitObject> currentConcurrentObjects = new Stack<HitObject>();
foreach (var b in SelectionBlueprints.OrderBy(b => b.HitObject.StartTime).ThenBy(b => b.HitObject.GetEndTime())) foreach (var b in SelectionBlueprints.Reverse())
{ {
// remove objects from the stack as long as their end time is in the past. // remove objects from the stack as long as their end time is in the past.
while (currentConcurrentObjects.TryPeek(out HitObject hitObject)) while (currentConcurrentObjects.TryPeek(out HitObject hitObject))