wined3d: Try harder to keep the current context.