summaryrefslogtreecommitdiffstats
path: root/gobject
Commit message (Collapse)AuthorAgeFilesLines
...
* Issue warning if 'obj' is a PyGEnum of wrong type, i.e. not matchingPaul Pogonyshev2008-07-261-0/+6
| | | | | | | | | | 2008-07-27 Paul Pogonyshev <pogonyshev@gmx.net> * gobject/pygtype.c (pyg_enum_get_value): Issue warning if 'obj' is a PyGEnum of wrong type, i.e. not matching 'enum_type' (bug #503771). svn path=/trunk/; revision=877
* reviewed by: <delete if not using a buddy>Johan Dahlin2008-07-266-129/+177
| | | | | | | | | | | | | | | | | | | | | | | | 2008-07-26 Johan Dahlin <johan@gnome.org> reviewed by: <delete if not using a buddy> * glib/pyglib-python-compat.h: * glib/pyglib.h: Make a few macros public * gobject/Makefile.am: * gobject/gobjectmodule.c (init_gobject): * gobject/pyginterface.c (pyg_interface_init), (pyg_interface_free), (pyg_register_interface), (pyg_register_interface_info), (pyg_lookup_interface_info), (pygobject_interface_register_types): * gobject/pyginterface.h: * gobject/pygobject-private.h: * gobject/pygobject.c: Move GInterface wrapper into its own file svn path=/trunk/; revision=875
* Build fix, remove extra \Johan Dahlin2008-07-261-1/+1
| | | | | | | | | | 2008-07-26 Johan Dahlin <johan@gnome.org> * gobject/Makefile.am (_gobject_la_SOURCES): Build fix, remove extra \ svn path=/trunk/; revision=865
* Move option over from gobject to glib.Johan Dahlin2008-07-267-1095/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2008-07-26 Johan Dahlin <johan@gnome.org> * glib/Makefile.am: * glib/glibmodule.c (pyglib_register_constants), (init_glib): * glib/option.py: * glib/pyglib.c (pyglib_init), (pyglib_option_group_transfer_group), (pyglib_option_group_new), (pyglib_option_context_new): * glib/pyglib.h: * glib/pygoptioncontext.c (pyg_option_context_parse), (pyg_option_context_set_main_group), (pyg_option_context_add_group), (pyglib_option_context_register_types): * glib/pygoptioncontext.h: * glib/pygoptiongroup.c (arg_func), (pyglib_option_group_register_types): * glib/pygoptiongroup.h: * gobject/Makefile.am: * gobject/__init__.py: * gobject/gobjectmodule.c (init_gobject): * gobject/option.py: * gobject/pygobject-private.h: * gobject/pygoptioncontext.c: * gobject/pygoptiongroup.c: Move option over from gobject to glib. svn path=/trunk/; revision=860
* Move over glib constants to gobjectJohan Dahlin2008-07-262-61/+34
| | | | | | | | | | | | | | | | | | 2008-07-26 Johan Dahlin <johan@gnome.org> * glib/glibmodule.c (pyglib_register_constants), (init_glib): * gobject/__init__.py: * gobject/gobjectmodule.c (init_gobject): Move over glib constants to gobject * tests/test_gio.py: * tests/test_mainloop.py: * tests/test_source.py: * tests/test_subprocess.py: * tests/test_thread.py: Update tests to refer to glib when appropriate svn path=/trunk/; revision=858
* Make distcheck passJohan Dahlin2008-07-251-1/+1
| | | | | | | | | | | 2008-07-25 Johan Dahlin <johan@gnome.org> * gobject/Makefile.am: * tests/Makefile.am: Make distcheck pass svn path=/trunk/; revision=854
* Remove private structures which moved to pyglib.Johan Dahlin2008-07-252-26/+0
| | | | | | | | | | | 2008-07-25 Johan Dahlin <johan@gnome.org> * gobject/gobjectmodule.c (init_gobject): * gobject/pygobject-private.h: Remove private structures which moved to pyglib. svn path=/trunk/; revision=853
* Move over Source, IOChannel, Idle, Timeout and PollFD to glib fromJohan Dahlin2008-07-216-1692/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2008-07-21 Johan Dahlin <johan@gnome.org> * glib/Makefile.am: * glib/glibmodule.c (pyg_idle_add), (pyg_timeout_add), (pyg_timeout_add_seconds), (pyg_io_add_watch), (pyglib_register_api), (pyglib_register_error), (pyglib_register_version_tuples), (init_glib): * glib/pygiochannel.c (py_io_channel_next), (py_io_channel_shutdown), (py_io_channel_set_encoding), (py_io_channel_read_chars), (py_io_channel_write_chars), (py_io_channel_write_lines), (py_io_channel_flush), (py_io_channel_set_flags), (py_io_channel_read_line), (py_io_channel_read_lines), (py_io_channel_seek), (py_io_channel_init), (pyglib_iochannel_register_types): * glib/pygiochannel.h: * glib/pyglib-private.h: * glib/pyglib.c (pyglib_threads_enabled), (pyglib_gil_state_ensure), (pyglib_gil_state_release), (pyglib_enable_threads), (pyglib_block_threads), (pyglib_unblock_threads), (pyglib_set_thread_block_funcs), (pyglib_handler_marshal), (pyglib_destroy_notify): * glib/pyglib.h: * glib/pygsource.c (pyg_source_set_callback), (pyglib_source_register_types): * glib/pygsource.h: * glib/pygspawn.c (pyglib_spawn_register_types): * glib/pygspawn.h: * gobject/Makefile.am: * gobject/__init__.py: * gobject/gobjectmodule.c (pyg_set_thread_block_funcs), (init_gobject): * gobject/pygiochannel.c: * gobject/pygobject-private.h: * gobject/pygsource.c: Move over Source, IOChannel, Idle, Timeout and PollFD to glib from gobject. Clean up and add a bit of new api for glib. svn path=/trunk/; revision=846
* Move maincontext and mainloop over to glib. Update the threadstate api toJohan Dahlin2008-07-2016-618/+101
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2008-07-20 Johan Dahlin <johan@gnome.org> * glib/Makefile.am: * glib/glibmodule.c (pyglib_main_context_default), (init_glib): * glib/pyglib.c (pyglib_init), (pyglib_threads_enabled), (pyglib_main_context_new): * glib/pyglib.h: * glib/pygmaincontext.c (_wrap_g_main_context_iteration), (pyglib_maincontext_register_types): * glib/pygmaincontext.h: * glib/pygmainloop.c (pyg_signal_watch_prepare), (pyg_signal_watch_check), (pyg_main_loop_new), (_wrap_g_main_loop_get_context), (_wrap_g_main_loop_run), (pyglib_mainloop_register_types): * glib/pygmainloop.h: * gobject/Makefile.am: * gobject/__init__.py: * gobject/gobjectmodule.c (pyg_destroy_notify), (pyobject_free), (pyg_object_set_property), (pyg_object_get_property), (_pyg_signal_accumulator), (pygobject__g_instance_init), (pyg_handler_marshal), (pygobject_gil_state_ensure), (pygobject_gil_state_release), (marshal_emission_hook), (_log_func), (init_gobject): * gobject/pygboxed.c (pyg_boxed_dealloc), (pyg_boxed_new): * gobject/pygenum.c (pyg_enum_add): * gobject/pygflags.c (pyg_flags_add): * gobject/pygiochannel.c (pyg_iowatch_marshal): * gobject/pygmaincontext.c: * gobject/pygmainloop.c: * gobject/pygobject-private.h: * gobject/pygobject.c (pygobject_data_free), (pyg_toggle_notify), (pygobject_new_with_interfaces), (pygobject_weak_ref_notify): * gobject/pygobject.h: * gobject/pygoptiongroup.c (destroy_g_group), (arg_func): * gobject/pygpointer.c (pyg_pointer_new): * gobject/pygsource.c (pyg_source_get_context), (pyg_source_prepare), (pyg_source_check), (pyg_source_dispatch), (pyg_source_finalize): * gobject/pygtype.c (pyg_closure_invalidate), (pyg_closure_marshal), (pyg_signal_class_closure_marshal): * tests/common.py: Move maincontext and mainloop over to glib. Update the threadstate api to use the variant in glib. svn path=/trunk/; revision=843
* Install the glib module, the helper library and the headers. Use it fromJohan Dahlin2008-07-204-926/+41
| | | | | | | | | | | | | | | | 2008-07-20 Johan Dahlin <johan@gnome.org> * glib/Makefile.am: * gobject/Makefile.am: * gobject/__init__.py: * gobject/gobjectmodule.c (pyg_threads_init), (pyg_error_check), (pyg_gerror_exception_check), (init_gobject): * gobject/option.py: Install the glib module, the helper library and the headers. Use it from gobject and remove the old glib specific code from there. svn path=/trunk/; revision=842
* Use pkg-config to check for libffi again.Johan Dahlin2008-07-201-1/+1
| | | | | | | | | | | 2008-07-20 Johan Dahlin <johan@gnome.org> * configure.ac: * gobject/Makefile.am: Use pkg-config to check for libffi again. svn path=/trunk/; revision=841
* Use the prefix G_IO_ for stripping constants instead of just G_ Check soJohan Dahlin2008-07-171-5/+14
| | | | | | | | | | | | | | | | | 2008-07-17 Johan Dahlin <johan@gnome.org> * gio/giomodule.c (init_gio): Use the prefix G_IO_ for stripping constants instead of just G_ * gobject/gobjectmodule.c (pyg_constant_strip_prefix): Check so the fist part of name and strip_prefix are the same, if they don't, just strip of the part of strip_prefix which matches. This removes the initial IO_* prefix for some constants in gio. Eg, gio.IO_ERROR_* -> gio.ERROR_* svn path=/trunk/; revision=817
* Bug 378704 – OptionParser.parse_args() returns unexpected results PatchJohan Dahlin2008-07-141-1/+5
| | | | | | | | | | | 2008-07-14 Johan Dahlin <johan@gnome.org> Bug 378704 – OptionParser.parse_args() returns unexpected results * gobject/option.py: Patch by Johannes Hölzl svn path=/trunk/; revision=804
* Bug 504337 - crash bug in gobject.Timeout and gobject.IdleJohan Dahlin2008-07-141-4/+2
| | | | | | | | | | | | | 2008-07-14 Johan Dahlin <johan@gnome.org> Bug 504337 - crash bug in gobject.Timeout and gobject.Idle * gobject/pygsource.c: * tests/test_source.py: Fix crash in Timeout and Idle, patch by Bryan Silverthorn. svn path=/trunk/; revision=799
* Fix error message referencing wrong argument.Juha Sahakangas2008-07-091-1/+1
| | | | | | | | | 2008-07-09 Juha Sahakangas <voas0113@saunalahti.fi> * gobject/gobjectmodule.c (pyg_io_add_watch): Fix error message referencing wrong argument. svn path=/trunk/; revision=792
* Bug 540696 – gobject.markup_escape_text() causes python to segfaultGustavo J. A. M. Carneiro2008-06-291-1/+1
| | | | svn path=/trunk/; revision=790
* New functions, unconditionally raise TypeError. (pygobject_methods): HookPaul Pogonyshev2008-06-091-0/+20
| | | | | | | | | | 2008-06-09 Paul Pogonyshev <pogonyshev@gmx.net> * gobject/pygobject.c (pygobject_copy, pygobject_deepcopy): New functions, unconditionally raise TypeError. (pygobject_methods): Hook them up. (bug #482370) svn path=/trunk/; revision=787
* Add the GParamSpec type wrapper to the module dictionary.Gustavo J. A. M. Carneiro2008-05-301-0/+4
| | | | svn path=/trunk/; revision=785
* Accept None for the child_setup parameter of gobject.spawn_async(). AlsoGustavo J. A. M. Carneiro2008-05-211-3/+12
| | | | | | | | | * gobject/gobjectmodule.c (pyg_spawn_async): Accept None for the child_setup parameter of gobject.spawn_async(). Also check that it is callable. svn path=/trunk/; revision=780
* Fix: raise warning as exception if asked by PyErr_Warn().Paul Pogonyshev2008-04-272-3/+8
| | | | | | | | | | | | | | 2008-04-27 Paul Pogonyshev <pogonyshev@gmx.net> * gobject/pygenum.c (pyg_enum_richcompare): Fix: raise warning as exception if asked by PyErr_Warn(). * gobject/pygflags.c (pyg_flags_richcompare): Don't return NULL after warning; more useful warning message. (#480424, borrowing code by Mark Doffman) svn path=/trunk/; revision=779
* Set gobject.GObject.__module__ to gobject._gobject, this helps pylint toJohan Dahlin2008-04-151-1/+4
| | | | | | | | | | | | | | | | | 2008-04-15 Johan Dahlin <johan@gnome.org> * gobject/gobjectmodule.c (init_gobject): Set gobject.GObject.__module__ to gobject._gobject, this helps pylint to check public methods of GObject subclasses * tests/Makefile.am (tests): * tests/test_gobject.py (TestGObjectAPI.testGObjectModule): Add a test for this (#523821, Simon Schampijer) svn path=/trunk/; revision=777
* Fix a typo Update the tests after the latest "refactoring". The testsuiteJohan Dahlin2008-04-081-2/+2
| | | | | | | | | | | | 2008-04-08 Johan Dahlin <jdahlin@async.com.br> * gobject/option.py: Fix a typo * tests/test_option.py: Update the tests after the latest "refactoring". The testsuite should run fine now again, finally. svn path=/trunk/; revision=770
* Unbreak Source.prepare (#523075, Bryan Silverthorn)Johan Dahlin2008-04-081-3/+1
| | | | | | | | | | | 2008-04-08 Johan Dahlin <jdahlin@async.com.br> * gobject/pygsource.c: * tests/test_source.py: Unbreak Source.prepare (#523075, Bryan Silverthorn) svn path=/trunk/; revision=766
* bug #428732 (pyg_enum_new): Fix two wrong assertions aboutPaul Pogonyshev2008-04-021-8/+29
| | | | | | | | | | | | 2008-04-02 Paul Pogonyshev <pogonyshev@gmx.net> * gobject/pygenum.c: bug #428732 (pyg_enum_new): Fix two wrong assertions about '__enum_values__' size and contents. (pyg_enum_reduce): New function (based on patch by Phil Dumont). (pyg_enum_methods): Hook it up. svn path=/trunk/; revision=756
* Don't return NULL after warning; more useful warning message (bugPaul Pogonyshev2008-03-241-2/+5
| | | | | | | | | 2008-03-24 Paul Pogonyshev <pogonyshev@gmx.net> * gobject/pygenum.c (pyg_enum_richcompare): Don't return NULL after warning; more useful warning message (bug #519631). svn path=/trunk/; revision=755
* Allow gobject.property work with subclasses. Add tests.Johan Dahlin2008-03-211-4/+4
| | | | | | | | | | | | | 2008-03-21 Johan Dahlin <johan@gnome.org> * gobject/__init__.py: * tests/test_properties.py: Allow gobject.property work with subclasses. Add tests. (#523352, Tomeu Vizoso) svn path=/trunk/; revision=752
* Never override customly set 'tp_new' and 'tp_alloc'.Paul Pogonyshev2008-03-021-2/+4
| | | | | | | | | 2008-03-02 Paul Pogonyshev <pogonyshev@gmx.net> * gobject/gobjectmodule.c (REGISTER_TYPE): Never override customly set 'tp_new' and 'tp_alloc'. svn path=/trunk/; revision=747
* Reviewed by: GustavoJohan Dahlin2008-01-031-11/+63
| | | | | | | | | | | | | | | 2008-01-03 Johan Dahlin <johan@gnome.org> Reviewed by: Gustavo * configure.ac: * gobject/pygmainloop.c (pyg_signal_watch_prepare): Optinally use PySignal_SetWakeupFd to avoid having to do a timeout to find out if there are any pending signals from python. Fixes #481569 svn path=/trunk/; revision=723
* Bug 460606 – wrap g_get_application_name and g_get_prgnameGustavo J. A. M. Carneiro2008-01-021-0/+30
| | | | svn path=/trunk/; revision=722
* check for NULL before dereferencing.Paolo Borelli2007-11-241-6/+8
| | | | | | | | | 2007-11-24 Paolo Borelli <pborelli@katamail.com> * gobject/gobjectmodule.c (pyg_type_register): check for NULL before dereferencing. svn path=/trunk/; revision=720
* do not use a potentially uninitialized variable. Bug #499334.Paolo Borelli2007-11-241-2/+3
| | | | | | | | | 2007-11-24 Paolo Borelli <pborelli@katamail.com> * gobject/gobjectmodule.c (pyg_type_register): do not use a potentially uninitialized variable. Bug #499334. svn path=/trunk/; revision=719
* Set the default value of old_args to 0, so we don't end up slicing withJohan Dahlin2007-11-121-1/+1
| | | | | | | | | | | 2007-11-12 Johan Dahlin <johan@gnome.org> * gobject/option.py (OptionParser.parse_args): Set the default value of old_args to 0, so we don't end up slicing with None. Fixes #496278 (Vincent Untz) svn path=/trunk/; revision=718
* Merge in values from all groups to the global option group. Slice up argsJohan Dahlin2007-11-061-1/+10
| | | | | | | | | | | | | | 2007-11-06 Johan Dahlin <johan@gnome.org> * gobject/option.py (OptionParser.parse_args): Merge in values from all groups to the global option group. Slice up args so it doesn't return too much. * tests/test_option.py: Refactor to be unittesty, Add new tests to test what options returns. svn path=/trunk/; revision=717
* Add pyg_option_group_new to the public APIJohan Dahlin2007-11-052-2/+7
| | | | | | | | | | | | | 2007-11-05 Johan Dahlin <johan@gnome.org> * gobject/pygobject.h: * gobject/gobjectmodule.c: Add pyg_option_group_new to the public API * configure.ac: Branch, bump version to 2.15.0. svn path=/trunk/; revision=714
* If there are no items, do not attempt to iterateJohan Dahlin2007-11-021-2/+3
| | | | svn path=/trunk/; revision=712
* Update documentation and filenameJohan Dahlin2007-08-281-3/+12
| | | | svn path=/trunk/; revision=701
* Avoid exporting the metaclass, just define it where it will be used.Johan Dahlin2007-08-271-6/+3
| | | | | | | | | | 2007-08-27 Johan Dahlin <jdahlin@async.com.br> * gobject/propertyhelper.py (property.__metaclass__.__repr__): Avoid exporting the metaclass, just define it where it will be used. svn path=/trunk/; revision=700
* Refactor a bit to make sure that it is possible to use in subclasses,Johan Dahlin2007-08-271-8/+7
| | | | | | | | | | | 2007-08-27 Johan Dahlin <jdahlin@async.com.br> * gobject/__init__.py (GObjectMeta._install_properties): Refactor a bit to make sure that it is possible to use in subclasses, fixes #470718 (Marco Giusti) svn path=/trunk/; revision=699
* Bug 470230 – check for default value in boolean type is wrongGustavo J. A. M. Carneiro2007-08-271-3/+1
| | | | svn path=/trunk/; revision=698
* removed unwanted definesGustavo J. A. M. Carneiro2007-08-271-1/+1
| | | | svn path=/trunk/; revision=697
* Fix compilation warning.Gustavo J. A. M. Carneiro2007-08-271-1/+1
| | | | svn path=/trunk/; revision=695
* Bug 466082 – pygobject_new_full not fully initialising PyGObject, chaos ↵Gustavo J. A. M. Carneiro2007-08-141-2/+6
| | | | | | results svn path=/trunk/; revision=694
* Only compile g_timeout_add_seconds for glib >= 2.13.5Gustavo J. A. M. Carneiro2007-07-081-1/+5
| | | | svn path=/trunk/; revision=691
* Wrap g_timeout_add_secondsGustavo J. A. M. Carneiro2007-07-081-0/+43
| | | | svn path=/trunk/; revision=690
* Work around the deprecation warning of BaseException.message in Python 2.6+ ↵Gustavo J. A. M. Carneiro2007-07-081-1/+16
| | | | | | affecting GError exceptions. Fixes #342948. svn path=/trunk/; revision=689
* revert last change (g_object_run_dispose)Gustavo J. A. M. Carneiro2007-07-071-11/+0
| | | | svn path=/trunk/; revision=684
* Bug 398696 – Wrap g_object_run_disposeGustavo J. A. M. Carneiro2007-07-071-0/+11
| | | | svn path=/trunk/; revision=683
* Bug 342948 – Add exception handling to GOptionGustavo J. A. M. Carneiro2007-07-074-17/+56
| | | | svn path=/trunk/; revision=681
* Bug 351072 – Cannot handle signals with parameter type G_TYPE_VALUE ↵Gustavo J. A. M. Carneiro2007-07-071-2/+19
| | | | | | (marshal/unmarshal for GValue-wrapped GValue) svn path=/trunk/; revision=680
* Rename the private struct field to private_flags, because private is a C++Murray Cumming2007-07-042-3/+3
| | | | | | | | | | | 2007-07-04 Murray Cumming <murrayc@murrayc.com> * gobject/pygobject.c: (pygobject_switch_to_toggle_ref): * gobject/pygobject.h: Rename the private struct field to private_flags, because private is a C++ keyword, so this broke builds of some C++ applications, such as Glom. svn path=/trunk/; revision=679