Skip to content

Commit 951587b

Browse files
dotnet format
1 parent 70db45d commit 951587b

File tree

10 files changed

+20
-21
lines changed

10 files changed

+20
-21
lines changed

samples/CommunityToolkit.Maui.Sample/Pages/Alerts/SnackbarPage.xaml.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ public partial class SnackbarPage : BasePage<SnackbarViewModel>
1414
{
1515
public const string DisplayCustomSnackbarText = "Display Custom Snackbar";
1616
const string dismissCustomSnackbarText = "Dismiss Custom Snackbar";
17-
17+
1818
readonly IReadOnlyList<Color> colors = [.. typeof(Colors)
1919
.GetFields(BindingFlags.Static | BindingFlags.Public)
2020
.ToDictionary(c => c.Name, c => (Color)(c.GetValue(null) ?? throw new InvalidOperationException()))
@@ -111,7 +111,7 @@ async void DisplaySnackbarInModalButtonClicked(object? sender, EventArgs e)
111111
.CenterHorizontal()
112112
.Text("Back to Snackbar MainPage");
113113
backButton.Command = new AsyncRelayCommand(mainPage.Navigation.PopModalAsync);
114-
114+
115115
await mainPage.Navigation.PushModalAsync(new ContentPage
116116
{
117117
Content = new VerticalStackLayout

src/CommunityToolkit.Maui.Core/Views/Alert/AlertView.macios.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ namespace CommunityToolkit.Maui.Core.Views;
99
public class AlertView(bool shouldFillAndExpandHorizontally) : UIView
1010
{
1111
const int defaultSpacing = 10;
12-
12+
1313
readonly List<UIView> children = [];
1414
readonly bool shouldFillAndExpandHorizontally = shouldFillAndExpandHorizontally;
1515

@@ -22,7 +22,7 @@ public class AlertView(bool shouldFillAndExpandHorizontally) : UIView
2222
/// PopupView Children
2323
/// </summary>
2424
public IReadOnlyList<UIView> Children => children;
25-
25+
2626
/// <summary>
2727
/// <see cref="AlertViewVisualOptions"/>
2828
/// </summary>
@@ -32,7 +32,7 @@ public class AlertView(bool shouldFillAndExpandHorizontally) : UIView
3232
/// <see cref="UIView"/> on which Alert will appear. When null, <see cref="AlertView"/> will appear at bottom of screen.
3333
/// </summary>
3434
public UIView? AnchorView { get; set; }
35-
35+
3636
/// <summary>
3737
/// Container of <see cref="AlertView"/>
3838
/// </summary>
@@ -72,14 +72,14 @@ public void Setup()
7272
public override void LayoutSubviews()
7373
{
7474
base.LayoutSubviews();
75-
75+
7676
if (AnchorView is null)
7777
{
7878
this.SafeBottomAnchor().ConstraintEqualTo(ParentView.SafeBottomAnchor(), -defaultSpacing).Active = true;
7979
this.SafeTopAnchor().ConstraintGreaterThanOrEqualTo(ParentView.SafeTopAnchor(), defaultSpacing).Active = true;
8080
}
8181
else if (AnchorView.Superview is not null
82-
&& AnchorView.Superview.ConvertRectToView(AnchorView.Frame, null).Top < Container.Frame.Height + SafeAreaLayoutGuide.LayoutFrame.Bottom)
82+
&& AnchorView.Superview.ConvertRectToView(AnchorView.Frame, null).Top < Container.Frame.Height + SafeAreaLayoutGuide.LayoutFrame.Bottom)
8383
{
8484
var top = AnchorView.Superview.Frame.Top + AnchorView.Frame.Height + defaultSpacing;
8585
this.SafeTopAnchor().ConstraintEqualTo(ParentView.TopAnchor, top).Active = true;
@@ -102,15 +102,15 @@ void SetParentConstraints()
102102
this.SafeLeadingAnchor().ConstraintGreaterThanOrEqualTo(ParentView.SafeLeadingAnchor(), defaultSpacing).Active = true;
103103
this.SafeTrailingAnchor().ConstraintLessThanOrEqualTo(ParentView.SafeTrailingAnchor(), -defaultSpacing).Active = true;
104104
}
105-
105+
106106
this.SafeCenterXAnchor().ConstraintEqualTo(ParentView.SafeCenterXAnchor()).Active = true;
107107

108108
Container.SafeLeadingAnchor().ConstraintEqualTo(this.SafeLeadingAnchor(), defaultSpacing).Active = true;
109109
Container.SafeTrailingAnchor().ConstraintEqualTo(this.SafeTrailingAnchor(), -defaultSpacing).Active = true;
110110
Container.SafeBottomAnchor().ConstraintEqualTo(this.SafeBottomAnchor(), -defaultSpacing).Active = true;
111111
Container.SafeTopAnchor().ConstraintEqualTo(this.SafeTopAnchor(), defaultSpacing).Active = true;
112112
}
113-
113+
114114
void Initialize()
115115
{
116116
TranslatesAutoresizingMaskIntoConstraints = false;

src/CommunityToolkit.Maui.MediaElement/Primitives/CustomTransportControls.windows.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ protected override void OnApplyTemplate()
1818
base.OnApplyTemplate();
1919

2020
var temp = GetTemplateChild("FullWindowButton") as AppBarButton;
21-
if(temp is not null)
21+
if (temp is not null)
2222
{
2323
FullScreenButton = temp;
2424
FullScreenButton.Visibility = Microsoft.UI.Xaml.Visibility.Visible;
@@ -40,4 +40,4 @@ void FullScreenButton_Click(object sender, RoutedEventArgs e)
4040
isFullScreen = true;
4141
}
4242
}
43-
}
43+
}

src/CommunityToolkit.Maui.MediaElement/Services/MediaControlsService.android.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@ public void UpdateNotifications(in MediaSession session, in PlatformMediaElement
9393
}
9494

9595
[MemberNotNull(nameof(playerNotificationManager))]
96-
9796
public void SetLegacyNotifications(in MediaSession session, in PlatformMediaElement mediaElement)
9897
{
9998
ArgumentNullException.ThrowIfNull(session);

src/CommunityToolkit.Maui.MediaElement/Views/MediaManager.macios.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ public void Dispose()
131131
Dispose(true);
132132
GC.SuppressFinalize(this);
133133
}
134-
134+
135135
protected virtual partial void PlatformPlay()
136136
{
137137
if (Player?.CurrentTime == PlayerItem?.Duration)
@@ -146,7 +146,7 @@ protected virtual partial void PlatformPause()
146146
{
147147
Player?.Pause();
148148
}
149-
149+
150150
protected virtual async partial Task PlatformSeek(TimeSpan position, CancellationToken token)
151151
{
152152
token.ThrowIfCancellationRequested();
@@ -379,7 +379,7 @@ protected virtual partial void PlatformUpdateShouldShowPlaybackControls()
379379
PlayerViewController.ShowsPlaybackControls =
380380
MediaElement.ShouldShowPlaybackControls;
381381
}
382-
382+
383383
protected virtual partial void PlatformUpdatePosition()
384384
{
385385
if (Player is null)
@@ -411,7 +411,7 @@ protected virtual partial void PlatformUpdatePosition()
411411
MediaElement.Duration = MediaElement.Position = TimeSpan.Zero;
412412
}
413413
}
414-
414+
415415
protected virtual partial void PlatformUpdateVolume()
416416
{
417417
if (Player is null)

src/CommunityToolkit.Maui.UnitTests/Behaviors/MaxLengthReachedBehaviorTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ public void ShouldNotDismissKeyboardWhenOptionSetToFalse()
139139
// assert
140140
Assert.True(entry.IsFocused);
141141
}
142-
142+
143143
static Entry CreateEntry(int? maxLength = 2,
144144
bool shouldDismissKeyboardAutomatically = false,
145145
ICommand? command = null,

src/CommunityToolkit.Maui.UnitTests/Behaviors/SetFocusOnEntryCompletedTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ public void SetsFocusWhenCompleted()
3434
// assert
3535
Assert.True(entry2.IsFocused);
3636
}
37-
37+
3838
static Entry CreateEntry(VisualElement? nextElement = null)
3939
{
4040
var entry = new Entry();

src/CommunityToolkit.Maui.UnitTests/Behaviors/UserStoppedTypingBehaviorTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ public async Task ShouldExecuteCommandImmediatelyWhenMinimumLengthThresholdHasNo
238238
// assert
239239
Assert.True(commandHasBeenExecuted);
240240
}
241-
241+
242242
static Entry CreateEntryWithBehavior(int stoppedTypingTimeThreshold = 500,
243243
int minimumLengthThreshold = 0,
244244
bool shouldDismissKeyboardAutomatically = false,
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
using Xunit;
22

3-
[assembly: CollectionBehavior(CollectionBehavior.CollectionPerAssembly, DisableTestParallelization = true, MaxParallelThreads = 1)]
3+
[assembly: CollectionBehavior(CollectionBehavior.CollectionPerAssembly, DisableTestParallelization = true, MaxParallelThreads = 1)]

src/CommunityToolkit.Maui.UnitTests/Layouts/StateContainerTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,7 @@ public async Task StateContainer_ChangingStateWhenCanStateChangePropertyIsFalse_
334334
};
335335

336336
var changeStateWithAnimationTask = StateContainer.ChangeStateWithAnimation(layout, StateKey.Error, null, afterStateChangeAnimation, TestContext.Current.CancellationToken);
337-
337+
338338
Assert.False(StateContainer.GetCanStateChange(layout));
339339
var exception = Assert.Throws<StateContainerException>(() => StateContainer.SetCurrentState(layout, StateKey.Anything));
340340
var exception2 = await Assert.ThrowsAsync<StateContainerException>(() => StateContainer.ChangeStateWithAnimation(layout, StateKey.Anything, TestContext.Current.CancellationToken));

0 commit comments

Comments
 (0)