1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-12 02:27:25 +08:00
osu-lazer/osu.Game/Graphics/Processing/RatioAdjust.cs
2016-08-26 17:27:49 +09:00

20 lines
530 B
C#

//Copyright (c) 2007-2016 ppy Pty Ltd <contact@ppy.sh>.
//Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using OpenTK;
namespace osu.Game.Graphics.Processing
{
class RatioAdjust : LargeContainer
{
protected override void Update()
{
base.Update();
Scale = Parent.ActualSize.Y / 768f;
Size = new Vector2(1 / Scale);
}
}
}