mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 23:52:57 +08:00
Merge pull request #22371 from peppy/more-settings-keywords
Add more keywords to settings based on feedback
This commit is contained in:
commit
9f2ed853eb
@ -35,6 +35,7 @@ namespace osu.Game.Overlays.Settings.Sections.Gameplay
|
|||||||
new SettingsCheckbox
|
new SettingsCheckbox
|
||||||
{
|
{
|
||||||
LabelText = SkinSettingsStrings.GameplayCursorDuringTouch,
|
LabelText = SkinSettingsStrings.GameplayCursorDuringTouch,
|
||||||
|
Keywords = new[] { @"touchscreen" },
|
||||||
Current = config.GetBindable<bool>(OsuSetting.GameplayCursorDuringTouch)
|
Current = config.GetBindable<bool>(OsuSetting.GameplayCursorDuringTouch)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
@ -70,6 +70,7 @@ namespace osu.Game.Overlays.Settings.Sections.General
|
|||||||
Add(new SettingsButton
|
Add(new SettingsButton
|
||||||
{
|
{
|
||||||
Text = GeneralSettingsStrings.OpenOsuFolder,
|
Text = GeneralSettingsStrings.OpenOsuFolder,
|
||||||
|
Keywords = new[] { @"logs", @"files", @"access", "directory" },
|
||||||
Action = () => storage.PresentExternally(),
|
Action = () => storage.PresentExternally(),
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -34,6 +34,7 @@ namespace osu.Game.Overlays.Settings.Sections
|
|||||||
new SettingsButton
|
new SettingsButton
|
||||||
{
|
{
|
||||||
Text = GeneralSettingsStrings.RunSetupWizard,
|
Text = GeneralSettingsStrings.RunSetupWizard,
|
||||||
|
Keywords = new[] { @"first run", @"initial", @"getting started" },
|
||||||
TooltipText = FirstRunSetupOverlayStrings.FirstRunSetupDescription,
|
TooltipText = FirstRunSetupOverlayStrings.FirstRunSetupDescription,
|
||||||
Action = () => firstRunSetupOverlay?.Show(),
|
Action = () => firstRunSetupOverlay?.Show(),
|
||||||
},
|
},
|
||||||
|
@ -15,7 +15,7 @@ namespace osu.Game.Overlays.Settings.Sections.Input
|
|||||||
{
|
{
|
||||||
protected override LocalisableString Header => BindingSettingsStrings.ShortcutAndGameplayBindings;
|
protected override LocalisableString Header => BindingSettingsStrings.ShortcutAndGameplayBindings;
|
||||||
|
|
||||||
public override IEnumerable<LocalisableString> FilterTerms => base.FilterTerms.Concat(new LocalisableString[] { "keybindings" });
|
public override IEnumerable<LocalisableString> FilterTerms => base.FilterTerms.Concat(new LocalisableString[] { @"keybindings", @"controls", @"keyboard", @"keys" });
|
||||||
|
|
||||||
public BindingSettings(KeyBindingPanel keyConfig)
|
public BindingSettings(KeyBindingPanel keyConfig)
|
||||||
{
|
{
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||||
// See the LICENCE file in the repository root for full licence text.
|
// See the LICENCE file in the repository root for full licence text.
|
||||||
|
|
||||||
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
|
||||||
using osu.Framework.Bindables;
|
using osu.Framework.Bindables;
|
||||||
using osu.Framework.Graphics;
|
using osu.Framework.Graphics;
|
||||||
using osu.Framework.Graphics.Containers;
|
using osu.Framework.Graphics.Containers;
|
||||||
@ -22,6 +22,8 @@ namespace osu.Game.Overlays.Settings
|
|||||||
|
|
||||||
public LocalisableString TooltipText { get; set; }
|
public LocalisableString TooltipText { get; set; }
|
||||||
|
|
||||||
|
public IEnumerable<string> Keywords { get; set; } = Array.Empty<string>();
|
||||||
|
|
||||||
public BindableBool CanBeShown { get; } = new BindableBool(true);
|
public BindableBool CanBeShown { get; } = new BindableBool(true);
|
||||||
IBindable<bool> IConditionalFilterable.CanBeShown => CanBeShown;
|
IBindable<bool> IConditionalFilterable.CanBeShown => CanBeShown;
|
||||||
|
|
||||||
@ -30,9 +32,13 @@ namespace osu.Game.Overlays.Settings
|
|||||||
get
|
get
|
||||||
{
|
{
|
||||||
if (TooltipText != default)
|
if (TooltipText != default)
|
||||||
return base.FilterTerms.Append(TooltipText);
|
yield return TooltipText;
|
||||||
|
|
||||||
return base.FilterTerms;
|
foreach (string s in Keywords)
|
||||||
|
yield return s;
|
||||||
|
|
||||||
|
foreach (LocalisableString s in base.FilterTerms)
|
||||||
|
yield return s;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user