public MapTile() { _mapLayout = new AbsoluteLayout(); AbsoluteLayout.SetLayoutFlags(this, AbsoluteLayoutFlags.All); AbsoluteLayout.SetLayoutBounds(this, new Rectangle(0f, 0f, 1f, 1f)); _mapLayout.Children.Add(this); mapPinDetail = new MapPinDetail(); mapPinDetail.IsVisible = false; AbsoluteLayout.SetLayoutFlags(mapPinDetail, AbsoluteLayoutFlags.All); AbsoluteLayout.SetLayoutBounds(mapPinDetail, new Rectangle(0f, 0f, 1f, 1f)); _mapLayout.Children.Add(mapPinDetail); }
public MapTile() { MapLayout = new AbsoluteLayout(); AbsoluteLayout.SetLayoutFlags(this, AbsoluteLayoutFlags.All); AbsoluteLayout.SetLayoutBounds(this, new Rectangle(0f, 0f, 1f, 1f)); MapPinDetail = new MapPinDetail { IsVisible = false }; AbsoluteLayout.SetLayoutFlags(MapPinDetail, AbsoluteLayoutFlags.PositionProportional); AbsoluteLayout.SetLayoutBounds(MapPinDetail, new Rectangle(0.5, 0.5, AbsoluteLayout.AutoSize, AbsoluteLayout.AutoSize)); MapLayout.Children.Add(this); MapLayout.Children.Add(MapPinDetail); }
public MapTile(RootContentUI contentUI) : base(MapSpan.FromCenterAndRadius(new Position(MinskLat, MinskLong), Distance.FromKilometers(5))) { ContentUI = contentUI; MapLayout = new AbsoluteLayout(); AbsoluteLayout.SetLayoutFlags(this, AbsoluteLayoutFlags.All); AbsoluteLayout.SetLayoutBounds(this, new Rectangle(0f, 0f, 1f, 1f)); MapPinDetail = new MapPinDetail(contentUI) { IsVisible = false }; AbsoluteLayout.SetLayoutFlags(MapPinDetail, AbsoluteLayoutFlags.PositionProportional); AbsoluteLayout.SetLayoutBounds(MapPinDetail, new Rectangle(0.5, 0.5, AbsoluteLayout.AutoSize, AbsoluteLayout.AutoSize)); MapLayout.Children.Add(this); MapLayout.Children.Add(MapPinDetail); }