Exemplo n.º 1
0
  /**
   * Creates and returns a list adapter for the current list activity
   *
   * @return
   */
  protected ListAdapter createAdapter() {

    mHistoryItemList = HistoryManager.getInstance().getHistory();
    List<String> historyTextList = new ArrayList<String>();
    for (HistoryItem item : mHistoryItemList) {
      historyTextList.add(item.getDescription());
    }

    return new ArrayAdapter<String>(this, LIST_ITEM_TYPE, historyTextList);
  }
Exemplo n.º 2
0
 private void historyItemSelected(HistoryItem historyItem) {
   Log.i(TAG, "chose:" + historyItem);
   historyItem.revertTo();
   doFinish();
 }