1
0
mirror of https://github.com/moparisthebest/Yaaic synced 2024-11-26 02:42:16 -05:00

UserActivity: Do not update list in Thread. Use a background task later

This commit is contained in:
Sebastian Kaspari 2010-10-27 23:14:25 +02:00
parent 4fc593050f
commit 99cf534f20

View File

@ -57,13 +57,9 @@ public class UsersActivity extends ListActivity implements OnItemClickListener
// Add sorted list of users in own thread to avoid blocking UI
// TODO: Move to a background task and show loading indicator while sorting
(new Thread() {
public void run() {
Arrays.sort(users, String.CASE_INSENSITIVE_ORDER);
getListView().setAdapter(new ArrayAdapter<String>(UsersActivity.this, R.layout.useritem, users));
}
}).start();
}
/**
* On user selected