Update the galleries tree.<p>

@param galleryTreeEntries the new gallery tree list
@param selectedGalleries the list of galleries to select
187716
public void updateTreeContent(List<CmsGalleryTreeEntry> galleryTreeEntries, List<String> selectedGalleries) {

        clearList();
        m_selectedGalleries = selectedGalleries;
        if (!galleryTreeEntries.isEmpty()) {
            m_itemIterator = new TreeItemGenerator(galleryTreeEntries);
            loadMoreItems();
        } else {
            showIsEmptyLabel();
        }
        onContentChange();
    }
905447
public void updateContentList(List<CmsTreeItem> treeItemsToShow) {

        m_scrollList.clearList();
        if ((treeItemsToShow != null) && !treeItemsToShow.isEmpty()) {
            for (CmsTreeItem dataValue : treeItemsToShow) {
                dataValue.removeOpener();
                m_scrollList.add(dataValue);
                CmsScrollPanel scrollparent = (CmsScrollPanel)m_scrollList.getParent();
                scrollparent.onResizeDescendant();
            }
        } else {
            showIsEmptyLabel();
        }
        scheduleResize();
    }
1093338
public void setStartGalleriesSetting(Map<String, String> settings) {

        m_startGalleriesSettings = new TreeMap<String, String>(settings);
    }
1282689
public void setFolders(java.util.Collection<FolderMetadata> folders) {
        if (folders == null) {
            this.folders = null;
            return;
        }

        this.folders = new java.util.ArrayList<FolderMetadata>(folders);
    }
1117023
public void buildCategoryTree(List<CmsCategoryTreeEntry> treeEntries, Collection<String> selectedCategories) {

        m_valuesSet = 0;
        m_allSidePath.clear();
        m_categories.removeFromParent();
        m_categories.clear();

        if ((treeEntries != null) && !treeEntries.isEmpty()) {
            // add the first level and children
            for (CmsCategoryTreeEntry category : treeEntries) {
                // set the category tree item and add to list
                CmsTreeItem treeItem;
                boolean hasSelectedChildren = hasSelectedChildren(category.getChildren(), selectedCategories);
                if (!category.getPath().isEmpty() || hasSelectedChildren) {
                    if (m_selectParent || !hasSelectedChildren) {
                        treeItem = buildTreeItem(category, selectedCategories, false);
                        if (treeItem.isOpen()) {
                            m_allSidePath.add(category.getSitePath());
                        }
                    } else {
                        treeItem = buildTreeItem(category, selectedCategories, true);
                    }
                    if (treeItem.isOpen()) {
                        m_singleSidePath = category.getSitePath();

                        m_valuesSet++;
                        addChildren(treeItem, category.getChildren(), selectedCategories);
                    }
                }
            }
        }
        m_scrollPanel.add(m_categories);
        m_scrollPanel.onResizeDescendant();

    }
721179
private void setListSelection(int selectedIndex) {
        if (selectedIndex == -1) {
            list.clearSelection();
        } else {
            list.setSelectedIndex(selectedIndex);
            list.ensureIndexIsVisible(selectedIndex);
        }
    }
1154319
public void onUpdateCategoriesTree(List<CmsCategoryTreeEntry> categoryTreeEntry, List<String> selectedCategories) {

        m_galleryDialog.getCategoriesTab().updateContentTree(categoryTreeEntry, selectedCategories);
    }
225212
public final void addSubEntries(final Collection<NavigationEntryInterface> psubEntries) {
    if (!CollectionUtils.isEmpty(psubEntries)) {
      subEntries.addAll(psubEntries);
      subEntries.forEach(subEntry -> subEntry.setParentEntry(this));
    }
  }
962237
public void setParseSVNEntries(boolean parseSVNentries) {
		this.parseSVNentries = parseSVNentries;
		getConfig().setProperty(SPIDER_PARSE_SVN_ENTRIES, Boolean.toString(parseSVNentries));
	}
99583
public void setCategoriesTabContent(List<CmsCategoryTreeEntry> categoryRoot, List<String> selected) {

        m_galleryDialog.getCategoriesTab().fillContent(categoryRoot, selected);
    }
1144272
private boolean hasSelectedChildren(List<CmsCategoryTreeEntry> children, Collection<String> selectedCategories) {

        boolean result = false;
        if (children == null) {
            return false;
        }
        for (CmsCategoryTreeEntry child : children) {
            result = selectedCategories.contains(child.getSitePath());
            if (result || hasSelectedChildren(child.getChildren(), selectedCategories)) {
                return true;
            }
        }

        return result;
    }
1245458
public void setSelectedCategories(Collection<CmsCategory> categories) {

        for (Entry<CmsCategory, CheckBox> entry : m_checkboxes.entrySet()) {
            entry.getValue().setValue(Boolean.valueOf(categories.contains(entry.getKey())));
            CmsCategory parentCat = (CmsCategory)getParent(entry.getKey());
            if (parentCat != null) {
                setCollapsed(parentCat, false);
            }
        }
    }
315440
private void addGalleryEntries(CmsGalleryTreeItem parent, List<CmsGalleryFolderEntry> galleries) {

        for (CmsGalleryFolderEntry galleryFolder : galleries) {
            CmsGalleryTreeItem folderItem = createGalleryFolderItem(galleryFolder);
            parent.addChild(folderItem);
            m_galleryTreeItems.put(galleryFolder.getStructureId(), folderItem);
            addGalleryEntries(folderItem, galleryFolder.getSubGalleries());
        }
    }
1028524
public void setBudgetedAndActualAmountsList(java.util.Collection<BudgetedAndActualAmounts> budgetedAndActualAmountsList) {
        if (budgetedAndActualAmountsList == null) {
            this.budgetedAndActualAmountsList = null;
            return;
        }

        this.budgetedAndActualAmountsList = new java.util.ArrayList<BudgetedAndActualAmounts>(budgetedAndActualAmountsList);
    }
998850
public void setStartGallery(String galleryType, String galleryUri) {

        if (galleryUri == null) {
            m_startGalleriesSettings.remove(galleryType);
        } else {
            m_startGalleriesSettings.put(galleryType, galleryUri);
        }
    }
34949
public void updateEntriesById(Collection<CmsUUID> ids) {

        Map<CmsUUID, CmsClientSitemapEntry> entries = m_controller.getEntriesById(ids);
        for (CmsClientSitemapEntry entry : entries.values()) {
            CmsSitemapTreeItem item = CmsSitemapTreeItem.getItemById(entry.getId());
            item.updateEntry(entry);
        }
    }
688976
public void setEntries(java.util.Collection<java.util.Map<String, String>> entries) {
        if (entries == null) {
            this.entries = null;
            return;
        }

        this.entries = new com.amazonaws.internal.SdkInternalList<java.util.Map<String, String>>(entries);
    }