Fixed flicker problem