##// END OF EJS Templates
generate extra wrappers for virtual slots to allow correct deriving via Python and to avoid recursion...
florianlink -
r175:7bc6abba6c12
parent child
Show More
@@ -489,7 +489,7 public:
489 489 FunctionType functionType() const { return m_function_type; }
490 490 void setFunctionType(FunctionType type) { m_function_type = type; }
491 491
492 bool isVirtual() { return !(isFinal() || isSignal() || isStatic()); }
492 bool isVirtual() const { return !(isFinal() || isSignal() || isStatic()); }
493 493
494 494 QStringList introspectionCompatibleSignatures(const QStringList &resolvedArguments = QStringList()) const;
495 495 QString signature() const;
@@ -272,7 +272,7 void ShellHeaderGenerator::write(QTextStream &s, const AbstractMetaClass *meta_c
272 272 AbstractMetaFunctionList functions = getFunctionsToWrap(meta_class);
273 273
274 274 foreach (const AbstractMetaFunction *function, functions) {
275 if (!function->isSlot()) {
275 if (!function->isSlot() || function->isVirtual()) {
276 276 s << " ";
277 277 writeFunctionSignature(s, function, 0, QString(),
278 278 Option(ConvertReferenceToPtr | FirstArgIsWrappedObject| IncludeDefaultExpression | OriginalName | ShowStatic | UnderscoreSpaces));
@@ -226,8 +226,10 void ShellImplGenerator::write(QTextStream &s, const AbstractMetaClass *meta_cla
226 226 // write member functions
227 227 for (int i = 0; i < functions.size(); ++i) {
228 228 AbstractMetaFunction *fun = functions.at(i);
229 if (fun->isSlot()) continue;
230
229 bool needsWrapping = (!fun->isSlot() || fun->isVirtual());
230 if (!needsWrapping) {
231 continue;
232 }
231 233 writeFunctionSignature(s, fun, meta_class, QString(),
232 234 Option(ConvertReferenceToPtr | FirstArgIsWrappedObject | OriginalName | ShowStatic | UnderscoreSpaces),
233 235 "PythonQtWrapper_");
@@ -489,8 +489,7
489 489 <enum-type name="QSharedMemory::AccessMode"/>
490 490 <enum-type name="QSharedMemory::SharedMemoryError"/>
491 491 <enum-type name="QElapsedTimer::ClockType"/>
492 <enum-type name="QMetaType::Type"/>
493
492
494 493 <enum-type name="QtMsgType">
495 494 <reject-enum-value name="QtSystemMsg"/>
496 495 </enum-type>
General Comments 0
You need to be logged in to leave comments. Login now