Mercurial > projects > qtd
comparison generator/dgenerator.cpp @ 294:bb37b0ed94c9 signals
some more QList
author | eldar |
---|---|
date | Fri, 13 Nov 2009 20:42:51 +0000 |
parents | 8627891e4556 |
children | 463563fc9e17 |
comparison
equal
deleted
inserted
replaced
293:8627891e4556 | 294:bb37b0ed94c9 |
---|---|
1692 else if (!d_class->isQObject()) | 1692 else if (!d_class->isQObject()) |
1693 s << INDENT << "qtd_" << d_class->name() << "_destructor(__nativeId);" << endl; | 1693 s << INDENT << "qtd_" << d_class->name() << "_destructor(__nativeId);" << endl; |
1694 } | 1694 } |
1695 s << INDENT << "}" << endl << endl; | 1695 s << INDENT << "}" << endl << endl; |
1696 } | 1696 } |
1697 | |
1698 if (d_class->typeEntry()->isValue()) | |
1699 { | |
1700 s << INDENT << "public static void __deleteNativeObject(void* ptr) {" << endl | |
1701 << INDENT << " qtd_" << d_class->name() << "_destructor(ptr);" << endl | |
1702 << INDENT << "}" << endl << endl; | |
1703 } | |
1704 | |
1705 if (d_class->typeEntry()->isValue()) | |
1706 { | |
1707 s << INDENT << "public static void __callNativeDestructor(void* ptr) {" << endl | |
1708 << INDENT << " qtd_" << d_class->name() << "_call_destructor(ptr);" << endl | |
1709 << INDENT << "}" << endl << endl; | |
1710 } | |
1697 } | 1711 } |
1698 | 1712 |
1699 void DGenerator::writeFlagsSetter(QTextStream &s, const AbstractMetaClass *d_class) | 1713 void DGenerator::writeFlagsSetter(QTextStream &s, const AbstractMetaClass *d_class) |
1700 { | 1714 { |
1701 if (d_class->isInterface() || d_class->isNamespace()) | 1715 if (d_class->isInterface() || d_class->isNamespace()) |
2533 | 2547 |
2534 // if (d_class->needsConversionFunc) | 2548 // if (d_class->needsConversionFunc) |
2535 writeConversionFunction(s, d_class); | 2549 writeConversionFunction(s, d_class); |
2536 | 2550 |
2537 if (d_class->hasConstructors() && !d_class->isQObject()) | 2551 if (d_class->hasConstructors() && !d_class->isQObject()) |
2538 s << "extern (C) void qtd_" << d_class->name() << "_destructor(void *ptr);" << endl << endl; | 2552 s << "extern (C) void qtd_" << d_class->name() << "_destructor(void *ptr);" << endl |
2553 << "extern (C) void qtd_" << d_class->name() << "_call_destructor(void *ptr);" << endl << endl; | |
2539 | 2554 |
2540 // qtd | 2555 // qtd |
2541 | 2556 |
2542 s << endl << "// C wrappers for signal emitters" << endl; | 2557 s << endl << "// C wrappers for signal emitters" << endl; |
2543 | 2558 |