FrameLayout의 단편을 .replace()
으로 대체하여 ViewPager를 사용할 수 있습니까? 둘 다 ViewGroups이기 때문입니다.Framelayout에 ViewPager를 동적으로 추가하십시오.
예를 들어, XML에서, I은
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent" />
<FrameLayout
android:id ="@+id/content"
android:layout_width="fill_parent"
android:layout_height="fill_parent" />
하고 난 런타임 단편 ViewPager에 조각을 잡고 콘텐츠 ID와 FrameLayout이 대체하려는. 그것은 가능한가 ??
와우, 시험해 보겠습니다. 고마워요! – XepterX