2012-09-20 1 views
0

나는 안드로이드에 대한 멍청한 행동이고보기 플리퍼에서 4 가지보기를 전환하려고합니다. 내 첫 번째보기는 listview이며 아무 문제없이 대칭 이동합니다. 그러나, 내 webviews의 아무도 내리고있다. viewflipper는 webviews가 아닌 button 및 imageviews와 같은 다른 자식 뷰와 함께 잘 작동합니다. 이 문제를 해결하는 데 큰 도움이됩니다. 대신 ViewFlipper를 사용ViewFilpper가 웹보기를 왜 넘기지 않는 이유는 무엇입니까?

<?xml version="1.0" encoding="utf-8"?> 
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" 
android:id="@+id/tab2" 
android:layout_width="match_parent" 
android:layout_height="match_parent" 
android:background="#FFFFFF" 
android:orientation="vertical" > 

<ViewFlipper 
    android:id="@+id/viewFlipper1" 
    android:layout_width="match_parent" 
    android:layout_height="match_parent" > 

    <ListView 
     android:id="@+id/ListViewId" 
     android:layout_width="fill_parent" 
     android:layout_height="wrap_content" 
     android:cacheColorHint="#00000000" > 
    </ListView> 

    <WebView 
     android:id="@+id/webViewnews" 
     android:layout_width="match_parent" 
     android:layout_height="match_parent" > 
    </WebView> 

    <WebView 
     android:id="@+id/webViewcoinshows" 
     android:layout_width="match_parent" 
     android:layout_height="match_parent" > 
    </WebView> 

    <WebView 
     android:id="@+id/webViewyoutube" 
     android:layout_width="match_parent" 
     android:layout_height="match_parent" > 
    </WebView> 
</ViewFlipper> 

답변

1

ViewPager 사용하지 않는 : android.support.v4.view.ViewPager 그것을 구현하고 당신에게 뒤집기, 그리고 확실히 작동 더 나은 효과를 제공하기 위해 쉽게, 내가 전에 그것을 한 적이 . 설명서 here을 찾을 수 있습니다.

관련 문제