LayoutInflater简单认识

2020-09-22  本文已影响0人  bogerLiu

LayouInflater简单认识

getSystemService

getSystemServiceName

这里是通过 static hashmap实现单例

通过map查找到 唯一实例PhoneLayoutInflater

activity phoneWindow

setContentView 调用PhoneWindow的setContentView 内部是LayoutInflater 调用phoneLayoutInflater 遍历循环调用创建View 主要是oncreateViewFromTag来创建View 并添加到View的父容器内,addView(view,layoutParams);

上一篇 下一篇

猜你喜欢

热点阅读