android去掉背景(颜色或者图片)

view.setBackgroundResource(0);
根据文档public void setBackgroundResource (int resid)
              Since: API Level 1
Set the background to a given resource. The resource should refer to a Drawable object or 0 to remove the background.

所以设置为o就是删除背景。

 

你可能感兴趣的:(android)