-1

我已经将我的第一个 android 应用程序上传到市场,它包含一些声音、一些图像和一些画廊项目。这使得项目大小接近 9.5MB。我分别对声音和图像使用了 mp3 和 png 格式。我通过右键单击项目-> Android 工具-> 导出签名的应用程序来导出项目.. 并且该过程继续进行。现在,当用户下载应用程序时,安装后会扩展,大小超过 24MB。它也有一些错误,可以在下图中看到:

在此处输入图像描述

有什么问题??提前致谢..

4

1 回答 1

1

Your application can't be moved to the SD-card, because you have to explicitly enable that first. To do so, use the android:installLocation-attribute in the <manifest>-tag of your Android Manifest. Also see: How to enable app being moved to sdcard (and support android < 2.2 still)?


For the "expanding after installation"-part: Have you checked the size if your (uncompressed) application on your dev-machine? You can extract the build .apk-file with 7zip (for example) to see what size it becomes.

To make Android optimize certain pieces of binary assets (for example your PNG-files), put them in the /res/XXX-subfolders rather then the older /assets-folder (because Android will optimize those):

Bitmap files may be automatically optimized with lossless image compression by the aapt tool during the build process. [...]

Source


As the last point, your applications "Clear Data"-button is not activated, because you don't seem to have any application-data.

The "application data" does not include any binary resources your application brings with it. It does simply remove any data which is stored on the Internal Storage for your application.

于 2012-07-01T21:13:48.497 回答