Desks: Let DesktopWallpaperActivity be focusable with empty desk
When there are no desktop windows on top of the DesktopWallpaperActivities, input events (such as keyboard shortcuts) could result in ANRs because the focused app (the desktop wallpaper) did not have any windows to send the input to. See go/anr-book. With this change, the activity is allowed to be focusable only when it is the top-resumed activity in the system, which is equivalent to it being visible with an empty desk. Flag: com.android.window.flags.enable_multiple_desktops_backend Fix: 402270860 Test: with 2 desks (1 non empty, 1 empty), switch back and forth with keyboard shortcuts a few times and verify there is no ANR. Change-Id: Idc7ac2c374bee72bb54bd7b3a5daca915262af25
Loading
Please register or sign in to comment