mirror of
https://github.com/osukey/osukey.git
synced 2025-07-01 16:29:58 +09:00
Initial commit.
This commit is contained in:
19
osu.Game/Graphics/Processing/RatioAdjust.cs
Normal file
19
osu.Game/Graphics/Processing/RatioAdjust.cs
Normal file
@ -0,0 +1,19 @@
|
||||
//Copyright (c) 2007-2016 ppy Pty Ltd <contact@ppy.sh>.
|
||||
//Licensed under the MIT License - 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);
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user