From d3cc418961462f9961ba8551e18671c7046c92ed Mon Sep 17 00:00:00 2001 From: Lucas A Date: Thu, 6 May 2021 11:12:19 +0200 Subject: [PATCH] Privatize DirectorySelector. --- .../Sections/Maintenance/DirectorySelectScreen.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/osu.Game/Overlays/Settings/Sections/Maintenance/DirectorySelectScreen.cs b/osu.Game/Overlays/Settings/Sections/Maintenance/DirectorySelectScreen.cs index a6ae3d6132..c08323e67c 100644 --- a/osu.Game/Overlays/Settings/Sections/Maintenance/DirectorySelectScreen.cs +++ b/osu.Game/Overlays/Settings/Sections/Maintenance/DirectorySelectScreen.cs @@ -20,7 +20,7 @@ namespace osu.Game.Overlays.Settings.Sections.Maintenance { private TriangleButton selectionButton; - protected DirectorySelector DirectorySelector { get; private set; } + private DirectorySelector directorySelector; protected override OverlayActivation InitialOverlayActivationMode => OverlayActivation.Disabled; @@ -79,7 +79,7 @@ namespace osu.Game.Overlays.Settings.Sections.Maintenance }, new Drawable[] { - DirectorySelector = new DirectorySelector + directorySelector = new DirectorySelector { RelativeSizeAxes = Axes.Both, } @@ -92,7 +92,7 @@ namespace osu.Game.Overlays.Settings.Sections.Maintenance Origin = Anchor.Centre, Width = 300, Text = "Select directory", - Action = () => OnSelection(DirectorySelector.CurrentPath.Value) + Action = () => OnSelection(directorySelector.CurrentPath.Value) }, } } @@ -104,9 +104,9 @@ namespace osu.Game.Overlays.Settings.Sections.Maintenance protected override void LoadComplete() { if (InitialPath != null) - DirectorySelector.CurrentPath.Value = InitialPath; + directorySelector.CurrentPath.Value = InitialPath; - DirectorySelector.CurrentPath.BindValueChanged(e => selectionButton.Enabled.Value = IsValidDirectory(e.NewValue), true); + directorySelector.CurrentPath.BindValueChanged(e => selectionButton.Enabled.Value = IsValidDirectory(e.NewValue), true); base.LoadComplete(); }