Make case statements work with latest Android SDK