其實(shí)就是從Context中獲取Context.LAYOUT_INFLATER_SERVICE所對應(yīng)的系統(tǒng)服務(wù)。這里涉及到Context實(shí)現(xiàn)以及服務(wù)創(chuàng)建的源碼,不繼續(xù)深究。重點(diǎn)是通常所使用的inflate()方法,比較常用的就是這兩個:inflate(@LayoutRes int resource, @Nullable ViewGroup root) inflate(@LayoutRes int resource, @Nullable ViewGroup root, ...
www.dbjr.com.cn/article/1523...htm 2025-6-3