1
0
mirror of https://github.com/ppy/osu.git synced 2024-09-22 04:07:25 +08:00

Rename variable for potential future expansion

This commit is contained in:
Dean Herbert 2020-07-10 18:19:18 +09:00
parent 4a1621bf98
commit f699a34c77
2 changed files with 5 additions and 5 deletions

View File

@ -24,7 +24,7 @@ namespace osu.Game.Graphics.UserInterface
Child = new PasswordMaskChar(CalculatedTextSize), Child = new PasswordMaskChar(CalculatedTextSize),
}; };
protected override bool AllowUpperCaseSamples => false; protected override bool AllowUniqueCharacterSamples => false;
protected override bool AllowClipboardExport => false; protected override bool AllowClipboardExport => false;

View File

@ -30,10 +30,10 @@ namespace osu.Game.Graphics.UserInterface
private SampleChannel caretMovedSample; private SampleChannel caretMovedSample;
/// <summary> /// <summary>
/// Whether to allow playing a different sample when inserting upper case text. /// Whether to allow playing a different samples based on the type of character.
/// If set to false, same sample will be played for both letter cases. /// If set to false, the same sample will be used for all characters.
/// </summary> /// </summary>
protected virtual bool AllowUpperCaseSamples => true; protected virtual bool AllowUniqueCharacterSamples => true;
protected override float LeftRightPadding => 10; protected override float LeftRightPadding => 10;
@ -78,7 +78,7 @@ namespace osu.Game.Graphics.UserInterface
{ {
base.OnTextAdded(added); base.OnTextAdded(added);
if (added.Any(char.IsUpper) && AllowUpperCaseSamples) if (added.Any(char.IsUpper) && AllowUniqueCharacterSamples)
capsTextAddedSample?.Play(); capsTextAddedSample?.Play();
else else
textAddedSamples[RNG.Next(0, 3)]?.Play(); textAddedSamples[RNG.Next(0, 3)]?.Play();