public void swapElements(int indexOne, int indexTwo) {
   mDbHelper.swapElements(
       DbHelper.getItem((Cursor) mAdapter.getItem(indexOne)),
       DbHelper.getItem((Cursor) mAdapter.getItem(indexTwo)));
   requery();
 }
 public void toggleCompleted(int index) {
   ListEntry entry = DbHelper.getItem((Cursor) mAdapter.getItem(index));
   mDbHelper.updateCompleted(entry.getId(), !entry.isCompleted());
   requery();
 }