SurfaceFlinger Input: Shrink frame by surfaceInsets.

Probably best explained by the comment in InputWindow.h. We can't
use touchable region because we need to shift the coordinate space.
As a follow-up I'm going to look in to shifting the coordinate space
on the client but it was very non obvious where to do so.

Test: Manual
Bug: 80101428
Bug: 113136004
Bug: 111440400
Change-Id: Ibbaffa89a80f3a047c716265251f547631bdf802
diff --git a/services/surfaceflinger/Layer.cpp b/services/surfaceflinger/Layer.cpp
index 3c37cf8..bfae03d 100644
--- a/services/surfaceflinger/Layer.cpp
+++ b/services/surfaceflinger/Layer.cpp
@@ -2069,12 +2069,12 @@
 
 InputWindowInfo Layer::fillInputInfo(const Rect& screenBounds) {
     InputWindowInfo info = mDrawingState.inputInfo;
-    info.frameLeft = screenBounds.left;
-    info.inputInfo.frameTop = screenBounds.top;
-    info.inputInfo.frameRight = screenBounds.right;
-    info.inputInfo.frameBottom = screenBounds.bottom;
+    info.frameLeft = screenBounds.left + info.surfaceInset;
+    info.frameTop = screenBounds.top + info.surfaceInset;
+    info.frameRight = screenBounds.right - info.surfaceInset;
+    info.frameBottom = screenBounds.bottom - info.surfaceInset;
 
-    info.touchableRegion = mDrawingState.inputInfo.touchableRegion.translate(
+    info.touchableRegion = info.touchableRegion.translate(
             screenBounds.left,
             screenBounds.top);
     info.visible = isVisible();