Copy from https://github.com/georgeee/ITMO_android_whirl