No global $app uses anymore

* obsolete code removal
* lowlevelError() became LowlevelException()
* no more `global $app` references in methods
This bit is still needed, i'm afraid. Records with "filelist" or "imagelist" made before 1.5 still have it stored serialized.