| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If a GValueArray is created from a list of GValues, it should not wrap
these GValues in a second layer of GValues before appending to the
array. The end result should be a GValueArray of GValues, not a
GValueArray of GValues holding another GValue (unless the user
explicitly creates such a value).
With this patch the behavior is now consistent when creating a
GValueArray and appending GValues directly, and creating a GValueArray
within a GValue based on a list of GValues.
For instance, to create a GValueArray of G_TYPE_UINT the user must
create GValues manually and create a GValueArray from these. The result
should be a GValueArray of GValues that hold G_TYPE_UINT, not a
GValueArray that contain GValues that hold a GValue that holds
G_TYPE_UINT.
See !66
|
| |
|
| |
|
|
|
|
|
| |
This allows us to get rid of the deprecated Py_UNICODE API and the
deprecation warnings with Python 3.7.
|
|
|
|
|
|
|
|
|
|
| |
In some cases changing the type used was enough, in some others I just force
casted things as too many changes would be required and overflow unlikely
(for array marshalling the cache uses gssize while the marshalling code uses
garray and thus guint)
My hope is that having this enabled will improve things gradually with
future cleanups.
|
|
|
|
| |
There is no pyglib anymore
|
| |
|
|
|
|
|
|
| |
Use PyGILState_Ensure/PyGILState_Release instead.
https://bugzilla.gnome.org/show_bug.cgi?id=699440
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=772949
|
|
|
|
|
|
|
|
| |
Wrap calls to GValueArray related calls with G_GNUC_BEGIN/END_IGNORE_DEPRECATIONS.
Although GValueArray is deprecated, we still need to support the marshaling of
them in PyGObject. The deprecations add noise to the build processes in which
new warnings could be lost. Essentially losing the element of surprise a new
warning should have on maintainers.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Replace the importing of gi._gobject._gobject with gi.repository.GObject
in tests/testhelpermodule.c
The testhelper module was only importing the static bindings
(gi._gobject._gobject) and not the overrides (gi.repository.GObject).
This was causing some tests to fail when test_thread was the first
test to run in the suite due to it registering new types based on
PyGObject_Type.
https://bugzilla.gnome.org/show_bug.cgi?id=703647
|
|
|
|
|
| |
Remove dynamic retrieval of PyGObject_Type as it is available
in pygobject.h since commit 2656bc47 (causing this compile warning)
|
|
|
|
|
|
|
|
|
| |
In pyg_value_from_pyobject(), recognize both the real GI GObject.ParamSpec type
as well as the statically wrapped _gobject.GParamSpec type.
This fixes marshalling GObject.ParamSpec signal/vfunc arguments.
https://bugzilla.gnome.org/show_bug.cgi?id=683099
|
|
|
|
|
|
| |
In _wrap_test_gerror_exception(), do not unref the method arguments. This
causes a crash when being run with the stricter refcounting/memory checks with
debug-enabled Python builds.
|
|
|
|
|
|
|
|
|
|
|
| |
Shift pygi module mechanics so the introspection generated 'Object'
class becomes derived from the static GObject class. Add initial
GObject.Object override which sets all static methods back essentially
leapfrogging the introspection methods. This sets the stage for having
the ability to remove static methods piecemeal in favor of
introspection/python in future commits.
https://bugzilla.gnome.org/show_bug.cgi?id=672727
|
|
|
|
|
|
| |
We already require a new enough glib version as we dropped g_thread_init() in
the main code a long time ago. But for formality's sake, bump glib requirement
to >= 2.32.
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=684700
|
|
|
|
|
|
|
|
| |
These cover various types, (u)int(64) and string.
Keep the test case for implicit int64 GValues disabled, as this currently does
not work and it is not clear whether it should:
https://bugzilla.gnome.org/show_bug.cgi?id=683775
|
|
|
|
|
|
| |
Another attempt to reproduce the reported error in
https://bugzilla.gnome.org/show_bug.cgi?id=683596
but this works already.
|
| |
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=683265
|
|
|
|
|
|
| |
This fixes a lot of -Wmissing-prototype warnings.
Also remove _pygi_marshal_cleanup_closure_unref() which is not used anywhere.
|
|
|
|
|
|
|
|
| |
Bindings don't write their own constructors anymore, and the old style
has been deprecated for ages, so let's just drop them now and make
pygobject simpler.
https://bugzilla.gnome.org/show_bug.cgi?id=657413
|
|
|
|
|
|
|
| |
Sink functions were meant to deal with floating references in a custom
way. They are not useful anymore with the dynamic bindings.
https://bugzilla.gnome.org/show_bug.cgi?id=642233
|
|
|
|
|
|
|
|
|
|
|
| |
* for PyGObject 3 we want to discourage the use of legacy
interfaces
* Using interfaces like from gi.repository import GObject makes
sure that the internal _gobject module is loaded and not
PyGObject 2's gobject module which would cause the application
to not work correctly
https://bugzilla.gnome.org/show_bug.cgi?id=642048
|
| |
|
|
|
|
|
|
|
|
| |
References were leaked for GInitiallyUnowned objects which got their
wrappers created several times, because someone else holds reference
on it and it got out of python scope at some point.
https://bugzilla.gnome.org/show_bug.cgi?id=639949
|
|
|
|
|
|
|
|
| |
When the object is constructed, its refcount is 2 because the library
refs it once. It should remain around until we ask the library to
release its reference.
https://bugzilla.gnome.org/show_bug.cgi?id=639949
|
|
|
|
|
|
|
|
|
| |
* include the compat header
* fix up PyInts to be PYGLIB_Long
* Use PYGLIB_DEFINE_TYPE macros to define module objects
* Use PYGLIB_MODULE_START/END to define modules
https://bugzilla.gnome.org/show_bug.cgi?id=615872
|
|
|
|
|
|
| |
This avoids inequality due to small precisions difference.
https://bugzilla.gnome.org/show_bug.cgi?id=625326
|
|
|
|
|
|
|
|
|
|
|
| |
sinkfunc defined.
* tests/*: Add ref counting tests for floating objects
* gobject/gobjectmodule.c, gobject/pygobject.c: Fall back to g_object_ref_sink
or g_object_ref if there isn't a sinkfunc defined. Make sure that
pygobject_sink gets called only once per GObject instance.
https://bugzilla.gnome.org/show_bug.cgi?id=583909
|
|
|
|
|
|
| |
(marshal/unmarshal for GValue-wrapped GValue)
svn path=/trunk/; revision=680
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
2007-07-02 Sebastian Granjoux <seb.sfo@free.fr>
reviewed by: Johan Dahlin
* gobject/gobjectmodule.c: (pyg_gerror_exception_check):
* tests/test_gtype.py:
* tests/testhelpermodule.c: (_wrap_test_gerror_exception):
Fix a bug in pyg_error_exception_check, add a test, Fixes #449879
svn path=/trunk/; revision=678
|
|
|
|
| |
svn path=/trunk/; revision=660
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
2007-04-29 Johan Dahlin <johan@gnome.org>
* gobject/pygtype.c: (pyg_value_array_from_pyobject):
* tests/test_gtype.py:
* tests/testhelpermodule.c: (_wrap_test_value_array):
Treat None in a GValueArray as pointer/NULL, patch by
Ed Catmur, fixes #352209.
svn path=/trunk/; revision=656
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
2007-04-29 Johan Dahlin <jdahlin@async.com.br>
* README:
* configure.ac:
* gobject/Makefile.am:
* gobject/ffi-marshaller.c: (g_value_to_ffi_type),
(g_value_from_ffi_type), (g_cclosure_marshal_generic_ffi):
* gobject/ffi-marshaller.h:
* gobject/gobjectmodule.c: (create_signal), (init_gobject):
* pygobject-2.0.pc.in:
* tests/test_signal.py:
* tests/testhelpermodule.c: (test1_callback),
(test1_callback_swapped), (test2_callback), (test3_callback),
(test4_callback), (test_float_callback), (test_double_callback),
(test_string_callback), (test_object_callback), (connectcallbacks),
(_wrap_connectcallbacks), (inittesthelper):
Add a generic CClosure marshaller based on ffi.
This makes it possible to connect to signals on PyGObjects from C.
libffi is now an optional dependency
Fixes #353816 (Edward Hervey)
svn path=/trunk/; revision=651
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
* tests/test_subtype.py:
* tests/testhelpermodule.c: (test_type_get_type),
(_wrap_get_unknown), (_wrap_test_g_object_new), (inittesthelper):
Clean up tests, we don't need a C binding to access tp_basicsize,
clean up the C tests, quite a bit aswell.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
* .cvsignore:
* Makefile.am:
* configure.in:
* gtk/Makefile.am:
* pygtk-2.0.pc.in:
* setup.py:
* tests/common.py:
* tests/testhelpermodule.c: Make the build of
atk, pango and gtk conditional. Fixes bug #74144.
|
| |
|
|
|
|
|
|
| |
This is make threading usable for both users of the threading
module and users that requires interaction with threads from
other extension modules.
|
|
|
|
|
|
| |
* tests/testhelpermodule.c:
* tests/test_thread.py: Add thread stuff, that emits stuff from
another thread and does some enum magic.
|
|
* tests/testhelper.c: Small c module to help testing
* tests/test_subtype.py: tests for this, use testhelper here
aswell
|