1
0
mirror of https://github.com/bitwarden/mobile synced 2025-12-25 12:43:39 +00:00

Button uppercase styling enforcement

This commit is contained in:
Kyle Spearrin
2016-08-24 00:07:46 -04:00
parent 2262e1c4c2
commit d4f52bce2b
8 changed files with 28 additions and 18 deletions

View File

@@ -46,9 +46,16 @@ namespace Bit.Android.Controls
private void SetUppercase()
{
var element = Element as ExtendedButton;
if(element != null && !element.Uppercase)
if(element != null && !string.IsNullOrWhiteSpace(element.Text))
{
Control.TransformationMethod = null;
if(element.Uppercase)
{
element.Text = element.Text.ToUpperInvariant();
}
else
{
Control.TransformationMethod = null;
}
}
}
}