code: @SuppressWarnings("unchecked")
      public void updateContentTree(List<CmsCategoryTreeEntry> treeEntries, List<String> selectedCategories) {
  
          clearList();
          if (m_categories == null) {
              m_categories = new HashMap<String, CmsCategoryBean>();
          }
          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 = buildTreeItem(category, selectedCategories);
                  treeItem.setTree((CmsTree<CmsTreeItem>)m_scrollList);
                  addChildren(treeItem, category.getChildren(), selectedCategories);
                  addWidgetToList(treeItem);
                  treeItem.setOpen(true, false);
              }
          } else {
              showIsEmptyLabel();
          }
      }
docs: Updates the content of th categories tree.<p>
  
  @param treeEntries the root category entry
  @param selectedCategories the categories to select after update