code: private void createMenuEntry(
          MenuItem parent,
          final CmsTreeNode<I_CmsContextMenuItem> node,
          CmsContextMenuTreeBuilder treeBuilder) {
  
          Command entryCommand = null;
          if (node.getChildren().size() == 0) {
              entryCommand = new Command() {
  
                  private static final long serialVersionUID = 1L;
  
                  public void menuSelected(MenuItem selectedItem) {
  
                      node.getData().executeAction(getDialogContext());
                  }
              };
          }
          MenuItem entry = parent.addItem((node.getData().getTitle(A_CmsUI.get().getLocale())), entryCommand);
          for (CmsTreeNode<I_CmsContextMenuItem> child : node.getChildren()) {
              createMenuEntry(entry, child, treeBuilder);
          }
          if (treeBuilder.getVisibility(node.getData()).isInActive()) {
              entry.setEnabled(false);
          }
      }
docs: Creates the context menu entry and it's children.<p>
  
  @param parent the entry parent
  @param node the item tree node
  @param treeBuilder the tree builder