简体   繁体   中英

android create widget menu icon

when browsing the widget menu on Android 3.0+ some widgets have simple icons and others have more of a screenshot of what the widget actually looks like.

How would I portray the latter in my own widget?

You can use the widget preview app on your Android emulator to take a screenshot of your widget and send it to yourself via email: 在此处输入图片说明

Then inside your appwidget-provider XML you can specify this:

<appwidget-provider xmlns:android="http://schemas.android.com/apk/res/android"
    [...]
    android:previewImage="@drawable/preview"
    />

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM