Clip reactions mask if the view falls below the input panel.

This commit is contained in:
Alex Hart
2020-02-06 12:06:41 -04:00
committed by Greyson Parrelli
parent 5e59f77f83
commit 21cf390d0e
3 changed files with 11 additions and 4 deletions

View File

@@ -74,7 +74,9 @@ public class MaskView extends View {
target.getDrawingRect(drawingRect);
activityContentView.offsetDescendantRectToMyCoords(target, drawingRect);
Bitmap mask = Bitmap.createBitmap(target.getWidth(), target.getHeight(), Bitmap.Config.ARGB_8888);
drawingRect.bottom = Math.min(drawingRect.bottom, getBottom() - getPaddingBottom());
Bitmap mask = Bitmap.createBitmap(target.getWidth(), drawingRect.height(), Bitmap.Config.ARGB_8888);
Canvas maskCanvas = new Canvas(mask);
target.draw(maskCanvas);