Fix depth values.

This commit is contained in:
Thomas Müller
2016-11-29 20:50:12 +01:00
parent 53df2932ad
commit b12b82fdd3
15 changed files with 19 additions and 19 deletions

View File

@ -39,7 +39,7 @@ namespace osu.Game.Screens.Backgrounds
float newDepth = 0;
if (background != null)
{
newDepth = background.Depth - 1;
newDepth = background.Depth + 1;
background.Flush();
background.FadeOut(250);
background.Expire();

View File

@ -111,7 +111,7 @@ namespace osu.Game.Screens
{
AddInternal(new ParallaxContainer
{
Depth = float.MinValue,
Depth = float.MaxValue,
Children = new[]
{
Background = bg

View File

@ -50,7 +50,7 @@ namespace osu.Game.Screens.Select
var lastContainer = beatmapInfoContainer;
float newDepth = lastContainer?.Depth - 1 ?? 0;
float newDepth = lastContainer?.Depth + 1 ?? 0;
BeatmapSetInfo beatmapSetInfo = beatmap.BeatmapSetInfo;
BeatmapInfo beatmapInfo = beatmap.BeatmapInfo;

View File

@ -81,12 +81,12 @@ namespace osu.Game.Screens.Select
group.State = BeatmapGroupState.Collapsed;
groups.Add(group);
group.Header.Depth = scrollableContent.Children.Count();
group.Header.Depth = -scrollableContent.Children.Count();
scrollableContent.Add(group.Header);
foreach (BeatmapPanel panel in group.BeatmapPanels)
{
panel.Depth = scrollableContent.Children.Count();
panel.Depth = -scrollableContent.Children.Count();
scrollableContent.Add(panel);
}