Class TLcdGXYCenterRasterController

All Implemented Interfaces:
ILcdUndoableSource, ILcdStatusSource, ILcdGXYController, KeyListener, MouseListener, MouseMotionListener, Serializable, EventListener

public class TLcdGXYCenterRasterController extends ALcdGXYSmartController
Deprecated.
TLcdGXYZoomWheelController features a more intuitive way to snap to raster and multilevel raster scales.
Centers an ILcdView on an instance of ILcdRaster.

The ILcdRaster which contains the location of the MouseEvent on the ILcdView, is the one on which to center. The location of the MouseEvent will be the new center of the view. If no raster contains the location, the last ILcdRaster instance will be centered upon. In case of a ILcdMultilevelRaster the second of its ILcdRaster instances is considered.

Resulting from the center operation, the scale of the ILcdGXYViewis such that the raster is depicted with a resolution of one. That is one pixel of the original image that the tile represents corresponds to one screen pixel. If necessary, the scale is clamped to lie within the scale range of the ILcdGXYLayer.

See Also:
  • Constructor Details

    • TLcdGXYCenterRasterController

      public TLcdGXYCenterRasterController()
      Deprecated.
  • Method Details

    • retrieveGXYLayer

      protected ILcdGXYLayer retrieveGXYLayer(ILcdGXYView aGXYView, MouseEvent aMouseEvent)
      Deprecated.
      Retrieves the first ILcdGXYLayer within the given ILcdGXYView which model has an ILcdModelDescriptor that is a TLcdRasterModelDescriptor or TLcdMultilevelRasterModelDescriptor and which contains the location of mouse event. If no layer contains the the location of the mouse event, the topmost raster layer is returned. If no raster layers exists, null is returned.
    • retrieveRaster

      protected ILcdRaster retrieveRaster(ILcdGXYLayer aGXYLayer, ILcdPoint aModelPoint)
      Deprecated.
      This method returns the first instance of ILcdRaster of the ILcdModel of the given ILcdGXYLayer that contains the given ILcdPoint. In case of an ILcdMultilevelRaster the second of its ILcdRaster instances is chosen. If aModelPoint is null, the last encountered single level raster is returned. If the layer doesn't contain such a raster, the raster at the second level of the last encountered multilevel raster is returned.
    • containsValidRaster

      protected boolean containsValidRaster(ILcdGXYLayer aGXYLayer, ILcdPoint aModelPoint)
      Deprecated.
    • centerRaster

      protected void centerRaster(MouseEvent aMouseEvent)
      Deprecated.
      See Also:
    • centerRaster

      protected void centerRaster(ILcdRaster aRaster, ILcdModelXYWorldTransformation aMWT, ILcdGXYLayer aGXYLayer, ILcdGXYView aGXYView, MouseEvent aMouseEvent)
      Deprecated.
      This method will center aRaster in aGXYView. The given ILcdRaster is represented in the given ILcdGXYLayer which is drawn in the ILcdGXYView. If the location of the MouseEvent is within the raster, the raster is center on that point, else the middle of the raster will be the central point in the view.
    • mouseClicked

      public void mouseClicked(MouseEvent e)
      Deprecated.
      This method doesn't perform any operation.
      Specified by:
      mouseClicked in interface MouseListener
      Overrides:
      mouseClicked in class ALcdGXYSmartController
    • mousePressed

      public void mousePressed(MouseEvent e)
      Deprecated.
      This method doesn't perform any operation.
      Specified by:
      mousePressed in interface MouseListener
      Overrides:
      mousePressed in class ALcdGXYSmartController
    • mouseReleased

      public void mouseReleased(MouseEvent e)
      Deprecated.
      This method triggers the centering of the view on a raster (see description above).
      Specified by:
      mouseReleased in interface MouseListener
      Overrides:
      mouseReleased in class ALcdGXYSmartController
    • mouseEntered

      public void mouseEntered(MouseEvent e)
      Deprecated.
      This method doesn't perform any operation.
      Specified by:
      mouseEntered in interface MouseListener
      Overrides:
      mouseEntered in class ALcdGXYSmartController
    • mouseExited

      public void mouseExited(MouseEvent e)
      Deprecated.
      This method doesn't perform any operation.
      Specified by:
      mouseExited in interface MouseListener
      Overrides:
      mouseExited in class ALcdGXYSmartController