Files
lawnchair/res/layout/live_preview_widget_cell.xml
Steven Ng 0be3a615d9 Render preview layout in full widgets sheet and bottom widgets sheet
Video: https://drive.google.com/file/d/1gRE0axaq6tm3R_gjSon0RR5lC8HCmwee/view?usp=sharing

Test: Install a sample app which provides a preview layout.
      Go to full widgets sheet to observe widget previews are correctly
      displayed for bitmap previews, layout previews and placeholder
      previews. Repeat the same for bottom widgets picker.
      Pin a widget from a sample app which provide a custom RemoteViews
      preview, observe the custom RemoteViews is correctly rendered.

Bug: 179797520
Change-Id: I2ccd1f77b54a2430d842ee25349fa6e54b9159dc
2021-02-16 19:34:03 +00:00

28 lines
1.1 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2021 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<com.android.launcher3.dragndrop.LivePreviewWidgetCell
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical"
android:focusable="true"
android:background="?android:attr/colorPrimaryDark"
android:gravity="center_horizontal">
<include layout="@layout/widget_cell_content" />
</com.android.launcher3.dragndrop.LivePreviewWidgetCell>