android - Out of memory problem

后端 未结 1 1140
萌比男神i
萌比男神i 2021-01-24 05:01

In my app, i am downloading images from the web. For this, first time i am downloading images from the web and these images are stored in the sdcard. Next time, i am checking th

1条回答
  •  暖寄归人
    2021-01-24 05:23

    I think you are not using the ViewHolder model for listview. In such case you are supposed the get such error as all the list items will be available in the memory whether it is visible or not.By using ViewHolder memory is assigned to only those items which are visible and are currently on the screen. ViewHolder patternincreses the performance by 150% For video tutorial about ViewHolder check out this .If you are already implemented then it is the case of memory leak you can refer this

    0 讨论(0)
提交回复
热议问题