Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to set an empty drawable

I'm dealing with bugs in the Facebook SDK and so to remove the bugs I'll need to set a drawable to nothing not NULL just nothing or empty space or something. How can I do that programmatically?

Drawable=... 
like image 922
Michael Nana Avatar asked Aug 09 '13 12:08

Michael Nana


1 Answers

You can use a transparent ColorDrawable:

Drawable transparentDrawable = new ColorDrawable(Color.TRANSPARENT); 

That's a Drawable that represents the transparent color and doesn't have an intrinsic size.

like image 50
njzk2 Avatar answered Sep 29 '22 14:09

njzk2