Fix crash when resuming MessageListXL.
It's related to the use of Activity.manageQuery(). This may be a regression in the framework, but it's annoying enough and causing a problem with testing, let's just not use managedQuery(). Bug 2901309. Change-Id: I8ae5b6ffe17979a094d5a23d49f42e8de04ed4f0
This commit is contained in:
parent
2cb5b04204
commit
f48fe98b2a
@ -894,7 +894,8 @@ public class MessageListFragment extends ListFragment implements OnItemClickList
|
||||
// Load messages
|
||||
String selection =
|
||||
Utility.buildMailboxIdSelection(mResolver, mMailboxKey);
|
||||
Cursor c = mActivity.managedQuery(EmailContent.Message.CONTENT_URI, MESSAGE_PROJECTION,
|
||||
Cursor c = mActivity.getContentResolver().query(
|
||||
EmailContent.Message.CONTENT_URI, MESSAGE_PROJECTION,
|
||||
selection, null, EmailContent.MessageColumns.TIMESTAMP + " DESC");
|
||||
return c;
|
||||
}
|
||||
@ -910,7 +911,6 @@ public class MessageListFragment extends ListFragment implements OnItemClickList
|
||||
}
|
||||
MessageListFragment.this.mAccountId = mAccountKey;
|
||||
|
||||
// TODO changeCursor(null)??
|
||||
mListAdapter.changeCursor(cursor);
|
||||
setListAdapter(mListAdapter);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user