Reputation: 2576
Sorry for silly question, but does Android really redraw views with visibility View.INVISIBLE
? Does it affect an overall performance comparing to using View.GONE
?
Upvotes: 2
Views: 183
Reputation: 21
Invisible Views are not shown on UI but they are taking the space on screen whereas gone view are not taking the space on screen as well i.e suppose you are having 3 text views in vertical direction and you make middle one invisible then there is a blank space between first and third and if the view for second one is gone then the third one takes the place of second one.
Upvotes: 0
Reputation: 152817
Invisible views are measured but not drawn. Gone views are not measured, so there's a performance difference.
Upvotes: 6