Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -597,7 +597,8 @@ bool IsElementVisibleInContainer(FrameworkElement element, FrameworkElement cont

default:
return elementBounds.Left < containerBounds.Right && elementBounds.Right > containerBounds.Left;
};
}
;
}

void OnScrollViewChanged(object sender, ScrollViewerViewChangedEventArgs e)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1642,7 +1642,8 @@ public override CGRect Frame
value.Width = (value.X - xSpace) + value.Width;
value.X = xSpace;
}
};
}
;

value.Height = ToolbarHeight;
}
Expand Down
6 changes: 4 additions & 2 deletions src/Controls/src/BindingSourceGen/PathParser.cs
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,8 @@ private Result<List<IPathPart>> HandleBinaryExpression(BinaryExpressionSyntax as
if (typeInfo == null)
{
return Result<List<IPathPart>>.Failure(DiagnosticsFactory.UnableToResolvePath(castTo.GetLocation()));
};
}
;

leftResult.Value.Add(new Cast(typeInfo.CreateTypeDescription(_enabledNullable)));

Expand All @@ -161,7 +162,8 @@ private Result<List<IPathPart>> HandleCastExpression(CastExpressionSyntax castEx
if (typeInfo == null)
{
return Result<List<IPathPart>>.Failure(DiagnosticsFactory.UnableToResolvePath(castExpression.GetLocation()));
};
}
;

result.Value.Add(new Cast(typeInfo.CreateTypeDescription(_enabledNullable)));

Expand Down
3 changes: 2 additions & 1 deletion src/Controls/src/Core/AppThemeBinding.cs
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,8 @@ void Set()
}
target.SetValueCore(_targetProperty, value, Internals.SetValueFlags.ClearDynamicResource, BindableObject.SetValuePrivateFlags.Default | BindableObject.SetValuePrivateFlags.Converted, specificity);
}
};
}
;
}

object _light;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1115,7 +1115,7 @@ public override UITableViewCell GetCell(UITableView tableView, NSIndexPath index
PreserveActivityIndicatorState(cell);
Performance.Stop(reference);

if(platformCell is ContextActionsCell contextActionsCell)
if (platformCell is ContextActionsCell contextActionsCell)
_contextActionsCells.Add(contextActionsCell);

return platformCell;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1996,7 +1996,8 @@ public override CGRect Frame
value.Width = (value.X - xSpace) + value.Width;
value.X = xSpace;
}
};
}
;

value.Height = ToolbarHeight;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,8 @@ void RemoveAllButCurrent(Fragment skip)

trans ??= ChildFragmentManager.BeginTransactionEx();
trans.Remove(f);
};
}
;

trans?.CommitAllowingStateLossEx();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -583,7 +583,8 @@ bool IsElementVisibleInContainer(FrameworkElement element, FrameworkElement cont

default:
return elementBounds.Left < containerBounds.Right && elementBounds.Right > containerBounds.Left;
};
}
;
}

async void ScrollToRequested(object sender, ScrollToRequestEventArgs args)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
using System.Collections.Generic;
using System.Linq;
using Foundation;
using Microsoft.Maui.Controls.Platform;
using ObjCRuntime;
using UIKit;
using Microsoft.Maui.Controls.Platform;

namespace Microsoft.Maui.Controls.Handlers.Items
{
Expand Down
6 changes: 3 additions & 3 deletions src/Controls/src/Core/Handlers/Items/iOS/TemplatedCell.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
using CoreGraphics;
using Foundation;
using Microsoft.Maui.Controls.Internals;
using Microsoft.Maui.Controls.Platform;
using Microsoft.Maui.Graphics;
using UIKit;
using Microsoft.Maui.Controls.Platform;

namespace Microsoft.Maui.Controls.Handlers.Items
{
Expand Down Expand Up @@ -97,8 +97,8 @@ public override UICollectionViewLayoutAttributes PreferredLayoutAttributesFittin
var preferredAttributes = base.PreferredLayoutAttributesFittingAttributes(layoutAttributes);

if (_measureInvalidated ||
!AttributesConsistentWithConstrainedDimension(preferredAttributes) ||
!preferredAttributes.Frame.Size.IsCloseTo(_size))
!AttributesConsistentWithConstrainedDimension(preferredAttributes) ||
!preferredAttributes.Frame.Size.IsCloseTo(_size))
{
// Measure this cell (including the Forms element) if there is no constrained size
var size = ConstrainedSize == default ? Measure() : ConstrainedSize;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ private int GetTargetPosition()
{
return 0;
}

return ItemsView.ItemsUpdatingScrollMode switch
{
ItemsUpdatingScrollMode.KeepItemsInView => 0,
Expand Down
3 changes: 2 additions & 1 deletion src/Controls/src/Core/Handlers/Items2/iOS/LayoutFactory2.cs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,8 @@ static NSCollectionLayoutBoundarySupplementaryItem[] CreateSupplementaryItems(La
scrollDirection == UICollectionViewScrollDirection.Vertical
? NSRectAlignment.Top
: NSRectAlignment.Leading));
};
}
;

