FrameLayout
に1LinearLayouts
が含まれているとします.1時間あたり1つしか表示されません。あまりにも多くのレイアウトの可視性をパフォーマンスの問題に変更することがありますか?
各LinearLayout
したがって
<FrameLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:id="@+id/alice
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="visible">
<!-- complex stuff -->
</LinearLayout>
<!-- many more linear layouts... -->
<LinearLayout
android:id="@+id/juliett
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone">
<!-- last complex stuff -->
</LinearLayout>
</FrameLayout>
等、Button
を含む、複雑な図でEditText
、TextView
:
LinearLayout
可視性を変更する、別の項目を示すために、あろう巨大なパフォーマンスの問題?- 問題がある場合、なぜ
ViewFlipper
を使用してもアプリのパフォーマンスが低下することはありませんか?
'onLayout'、' onMeasure'、 'onRequestFocusInDescendants'、' onDraw'メソッドは 'View.VISIBLE'に設定されているビューでのみ呼び出され、' View。失踪した。私は、 'Fragment'や' ViewFlipper'が_cleaner_解決策であることを認識していますが、_performance issue_もあるかどうか質問しています。 –