简体   繁体   中英

launcher icon resizing

I am trying to make my MediaShortcut app ( source ) create launcher icons whose size depends on the density of the screen. The image is retreived from android.provider.MediaStore.Images.Thumbnails .getThumbnail(getContentResolver(), "imageid"), android.provider.MediaStore.Images.Thumbnails.MICRO_KIND, null)

So first i get the screen's density using http://developer.android.com/reference/android/util/DisplayMetrics.html and then resize the image according to this table http://developer.android.com/guide/practices/ui_guidelines/icon_design.html

This seems to work fine on most of my devices but on my Asus slider (and a friends transformer) the icon is significantly smaller than the other icons on the home screen. on other devices i have noticed the icon is too big and only part of it is shown.

Does anybody have any idea why this could be? Thanks!

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