Change screenmodes at runtime

Implementation for the openfl-native pull request of the same name.