Class CmsResultListItem

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.gwt.client.ui.CmsListItem
org.opencms.ade.galleries.client.ui.CmsResultListItem
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, I_CmsDraggable, I_CmsListItem, I_CmsTruncable

public class CmsResultListItem extends CmsListItem
Provides the specific list item for the results list.

Since:
8.0.
  • Constructor Details

    • CmsResultListItem

      public CmsResultListItem(org.opencms.ade.galleries.shared.CmsResultItemBean resultItem, boolean hasPreview, boolean showPath, CmsDNDHandler dndHandler)
      Creates a new result list item with a main widget.

      Parameters:
      resultItem - the result item
      hasPreview - if the item has a preview option
      showPath - true to show the resource path in sub title
      dndHandler - the drag and drop handler
  • Method Details

    • createDeleteButton

      Creates the delete button for this item.

      Returns:
      the delete button
    • addDoubleClickHandler

      public com.google.gwt.event.shared.HandlerRegistration addDoubleClickHandler(com.google.gwt.event.dom.client.DoubleClickHandler handler)
      Adds a double click event handler.

      Parameters:
      handler - the event handler to add
      Returns:
      the handler registration for removing the event handler
    • addPreviewClickHandler

      public void addPreviewClickHandler(com.google.gwt.event.dom.client.ClickHandler handler)
      Adds the preview button click handler.

      Parameters:
      handler - the click handler
    • addSelectClickHandler

      public void addSelectClickHandler(com.google.gwt.event.dom.client.ClickHandler handler)
      Adds the select button click handler.

      Parameters:
      handler - the click handler
    • getName

      public String getName()
      Returns the name.

      Returns:
      the name
    • getResourceType

      Returns the resource type name.

      Returns:
      the resource type name
    • getResult

      public org.opencms.ade.galleries.shared.CmsResultItemBean getResult()
      Gets the search result bean.

      Returns:
      the search result bean
    • setName

      public void setName(String name)
      Sets the name.

      Parameters:
      name - the name to set
    • setResourceType

      public void setResourceType(String resourceType)
      Sets the resource type name.

      Parameters:
      resourceType - the resource type name to set