Moje rozloženie xml (lvlayout.xml) pre zobrazenie zoznamu je v súčasnosti toto:
<TextView
android:id="@+id/busnum"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="15dip"
android:gravity="center_horizontal" />
<TextView
android:id="@+id/servdate"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="10dip"
android:textColor="#23cf34" />
Populácia zobrazenia zoznamu pomocou jednoduchého adaptéra ako je tento:
dueAdapter = new SimpleCursorAdapter(main.this, R.layout.lvlayout,
dueBusesCursor, columnsdue, to);
dueListView = (ListView) findViewById(R.id.ListView01);
dueListView.setAdapter(dueAdapter);
Ako môžem zobraziť zoznamy horizontálne tak, aby sa používateľ posúval do strán? vopred ďakujem.
odpovede:
1 pre odpoveď č. 1ListView nepodporuje horizontálny režim. Najbližšie k horizontálnej ListView je Galéria.
0 pre odpoveď č. 2
môžete použiť ViewPager:
http://developer.android.com/reference/android/support/v4/view/ViewPager.html