public void onDestroyActionMode(ActionMode mode) {
   selected = new ArrayList<LayerStore>();
   getListView().clearChoices();
   getListView().clearFocus();
   actionMode = null;
   adapter.notifyDataSetChanged();
 }
  /* (non-Javadoc)
   * @see android.support.v4.app.LoaderManager.LoaderCallbacks#onLoadFinished(android.support.v4.content.Loader, java.lang.Object)
   */
  @Override
  public void onLoadFinished(Loader<List<LayerStore>> loader, List<LayerStore> result) {

    adapter.clear();
    ArrayList<LayerStore> ll = new ArrayList<LayerStore>();
    int size = result.size();

    Log.v("SOURCES", "Loaded sources:" + size);
    if (size > 0) {
      for (LayerStore ls : result) {
        adapter.add(ls);
      }
    }

    adapter.notifyDataSetChanged();
  }