General performance improvements

Improved performance of Android demo project. Minor fixes