am 5768ef61: Merge change 23939 into eclair

Merge commit '5768ef614bc7e45720da4ea2c92d261292993970' into eclair-plus-aosp

* commit '5768ef614bc7e45720da4ea2c92d261292993970':
  Fix crash related to long press of footer view in MessageList (2099784)
This commit is contained in:
Marc Blank 2009-09-04 16:17:29 -07:00 committed by Android Git Automerger
commit cc6e0db2c6

View File

@ -383,12 +383,12 @@ public class MessageList extends ListActivity implements OnItemClickListener, On
@Override
public void onCreateContextMenu(ContextMenu menu, View v, ContextMenuInfo menuInfo) {
super.onCreateContextMenu(menu, v, menuInfo);
// There is no context menu for the list footer
if (v == mListFooterView) {
return;
}
AdapterView.AdapterContextMenuInfo info = (AdapterView.AdapterContextMenuInfo) menuInfo;
// There is no context menu for the list footer
if (info.targetView == mListFooterView) {
return;
}
MessageListItem itemView = (MessageListItem) info.targetView;
Cursor c = (Cursor) mListView.getItemAtPosition(info.position);