public void listAdded(String listName) {
   FavoritesListener[] listeners =
       myListeners.toArray(new FavoritesListener[myListeners.size()]);
   for (FavoritesListener listener : listeners) {
     listener.listAdded(listName);
   }
 }
 public synchronized void createNewList(
     @NotNull String name, boolean readOnly, boolean allowsTree) {
   myName2FavoritesRoots.put(name, new ArrayList<TreeItem<Pair<AbstractUrl, String>>>());
   if (readOnly) {
     myReadOnlyLists.add(name);
   }
   if (allowsTree) {
     myAllowsTreeLists.add(name);
   }
   fireListeners.listAdded(name);
 }
 public synchronized boolean renameFavoritesList(
     @NotNull String oldName, @NotNull String newName) {
   if (myReadOnlyLists.contains(oldName)) return false;
   List<TreeItem<Pair<AbstractUrl, String>>> list = myName2FavoritesRoots.remove(oldName);
   if (list != null && newName.length() > 0) {
     myName2FavoritesRoots.put(newName, list);
     fireListeners.listRemoved(oldName);
     fireListeners.listAdded(newName);
     return true;
   }
   return false;
 }