Refactoring

This commit is contained in:
M66B
2019-05-22 15:41:54 +02:00
parent 7a23d0bffd
commit 1f14c58ae8
5 changed files with 17 additions and 16 deletions

View File

@@ -621,15 +621,4 @@ public class Helper {
bundle.writeToParcel(p, 0);
return p.dataSize();
}
static long getFreeMem() {
Runtime rt = Runtime.getRuntime();
long used = (rt.totalMemory() - rt.freeMemory());
long max = rt.maxMemory();
return (max - used);
}
static int getFreeMemMb() {
return (int) (getFreeMem() / 1024L / 1024L);
}
}