android program learn 1.2

Fragment concept:

Fragment can be considered as a piece of activity.

one activity can be devide into several fragment.

fragmentManager can help to control several fragment in the same activity.

and the fragment can be static and dynamic. 

U can create the static fragment with sample xml, but it will appear fixed with activity “onCreat”.

U also can create the dynamic fragment with a.xml and b.xml in same content.xml, then 

use “listener” method to get √ some input to decide the content.xml shows “a.xml”or “b.xml”

all the control program written in the java.class.

we need to learn how to transfer the data from fragment to activity and inverse way.

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容