mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 15:07:44 +08:00
Merge pull request #12667 from peppy/fix-editor-threading-failure
Remove unsafe access to Composer.HitObjects
This commit is contained in:
commit
f2f41545f8
@ -34,13 +34,6 @@ namespace osu.Game.Screens.Edit.Compose.Components
|
||||
[BackgroundDependencyLoader]
|
||||
private void load()
|
||||
{
|
||||
// For non-pooled rulesets, hitobjects are already present in the playfield which allows the blueprints to be loaded in the async context.
|
||||
if (Composer != null)
|
||||
{
|
||||
foreach (var obj in Composer.HitObjects)
|
||||
AddBlueprintFor(obj.HitObject);
|
||||
}
|
||||
|
||||
selectedHitObjects.BindTo(Beatmap.SelectedHitObjects);
|
||||
selectedHitObjects.CollectionChanged += (selectedObjects, args) =>
|
||||
{
|
||||
@ -69,7 +62,6 @@ namespace osu.Game.Screens.Edit.Compose.Components
|
||||
|
||||
if (Composer != null)
|
||||
{
|
||||
// For pooled rulesets, blueprints must be added for hitobjects already "current" as they would've not been "current" during the async load addition process above.
|
||||
foreach (var obj in Composer.HitObjects)
|
||||
AddBlueprintFor(obj.HitObject);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user