1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-13 08:32:57 +08:00

Update to latest framework version.

This commit is contained in:
Dean Herbert 2016-09-11 02:23:26 +09:00
parent e27eb996bc
commit 842fb1892f
7 changed files with 17 additions and 16 deletions

@ -1 +1 @@
Subproject commit 1b97dd48c3efa59f97907d7868f007c999686e66
Subproject commit 0576492962ac9fd80b46706ae5a78be9e99ae1b5

View File

@ -122,7 +122,7 @@ namespace osu.Game.GameModes
protected override bool OnClick(InputState state)
{
Scale = 1.5f;
Scale = new Vector2(1.5f);
ScaleTo(1, 500, EasingTypes.In);
Activated?.Invoke();

View File

@ -13,6 +13,7 @@ using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Drawables;
using osu.Framework.Graphics.Sprites;
using osu.Game.Graphics.Containers;
using OpenTK;
namespace osu.Game.GameModes
{
@ -36,7 +37,7 @@ namespace osu.Game.GameModes
SpriteText text = new SpriteText()
{
Text = $@"Font testy at size {i}",
Scale = i
Scale = new Vector2(i)
};
flow.Add(text);

View File

@ -279,7 +279,7 @@ namespace osu.Game.GameModes.Menu
private MenuVisualisation vis;
private Action clickAction;
public float SizeForFlow => logo == null ? 0 : logo.ActualSize.X * logo.Scale * logoBounceContainer.Scale * 0.8f;
public float SizeForFlow => logo == null ? 0 : logo.ActualSize.X * logo.Scale.X * logoBounceContainer.Scale.X * 0.8f;
public override void Load()
{
@ -424,7 +424,7 @@ namespace osu.Game.GameModes.Menu
Anchor = Anchor.Centre,
Origin = Anchor.Centre,
Colour = colour,
VectorScale = new Vector2(0, 1)
Scale = new Vector2(0, 1)
});
iconText = new AutoSizeContainer
@ -440,7 +440,7 @@ namespace osu.Game.GameModes.Menu
{
Anchor = Anchor.Centre,
Origin = Anchor.Centre,
Scale = 0.7f,
Scale = new Vector2(0.7f),
};
iconText.Add(icon);
@ -588,8 +588,8 @@ namespace osu.Game.GameModes.Menu
protected override void Update()
{
HandleInput = state != ButtonState.Exploded && box.VectorScale.X >= 0.8f;
iconText.Alpha = MathHelper.Clamp((box.VectorScale.X - 0.5f) / 0.3f, 0, 1);
HandleInput = state != ButtonState.Exploded && box.Scale.X >= 0.8f;
iconText.Alpha = MathHelper.Clamp((box.Scale.X - 0.5f) / 0.3f, 0, 1);
base.Update();
}
@ -663,7 +663,7 @@ namespace osu.Game.GameModes.Menu
Quad q = base.DrawQuad;
//Will become infinite if we don't limit its maximum size.
float wedge = Math.Min(q.Width, wedgeWidth / Scale / VectorScale.X);
float wedge = Math.Min(q.Width, wedgeWidth / Scale.X);
q.TopLeft.X += wedge;
q.BottomRight.X -= wedge;

View File

@ -12,8 +12,8 @@ namespace osu.Game.Graphics.Processing
protected override void Update()
{
base.Update();
Scale = Parent.ActualSize.Y / 768f;
Size = new Vector2(1 / Scale);
Scale = new Vector2(Parent.ActualSize.Y / 768f);
Size = new Vector2(1 / Scale.X);
}
}
}

View File

@ -70,8 +70,8 @@ namespace osu.Game.Graphics.UserInterface
SizeMode = InheritMode.Y,
Alpha = 0
};
TextContainer.Add(cursor);
TextContainer.Add(cursor);
TextContainer.Add(textFlow);
}

View File

@ -46,7 +46,7 @@ namespace osu.Game
//};
//API.Queue(req);
AddProcessingContainer(new RatioAdjust());
AddProcessing(new RatioAdjust());
//Add(new FontTest());
@ -62,10 +62,10 @@ namespace osu.Game
base.Dispose(isDisposing);
}
public override bool Invalidate(bool affectsSize = true, bool affectsPosition = true, Drawable source = null)
public override bool Invalidate(Invalidation invalidation = Invalidation.All, Drawable source = null, bool shallPropagate = true)
{
if (!base.Invalidate(affectsSize, affectsPosition, source)) return false;
if (!base.Invalidate(invalidation, source, shallPropagate)) return false;
if (Parent != null)
{
Parent.Width = Config.Set(OsuConfig.Width, ActualSize.X).Value;