aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside2/PySide2/glue/qtopengl.cpp
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2019-06-24 18:46:26 +0200
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2019-06-24 18:46:26 +0200
commit0225a252f756359d1fca5474998a2a11cdbda46d (patch)
tree1475ce065f1d71d9cd334e608062876f81af6a95 /sources/pyside2/PySide2/glue/qtopengl.cpp
parent2bc0decca59d867dbf893e34cf9f2ff9745ab603 (diff)
parent6a22e8cb35cfccbacd65b56e193bf2ae83f205ea (diff)
Merge remote-tracking branch 'origin/5.12' into 5.13
Diffstat (limited to 'sources/pyside2/PySide2/glue/qtopengl.cpp')
-rw-r--r--sources/pyside2/PySide2/glue/qtopengl.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/sources/pyside2/PySide2/glue/qtopengl.cpp b/sources/pyside2/PySide2/glue/qtopengl.cpp
index 6c106522c..25b6ee096 100644
--- a/sources/pyside2/PySide2/glue/qtopengl.cpp
+++ b/sources/pyside2/PySide2/glue/qtopengl.cpp
@@ -39,7 +39,7 @@
// @snippet qglbuffer-allocate
int size = (%2 < 0) ? %1.size() : %2;
-%CPPSELF.allocate((const void*) %1.data(), size);
+%CPPSELF.allocate(static_cast<const void *>(%1.data()), size);
// @snippet qglbuffer-allocate
// @snippet qglbuffer-read
@@ -47,7 +47,7 @@ char *data = new char[%3];
bool result = %CPPSELF.read(%1, data, %3);
QByteArray ret;
if (result)
- ret.append((const char*)data, %3);
+ ret.append(data, %3);
%PYARG_0 = PyTuple_New(2);
PyTuple_SET_ITEM(%PYARG_0, 0, %CONVERTTOPYTHON[bool](result));
PyTuple_SET_ITEM(%PYARG_0, 1, %CONVERTTOPYTHON[QByteArray](ret));
@@ -56,12 +56,12 @@ delete[] data;
// @snippet qglbuffer-write
int size = (%3 < 0) ? %2.size() : %3;
-%CPPSELF.write(%1, (const void*) %2.data(), size);
+%CPPSELF.write(%1, static_cast<const void *>(%2.data()), size);
// @snippet qglbuffer-write
// @snippet qglbuffer-map
Py_ssize_t dataSize = %CPPSELF.size();
-void* data = %CPPSELF.map(%1);
+void *data = %CPPSELF.map(%1);
if (!data) {
Py_INCREF(Py_None);