fresco icon indicating copy to clipboard operation
fresco copied to clipboard

custome view -- multiple bitmap

Open JoneWeng opened this issue 11 years ago • 3 comments

what callback method is bitmap be loaded ? What should I do in it (invalidate view)? method onDraw like this:

onDraw (canvas){ mHolders.draw(canvas); }

i think the callback method is invalidateDrawable or ControllerListener, so code like this

invalidateDrawable(drawable who){ // check drawable invalidate(who.getBounds()); }

new ControllerListener(){ onFinalSet(){ invalidate(xxx.getBounds()); } }

please help me.. Troubled me for a long time. i hope fresco provider multiple bitmap views .

JoneWeng avatar Jun 02 '15 02:06 JoneWeng

Please read Writing Custom Views.

plamenko avatar Jun 02 '15 11:06 plamenko

I've read it. what callback method is bitmap be loaded ? invalidateDrawable or ControllerListener

JoneWeng avatar Jun 02 '15 13:06 JoneWeng

ControllerListener will tell you when the image is loaded.

You don't need to invalidate the view for that reason, though. Fresco takes care of that for you.

tyronen avatar Jun 03 '15 18:06 tyronen