1
我正在用一堆图像按钮做一个scrollView。不幸的是,这个视图需要很长时间才能加载 - 以至于用户可能会认为应用程序是错误的。图像按钮在Android中的缓慢加载时间
有关如何使此过程更快的任何想法?
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="fill_parent"
android:layout_height="fill_parent" >
<TableLayout
android:layout_height="fill_parent"
android:layout_width="fill_parent"
>
<TableRow>
<ImageButton
android:id="@+id/ImageButtonCone"
android:layout_width="160dp"
android:layout_height="200dp"
android:scaleType="fitCenter"
android:background="@drawable/cone"
/>
<ImageButton
android:id="@+id/ImageButtonCube"
android:layout_width="160dp"
android:layout_height="200dp"
android:scaleType="fitCenter"
android:background="@drawable/cube"
/>
</TableRow>
<TableRow>
<ImageButton
android:id="@+id/ImageButtonCylinder"
android:layout_width="160dp"
android:layout_height="200dp"
android:scaleType="fitCenter"
android:background="@drawable/cylinder"
/>
<ImageButton
android:id="@+id/ImageButtonTrapezoidalprism"
android:layout_width="160dp"
android:layout_height="200dp"
android:scaleType="fitCenter"
android:background="@drawable/trapezoidal_prism"
/>
等等
有多少个按钮? – Simon
12目前(虽然我想补充更多......可能不得不做第二页) - 在模拟器上正常工作(ish),但在手机上永远占用。 – Kurt
以前从未听说过:仿真器比设备速度更快.. – Ronnie