Fix QT_NO_OPENGL build after 66c5bb0e
QOpenGLContext is an incomplete type for QT_NO_OPENGL builds so, whilst references and pointers are fine, they cannot be dereferenced (implict in the case of references), nor can automatic storage variables be declared.