mirror of
https://github.com/ppy/osu
synced 2025-01-04 21:30:08 +00:00
Fix SourceChanged
not being correctly forwarded through LegacySkinTransformer
This commit is contained in:
parent
47eeab34e1
commit
2438c20d63
@ -53,8 +53,8 @@ namespace osu.Game.Skinning
|
|||||||
|
|
||||||
public event Action SourceChanged
|
public event Action SourceChanged
|
||||||
{
|
{
|
||||||
add { throw new NotSupportedException(); }
|
add => Source.SourceChanged += value;
|
||||||
remove { }
|
remove => Source.SourceChanged -= value;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -46,6 +46,9 @@ namespace osu.Game.Skinning
|
|||||||
RelativeSizeAxes = Axes.Both;
|
RelativeSizeAxes = Axes.Both;
|
||||||
|
|
||||||
noFallbackLookupProxy = new NoFallbackProxy(this);
|
noFallbackLookupProxy = new NoFallbackProxy(this);
|
||||||
|
|
||||||
|
if (skin is ISkinSource source)
|
||||||
|
source.SourceChanged += TriggerSourceChanged;
|
||||||
}
|
}
|
||||||
|
|
||||||
public ISkin FindProvider(Func<ISkin, bool> lookupFunction)
|
public ISkin FindProvider(Func<ISkin, bool> lookupFunction)
|
||||||
@ -168,6 +171,9 @@ namespace osu.Game.Skinning
|
|||||||
|
|
||||||
if (fallbackSource != null)
|
if (fallbackSource != null)
|
||||||
fallbackSource.SourceChanged -= TriggerSourceChanged;
|
fallbackSource.SourceChanged -= TriggerSourceChanged;
|
||||||
|
|
||||||
|
if (skin is ISkinSource source)
|
||||||
|
source.SourceChanged -= TriggerSourceChanged;
|
||||||
}
|
}
|
||||||
|
|
||||||
private class NoFallbackProxy : ISkinSource
|
private class NoFallbackProxy : ISkinSource
|
||||||
|
Loading…
Reference in New Issue
Block a user