1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-15 15:12:57 +08:00

Merge branch 'master' into multiplayer-match-rulesets

This commit is contained in:
Dean Herbert 2021-08-03 23:40:24 +09:00
commit c856611f65
2 changed files with 6 additions and 4 deletions

View File

@ -14,7 +14,7 @@ using osuTK;
namespace osu.Game.Screens.OnlinePlay.Match.Components namespace osu.Game.Screens.OnlinePlay.Match.Components
{ {
public class GameTypePicker : DisableableTabControl<MatchType> public class MatchTypePicker : DisableableTabControl<MatchType>
{ {
private const float height = 40; private const float height = 40;
private const float selection_width = 3; private const float selection_width = 3;
@ -23,13 +23,15 @@ namespace osu.Game.Screens.OnlinePlay.Match.Components
protected override Dropdown<MatchType> CreateDropdown() => null; protected override Dropdown<MatchType> CreateDropdown() => null;
public GameTypePicker() public MatchTypePicker()
{ {
Height = height + selection_width * 2; Height = height + selection_width * 2;
TabContainer.Spacing = new Vector2(10 - selection_width * 2); TabContainer.Spacing = new Vector2(10 - selection_width * 2);
AddItem(MatchType.HeadToHead); AddItem(MatchType.HeadToHead);
AddItem(MatchType.TeamVersus); AddItem(MatchType.TeamVersus);
// TODO: remove after osu-web is updated to set the correct default type.
AddItem(MatchType.Playlists);
} }
private class GameTypePickerItem : DisableableTabItem private class GameTypePickerItem : DisableableTabItem

View File

@ -44,7 +44,7 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer.Match
public OsuTextBox NameField, MaxParticipantsField; public OsuTextBox NameField, MaxParticipantsField;
public RoomAvailabilityPicker AvailabilityPicker; public RoomAvailabilityPicker AvailabilityPicker;
public GameTypePicker TypePicker; public MatchTypePicker TypePicker;
public OsuTextBox PasswordTextBox; public OsuTextBox PasswordTextBox;
public TriangleButton ApplyButton; public TriangleButton ApplyButton;
@ -158,7 +158,7 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer.Match
Spacing = new Vector2(7), Spacing = new Vector2(7),
Children = new Drawable[] Children = new Drawable[]
{ {
TypePicker = new GameTypePicker TypePicker = new MatchTypePicker
{ {
RelativeSizeAxes = Axes.X, RelativeSizeAxes = Axes.X,
Enabled = { Value = false } Enabled = { Value = false }