if (layoutHeaderFooterInfo.HasFooter)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
using System.Collections.Generic;
using System.Linq;
using Foundation;
using Microsoft.Maui.Controls.Platform;
using ObjCRuntime;
using UIKit;
using Microsoft.Maui.Controls.Platform;

namespace Microsoft.Maui.Controls.Handlers.Items2
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ void InvalidateLayoutIfItemsMeasureChanged()
// We could then invalidate the layout for supplementary cell only `collectionView.IndexPathForCell(headerCell)` like we do on standard cells,
// but that causes other cells to oddly collapse (see Issue25362 UITest), so in this case we have to stick with `InvalidateLayout`.
var collectionView = CollectionView;

if (ItemsView.Header is not null || ItemsView.HeaderTemplate is not null)
{
var visibleHeaders = collectionView.GetVisibleSupplementaryViews(UICollectionElementKindSectionKey.Header);
Expand Down
4 changes: 2 additions & 2 deletions src/Controls/src/Core/Handlers/Items2/iOS/TemplatedCell2.cs
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,8 @@ public override void PrepareForReuse()

public void Bind(DataTemplate template, object bindingContext, ItemsView itemsView)
{
var virtualView = PlatformHandler?.VirtualView as View ??
template.CreateContent(bindingContext, itemsView) as View;
var virtualView = PlatformHandler?.VirtualView as View ??
template.CreateContent(bindingContext, itemsView) as View;

BindVirtualView(virtualView, bindingContext, itemsView, false);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,9 @@ public static void UpdateToolbarDynamicOverflowEnabled(this MauiToolbar platform

private static void UpdateBackButtonVisibility(MauiToolbar platformToolbar, Toolbar toolbar)
{
platformToolbar.IsBackButtonVisible =
toolbar.BackButtonVisible
? NavigationViewBackButtonVisible.Visible
platformToolbar.IsBackButtonVisible =
toolbar.BackButtonVisible
? NavigationViewBackButtonVisible.Visible
: NavigationViewBackButtonVisible.Collapsed;
}
}
Expand Down
3 changes: 2 additions & 1 deletion src/Controls/src/Core/Shell/ShellSection.cs
Original file line number Diff line number Diff line change
Expand Up @@ -694,7 +694,8 @@ void WaitForRendererToGetRemoved(object s, EventArgs p)
{
sc.Page.PlatformEnabledChanged -= WaitForRendererToGetRemoved;
base.OnChildRemoved(child, oldLogicalIndex);
};
}
;
}
else
{
Expand Down
3 changes: 2 additions & 1 deletion src/Controls/tests/Core.UnitTests/BindingUnitTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1241,7 +1241,8 @@ void create()
proxies.Add(new WeakReference(listener));
}
Assert.NotEmpty(proxies); // Should be at least 1
};
}
;
create();

await Task.Yield();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ await AttachAndRun(border, (handler) =>
await AssertColorAtPoint(border, expected, typeof(BorderHandler), cornerRadius, cornerRadius);
}

[Fact]
[Description("The IsVisible property of a Border should match with native IsVisible")]
[Fact]
[Description("The IsVisible property of a Border should match with native IsVisible")]
public async Task VerifyBorderIsVisibleProperty()
{
var border = new Border();
Expand All @@ -73,9 +73,9 @@ public async Task VerifyBorderIsVisibleProperty()
var nativeView = GetNativeBorder(handler);
await InvokeOnMainThreadAsync(() =>
{
var isVisible = nativeView.Visibility == Microsoft.UI.Xaml.Visibility.Visible;
Assert.Equal(expectedValue, isVisible);
});
var isVisible = nativeView.Visibility == Microsoft.UI.Xaml.Visibility.Visible;
Assert.Equal(expectedValue, isVisible);
});
}

ContentPanel GetNativeBorder(BorderHandler borderHandler) =>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ await InvokeOnMainThreadAsync(() =>

await AssertionExtensions.WaitForGC(handlerReference, platformViewReference);
}

[Fact(DisplayName = "Border With Stroke Shape And Name Does Not Leak")]
public async Task DoesNotLeakWithStrokeShape()
{
Expand Down
Loading