替换的fragment不能全屏是怎么回事。。。

============问题描述============



getActivity().

		getSupportFragmentManager()

		.beginTransaction()

		.replace(R.id.loading, content)

		.commit();


使用如上代码替换个fragment,然后替换的fragment不能全屏显示。。。比被替换的fragment小了很多,而且似乎是wrap_content的样子。可是两个fragment我都设置了fill_parent的。。。
请教怎样让替换的fragment全屏显示。。。

============解决方案1============


检查下xml中是否都设置为fill_parent,代码里是否有再次更改布局比例了。我看了下自己的代码,写的fill_parent没有问题
posted @ 2014-10-23 16:20  0基础学android开发  阅读(1069)  评论(1编辑  收藏  举报
我要啦免费统计