MDP-Team / MDP-Assignment

Assignment for Mobile Device Programming Study Unit
0 stars 0 forks source link

Update drawer item "click" listener #5

Open dannydes opened 10 years ago

dannydes commented 10 years ago

The selectItem() method is to be extended so as to launch the sorting scheme selected. Method starts at https://github.com/MDP-Team/MDP-Assignment/blob/master/app/src/main/java/uom/ict/mdp/NavigationDrawerFragment.java#L191.

We should also explore the existence of methods retrieving the name or some property of the selected item.

Algorithm is to look like this:

if (this_sort_selected) {
  this_sort();
} else {
  that_sort();
}
dannydes commented 10 years ago

http://developer.android.com/reference/android/widget/AbsListView.html#setItemChecked(int,%20boolean)

http://developer.android.com/reference/android/widget/AbsListView.html#isItemChecked(int)