Пример #1
0
  private void fillData() {
    mGroupAdapter = new SeparatedListAdapter(this);

    mGroupAdapter.addSection("", new GameMessageAdapter(this, mMessage, true));
    if (mPeople != null)
      mGroupAdapter.addSection("People", new UserListAdapter(this, mPeople, false, null));

    setListAdapter(mGroupAdapter);
  }
Пример #2
0
  @Override
  protected void onListItemClick(ListView l, View v, int position, long id) {
    super.onListItemClick(l, v, position, id);
    Log.v(TAG, "position = " + position + "; id = " + id);

    if (position < 3) return;

    int userId = (Integer) mGroupAdapter.getItem(position);
    Common.log(TAG, "onListItemClick(): user id = " + userId);
    Intent i = new Intent(this, PeopleTrackList.class);
    i.putExtra("userId", userId);
    startActivity(i);
  }