Fix Shader Reload After Resuming the Game

This is a long-standing bug that has been reported many times (e.g. in #788). I got it reproduced on Android and got it resolved using this minimal fix (as opposed to the one proposed in #788).