mirror of
https://github.com/ppy/osu.git
synced 2025-01-13 08:02:54 +08:00
Fix CI errors
This commit is contained in:
parent
0b735b84cf
commit
7ab27399bf
@ -28,9 +28,7 @@ namespace osu.Game.Screens.Import
|
|||||||
|
|
||||||
public override bool HideOverlaysOnEnter => true;
|
public override bool HideOverlaysOnEnter => true;
|
||||||
|
|
||||||
private string[] fileExtensions;
|
|
||||||
private string defaultPath;
|
private string defaultPath;
|
||||||
|
|
||||||
private readonly Bindable<FileInfo> currentFile = new Bindable<FileInfo>();
|
private readonly Bindable<FileInfo> currentFile = new Bindable<FileInfo>();
|
||||||
private readonly IBindable<DirectoryInfo> currentDirectory = new Bindable<DirectoryInfo>();
|
private readonly IBindable<DirectoryInfo> currentDirectory = new Bindable<DirectoryInfo>();
|
||||||
private TextFlowContainer currentFileText;
|
private TextFlowContainer currentFileText;
|
||||||
@ -45,7 +43,7 @@ namespace osu.Game.Screens.Import
|
|||||||
{
|
{
|
||||||
storage.GetStorageForDirectory("imports");
|
storage.GetStorageForDirectory("imports");
|
||||||
var originalPath = storage.GetFullPath("imports", true);
|
var originalPath = storage.GetFullPath("imports", true);
|
||||||
fileExtensions = new string[] { ".osk", ".osr", ".osz" };
|
string[] fileExtensions = { ".osk", ".osr", ".osz" };
|
||||||
defaultPath = originalPath;
|
defaultPath = originalPath;
|
||||||
|
|
||||||
InternalChild = contentContainer = new Container
|
InternalChild = contentContainer = new Container
|
||||||
@ -126,7 +124,7 @@ namespace osu.Game.Screens.Import
|
|||||||
{
|
{
|
||||||
RelativeSizeAxes = Axes.X,
|
RelativeSizeAxes = Axes.X,
|
||||||
AutoSizeAxes = Axes.Y,
|
AutoSizeAxes = Axes.Y,
|
||||||
Margin = new MarginPadding { Bottom = 15, Top =15 },
|
Margin = new MarginPadding { Bottom = 15, Top =15 } ,
|
||||||
Children = new Drawable[]
|
Children = new Drawable[]
|
||||||
{
|
{
|
||||||
new FillFlowContainer
|
new FillFlowContainer
|
||||||
@ -135,21 +133,21 @@ namespace osu.Game.Screens.Import
|
|||||||
AutoSizeAxes = Axes.Y,
|
AutoSizeAxes = Axes.Y,
|
||||||
Children = new Drawable[]
|
Children = new Drawable[]
|
||||||
{
|
{
|
||||||
new TriangleButton
|
new TriangleButton
|
||||||
{
|
{
|
||||||
Text = "Import",
|
Text = "Import",
|
||||||
Anchor = Anchor.BottomCentre,
|
Anchor = Anchor.BottomCentre,
|
||||||
Origin = Anchor.BottomCentre,
|
Origin = Anchor.BottomCentre,
|
||||||
RelativeSizeAxes = Axes.X,
|
RelativeSizeAxes = Axes.X,
|
||||||
Height = 50,
|
Height = 50,
|
||||||
Width = 0.9f,
|
Width = 0.9f,
|
||||||
Action = () =>
|
Action = () =>
|
||||||
{
|
{
|
||||||
var d = currentFile.Value?.FullName;
|
var d = currentFile.Value?.FullName;
|
||||||
if (d != null)
|
if (d != null)
|
||||||
startImport(d);
|
startImport(d);
|
||||||
else
|
else
|
||||||
currentFileText.FlashColour(Color4.Red, 500);
|
currentFileText.FlashColour(Color4.Red, 500);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -187,6 +185,7 @@ namespace osu.Game.Screens.Import
|
|||||||
|
|
||||||
fileSelectContainer.Add(fileSelector);
|
fileSelectContainer.Add(fileSelector);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void updateFileSelectionText(ValueChangedEvent<FileInfo> v)
|
private void updateFileSelectionText(ValueChangedEvent<FileInfo> v)
|
||||||
{
|
{
|
||||||
currentFileText.Text = v.NewValue?.Name ?? "Select a file";
|
currentFileText.Text = v.NewValue?.Name ?? "Select a file";
|
||||||
|
Loading…
Reference in New Issue
Block a user