Don't add padding for Smartspace (actual and preview).
As demonstrated in ag/27287153, the actual Smartspace doesn't have any top padding, but the qsb_preview does. - Turns out, ShortcutAndWidgetContainer sets padding on its children. - The actual Smartspace has padding removed by overriding the `setPadding` method in SmartspaceViewContainer. (See ag/13562740.) This CL updates ShortcutAndWidgetContainer.java to not add padding for either the actual or the preview Smartspace. It makes use of `R.id.search_container_workspace` to identify the applicable cases, rather than checking class types or names. This way, there is no Pixel-specific logic added. Before: https://hsv.googleplex.com/6335187293044736?node=18 After: https://hsv.googleplex.com/5450651931770880?node=18 Actual Smartspace, for reference: - https://hsv.googleplex.com/6083634648842240?node=14 Note the `isChildQsb` also returns true for the QsbContainerView. Since that class already has the same `setPadding` override: - https://cs.android.com/android/platform/superproject/main/+/main:packages/apps/Launcher3/src/com/android/launcher3/qsb/QsbContainerView.java;l=147-150;drc=e58aaf1802e43f73bbd417658c1c4c42e2fe28fd This CL does't affect its padding. Flag: EXEMPT bugfix Bug: 338601960 Test: Go to Wallpaper & style preview for Home screen. Change-Id: I5b6f7752cfee556b815c83e9df85f9e74f23ab4b
Loading
Please register or sign in to comment