mirror of
https://github.com/moparisthebest/k-9
synced 2024-11-04 08:35:08 -05:00
Update issue 2479
possible fix for "The content of the adapter has changed but ListView did not receive a notification."
This commit is contained in:
parent
951dbcbd33
commit
60ea4c6ce7
@ -341,8 +341,9 @@ public class ChooseFolder extends K9ListActivity
|
||||
}
|
||||
});
|
||||
mAdapter.setNotifyOnChange(false);
|
||||
mAdapter.clear();
|
||||
int selectedFolder = -1;
|
||||
try {
|
||||
mAdapter.clear();
|
||||
int position = 0;
|
||||
for (String name : localFolders)
|
||||
{
|
||||
@ -375,6 +376,15 @@ public class ChooseFolder extends K9ListActivity
|
||||
}
|
||||
position++;
|
||||
}
|
||||
} finally {
|
||||
mAdapter.setNotifyOnChange(true);
|
||||
runOnUiThread(new Runnable() {
|
||||
public void run() {
|
||||
// runOnUiThread(
|
||||
mAdapter.notifyDataSetChanged();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
mHandler.dataChanged();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user