aboutsummaryrefslogtreecommitdiffstats
path: root/libshiboken
Commit message (Collapse)AuthorAgeFilesLines
* Created Shiboken::warning function.Renato Filho2012-03-082-0/+35
| | | | | | | This is a help function to make able call python warning with formatted strings. Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Added Shiboken buffer interface.Hugo Parente Lima2012-03-084-0/+123
| | | | | | | | | | | | | This interface is just a wrapper to the differents API's provided by Python to deal with memory buffers in various versions of Python, so is recommended to use this API to deal with Python memory buffers instead of the CPython API. If you want to have a Python buffer as argument of any function just change the argument type to "PyBuffer" and the generator will handle it right regarding to type checking. Reviewer: Renato Araújo <renato.filho@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* optimized keepreference function.Renato Filho2012-03-082-17/+27
| | | | | Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Created the function 'removeReference', used to remove a specificRenato Filho2012-03-082-0/+24
| | | | | | | reference from other object. Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Generate code using the new pyside class DestroyListener.Renato Filho2012-03-081-2/+2
| | | | | Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Hugo Parente Lima <hugo.pl@gmail.com>
* Removed unused variables/functions.Hugo Parente Lima2012-03-081-12/+0
| | | | | Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Defined Shiboken.ObjectType tp_setattro to PyObject_GenericSetAttr.Marcelo Lira2012-03-081-1/+1
| | | | | | | | This fixes bug 634. http://bugs.pyside.org/show_bug.cgi?id=634 Reviewed by Hugo Parente <hugo.lima@openbossa.org> Reviewed by Luciano Wolf <luciano.wolf@openbossa.org>
* Fixed keep reference funcion.Renato Filho2012-03-081-6/+8
| | | | | | | | | | The keepReference function does not increase the referece of all objects if the argument is a list. Fixes bug #854. Reviewer: Hugo Parente <hugo.lima@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Improved garbage collector handling of Shiboken types.Marcelo Lira2012-03-081-8/+27
|
* Improved the SbkDbg to avoid throwing exceptions when showing an object.Marcelo Lira2012-03-083-2/+19
| | | | | | | Also added a new Shiboken::Object::isValid signature to help. Reviewed by Hugo Parente <hugo.lima@openbossa.org> Reviewed by Lauro Moura <lauro.neto@openbossa.org>
* Fixed enum repr, print functions.Renato Filho2012-03-081-13/+18
| | | | | | | fixes bug #654. Reviewer: Lauro Moura <lauro.neto@openbossa.org> Hugo Parente <hugo.lima@openbossa.org>
* Remove GCC 4.6 warning on basewrapper.cpp and shibokengenerator.cppHugo Parente Lima2012-03-081-2/+2
| | | | | libshiboken/basewrapper.cpp:212:57: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings] generator/shibokengenerator.cpp:1118:9: warning: variable ‘numArgs’ set but not used [-Wunused-but-set-variable]
* Check for old-style bases before calling tp_newsb-1.0.1Lauro Neto2012-03-081-10/+22
| | | | | | | | | | | | | Instead of creating the type instance and them checking for old-style base classes, check for them in the beginning. The later check was causing the new type object to "leak" and failing an assert in the garbage collector. Reviewer: Luciano Wolf <luciano.wolf@openbossa.org> Reviewer: Hugo Lima <hugo.lima@openbossa.org>
* Don't return a overload method if the object is dieing.Hugo Parente Lima2012-03-081-1/+3
| | | | | Reviewer: Renato Araújo <renato.filho@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Do nothing when trying to make an valid object valid twice.Hugo Parente Lima2012-03-081-1/+1
|
* Updated module reload test.Renato Filho2012-03-081-3/+8
| | | | | | | | | Avoid to load a module twice. Fixes bug #734. Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Fixed parentInfo cleanup.Renato Filho2012-03-081-3/+6
| | | | | | | Fixes bug #735. Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Fix bug 693 - "Heap corruption or double free reported on program exit"Hugo Parente Lima2012-03-083-1/+28
| | | | | Reviewer: Renato Araújo <renato.filho@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Fix bug in TypeResolver::getType function.Hugo Parente Lima2012-03-081-2/+1
| | | | The function was always using a empty string.
* Check for class initialization on function Object.isValid.Renato Filho2012-03-082-16/+45
| | | | | | | Fix bug #696. Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Avoid declar shiboken classes derived from old style objects.Renato Filho2012-03-081-0/+11
| | | | | | | Fixes bug #704. Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* SbkNumber_Check now makes use of PyNumber_Check.Marcelo Lira2012-03-081-1/+3
| | | | | | | Plus some provisions to handle old-style classes. Reviewed by Bruno Araújo <bruno.araujo@openbossa.org> Reviewed by Luciano Wolf <luciano.wolf@openbossa.org>
* Replaced use from QList to QSet in children list.Renato Araujo Oliveira Filho2012-03-082-3/+3
| | | | | | | Patch from farsmo <farsmo@sogetthis.com> Reviewer: Hugo Parente <hugo.lima@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Fixed enum __repr__ function.Renato Araujo Oliveira Filho2012-03-082-9/+33
| | | | | | | fixes bug #617. Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Use SBK_PYTHON_INCLUDE_DIR instead of PYTHON_INCLUDE_DIRS or ↵Hugo Parente Lima2012-03-081-1/+1
| | | | | | | PYTHON_INCLUDE_PATH. Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Lauro Moura <lauro.neto@openbossa.org>
* Fix bug#605 - "Using metaclasses with the PySide classes doesn't work"Hugo Parente Lima2012-03-081-2/+2
|
* Shiboken enums now have a tp_print representation.Marcelo Lira2012-03-081-1/+15
| | | | | | | | | | This fixes the bug #611[1], and an unit test was also added. [1] http://bugs.openbossa.org/show_bug.cgi?id=611 Reviewed by Hugo Parente <hugo.lima@openbossa.org> Reviewed by Luciano Wolf <luciano.wolf@openbossa.org> Reviewed by Renato Araújo <renato.filho@openbossa.org>
* Add Shiboken::Object::isValid(SbkObject* pyObj, bool throwPyError = true) ↵Hugo Parente Lima2012-03-082-1/+16
| | | | | | | | | | function to libshiboken. This function is needed to fix bug#552 when a libpyside code needs to check if a SbkObject is valid without set a Python error when it isn't. Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Renato Araújo <renato.filho@openbossa.org>
* Used c++ pointer during the c++ class attribute get function.Renato Araujo Oliveira Filho2012-03-081-2/+0
| | | | | | | | Now all function get for class attribute return the internal memory of the c++ attribute. Reviewer: Hugo Parente <hugo.lima@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Optimized setParent function.Renato Araujo Oliveira Filho2012-03-081-2/+2
| | | | | | | | | | Replaced use of find in the children list for check on the current child if his has a parent and if the parent is the same. Fixes bug #556 Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Hugo Parente <hugo.lima@openbossa.org>
* Append python name to libshiboken output fileLauro Neto2012-03-081-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | libshiboken is strongly tied to the python it was compiled against. This commit adds the python name to the output file to make this connection explicit. The generator plugin, binary and includes are untouched as they don't depend on python. Also, Instead of installing the cmake info in a single file, ShibokenConfig.cmake will load the correct file (ShibokenConfig-<python name>.cmake) based on the value of PYTHON_BASENAME when cmake is called. The last shiboken installed will be the default as each install will overwrite ShibokenConfig.cmake. To select an specific python, call cmake with -DPYTHON_BASENAME=python2.6, for python2.6 release. Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Lauro Moura <lauro.neto@openbossa.org>
* Initialize ShibokenObject private data.Renato Araujo Oliveira Filho2012-03-081-0/+3
| | | | | | | | | This avoid errors during the functions call which uses the private data. Fixes bug #589 Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Hugo Parente <hugo.lima@openbossa.org>
* Put __file__ on argv only when a empty list is given.Hugo Parente Lima2012-03-081-14/+22
| | | | | Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Renato Araújo <renato.filho@openbossa.org>
* Fix bug#554 - "Inner classes don't work and give us a segfault"Hugo Parente Lima2012-03-081-4/+3
| | | | | Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Renato Araújo <renato.filho@openbossa.org>
* Removed WITH_THREAD ifdefs, it causes a lot of warnings on Windows and was ↵Hugo Parente Lima2012-03-082-3/+0
| | | | always set by our buildsystem.
* Print debug messages to stderr isntead of stdout.Hugo Parente Lima2012-03-081-4/+4
|
* Disable copy of ThreadStateSaver objects.Hugo Parente Lima2012-03-081-0/+3
|
* Fixed comments typo.Renato Araujo Oliveira Filho2012-03-082-3/+3
|
* Fix object destruction process to avoid pass a invalid object during theRenato Araujo Oliveira Filho2012-03-083-12/+19
| | | | | | | | | __del__ function. Fix bug #505 Reviewer: Luciano Wolf <luciano.wolf@openbossa.org> Marcelo Lira <marcelo.lira@openbossa.org>
* Finally fix bug#500 - "If an instance of QPrintDialog is created a deadlock ↵Hugo Parente Lima2012-03-081-1/+5
| | | | | | | happens on shutdown." Reviewer: Luciano Wolf <luciano.wolf@openbossa.org> Marcelo Lira <marcelo.lira@openbossa.org>
* Fix bug#513 - "Hardcoded bool return type for operator overloads"Hugo Parente Lima2012-03-081-2/+3
| | | | | Reviewer: Renato Araújo <renato.filho@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Revert "Fix bug#500 - "If an instance of QPrintDialog is created a deadlock ↵Hugo Parente Lima2012-03-081-4/+1
| | | | | | happens on shutdown."" This reverts commit fb90a3df97b53f3ef4878d8beb719d4aa7b0c6cb.
* Fix bug#500 - "If an instance of QPrintDialog is created a deadlock happens ↵Hugo Parente Lima2012-03-081-2/+5
| | | | | | | on shutdown." Reviewer: Lauro Mora <lauro.neto@openbossa.org> Marcelo Lira <marcelo.lira@openbossa.org>
* Added another overload for makeTuple, this time with just one argument.Hugo Parente Lima2012-03-081-1/+7
| | | | | Reviewer: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
* Add subtype init hook.Hugo Parente Lima2012-03-083-3/+34
| | | | The hook is invoked every time the user creates a sub-type inherited from a Shiboken based type.
* Remove cpp object copier as it was used by anyone and nobody missed him.Hugo Parente Lima2012-03-083-20/+0
| | | | | Reviewer: Luciano Wolf <luciano.wolf@openbossa.org> Lauro Moura <lauro.neto@openbossa.org>
* Removed useless stuff from TypeResolver.Hugo Parente Lima2012-03-082-34/+17
|
* Remove SbkTypeInfo and CppObjectCopier structs, they aren't needed after the ↵Hugo Parente Lima2012-03-083-49/+9
| | | | fix on qt_metacall.
* Remove objectDeleter function and use the well known ↵Hugo Parente Lima2012-03-081-7/+1
| | | | Shiboken::callCppDestructor.
* Remove const version of Converters to avoid hidding generator bugs.Hugo Parente Lima2012-03-081-12/+0
|