mirror of
https://github.com/bitwarden/mobile
synced 2025-12-23 11:43:49 +00:00
Changed all C# control flow block statements to include space between keyword and open paren (#800)
This commit is contained in:
@@ -17,7 +17,7 @@ namespace Bit.iOS.Core.Views
|
||||
var descriptor = UIFontDescriptor.PreferredBody;
|
||||
var pointSize = descriptor.PointSize;
|
||||
|
||||
if(labelName != null && !useLabelAsPlaceholder)
|
||||
if (labelName != null && !useLabelAsPlaceholder)
|
||||
{
|
||||
Label = new UILabel
|
||||
{
|
||||
@@ -30,7 +30,7 @@ namespace Bit.iOS.Core.Views
|
||||
ContentView.Add(Label);
|
||||
}
|
||||
|
||||
if(useTextView)
|
||||
if (useTextView)
|
||||
{
|
||||
TextView = new UITextView
|
||||
{
|
||||
@@ -41,7 +41,7 @@ namespace Bit.iOS.Core.Views
|
||||
BackgroundColor = ThemeHelpers.BackgroundColor
|
||||
};
|
||||
|
||||
if(!ThemeHelpers.LightTheme)
|
||||
if (!ThemeHelpers.LightTheme)
|
||||
{
|
||||
TextView.KeyboardAppearance = UIKeyboardAppearance.Dark;
|
||||
}
|
||||
@@ -53,7 +53,7 @@ namespace Bit.iOS.Core.Views
|
||||
NSLayoutConstraint.Create(ContentView, NSLayoutAttribute.Bottom, NSLayoutRelation.Equal, TextView, NSLayoutAttribute.Bottom, 1f, 10f)
|
||||
});
|
||||
|
||||
if(labelName != null && !useLabelAsPlaceholder)
|
||||
if (labelName != null && !useLabelAsPlaceholder)
|
||||
{
|
||||
ContentView.AddConstraint(
|
||||
NSLayoutConstraint.Create(TextView, NSLayoutAttribute.Top, NSLayoutRelation.Equal, Label, NSLayoutAttribute.Bottom, 1f, 10f));
|
||||
@@ -64,7 +64,7 @@ namespace Bit.iOS.Core.Views
|
||||
NSLayoutConstraint.Create(TextView, NSLayoutAttribute.Top, NSLayoutRelation.Equal, ContentView, NSLayoutAttribute.Top, 1f, 10f));
|
||||
}
|
||||
|
||||
if(height.HasValue)
|
||||
if (height.HasValue)
|
||||
{
|
||||
ContentView.AddConstraint(
|
||||
NSLayoutConstraint.Create(TextView, NSLayoutAttribute.Height, NSLayoutRelation.Equal, null, NSLayoutAttribute.NoAttribute, 1f, height.Value));
|
||||
@@ -83,12 +83,12 @@ namespace Bit.iOS.Core.Views
|
||||
BackgroundColor = ThemeHelpers.BackgroundColor
|
||||
};
|
||||
|
||||
if(!ThemeHelpers.LightTheme)
|
||||
if (!ThemeHelpers.LightTheme)
|
||||
{
|
||||
TextField.KeyboardAppearance = UIKeyboardAppearance.Dark;
|
||||
}
|
||||
|
||||
if(useLabelAsPlaceholder)
|
||||
if (useLabelAsPlaceholder)
|
||||
{
|
||||
TextField.Placeholder = labelName;
|
||||
}
|
||||
@@ -100,7 +100,7 @@ namespace Bit.iOS.Core.Views
|
||||
NSLayoutConstraint.Create(ContentView, NSLayoutAttribute.Bottom, NSLayoutRelation.Equal, TextField, NSLayoutAttribute.Bottom, 1f, 10f)
|
||||
});
|
||||
|
||||
if(labelName != null && !useLabelAsPlaceholder)
|
||||
if (labelName != null && !useLabelAsPlaceholder)
|
||||
{
|
||||
ContentView.AddConstraint(
|
||||
NSLayoutConstraint.Create(TextField, NSLayoutAttribute.Top, NSLayoutRelation.Equal, Label, NSLayoutAttribute.Bottom, 1f, 10f));
|
||||
@@ -111,14 +111,14 @@ namespace Bit.iOS.Core.Views
|
||||
NSLayoutConstraint.Create(TextField, NSLayoutAttribute.Top, NSLayoutRelation.Equal, ContentView, NSLayoutAttribute.Top, 1f, 10f));
|
||||
}
|
||||
|
||||
if(height.HasValue)
|
||||
if (height.HasValue)
|
||||
{
|
||||
ContentView.AddConstraint(
|
||||
NSLayoutConstraint.Create(TextField, NSLayoutAttribute.Height, NSLayoutRelation.Equal, null, NSLayoutAttribute.NoAttribute, 1f, height.Value));
|
||||
}
|
||||
}
|
||||
|
||||
if(labelName != null && !useLabelAsPlaceholder)
|
||||
if (labelName != null && !useLabelAsPlaceholder)
|
||||
{
|
||||
ContentView.AddConstraints(new NSLayoutConstraint[] {
|
||||
NSLayoutConstraint.Create(Label, NSLayoutAttribute.Leading, NSLayoutRelation.Equal, ContentView, NSLayoutAttribute.Leading, 1f, 15f),
|
||||
@@ -134,11 +134,11 @@ namespace Bit.iOS.Core.Views
|
||||
|
||||
public void Select()
|
||||
{
|
||||
if(TextView != null)
|
||||
if (TextView != null)
|
||||
{
|
||||
TextView.BecomeFirstResponder();
|
||||
}
|
||||
else if(TextField != null)
|
||||
else if (TextField != null)
|
||||
{
|
||||
TextField.BecomeFirstResponder();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user