summaryrefslogtreecommitdiffstats
path: root/generator/cppgenerator.cpp
diff options
context:
space:
mode:
authorHugo Parente Lima <hugo.pl@gmail.com>2010-11-09 17:38:21 -0200
committerHugo Parente Lima <hugo.pl@gmail.com>2010-11-10 15:36:28 -0200
commitf1ad9bf233f1fe88e72d350caaffc5164ce20511 (patch)
tree0ac596c230dceeaa61fd71a0a1712f060e16834d /generator/cppgenerator.cpp
parent6280785f538dc033e85826bf2525848c75327ea8 (diff)
downloadshiboken-f1ad9bf233f1fe88e72d350caaffc5164ce20511.tar.gz
shiboken-f1ad9bf233f1fe88e72d350caaffc5164ce20511.tar.xz
shiboken-f1ad9bf233f1fe88e72d350caaffc5164ce20511.zip
Replaced SbkBaseWrapper_setOwnership by getOwnership and releaseOwnership (both inside Shiboken:Wrapper namespace)
Diffstat (limited to 'generator/cppgenerator.cpp')
-rw-r--r--generator/cppgenerator.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/generator/cppgenerator.cpp b/generator/cppgenerator.cpp
index fe623953..2ab4bfdc 100644
--- a/generator/cppgenerator.cpp
+++ b/generator/cppgenerator.cpp
@@ -2121,10 +2121,10 @@ void CppGenerator::writeMethodCall(QTextStream& s, const AbstractMetaFunction* f
s << INDENT;
if (arg_mod.ownerships[TypeSystem::TargetLangCode] == TypeSystem::TargetLangOwnership) {
- s << "SbkBaseWrapper_setOwnership(" << pyArgName << ", true);";
+ s << "Shiboken::Wrapper::getOwnership(" << pyArgName << ");";
} else if (wrappedClass->hasVirtualDestructor()) {
if (arg_mod.index == 0) {
- s << "SbkBaseWrapper_setOwnership(" PYTHON_RETURN_VAR ", 0);";
+ s << "Shiboken::Wrapper::releaseOwnership(" PYTHON_RETURN_VAR ");";
} else {
s << "BindingManager::instance().transferOwnershipToCpp(" << pyArgName << ");";
}
@@ -2666,7 +2666,7 @@ void CppGenerator::writeCopyFunction(QTextStream& s, const AbstractMetaClass *me
s << INDENT << PYTHON_RETURN_VAR " = Shiboken::Converter<" << metaClass->qualifiedCppName();
s << "*>::toPython(copy);" << endl;
- s << INDENT << "SbkBaseWrapper_setOwnership(" PYTHON_RETURN_VAR ", true);" << endl;
+ s << INDENT << "Shiboken::Wrapper::getOwnership(" PYTHON_RETURN_VAR ");" << endl;
s << endl;