Android memory leak: InputMethodManager, Bitmap

This is strange, I can get rid of my own memory leaks, but in this case I can not do the same.

It is shown below that the heap contains a bitmap (for example, 2.5 MB) that is associated with the current Activity (mDecor indicates the current activity).

I tried removing instances of InputMethodManager throughout the application, with no effect

I tried to set the default keyboard state (if the bitmap is some kind of sprint available for the system keyboard), still no effect

android:windowSoftInputMode="stateHidden" 

Nothing helped, what can I do about it? Please note that the solution is not specific to the Android API (I tested API 8 and 14/15/16, and they all have the same problem).

A bunch


Probably a mistake, can anyone confirm this?

+6
source share

Source: https://habr.com/ru/post/926705/


All Articles