From b1b09172aee658e085423ddf6abfea291a072c74 Mon Sep 17 00:00:00 2001 From: Rhys Weatherley Date: Thu, 4 Jun 2009 11:41:44 +1000 Subject: Code cleanup - use constructor initializers in shader classes. Task-number: QT-80 Reviewed-by: Ian Walters --- src/opengl/qglshaderprogram.cpp | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/opengl/qglshaderprogram.cpp b/src/opengl/qglshaderprogram.cpp index 67fd9d0..37732dd 100644 --- a/src/opengl/qglshaderprogram.cpp +++ b/src/opengl/qglshaderprogram.cpp @@ -245,14 +245,14 @@ class QGLShaderPrivate { public: QGLShaderPrivate(QGLShader::ShaderType type, const QGLContext *ctx) + : context(ctx) + , shader(0) + , shaderType(type) + , compiled(false) + , isPartial(type == QGLShader::PartialVertexShader || + type == QGLShader::PartialFragmentShader) + , hasPartialSource(false) { - context = ctx; - shader = 0; - shaderType = type; - compiled = false; - isPartial = (type == QGLShader::PartialVertexShader || - type == QGLShader::PartialFragmentShader); - hasPartialSource = false; } const QGLContext *context; @@ -727,14 +727,14 @@ class QGLShaderProgramPrivate { public: QGLShaderProgramPrivate(const QGLContext *ctx) + : context(ctx) + , program(0) + , linked(false) + , inited(false) + , hasPartialShaders(false) + , vertexShader(0) + , fragmentShader(0) { - context = ctx; - program = 0; - linked = false; - inited = false; - hasPartialShaders = false; - vertexShader = 0; - fragmentShader = 0; } ~QGLShaderProgramPrivate() { -- cgit v0.12