Class VColorPickerGrid

  • All Implemented Interfaces:
    com.google.gwt.event.dom.client.ClickHandler, com.google.gwt.event.dom.client.HasClickHandlers, com.google.gwt.event.logical.shared.HasAttachHandlers, com.google.gwt.event.shared.EventHandler, 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.HasWidgets, com.google.gwt.user.client.ui.HasWidgets.ForIsWidget, com.google.gwt.user.client.ui.IndexedPanel, com.google.gwt.user.client.ui.IndexedPanel.ForIsWidget, com.google.gwt.user.client.ui.InsertPanel, com.google.gwt.user.client.ui.InsertPanel.ForIsWidget, com.google.gwt.user.client.ui.IsWidget, Iterable<com.google.gwt.user.client.ui.Widget>

    public class VColorPickerGrid
    extends com.google.gwt.user.client.ui.AbsolutePanel
    implements com.google.gwt.event.dom.client.ClickHandler, com.google.gwt.event.dom.client.HasClickHandlers
    Client side implementation for ColorPickerGrid.
    Since:
    7.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
      • Nested classes/interfaces inherited from interface com.google.gwt.user.client.ui.HasWidgets

        com.google.gwt.user.client.ui.HasWidgets.ForIsWidget
      • Nested classes/interfaces inherited from interface com.google.gwt.user.client.ui.IndexedPanel

        com.google.gwt.user.client.ui.IndexedPanel.ForIsWidget
      • Nested classes/interfaces inherited from interface com.google.gwt.user.client.ui.InsertPanel

        com.google.gwt.user.client.ui.InsertPanel.ForIsWidget
    • Field Summary

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

        DEBUG_ID_PREFIX
    • Constructor Summary

      Constructors 
      Constructor Description
      VColorPickerGrid()
      Instantiates the client side component for a color picker grid.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      com.google.gwt.event.shared.HandlerRegistration addClickHandler​(com.google.gwt.event.dom.client.ClickHandler handler)  
      int getSelectedX()
      Returns currently selected x-coordinate of the grid.
      int getSelectedY()
      Returns currently selected y-coordinate of the grid.
      boolean isGridLoaded()
      Checks whether the colors have been successfully updated at least once.
      void onClick​(com.google.gwt.event.dom.client.ClickEvent event)  
      void updateColor​(String[] changedColor, String[] changedX, String[] changedY)
      Updates the changed colors within the grid based on the given x- and y-coordinates.
      void updateGrid​(int rowCount, int columnCount)
      Updates the row and column count and creates a new grid based on them.
      • Methods inherited from class com.google.gwt.user.client.ui.AbsolutePanel

        add, add, add, getWidgetLeft, getWidgetTop, insert, insert, insert, remove, setWidgetPosition, setWidgetPositionImpl
      • Methods inherited from class com.google.gwt.user.client.ui.ComplexPanel

        add, add, adjustIndex, checkIndexBoundsForAccess, checkIndexBoundsForInsertion, getChildren, getWidget, getWidgetCount, getWidgetIndex, getWidgetIndex, insert, insert, iterator, remove
      • Methods inherited from class com.google.gwt.user.client.ui.Panel

        add, adopt, clear, doAttachChildren, doDetachChildren, orphan, remove
      • Methods inherited from class com.google.gwt.user.client.ui.Widget

        addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, fireEvent, getHandlerCount, getLayoutData, getParent, isAttached, isOrWasAttached, onAttach, onBrowserEvent, onDetach, 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, resolvePotentialElement, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toString
      • Methods inherited from interface com.google.gwt.event.shared.HasHandlers

        fireEvent
      • Methods inherited from interface com.google.gwt.user.client.ui.IndexedPanel

        getWidget, getWidgetCount, getWidgetIndex, remove
      • Methods inherited from interface com.google.gwt.user.client.ui.IndexedPanel.ForIsWidget

        getWidgetIndex
      • Methods inherited from interface com.google.gwt.user.client.ui.InsertPanel.ForIsWidget

        add
    • Constructor Detail

      • VColorPickerGrid

        public VColorPickerGrid()
        Instantiates the client side component for a color picker grid.
    • Method Detail

      • updateGrid

        public void updateGrid​(int rowCount,
                               int columnCount)
        Updates the row and column count and creates a new grid based on them. The new grid replaces the old grid if one existed.

        For internal use only. May be renamed or removed in a future release.

        Parameters:
        rowCount - how many rows the grid should have
        columnCount - how many columns the grid should have
      • updateColor

        public void updateColor​(String[] changedColor,
                                String[] changedX,
                                String[] changedY)
        Updates the changed colors within the grid based on the given x- and y-coordinates. Nothing happens if any of the parameters is null or the parameter lengths don't match.

        For internal use only. May be renamed or removed in a future release.

        Parameters:
        changedColor - the changed colors
        changedX - the x-coordinates for the changed colors
        changedY - the y-coordinates for the changed colors
      • getSelectedX

        public int getSelectedX()
        Returns currently selected x-coordinate of the grid.
        Returns:
        the selected x-coordinate
      • getSelectedY

        public int getSelectedY()
        Returns currently selected y-coordinate of the grid.
        Returns:
        the selected y-coordinate
      • isGridLoaded

        public boolean isGridLoaded()
        Checks whether the colors have been successfully updated at least once.

        For internal use only. May be renamed or removed in a future release.

        Returns:
        true if the colors have been successfully updated at least once, false otherwise
      • onClick

        public void onClick​(com.google.gwt.event.dom.client.ClickEvent event)
        Specified by:
        onClick in interface com.google.gwt.event.dom.client.ClickHandler
      • addClickHandler

        public com.google.gwt.event.shared.HandlerRegistration addClickHandler​(com.google.gwt.event.dom.client.ClickHandler handler)
        Specified by:
        addClickHandler in interface com.google.gwt.event.dom.client.HasClickHandlers