summaryrefslogtreecommitdiffstats
path: root/src/tools/qucom.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <[email protected]>2012-12-06 16:47:27 -0600
committerTimothy Pearson <[email protected]>2012-12-06 16:47:27 -0600
commit78125ea2f051107b84fdc0354acdedb7885308ee (patch)
treec162d7f55467f81a01e2e669ce297acce06b3947 /src/tools/qucom.cpp
parent7aa5ac7f0e76c5b87e4ca837b75b3edd522a3372 (diff)
downloadqt3-78125ea2f051107b84fdc0354acdedb7885308ee.tar.gz
qt3-78125ea2f051107b84fdc0354acdedb7885308ee.zip
Add real threading support, including per-thread event loops, to QThread
Diffstat (limited to 'src/tools/qucom.cpp')
-rw-r--r--src/tools/qucom.cpp24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/tools/qucom.cpp b/src/tools/qucom.cpp
index f210318..c48e166 100644
--- a/src/tools/qucom.cpp
+++ b/src/tools/qucom.cpp
@@ -39,6 +39,9 @@
**********************************************************************/
#include "qucom_p.h"
+#include "qucomextra_p.h"
+
+#include "qvariant.h"
// Standard types
@@ -545,3 +548,24 @@ void QUType_QString::clear( QUObject *o )
delete (QString*)o->payload.ptr;
o->payload.ptr = 0;
}
+
+QUObject* QUObject::deepCopy(QUObject* newLocation) {
+ QUObject* ret;
+ if (newLocation) {
+ ret = new(newLocation) QUObject(*this);
+ }
+ else {
+ ret = new QUObject(*this);
+ }
+ // Any type that has a clear() method must be copied here!
+ if (*(type->uuid()) == TID_QUType_charstar) {
+ static_QUType_charstar.set( ret, (const char *)static_QUType_charstar.get(this), true );
+ }
+ if (*(type->uuid()) == TID_QUType_QString) {
+ static_QUType_QString.set( ret, (QString)static_QUType_QString.get(this) );
+ }
+ if (*(type->uuid()) == TID_QUType_QVariant) {
+ static_QUType_QVariant.set( ret, (QVariant)static_QUType_QVariant.get(this) );
+ }
+ return ret;
+}