mirror of
https://github.com/ppy/osu.git
synced 2026-05-23 19:00:09 +08:00
Dispose ResourcesSkin before clearing skin sources
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using System.Linq;
|
||||
using JetBrains.Annotations;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Audio;
|
||||
@@ -72,6 +73,9 @@ namespace osu.Game.Skinning
|
||||
|
||||
protected virtual void UpdateSkins()
|
||||
{
|
||||
foreach (var resourcesSkin in SkinSources.OfType<ResourcesSkin>())
|
||||
resourcesSkin.Dispose();
|
||||
|
||||
SkinSources.Clear();
|
||||
|
||||
foreach (var skin in skinSource.AllSources)
|
||||
|
||||
Reference in New Issue
Block a user