Remove a redundant repaint when a layer becomes composited