Massive responsivity gains have been achieved here. Rescaling performance doesn't seem to be particularly affected.
Also, slightly reformat the source code according to clang-format.