performance boost / fix flickering in #384