Fix for shaders and VBOs breaking on game resume

This is ex's fix from http://getmoai.com/forums/post7439.html#p7439

People are still running into this big issue. The fix is working well for me since about a year, I can only assume it's good.