mirror of
https://github.com/ppy/osu.git
synced 2025-01-12 10:22:56 +08:00
Final changes to DI fields and values
This commit is contained in:
parent
477bd7fa61
commit
a7792070bc
@ -11,16 +11,13 @@ namespace osu.Game.Overlays.Settings.Sections.General
|
||||
{
|
||||
public class UpdateSettings : SettingsSubsection
|
||||
{
|
||||
[Resolved(CanBeNull = true)]
|
||||
private OsuGameBase game { get; set; }
|
||||
|
||||
[Resolved(CanBeNull = true)]
|
||||
private UpdateManager updateManager { get; set; }
|
||||
|
||||
protected override string Header => "Updates";
|
||||
|
||||
[BackgroundDependencyLoader(true)]
|
||||
private void load(Storage storage, OsuConfigManager config)
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(Storage storage, OsuConfigManager config, OsuGameBase game)
|
||||
{
|
||||
Add(new SettingsEnumDropdown<ReleaseStream>
|
||||
{
|
||||
@ -28,7 +25,8 @@ namespace osu.Game.Overlays.Settings.Sections.General
|
||||
Bindable = config.GetBindable<ReleaseStream>(OsuSetting.ReleaseStream),
|
||||
});
|
||||
|
||||
if (game != null && updateManager != null)
|
||||
// We shouldn't display the button for the base UpdateManager (without updating logic)
|
||||
if (updateManager != null && updateManager.GetType() != typeof(UpdateManager))
|
||||
{
|
||||
Add(new SettingsButton
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user