Last active
April 3, 2020 20:04
-
-
Save FarshadTahmasbi/fcc9425eaa308a567e649e08e4b6af26 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
img.getLocalVisibleRect(rect) | |
val clipType = when { | |
rect.height() == img.height -> NO_CLIP | |
rect.top > 0 -> CLIP_TOP | |
else -> CLIP_BOTTOM | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment