public TreeItem( boolean root )
  {
    this.root = root;
    NavigationTreeResources.INSTANCE.css().ensureInjected();
    Element element = DOM.createElement( "li" );
    widgetContainer = DOM.createDiv();
    widgetContainer.setId( NavigationTreeResources.INSTANCE.css().widgetContainer() );
    element.appendChild( widgetContainer );
    setElement( element );
    setStyleName( NavigationTreeResources.INSTANCE.css().treeItem() );
    DOM.setElementProperty( element, "id", DOM.createUniqueId() );

    // A root element always has children && special Style if root contains no element
    if ( root )
    {
      initChildren();
    }
  }