1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-12 04:40:07 +08:00

Merge branch 'master' into partial-judgements

This commit is contained in:
Dean Herbert 2017-03-30 14:07:43 +09:00 committed by GitHub
commit 77ac205b62
6 changed files with 11 additions and 7 deletions

View File

@ -36,7 +36,8 @@ namespace osu.Game.Beatmaps.Drawables
new DelayedLoadContainer
{
RelativeSizeAxes = Axes.Both,
TimeBeforeLoad = 100,
TimeBeforeLoad = 300,
FinishedLoading = d => d.FadeInFromZero(400, EasingTypes.Out),
Children = new[]
{
new PanelBackground(beatmap)

View File

@ -199,7 +199,7 @@ namespace osu.Game
{
Depth = -3,
OnHome = delegate { intro?.ChildScreen?.MakeCurrent(); },
OnPlayModeChange = delegate (PlayMode m) { PlayMode.Value = m; },
OnPlayModeChange = m => PlayMode.Value = m,
}).LoadAsync(this, t =>
{
PlayMode.ValueChanged += delegate { Toolbar.SetGameMode(PlayMode.Value); };

View File

@ -65,14 +65,13 @@ namespace osu.Game.Overlays.Toolbar
foreach (PlayMode m in Ruleset.PlayModes)
{
var localMode = m;
modeButtons.Add(new ToolbarModeButton
{
Mode = m,
Action = delegate
{
SetGameMode(localMode);
OnPlayModeChange?.Invoke(localMode);
SetGameMode(m);
OnPlayModeChange?.Invoke(m);
}
});
}

View File

@ -181,7 +181,8 @@ namespace osu.Game.Screens.Select
{
if (!IsLoaded) return;
criteria = newCriteria ?? criteria ?? new FilterCriteria();
if (newCriteria != null)
criteria = newCriteria;
Action perform = delegate
{
@ -202,6 +203,8 @@ namespace osu.Game.Screens.Select
if (selectedGroup == null || selectedGroup.State == BeatmapGroupState.Hidden)
SelectNext();
else
selectGroup(selectedGroup);
};
filterTask?.Cancel();

View File

@ -175,6 +175,7 @@ namespace osu.Game.Screens.Select
if (osu != null)
playMode.BindTo(osu.PlayMode);
playMode.ValueChanged += (s, e) => FilterChanged?.Invoke(CreateCriteria());
}
protected override bool OnMouseDown(InputState state, MouseDownEventArgs args) => true;

View File

@ -276,7 +276,7 @@ namespace osu.Game.Screens.Select
initialAddSetsTask.Cancel();
}
private void playMode_ValueChanged(object sender, EventArgs e) => carousel.Filter();
private void playMode_ValueChanged(object sender, EventArgs e) => Beatmap.PreferredPlayMode = playMode;
private void changeBackground(WorkingBeatmap beatmap)
{