Class BaseContainerChild

    • Constructor Detail

      • BaseContainerChild

        protected BaseContainerChild​(String name,
                                     be.yildizgames.module.coordinate.BaseCoordinate coordinates,
                                     Container container)
        Full constructor.
        Parameters:
        name - Widget name, must be unique.
        coordinates - Widget size and position.
        container - Container holding the widget.
    • Method Detail

      • addEmptyZoneImpl

        protected final void addEmptyZoneImpl​(be.yildizgames.common.geometry.Rectangle zone)
        Specified by:
        addEmptyZoneImpl in class BaseWidget
      • setUnaffectedByZoom

        public final void setUnaffectedByZoom()
        If the view containing this widget is zoomed, the widget will not be affected.
      • updateSizeAfterZoom

        public final void updateSizeAfterZoom​(float factor)
        Zoom in the container does not update this object size, to keep it coherent, it is updated in this method.
        Specified by:
        updateSizeAfterZoom in interface ContainerChild
        Parameters:
        factor - Zoom factor.
      • setStatic

        public final ContainerChild setStatic()
        Optimization to avoid to check this element when receiving events.
        Returns:
        this.
      • setLeftFromParent

        public final ContainerChild setLeftFromParent​(PositionRelativeLeft relative,
                                                      int diff)
        Description copied from interface: ContainerChild
        Set the left position relative to the parent position with a difference.
        Specified by:
        setLeftFromParent in interface ContainerChild
        Parameters:
        relative - Position to set.
        diff - Difference to set.
        Returns:
        This element for chaining methods.
      • setTopFromParent

        public final ContainerChild setTopFromParent​(PositionRelativeTop relative,
                                                     int diff)
        Description copied from interface: ContainerChild
        Set the top position relative to the parent position with a difference.
        Specified by:
        setTopFromParent in interface ContainerChild
        Parameters:
        relative - Position to set.
        diff - Difference to set.
        Returns:
        This element for chaining methods.