getActivity ().
getSupportFragmentManager ()
. BeginTransaction ()
. Replace (R.id.loading, content)
. Commit ();
Use the above code to replace a fragment, and then replace the fragment is not full screen. . . A lot smaller than the replaced fragment, but seems to be wrap_content look. But I have set up two fragment of fill_parent. . .
Ask how to make replacement fragment full screen. . .<-! Main posts under Banner (D4) -><-! Posts under the main text (D5) ->
Reply:
Check whether the following xml are set to fill_parent, whether to change the layout of the proportion of the code again. I looked at your code, there is no problem writing fill_parent
Reply:
I began to have this problem, but later found the parent control is defined Padding, that is, the value of the margins and the like, they can get rid of the full screen.
No comments:
Post a Comment