How do you inflate a view on Android?

How do you inflate a view on Android?
Answer
Just think we specified a button in an XML layout file with its layout width and layout height set to match_parent. On This Buttons Click Event We Can Set Following Code to Inflate Layout on This Activity. LayoutInflater inflater = LayoutInflater. from(getContext()); inflater.
 

Tìm kiếm

Back
Top