зеркало из https://github.com/DeGsoft/maui-linux.git
27 строки
670 B
C#
27 строки
670 B
C#
using CoreGraphics;
|
|
using Foundation;
|
|
|
|
namespace Xamarin.Forms.Platform.iOS
|
|
{
|
|
internal sealed class HorizontalDefaultCell : DefaultCell
|
|
{
|
|
public static NSString ReuseId = new NSString("Xamarin.Forms.Platform.iOS.HorizontalDefaultCell");
|
|
|
|
[Export("initWithFrame:")]
|
|
public HorizontalDefaultCell(CGRect frame) : base(frame)
|
|
{
|
|
Constraint = Label.HeightAnchor.ConstraintEqualTo(Frame.Height);
|
|
Constraint.Active = true;
|
|
}
|
|
|
|
public override void ConstrainTo(CGSize constraint)
|
|
{
|
|
Constraint.Constant = constraint.Height;
|
|
}
|
|
|
|
public override CGSize Measure()
|
|
{
|
|
return new CGSize(Label.IntrinsicContentSize.Width, Constraint.Constant);
|
|
}
|
|
}
|
|
} |