Class CmsPublishGroupPanel

java.lang.Object
com.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.google.gwt.user.client.ui.Composite
org.opencms.ade.publish.client.CmsPublishGroupPanel
All Implemented Interfaces:
com.google.gwt.event.logical.shared.HasAttachHandlers, com.google.gwt.event.shared.HasHandlers, com.google.gwt.user.client.EventListener, com.google.gwt.user.client.ui.HasVisibility, com.google.gwt.user.client.ui.IsRenderable, com.google.gwt.user.client.ui.IsWidget

public class CmsPublishGroupPanel extends com.google.gwt.user.client.ui.Composite
A panel representing a single publish group.

Since:
8.0.0
  • Nested Class Summary

    Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject

    com.google.gwt.user.client.ui.UIObject.DebugIdImpl, com.google.gwt.user.client.ui.UIObject.DebugIdImplEnabled
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected static final I_CmsPublishCss
    The CSS bundle used for this widget.
    static int[]
    Button slot mapping for publish list items.
    protected int
    The group index for this panel's corresponding group.
    The data model for the publish dialog.
    The handler which is called when the publish item selection changes.
    static final int
    The slot for the preview button.
    static final int
    The slot for the context menu button.
    static final int
    The slot for the 'remove' checkbox.
    static final int
    The slot for the warning symbol.

    Fields inherited from class com.google.gwt.user.client.ui.UIObject

    DEBUG_ID_PREFIX
  • Constructor Summary

    Constructors
    Constructor
    Description
    CmsPublishGroupPanel(org.opencms.ade.publish.shared.CmsPublishGroup publishGroup, String title, int groupIndex, I_CmsPublishSelectionChangeHandler selectionChangeHandler, CmsPublishDataModel model, Map<org.opencms.util.CmsUUID,org.opencms.ade.publish.client.CmsPublishItemSelectionController> controllersById, CmsContextMenuHandler menuHandler, I_CmsContentEditorHandler editorHandler, boolean showProblemsOnly)
    Constructs a new instance.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Adds the list item for the next publish resource and returns true on success, while also incrementing the internal item index.
    createListItemWidget(org.opencms.ade.publish.shared.CmsPublishResource resourceBean, int[] slotMapping)
    Creates a basic list item widget for a given publish resource bean.
    static void
    fillButtonSlot(CmsListItemWidget listItemWidget, int index, com.google.gwt.user.client.ui.Widget widget, int[] slotMapping)
    Fills a slot for a button in a publish list item widget.
    boolean
    Returns true if there are more potential items to add.
    protected boolean
    Returns true if the corresponding group has no resources with problems.
    protected boolean
    Returns true if the corresponding group has only resources with problems.
    void
    Hides the tri-state select box for the group.
    void
    Updates the check box state for this group.

    Methods inherited from class com.google.gwt.user.client.ui.Composite

    claimElement, getWidget, initializeClaimedElement, initWidget, isAttached, onAttach, onBrowserEvent, onDetach, render, render, resolvePotentialElement, setWidget

    Methods inherited from class com.google.gwt.user.client.ui.Widget

    addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isOrWasAttached, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents, unsinkEvents

    Methods inherited from class com.google.gwt.user.client.ui.UIObject

    addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toString

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

  • Constructor Details

    • CmsPublishGroupPanel

      public CmsPublishGroupPanel(org.opencms.ade.publish.shared.CmsPublishGroup publishGroup, String title, int groupIndex, I_CmsPublishSelectionChangeHandler selectionChangeHandler, CmsPublishDataModel model, Map<org.opencms.util.CmsUUID,org.opencms.ade.publish.client.CmsPublishItemSelectionController> controllersById, CmsContextMenuHandler menuHandler, I_CmsContentEditorHandler editorHandler, boolean showProblemsOnly)
      Constructs a new instance.

      Parameters:
      publishGroup - the group for which to build the group panel
      title - the title of the group
      groupIndex - the index of the group which this panel should render
      selectionChangeHandler - the handler for selection changes for publish resources
      model - the data model for the publish resources
      controllersById - the map of selection controllers to which this panel's selection controllers should be added
      menuHandler - the context menu handler
      editorHandler - the content editor handler
      showProblemsOnly - if true, sets this panel into "show resources with problems only" mode
  • Method Details

    • createListItemWidget

      public static CmsListItemWidget createListItemWidget(org.opencms.ade.publish.shared.CmsPublishResource resourceBean, int[] slotMapping)
      Creates a basic list item widget for a given publish resource bean.

      Parameters:
      resourceBean - the publish resource bean
      slotMapping - maps button slot ids to actual button indexes
      Returns:
      the list item widget representing the publish resource bean
    • fillButtonSlot

      public static void fillButtonSlot(CmsListItemWidget listItemWidget, int index, com.google.gwt.user.client.ui.Widget widget, int[] slotMapping)
      Fills a slot for a button in a publish list item widget.

      Parameters:
      listItemWidget - the list item widget
      index - the slot index
      widget - the widget which should be displayed in the slot
      slotMapping - array mapping logical slot ids to button indexes
    • addNextItem

      public boolean addNextItem()
      Adds the list item for the next publish resource and returns true on success, while also incrementing the internal item index.

      Returns:
      true if an item was added
    • hasMoreItems

      public boolean hasMoreItems()
      Returns true if there are more potential items to add.

      Returns:
      true if there are possibly more items
    • hideGroupSelectCheckBox

      public void hideGroupSelectCheckBox()
      Hides the tri-state select box for the group.

    • updateCheckboxState

      Updates the check box state for this group.

      Parameters:
      value - the state to use for updating the check box
    • hasNoProblemResources

      protected boolean hasNoProblemResources()
      Returns true if the corresponding group has no resources with problems.

      Returns:
      true if the group for this panel has no resources with problems
    • hasOnlyProblemResources

      protected boolean hasOnlyProblemResources()
      Returns true if the corresponding group has only resources with problems.

      Returns:
      true if the group for this panel has only resources with problems.