Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d841628a authored by Chong Zhang's avatar Chong Zhang Committed by Android (Google) Code Review
Browse files

Merge "Exclude system decor area from tap detection."

parents 6d9df397 73c3fcf5
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -373,6 +373,12 @@ class DisplayContent {
                     */
                    if (isFreeformed) {
                        mTmpRect.inset(-delta, -delta);
                        // Intersect with display content rect. If we have system decor (status bar/
                        // navigation bar), we want to exclude that from the tap detection.
                        // Otherwise, if the app is partially placed under some system button (eg.
                        // Recents, Home), pressing that button would cause a full series of
                        // unwanted transfer focus/resume/pause, before we could go home.
                        mTmpRect.intersect(mContentRect);
                    }
                    mTouchExcludeRegion.op(mTmpRect, Region.Op.DIFFERENCE);
                }