widget: update preview

Update the widget preview to reflect the UI tweaks made.
This commit is contained in:
OxygenCobalt 2021-09-12 17:33:48 -06:00
parent 08169b6167
commit bc6bba56fc
No known key found for this signature in database
GPG key ID: 37DBE3621FE9AD47
4 changed files with 2 additions and 7 deletions

View file

@ -37,8 +37,7 @@ abstract class LifecycleDialog : AppCompatDialogFragment() {
override fun onCreateDialog(savedInstanceState: Bundle?): Dialog {
val builder = MaterialAlertDialogBuilder(requireActivity(), theme)
// Setting the background in XML will also apply it to the tooltip for some insane reason
// so we have to do it programmatically instead.
// Apply a custom background to avoid rounded corners.
builder.background = R.attr.colorSurface.resolveAttr(requireContext()).toDrawable()
onConfigDialog(builder)

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 17 KiB

View file

@ -37,6 +37,4 @@
<dimen name="elevation_large">8dp</dimen>
<dimen name="offset_thumb">4dp</dimen>
<dimen name="abc_dialog_list_padding_top_no_title">0dp</dimen>
</resources>

View file

@ -72,7 +72,5 @@
<item name="android:background">?attr/colorSurface</item>
</style>
<style name="Widget.Component.AppWidget.Panel" parent="Widget.Component.AppWidget.Panel.Base">
<item name="android:elevation">@dimen/elevation_normal</item>
</style>
<style name="Widget.Component.AppWidget.Panel" parent="Widget.Component.AppWidget.Panel.Base" />
</resources>