lawloretienne / ImageGallery

A gallery used to host an array of images
Apache License 2.0
645 stars 116 forks source link

Can I change background color by passing something to the intent? #30

Closed shiv19 closed 6 years ago

shiv19 commented 7 years ago

I want to set the background color to com.etiennelawlor.imagegallery.library.enums.PaletteColorType.LIGHT_VIBRANT

Currently, I am trying

intent.putExtra("palette_color_type", com.etiennelawlor.imagegallery.library.enums.PaletteColorType.LIGHT_VIBRANT);

It doesn't work

reguez commented 7 years ago

do this : LinearLayout tmp; @Override public void loadImageThumbnail(ImageView iv, String imageUrl, int dimension) { if(tmp==null){ tmp = (LinearLayout) fragment.getView(); tmp.setBackgroundColor(Color.RED); } /// rest of the code }