When using setVisibility(int) the int can be VISIBLE, INVISIBLE and GONE
These, when I look them up, have (obviously) set int values.
However, I cannot just put in (say) “GONE” because it is not recognised.
How can I import the definitions, or do i have to define them in my own code?
When using setVisibility(int) the int can be VISIBLE, INVISIBLE and GONE These, when I
Share
Just put
import static android.view.View.GONEbeneath your imports and you can use theGONEconstant directly without needing any additional qualifiers.