xamarin/Xamarin.Forms

[Bug] Image on Button or ImageButton distorts when swapped

Ouverte

#6 937 ouverte le 19 juil. 2019

 (2 commentaires) (3 réactions) (0 personne assignée)C# (1 926 forks)batch import
a/imagebuttona/layoute/3 :clock3:help wantedp/Androidt/bug :bug:up-for-grabs

Métriques du dépôt

Stars
 (5 644 étoiles)
Métriques de merge PR
 (Aucune PR mergée en 30 j)

Description

Description

When swapping out the Source Image on the attached project the image will occasionally distort. If you click it enough times it'll return back to normal.

Steps to Reproduce

  1. Run attached project
  2. click on the heart a few times and you will see sometimes it distorts

In the sample if you delete the Frame above the ImageButton then the distortion no longer occurs

Expected Behavior

The image should always stay the same height/width

Actual Behavior

The image when changing stretches and occasionally doesn't return to normal

Basic Information

  • Version with issue: 4.3
  • Last known good version: I tested as far back as 3.4 and the issue still presented itself there
    • Android: API 23

Screenshots

image

Reproduction Link

ImageSizesWeirdWhenChanged.zip

Guide contributeur