QOpenGLEngineSharedShaders: disable copy/moves

The class manages resources via raw pointers, and as such it's certainly
not copiable. Explicitly disallow such copies. (It might be made
movable, but no-one needs to move it, so I'm disabling moves as well.)

This fixes warnings in QMetaType, which would otherwise pick up
copy/moves as the class is also marked as a Q_GADGET.

Change-Id: I983765b35304c8ab9ad42d31bcb729cfc9bfa2ac
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
This commit is contained in:
Giuseppe D'Angelo 2025-01-08 16:49:26 +01:00
parent 20b07bfa30
commit 517dcbf42e

View File

@ -221,6 +221,7 @@ class QOpenGLEngineShaderProg;
class Q_OPENGL_EXPORT QOpenGLEngineSharedShaders
{
Q_GADGET
Q_DISABLE_COPY_MOVE(QOpenGLEngineSharedShaders)
public:
enum SnippetName {