mirror of
https://github.com/ppy/osu.git
synced 2024-12-15 00:33:21 +08:00
Update framework with better children list
This commit is contained in:
parent
f70bdd80aa
commit
1bca9ca0e9
@ -35,7 +35,7 @@ namespace osu.Game.Overlays.Chat
|
||||
|
||||
public IEnumerable<Channel> Channels
|
||||
{
|
||||
set { ChannelFlow.Children = value.Select(c => new ChannelListItem(c)); }
|
||||
set { ChannelFlow.ChildrenEnumerable = value.Select(c => new ChannelListItem(c)); }
|
||||
}
|
||||
|
||||
public ChannelSection()
|
||||
|
@ -38,7 +38,7 @@ namespace osu.Game.Overlays.Chat
|
||||
{
|
||||
set
|
||||
{
|
||||
sectionsFlow.Children = value;
|
||||
sectionsFlow.ChildrenEnumerable = value;
|
||||
|
||||
foreach (ChannelSection s in sectionsFlow.Children)
|
||||
{
|
||||
|
@ -56,7 +56,7 @@ namespace osu.Game.Overlays.Dialog
|
||||
get { return buttonsContainer.Children; }
|
||||
set
|
||||
{
|
||||
buttonsContainer.Children = value;
|
||||
buttonsContainer.ChildrenEnumerable = value;
|
||||
foreach (PopupDialogButton b in value)
|
||||
{
|
||||
var action = b.Action;
|
||||
|
@ -24,7 +24,7 @@ namespace osu.Game.Overlays.Direct
|
||||
SetInfo = setInfo;
|
||||
}
|
||||
|
||||
protected IEnumerable<DifficultyIcon> GetDifficultyIcons()
|
||||
protected List<DifficultyIcon> GetDifficultyIcons()
|
||||
{
|
||||
var icons = new List<DifficultyIcon>();
|
||||
|
||||
|
@ -129,7 +129,7 @@ namespace osu.Game.Overlays
|
||||
private void recreatePanels(PanelDisplayStyle displayStyle)
|
||||
{
|
||||
if (BeatmapSets == null) return;
|
||||
panels.Children = BeatmapSets.Select(b => displayStyle == PanelDisplayStyle.Grid ? (DirectPanel)new DirectGridPanel(b) { Width = 400 } : new DirectListPanel(b));
|
||||
panels.ChildrenEnumerable = BeatmapSets.Select(b => displayStyle == PanelDisplayStyle.Grid ? (DirectPanel)new DirectGridPanel(b) { Width = 400 } : new DirectListPanel(b));
|
||||
}
|
||||
|
||||
public class ResultCounts
|
||||
|
@ -44,7 +44,7 @@ namespace osu.Game.Overlays
|
||||
panelFlow.Clear();
|
||||
else
|
||||
{
|
||||
panelFlow.Children = users.Select(u =>
|
||||
panelFlow.ChildrenEnumerable = users.Select(u =>
|
||||
{
|
||||
var p = new UserPanel(u) { Width = 300 };
|
||||
p.Status.BindTo(u.Status);
|
||||
|
@ -495,7 +495,7 @@ namespace osu.Game.Screens.Multiplayer
|
||||
levelRangeLower.Text = ranks.Min().ToString();
|
||||
levelRangeHigher.Text = ranks.Max().ToString();
|
||||
|
||||
participantsFlow.Children = value.Select(u => new UserTile(u));
|
||||
participantsFlow.ChildrenEnumerable = value.Select(u => new UserTile(u));
|
||||
}
|
||||
|
||||
private class UserTile : Container, IHasTooltip
|
||||
|
@ -164,7 +164,7 @@ namespace osu.Game.Screens.Ranking
|
||||
}
|
||||
};
|
||||
|
||||
statisticsContainer.Children = Score.Statistics.Select(s => new DrawableScoreStatistic(s));
|
||||
statisticsContainer.ChildrenEnumerable = Score.Statistics.Select(s => new DrawableScoreStatistic(s));
|
||||
}
|
||||
|
||||
protected override void LoadComplete()
|
||||
|
@ -439,7 +439,7 @@ namespace osu.Game.Screens.Select
|
||||
{
|
||||
Show();
|
||||
if (header.Text == "Tags")
|
||||
content.Children = value.Split(' ').Select(text => new OsuSpriteText
|
||||
content.ChildrenEnumerable = value.Split(' ').Select(text => new OsuSpriteText
|
||||
{
|
||||
Text = text,
|
||||
Font = "Exo2.0-Regular",
|
||||
|
Loading…
Reference in New Issue
Block a user