-1

私はAndroid開発の初心者で、ビューフリッパー内にリストビューと複数のWebビューを表示しようとしています。webviews と listview を追加する前に、viewflipper xml は正常に解析および実行されていました。ただし、現在、eclipe は同じ「要素タイプ "WebView" の後に属性仕様 ">" または "/>" が続く必要があります。」ビューフリッパーの各子ビューのメッセージ。何が起こっているのかを理解しようとして、私は機知に富んでいます。どんな助けでも大歓迎です。

<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="match_parent"
android:layout_height="match_parent" android:background="#FFFFFF">

<ImageButton
    android:id="@+id/twitter"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_gravity="bottom|right"
    android:background="@null"
    android:src="@drawable/twitterlogo" >
</ImageButton>

<ImageButton
android:id="@+id/youtube"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|right"
android:layout_marginRight="100dp"
android:background="@null"
android:src="@drawable/youtubelogo" >
</ImageButton>

<ImageButton
android:id="@+id/rss"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|right"
android:layout_marginRight="50dp"
android:background="@null"
android:src="@drawable/rsslogo" >
</ImageButton>

<ImageButton
android:id="@+id/calendar"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|right"
android:layout_marginRight="150dp"
android:background="@null"
android:src="@drawable/ic_launcher" >
</ImageButton>

<ViewFlipper android:layout_width="match_parent"
    android:layout_height="match_parent" android:id="@+id/viewFlipper1" >
    <WebView android:id="@+id/webViewnews"android:layout_width="match_parent"
        android:layout_height="match_parent" ></WebView>
    <ListView android:id="@+id/ListViewId" android:layout_width="fill_parent"
        android:layout_height="wrap_content"android:cacheColorHint="#00000000"></ListView>          
    <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>

4

1 に答える 1

1

プロジェクトをクリーンアップする必要があるようです。それでもうまくいかない場合は、構造を少しクリーンアップします。Crtl+Shift+F でうまくいくはずです。

于 2012-09-20T04:15:13.110 に答える