Use one render loop per QQuickWindow

This is a backport of https://codereview.qt-project.org/#change,68499,patchset=6
with a few bugfixes for the animation advance.  The original commit
message was:

    From 30e2c054bad56dbc6286458c44eb0aaba81821d5 Mon Sep 17 00:00:00 2001
    From: Gunnar Sletta <gunnar.sletta@digia.com>
    Date: Thu, 17 Oct 2013 14:53:33 +0200
    Subject: [PATCH] Use one render loop per QQuickWindow

    See the task for the full reasoning behind this patch.

    The threaded renderloop has been refactored to have one window per
    thread. This is mostly a simplification of the current code path where
    for loops over multiple windows are turned into if (window).

    The QSGContext has been split into two classes, QSGRenderContext
    for which there is one per OpenGLContext.

    The rest of the patch is name changes and a couple of cleanups
    in the hopes of simplifying this change.

    Task-number: QTBUG-33993

    Change-Id: I31c81f9694d7da7474a72333169be38de62613c4
Share precompiled materials between all window contexts