mirror of
https://github.com/ppy/osu.git
synced 2025-01-12 15:22:55 +08:00
Add comments + cleanup
This commit is contained in:
parent
8191f03503
commit
1c242556ca
@ -170,6 +170,7 @@ namespace osu.Game.Skinning
|
||||
{
|
||||
string textureName = $"{font}-{c}";
|
||||
|
||||
// Approximate value that brings character sizing roughly in-line with stable
|
||||
float ratio = 36;
|
||||
|
||||
var texture = textures.Get($"{textureName}@2x");
|
||||
|
@ -18,6 +18,9 @@ namespace osu.Game.Skinning
|
||||
public class SkinnableDrawable<T> : SkinReloadableDrawable
|
||||
where T : Drawable
|
||||
{
|
||||
/// <summary>
|
||||
/// The displayed component. May or may not be a type-<typeparamref name="T"/> member.
|
||||
/// </summary>
|
||||
protected Drawable Drawable { get; private set; }
|
||||
|
||||
private readonly Func<string, T> createDefault;
|
||||
@ -45,7 +48,6 @@ namespace osu.Game.Skinning
|
||||
|
||||
protected override void SkinChanged(ISkinSource skin, bool allowFallback)
|
||||
{
|
||||
Drawable = null;
|
||||
Drawable = skin.GetDrawableComponent(componentName);
|
||||
|
||||
if (Drawable != null)
|
||||
|
Loading…
Reference in New Issue
Block a user