Remove header after deleting all group
This commit is contained in:
parent
2b9275bcd9
commit
96502930d2
1 changed files with 8 additions and 5 deletions
|
@ -325,13 +325,17 @@ public class NotesFragment extends OsmAndListFragment {
|
|||
return new SortFragmentListener() {
|
||||
@Override
|
||||
public void onSortModeChanged() {
|
||||
listAdapter.clear();
|
||||
listAdapter.addAll(createItemsList());
|
||||
listAdapter.notifyDataSetChanged();
|
||||
recreateAdapterData();
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private void recreateAdapterData() {
|
||||
listAdapter.clear();
|
||||
listAdapter.addAll(createItemsList());
|
||||
listAdapter.notifyDataSetChanged();
|
||||
}
|
||||
|
||||
private void enterSelectionMode(final int type) {
|
||||
actionMode = getActionBarActivity().startSupportActionMode(new ActionMode.Callback() {
|
||||
|
||||
|
@ -418,9 +422,8 @@ public class NotesFragment extends OsmAndListFragment {
|
|||
Recording rec = it.next();
|
||||
plugin.deleteRecording(rec, true);
|
||||
it.remove();
|
||||
listAdapter.remove(rec);
|
||||
}
|
||||
listAdapter.notifyDataSetChanged();
|
||||
recreateAdapterData();
|
||||
}
|
||||
})
|
||||
.setNegativeButton(R.string.shared_string_cancel, null)
|
||||
|
|
Loading…
Reference in a new issue