facebook/fresco

Issue with status bar transparent

Open

#2254 aperta il 7 dic 2018

Vedi su GitHub
 (3 commenti) (0 reazioni) (0 assegnatari)Java (3750 fork)batch import
good first issuehelp wantedstarter-task

Metriche repository

Star
 (17.072 star)
Metriche merge PR
 (Nessuna PR mergiata in 30 g)

Descrizione

Description

When the status bar is transparent, Fresco doesn't draw the image underneath it

Reproduction

Just run: https://github.com/omainegra/furry-octo-potato As an extra, you can toggle the commented code and see how it works with a regular ImageView

Issue

device-2018-12-10-101329

Expected

device-2018-12-10-101359

Update

After playing with it I found that redrawing after ViewCompat.setOnApplyWindowInsetsListener fixes the problem.

ViewCompat.setOnApplyWindowInsetsListener(findViewById<SimpleDraweeView>(R.id.draweeView)) { view, insetsCompat ->
    view.requestLayout()
    insetsCompat
} 

Additional Information

  • Fresco version: 1.11.0
  • Platform version: [{ Nexus 6P, Android 8.1 }, { Pixel 3, Android 9 }]

Guida contributor