Anchor = new Point(0.5, 0.5)
↓
update Icon = RedCircle → Anchor is initialize (0.5, 1.0)
EXPECTED BEHAVIOR
update Icon = RedCircle
HOW TO REPRODUCE
// code for reproduce
Xamarin.Forms.GoogleMaps.Android/Logics/PinLogic.cs
protected override void OnUpdateIcon(Pin outerItem, Marker nativeItem)
{
if (outerItem.Icon != null && outerItem.Icon.Type == BitmapDescriptorType.View)
{
// If the pin has an IconView set this method will convert it into an icon for the marker
TransformXamarinViewToAndroidBitmap(outerItem, nativeItem);
}
else
{
var factory = _bitmapDescriptorFactory ?? DefaultBitmapDescriptorFactory.Instance;
var nativeDescriptor = factory.ToNative(outerItem.Icon);
nativeItem.SetIcon(nativeDescriptor);
nativeItem.SetAnchor(0.5f, 1f);
nativeItem.SetInfoWindowAnchor(0.5f, 0f);
}
}
↓
// nativeItem.SetAnchor(0.5f, 1f);
// nativeItem.SetInfoWindowAnchor(0.5f, 0f);
Is there a situation where the last two lines are needed?
need the branch condition?
VERSIONS
PLATFORMS
ACTUAL BEHAVIOR
Anchor is initialized when updating Pin.
ACTUAL SCREENSHOTS/STACKTRACE
Anchor = new Point(0.5, 0.5) ↓ update Icon = RedCircle → Anchor is initialize (0.5, 1.0)
EXPECTED BEHAVIOR
update Icon = RedCircle
HOW TO REPRODUCE
Is there a situation where the last two lines are needed? need the branch condition?