mirror of
https://github.com/ppy/osu.git
synced 2025-01-15 23:12:55 +08:00
Add comment.
This commit is contained in:
parent
02cab41d34
commit
123c8f3489
@ -53,8 +53,12 @@ namespace osu.Game.Modes.UI
|
|||||||
|
|
||||||
private class ScaledContainer : Container
|
private class ScaledContainer : Container
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// A value (in game pixels that we should scale our content to match).
|
||||||
|
/// </summary>
|
||||||
public float? CustomWidth;
|
public float? CustomWidth;
|
||||||
|
|
||||||
|
//dividing by the customwidth will effectively scale our content to the required container size.
|
||||||
protected override Vector2 DrawScale => CustomWidth.HasValue ? new Vector2(DrawSize.X / CustomWidth.Value) : base.DrawScale;
|
protected override Vector2 DrawScale => CustomWidth.HasValue ? new Vector2(DrawSize.X / CustomWidth.Value) : base.DrawScale;
|
||||||
|
|
||||||
public override bool Contains(Vector2 screenSpacePos) => true;
|
public override bool Contains(Vector2 screenSpacePos) => true;
|
||||||
|
Loading…
Reference in New Issue
Block a user