summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Lillqvist <tml@collabora.com>2015-09-04 16:51:26 +0300
committerTor Lillqvist <tml@collabora.com>2015-09-04 17:35:18 +0300
commit20f1ba114c56b13659bb3ccd3dfdbcfc15a3d10e (patch)
tree30beeddad03dbc9cc96afabe1bed10878b78d5ec
parent0590fe942a7047b2cca480657a93f24144ea9f3c (diff)
Add explanation and enforce non-instantiability
Change-Id: I3ea699dcda21b695a486c86d7f7b7a8abc2a8fbe
-rw-r--r--include/vcl/opengl/OpenGLHelper.hxx6
-rw-r--r--include/vcl/opengl/OpenGLWrapper.hxx6
2 files changed, 8 insertions, 4 deletions
diff --git a/include/vcl/opengl/OpenGLHelper.hxx b/include/vcl/opengl/OpenGLHelper.hxx
index 646a2d39254e..9f725e694605 100644
--- a/include/vcl/opengl/OpenGLHelper.hxx
+++ b/include/vcl/opengl/OpenGLHelper.hxx
@@ -34,9 +34,11 @@
} \
} while (false)
-class VCL_DLLPUBLIC OpenGLHelper
+// All member functions static and VCL_DLLPUBLIC. Basically a glorified namespace.
+struct VCL_DLLPUBLIC OpenGLHelper
{
-public:
+ OpenGLHelper() SAL_DELETED_FUNCTION; // Should not be instantiated
+
static GLint LoadShaders(const OUString& rVertexShaderName, const OUString& rFragmentShaderName, const OString& preamble = "" );
/**
diff --git a/include/vcl/opengl/OpenGLWrapper.hxx b/include/vcl/opengl/OpenGLWrapper.hxx
index c2f44c0c6b6b..4d3a9e9ab57b 100644
--- a/include/vcl/opengl/OpenGLWrapper.hxx
+++ b/include/vcl/opengl/OpenGLWrapper.hxx
@@ -14,9 +14,11 @@
#include <vcl/dllapi.h>
-class VCL_DLLPUBLIC OpenGLWrapper
+// All member functions static and VCL_DLLPUBLIC. Basically a glorified namespace.
+struct VCL_DLLPUBLIC OpenGLWrapper
{
-public:
+ OpenGLWrapper() SAL_DELETED_FUNCTION; // Should not be instantiated
+
/**
* Returns true if VCL has OpenGL rendering enabled
*/