Interface ZoomableSharingView

  • All Known Implementing Classes:
    ZoomableImageView

    public interface ZoomableSharingView
    • Method Detail

      • addOnTouchListener

        void addOnTouchListener​(android.view.View.OnTouchListener onTouchListener)
        Sets touch gesture listener on this view.
        Parameters:
        onTouchListener - listener object.
        See Also:
        View.OnTouchListener
      • getCurrentScale

        float getCurrentScale()
        Returns current scale of this view.
        Returns:
        scale.
      • getCurrentMatrix

        android.graphics.Matrix getCurrentMatrix()
        Returns current matrix of image.
        Returns:
        matrix.
      • getImageBoundsRect

        android.graphics.RectF getImageBoundsRect()
        Returns image bounds.
        Returns:
        bounds.
      • getImageBitmap

        android.graphics.Bitmap getImageBitmap()
        Returns bitmap image which was added to this view.
        Returns:
        bitmap image.
      • setImageBitmap

        void setImageBitmap​(android.graphics.Bitmap bitmap,
                            boolean original)
        Sets image bitmap for this view. If original is true, all image bounds are recalculated and its positioning inside the view.
        Parameters:
        bitmap - object represents image.
        original - if true - image will be fitted inside this view.
      • getActualBitmapTouch

        android.graphics.PointF getActualBitmapTouch​(android.graphics.PointF viewTouch)
        Calculates a bitmap coordinates from display touch. Returns null if the touch was outside the bitmap.
        Parameters:
        viewTouch - display touch point.
        Returns:
        point coordinates.
      • getActualDisplayTouch

        android.graphics.PointF getActualDisplayTouch​(android.graphics.PointF bitmapTouch)
        Calculates a display coordinates from the bitmap touch.
        Parameters:
        bitmapTouch - bitmap touch point.
        Returns:
        point from bitmap touch.