Skip to content

Variablize lowMemoryThreshold to keep tabs open

Marius Gripsgard requested to merge xenial_-_morph-low-memory-threshold into xenial

Created by: UniversalSuperBox

I've noticed that in morph-browser, the out-of-memory tab loader was a bit excessive. For some reason, it would unload tabs even when the system had lots of memory available -- 1GB or more! Turns out, the freeMemRatio < 0.2 test always returned true, no matter what. I'm not sure why this happens, probably a QML+JS quirk. By moving the low memory threshold into a new variable, the test returns correctly based on the amount of available memory in the system. No more unloading of every tab!

Fixes ubports/morph-browser#99

Merge request reports