I have some class LoginActivity.java. In the onCreate method I retrieve ListView:
ListView list = (ListView)findViewById(R.id.snListView);
then:
list.setAdapter(adapter);
In addition there are login.xml layout - there are:
<ListView
android:id="@+id/snListView"
android:layout_width="match_parent"
android:layout_height="match_parent" >
</ListView>
and sn_row.xml:
<RelativeLayout xmlns:andr..."
android:layout_width="wrap_content"
android:layout_height="100dp"
android:background="@drawable/listview_item_background"
android

rientation="horizontal" >
...
At the moment I have cell's height 100dp, I need that cell's height will depend on device, I mean I have here 5 cells showing at login screen in ListView and I need that these 5 rows will fit the ListView (cell's height = ListView's height/5).