Commit graph

262 commits

Author SHA1 Message Date
Simon McVittie
5284ed3979 * doc/dbus-tutorial.xml: Replace Python section of tutorial with
a pointer to the tutorial maintained as part of dbus-python
2007-01-25 16:42:54 +00:00
Havoc Pennington
6c2620f242 2006-11-17 Havoc Pennington <hp@redhat.com>
* doc/dbus-faq.xml: minor FAQ tweaks
2006-11-18 03:21:50 +00:00
Havoc Pennington
dbc061b812 2006-11-14 Havoc Pennington <hp@redhat.com>
* dbus/dbus-internals.c (_dbus_generate_uuid): The spec said the
	UUID had the timestamp last, but the implementation had it first;
	move it to last since I think it's a tiny bit nicer (easier to
	compare at a glance, faster to sort, less code), and will not
	cause any practical compatibility problems. Also, always convert
	the timestamp to big endian.

	* doc/dbus-specification.xml: Clean up the docs on the UUID.

	* tools/dbus-uuidgen.1: more prominently say it is not suitable
	as a replacement for regular uuidgen/RFC4122.
2006-11-15 01:52:01 +00:00
Havoc Pennington
3a02d8c132 2006-11-08 Havoc Pennington <hp@redhat.com>
* doc/dbus-specification.xml: add a note about protocol stability

	* doc/TODO: Remove "important for 1.0" section, replace with
	"important for 1.2" section
2006-11-09 00:19:29 +00:00
John (J5) Palmieri
b7491d9258 * README: remove some of the out of date flags
* doc/TODO: Remove todo items which are done
2006-11-08 23:17:20 +00:00
Havoc Pennington
151b3aaaef 2006-11-07 Havoc Pennington <hp@redhat.com>
* doc/dbus-specification.xml, doc/dbus-faq.xml, README: various
	documentation updates. Bump faq/spec versions (not to 1.0; I don't
	think the spec will be "finished"/1.0 when we ship the 1.0 library).
2006-11-07 06:13:53 +00:00
Havoc Pennington
d3440ebe9d 2006-10-30 Havoc Pennington <hp@redhat.com>
* tools/dbus-launch.1, doc/TODO: capture intent to change the
	command line options of dbus-launch a bit post 1.0
2006-10-30 06:29:58 +00:00
Havoc Pennington
fbfec98d0f 2006-10-26 Havoc Pennington <hp@redhat.com>
* dbus/dbus-sysdeps-pthread.c (_dbus_pthread_mutex_lock): change
	to be recursive
	(_dbus_pthread_mutex_unlock): make it recursive
	(_dbus_pthread_condvar_wait): save/restore the recursion count
	(_dbus_pthread_condvar_wait_timeout): save/restore the recursion count
2006-10-27 03:29:09 +00:00
Havoc Pennington
bdbbf46ca8 2006-10-26 Havoc Pennington <hp@redhat.com>
* doc/dbus-specification.xml: clarify the UUID text slightly

	* dbus/dbus-sysdeps-pthread.c: check for and mostly abort on
	pthread errors. Add DBusMutexPThread and DBusCondVarPThread
	in preparation for being able to extend them for e.g. recursive
	mutexes.
2006-10-27 02:17:42 +00:00
John (J5) Palmieri
caae991f97 * dbus-sysdeps-unix.c (_dbus_set_local_creds): Clean up the
LOCAL_CREDS vs CMSGCRED stuff a bit.  Prefer CMSGCRED.  This
  needs to be cleaned up more.

* doc/TODO: Add a todo that *BSD hackers should look at cleaning
  up the CREDS issue.
2006-10-26 19:01:10 +00:00
Havoc Pennington
afa4ffbd85 2006-10-21 Havoc Pennington <hp@redhat.com>
* dbus/dbus-message.h: put #ifndef DBUS_DISABLE_DEPRECATED around
	dbus_message_iter_get_array_len().

	* throughout: documentation improvements.
2006-10-21 17:08:08 +00:00
Havoc Pennington
04964f9562 more todo items 2006-10-20 05:56:57 +00:00
Havoc Pennington
ebb239648b 2006-10-20 Havoc Pennington <hp@redhat.com>
* doc/TODO: remove the int64 thing from 1.0 since it doesn't
	matter, and the message-loader-breaker thing since nobody is going
	to do it.  Add an item to 1.0 about supporting recursive locks
	in dbus_threads_init_default() though, since it should be easy.

	* dbus/dbus-connection.c (_dbus_connection_read_write_dispatch):
	Fix this in the !dispatch case to avoid busy-looping after
	disconnection

        * More misc docs improvements
2006-10-20 05:16:58 +00:00
John (J5) Palmieri
2dd42bd7f5 * doc/TODO: Remove the check TODO item 2006-10-14 16:25:53 +00:00
Havoc Pennington
a2129f7ccc 2006-10-01 Havoc Pennington <hp@redhat.com>
* dbus/dbus-connection.c (_dbus_connection_close_if_only_one_ref):
	Add a hack to make DBusNewConnectionFunction work right.

	* dbus/dbus-server-socket.c (handle_new_client_fd_and_unlock): use
	the hack here. Also, fix the todo about refcount leak.

	* dbus/dbus-server-debug-pipe.c (_dbus_transport_debug_pipe_new):
	and use the hack here

        * dbus/dbus-connection.c: Kill the "shared" flag vs. the
	"shareable" flag; this was completely broken, since it meant
	dbus_connection_open() returned a connection of unknown
	shared-ness. Now, we always hold a ref on anything opened
	as shareable.

	Move the call to notify dbus-bus.c into
	connection_forget_shared_unlocked, so libdbus consistently forgets
	all its knowledge of a connection at once. This exposed numerous
	places where things were totally broken if we dropped a ref inside
	get_dispatch_status_unlocked where
	connection_forget_shared_unlocked was previously, so move
	connection_forget_shared_unlocked into
	_dbus_connection_update_dispatch_status_and_unlock. Also move the
	exit_on_disconnect here.

	(shared_connections_shutdown): this assumed weak refs to the
	shared connections; since we have strong refs now, the assertion
	was failing and stuff was left in the hash. Fix it to close
	still-open shared connections.

	* bus/dispatch.c: fixup to use dbus_connection_open_private on the
	debug pipe connections

	* dbus/dbus-connection.c (dbus_connection_dispatch): only notify
	dbus-bus.c if the closed connection is in fact shared
	(_dbus_connection_close_possibly_shared): rename from
	_dbus_connection_close_internal
	(dbus_connection_close, dbus_connection_open,
	dbus_connection_open_private): Improve docs to explain the deal
	with when you should close or unref or both

	* dbus/dbus-bus.c
	(_dbus_bus_notify_shared_connection_disconnected_unlocked): rename
	from _dbus_bus_check_connection_and_unref_unlocked and modify to
	loop over all connections

	* test/test-utils.c (test_connection_shutdown): don't try to close
	shared connections.

	* test/name-test/test-threads-init.c (main): fix warnings in here

	* dbus/dbus-sysdeps.c (_dbus_abort): support DBUS_BLOCK_ON_ABORT
	env variable to cause blocking waiting for gdb; drop
	DBUS_PRINT_BACKTRACE and just call _dbus_print_backtrace()
	unconditionally.

	* configure.in: add -export-dynamic to libtool flags if assertions enabled
	so _dbus_print_backtrace works.

	* dbus/dbus-sysdeps-unix.c (_dbus_print_backtrace): use fprintf
	instead of _dbus_verbose to print the backtrace, and diagnose lack
	of -rdynamic/-export-dynamic
2006-10-01 15:36:19 +00:00
Havoc Pennington
d8155bf51b 2006-09-30 Havoc Pennington <hp@redhat.com>
* configure.in (LT_CURRENT, LT_AGE): increment current and age to
	reflect addition of interfaces.

	* doc/dbus-specification.xml: describe a new
	org.freedesktop.DBus.Peer.GetMachineId method

	* dbus/dbus-string.c (_dbus_string_skip_white_reverse): new function
	(_dbus_string_skip_white, _dbus_string_skip_blank): use new
	DBUS_IS_ASCII_BLANK, DBUS_IS_ASCII_WHITE macros and fix assertion
	at end of skip_white
	(_dbus_string_chop_white): new function

	* bus/connection.c (bus_connections_setup_connection): call
	dbus_connection_set_route_peer_messages.

	* dbus/dbus-connection.c
	(_dbus_connection_peer_filter_unlocked_no_update): modify to
	support a GetMachineId method.

	Also, support a new flag to let the bus pass peer methods through
	to apps on the bus, which can be set with
	dbus_connection_set_route_peer_messages.

	Finally, handle and return an error for anything unknown on the
	Peer interface, which will allow us to extend the Peer interface
	in the future without fear that we're now intercepting something
	apps were wanting to see.

	* tools/dbus-uuidgen.c: a thin wrapper around the functions in
	dbus/dbus-uuidgen.c

	* dbus/dbus-uuidgen.c: implement the bulk of the dbus-uuidgen
	binary here, since most of the code is already in libdbus

	* dbus/dbus-sysdeps.c (_dbus_read_local_machine_uuid): read the
	uuid from the system config file

	* dbus/dbus-internals.c (_dbus_generate_uuid, _dbus_uuid_encode)
	(_dbus_read_uuid_file_without_creating)
	(_dbus_create_uuid_file_exclusively, _dbus_read_uuid_file): new
	uuid-related functions, partly factored out from dbus-server.c

	* dbus/dbus-sysdeps.c (_dbus_error_from_errno): convert EEXIST to
	DBUS_ERROR_FILE_EXISTS instead of EEXIST

	* dbus/dbus-protocol.h (DBUS_ERROR_FILE_EXISTS): add file exists error

	* tools/dbus-cleanup-sockets.1: explain what the point of this
	thing is a bit more

	* autogen.sh (run_configure): add --config-cache to default
	configure args

	* dbus/dbus-internals.h (_DBUS_ASSERT_ERROR_IS_SET): disable the
	error set/clear assertions when DBUS_DISABLE_CHECKS is defined

	* tools/dbus-launch.c (main): if xdisplay hasn't been opened,
	don't try to save address, fixes crash in make check
2006-10-01 03:18:47 +00:00
John (J5) Palmieri
57ab23491c * dbus/dbus-threads.c: Allow recursive mutex's to be passed into
dbus_threads_init and be used by the dbus mutex functions to
  avoid deadlocks.

* doc/TODO: Remove recursive mutex dbus_connection_dispatch TODO item
2006-09-14 04:26:00 +00:00
John (J5) Palmieri
1eae184450 * doc/TODO:
- Remove pending call locking todo item
- dbus_connection_open now holds hard ref.  Remove todo item
- do proper locking on _dbus_bus_check_connection_and_unref
  and handle DBUS_BUS_STARTER. Remove todo item
- Warn on closing of a shared connection.  Remove todo item

* bus/bus.c, bus/connection.c, bus/dispatch.c, dbus/dbus-bus.c,
  dbus/dbus-connection.c: Use the dbus_connection_close_internal
  so we don't get the warning when closing shared connections

* test/test-service.c, test/test-shell-service.c: Applications
  don't close shared connections themselves so we unref instead of
  close

* test/test-utils.c (test_connection_shutdown): Close the connection

* dbus/dbus-bus.c (_dbus_bus_check_connection_and_unref): Changed to
  _dbus_bus_check_connection_and_unref_unlocked since we only call this
  method on a locked connection.
  Make sure we call _dbus_connection_unref_unlocked instead of
  dbus_connection_unref also.
  Handle DBUS_BUS_STARTER correctly

* dbus/dbus-connection.c (connection_record_shared_unlocked):
  Mark as shared and hard ref the connection
  (connection_forget_shared_unlocked): Remove the hard ref from the
  connection
  (_dbus_connection_close_internal_and_unlock):  New internal function
  which takes a locked connection and unlocks it after closing it
  (_dbus_connection_close_internal): New internal function which acts
  like the origonal dbus_connection_close method by grabbing a connection
  lock and calling _dbus_connection_close_internal_and_unlock
  (dbus_connection_close): Public close method, warns when the app
  trys to close a shared connection
2006-09-06 22:00:07 +00:00
John (J5) Palmieri
e4f3d0ca17 * doc/TODO: Removed dtd publishing item.
It seems the dtd has already been added at
  http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd
2006-09-06 19:40:54 +00:00
John (J5) Palmieri
88f69757b9 * doc/TODO, various source files: Audited todo's and FIXME's and
prepended the ones we should be looking at with 1.0.  Those
  prepended with 1.0? need clerification or might not be needed
  for 1.0
2006-09-06 00:14:06 +00:00
Havoc Pennington
f678f8dd41 add some items related to shared connections 2006-08-24 16:07:25 +00:00
Havoc Pennington
6fcd97c084 2006-08-20 Havoc Pennington <hp@redhat.com>
* doc/dbus-faq.xml, doc/dbus-tutorial.xml: some improvements to
	the docs
2006-08-20 21:41:42 +00:00
Robert McQueen
711c065e59 2006-08-17 Alp Toker <alp@atoker.com>
* doc/dbus-specification.xml: Fix some minor typos.
2006-08-17 21:20:13 +00:00
John (J5) Palmieri
7652304bff * s/D-BUS/D-Bus/g 2006-08-03 20:34:36 +00:00
Havoc Pennington
4bf50e206c add note about fixing locking on pending call 2006-07-21 23:21:54 +00:00
John (J5) Palmieri
b459906a7a * doc/TODO:
* dbus/dbus-bus.c:
* dbus-errors.c:
* dbus/dbus-marshal-validate.c:
  Removed TODO items which were fixed or are no longer relevent
2006-07-17 17:44:07 +00:00
John (J5) Palmieri
7628b54125 * bus/activation.[ch] (bus_activation_list_services): new function to
get the list of services that can be activated

* bus/dispatch.c: test coverage for the new bus method
  ListActivatableNames

* bus/driver.c: new bus method ListActivatableNames to get the list of
  services that can be activated

* doc/dbus-specification.xml: ListActivatableNames method documentation
2006-07-14 01:17:59 +00:00
John (J5) Palmieri
50f88a0322 * dbus/dbus-connection.c (dbus_connection_close): removed deprecated
function
  (dbus_connection_dispatch): On disconnect unref any shared connections

* dbus/dbus-bus.c (_dbus_bus_check_connection_and_unref): new function
  for cleaning up shared connections on disconnect
  (internal_bus_get): get a hard refrence to shared connections when
  they are created

* doc/TODO: Remove items which are no longer relevent or have been fixed
  Split 1.0 todo items with a 0.90 freeze todo list
2006-07-07 19:42:56 +00:00
Havoc Pennington
5db59894bb add dbus_bus_get refcount item to TODO
link to mail list post about pending call threading problems
2006-06-14 04:16:30 +00:00
Havoc Pennington
cd766664ac the recursive locks todo item was a little misleading 2006-06-06 20:28:57 +00:00
John (J5) Palmieri
50266d4190 * Adding old doc patch that never got applied
* dbus/bus.c (dbus_bus_add_match): Add documentation

* doc/dbus-specification.xml: Add documentation for the match rules
  and the AddMatch and RemoveMatch methods
2006-05-03 22:56:35 +00:00
Havoc Pennington
345671f75c add dispatch recursion item to TODO 2006-02-15 16:38:11 +00:00
Ross Burton
f72c693f48 Add documentation on glib client bindings and annotations 2005-12-19 18:11:05 +00:00
John (J5) Palmieri
1a163e765c * configure.in: Add test/name-test/Makefile to the generated
Makefile list

	* dbus/dbus-shared.h (#define DBUS_NAME_FLAG_ALLOW_REPLACEMENT):
	New flag which replaces DBUS_NAME_FLAG_PROHIBIT_REPLACEMENT
	(#define DBUS_NAME_FLAG_DO_NOT_QUEUE): New flag for specifying
	not to queue an ower if it can't be the primary owner

	* bus/bus.h: Add new internal BusOwner struct

	* bus/driver.c (bus_driver_handle_hello): Send flags (0 for default)
	to bus_registry_ensure and don't set the prohibit_replacement flag
	since they are now set per BusOwner and not per name.
	(bus_driver_handle_list_queued_owners): bus method (ListQueuedOwners)
	that returns the list of connections in a name's connection queue

	* bus/services.c (struct BusService): remove prohibit_replacement field
	(struct BusOwner): new struct for keeping track of queued connections
	and their associated flags for the queue
	(struct BusRegistry): add a BusOwner memory pool
	(bus_registry_new): initialize the BusOwner memory pool
	(bus_registry_unref): free the BusOwner memory pool
	(_bus_service_find_owner_link): new internal method for
	searching the queue for a specific connection
	(bus_owner_set_flags): new method for adding setting the flags on a
	bus owner
	(bus_owner_new): new method that creates a BusOwner object from the
	pool and sets its flags
	(bus_owner_ref, bus_owner_unref): ref counting for BusOwner objects
	(bus_registry_ensure): Add the flags parameter
	(bus_registry_acquire_service): Switch from using raw connections to
	using the BusOwner struct
	Add new state machine for dealing with the new set of flags
	(bus_registry_set_service_context_table, struct OwnershipCancelData,
	cancel_ownership, free_ownership_cancel_data,
	add_cancel_ownership_to_transaction, struct OwnershipRestoreData,
	restore_ownership, free_ownership_restore_data,
	add_restore_ownership_to_transaction): Switch to using BusOwner
	instead of raw connections
	(bus_service_add_owner): Add flags parameter
	Switch to using BusOwner instead of raw connections
	Add state machine for dealing with the new set of flags
	(bus_service_swap_owner): Swaps the first and second owners in the
	queue.  Used to make sure proper signals are sent when a service looses
	or gains primary ownership.  We never insert an owner at the top of the
	queue.  Instead we insert it in the second position and then swap.
	(bus_service_remove_owner): Remove the owner from the queue sending
	out the NameLost and NameOwnerChanged signals if the we were the
	primary owner
	(bus_service_get_primary_owners_connection): New method that extracts
	the connection from the primary owner
	(bus_service_get_primary_owner): Returns the BusOwner instead of the
	connection
	(bus_service_get_allow_replacement): Changed from the old
	bus_service_get_prohibit_replacement method.  Checks the flags of the
	primary owner and returns if it can be replaced or not
	(bus_service_set_prohibit_replacement): removed
	(bus_service_has_owner): returns TRUE if and owner with
	the specified connection exists in the queue

	* dbus/dbus-bus.c (dbus_bus_connection_get_unique_name): New helper
	method that only compiles if tests are enabled.  Allows us to get the
	unique name of a connection so we can check it against the queue when
	doing regression tests

	* bus/activation.c (bus_activation_send_pending_auto_activate),
	bus/dispatch.c (bus_dispatch),
	bus/driver.c (bus_driver_handle_get_service_owner,
	bus_driver_handle_get_connection_unix_user,
	bus_driver_handle_get_connection_unix_process_id,
	bus_driver_handle_get_connection_selinux_security_context),
	bus/signals.c (connection_is_primary_owner):
	use bus_service_get_primary_owners_connection instead of
	bus_service_get_primary_owner

	* dbus/dbus-sysdeps.c (_dbus_connect_unix_socket,
	_dbus_listen_unix_socket): Calculate the length of the socket
	path and use that instead of using a fixed length which was
	causing socket names to contain many trailing Nul bytes.

	* dbus/dbus-glib-lowlevel.h, glib/dbus-gobject.c
	(dbus_g_method_get_sender): New method for extracting the sender
	from a DBusGMethodInvocation
	(dbus_g_method_return_get_reply): changed name to
	dbus_g_method_get_reply
	(dbus_g_method_return_send_reply): changed name to
	dbus_g_method_send reply

	* doc/dbus-specification.xml: New docs that describe how the new
	queueing system works and talks about the changes to the how
	we specify socket names

	* glib/examples/example-service.c,
	glib/examples/example-signal-emitter.c,
	glib/examples/statemachine/statemachine-server.c:
	Changed the RequestName flags to the new system

	* test/name-test/ (test-names.c, run-test.sh, Makefile.am): New
	regression test suite for testing various states of the new
	queueing system
2005-11-22 20:37:00 +00:00
Robert McQueen
b5e4d26ade 2005-11-15 Robert McQueen <robot101@debian.org>
* bus/driver.c, bus/services.c, bus/services.h: Add a ReleaseName
	method to org.freedesktop.DBus to release a bus name or give up
	waiting in the queue for it.

	* dbus/dbus-bus.c, dbus/dbus-bus.h, dbus/dbus-shared.h: Add a
	dbus_bus_release_name method to send the ReleaseName method calls.
	Add constants for the return values to dbus/dbus-shared.h.

	* doc/dbus-specification.xml: Document the new ReleaseName method
	in the specification.

	* python/dbus_bindings.pyx: Add a low-level python binding for the
	release name method.

	* python/exceptions.py, python/service.py: Make freeing BusName
	objects release the name. Add a NameExistsException, and fix a
	bug with creating UnknownMethodException.

	* test/python/test-client.py: Add tests for freeing BusName
	objects causing names to be released.
2005-11-15 17:19:19 +00:00
Ross Burton
4e2b0d94ec Add a NoReply annotation 2005-10-25 08:54:57 +00:00
John (J5) Palmieri
66e1cb9e68 * bus/driver.c (bus_driver_handle_introspect): Add signals
to the introspect data. (patch from Daniel P. Berrange
  <dan at berrange.com>)

* bus/dispatch.c (check_existent_ping): Add testcase for Ping

* dbus/dbus-connection.c (_dbus_connection_peer_filter,
  _dbus_connection_run_builtin_filters): Changed these to
  be unlock_no_update functions and call
  _dbus_connection_send_unlocked_no_update instead of
  dbus_connection_send to avoid locking errors.

* doc/TODO: Removed the make Ping test TODO
2005-10-03 19:55:56 +00:00
Waldo Bastian
8b34c2c538 * dbus/dbus-marshal-validate.c, doc/dbus-specification.xml,
test/Makefile.am, test/test-names.c: allow hyphens in bus names.
2005-09-12 08:19:33 +00:00
Havoc Pennington
51c609c340 links to some pending tasks 2005-08-25 03:15:46 +00:00
John (J5) Palmieri
8d1e7dfeb9 * ChangeLog: clean up my last entry a bit
* doc/introspect.xsl: New stylesheet for converting introspection data
	into browser renderable xhtml. Contributed by Lennart Poettering.

	* doc/introspect.dtd: Fixups in the introspect format from Lennart
	Poettering.

	* doc/dbus-tutorial.xml:
	- Add Colin Walter to the Authors section for authoring the GLib
	section
	- Add descriptions of the new signature and type functionality
	in the Python complex type mapping section
	- Add a sidenote on the new args matching functionality in
	the Python bindings
	- Fixed up some of the examples to use the gobject.MainLoop
	instead of gtk.main

	* python/_dbus.py:
	(Bus::_create_args_dict): New. Converts a hash of arg matches
	to a more useable format
	(Bus::add_signal_receiver): add a **keywords parameter for catching
	arg match parameters
	(Bus::remove_signal_receiver): add a **keywords parameter for catching
	arg match parameters

	* python/matchrules.py:
	(MatchTree::exec_matches): Check for arg matches
	(SignalMatchRule::add_args_match): New method
	(SignalMatchRule::execute): Added args_list parameter as an optimization
	so we don't have to marshal the args more than once
	(SignalMatchRule::match_args_from_list): New method that checks to see
	if the rule's arg matches match an argument list.  Only arguments
	set in the rule are checked.
	(SignalMatchRule::match_args_from_rule): New method that checks to see
	if the rule's arg matches match another rule's.  All args have to match
	in order for this method to return true.  If either rule has more args
	then it is not a match.
	(SignalMatchRule::is_match): Add args match
	(SignalMatchRule::repr): Add args to the final output if they exist
2005-08-18 04:04:57 +00:00
Havoc Pennington
c76d24b007 some docs cleanups 2005-08-01 18:59:02 +00:00
Havoc Pennington
afcc19c157 add "publish introspect dtd" to TODO for 1.0 2005-07-31 01:38:55 +00:00
Havoc Pennington
ba04a545aa 2005-07-29 Havoc Pennington <hp@redhat.com>
* test/glib/test-profile.c (write_junk): initialize the junk
	buffer so valgrind doesn't have a breakdown
2005-07-30 01:33:55 +00:00
Havoc Pennington
c8a5cff515 remove that todo item 2005-07-29 17:46:58 +00:00
Havoc Pennington
51a4261d0e 2005-07-29 Havoc Pennington <hp@redhat.com>
* bus/signals.c (bus_signals_test): add match_rule_equal() tests
	(match_rule_matches): remove unused arg
	(test_matching): add tests for match_rule_matches()

	* bus/signals.c (bus_match_rule_parse_arg_match): add ability to
	do arg0='foo' arg5='bar' in the match rules
	(match_rule_matches): don't match if the arg0='foo' doesn't match.

	* dbus/dbus-protocol.h (DBUS_MAXIMUM_MATCH_RULE_ARG_NUMBER): add this
2005-07-29 17:43:30 +00:00
Colin Walters
3b628f9209 2005-07-15 Colin Walters <walters@verbum.org>
* doc/TODO: Add note about convenience wrappers.
2005-07-15 22:02:25 +00:00
John (J5) Palmieri
a7595655fb * bus/dispatch.c, test/test-service.c: Add testcase
for sending messages to oneself (TODO item).

* python/service.py (class Object): Swap ordering of bus_name
  and object_path parameters to better support inheritance.

* doc/dbus-tutorial.xml: change Python docs to reflect change
  in parameter ordering and fix the inheritance section.

* doc/TODO: remove sending message to oneself TODO item
2005-07-15 15:21:43 +00:00
John (J5) Palmieri
dc4d80e567 * python/_dbus.py (Bus::remove_signal_receiver):
don't add a callback to the match if none has been passed in

* python/matchrules.py (SignalMatchTree::remove): if the rule
  being matched does not have a callback treat it as a wildcard
  fix matching logic

* doc/dbus-tutorial.xml: Add Python tutorial
2005-07-15 02:15:08 +00:00
John (J5) Palmieri
d06bfe528b * python/dbus_bindings.pyx.in: removed
* python/dbus_bindings.pyx: Added.
	- Fixed some memleaks (patch from
	  Sean Meiners <sean.meiners@linspireinc.com>)
	- Broke out the #include "dbus_h_wrapper.h" and put it in its
	  own pxd file (Pyrex definition)
	- Broke out glib dependancies into its own pyx module

* python/dbus_bindings.pdx: Added.
	- Defines C class Connection for exporting to other modules

* python/dbus_glib_bindings.pyx: Added.
	- New module to handle lowlevel dbus-glib mainloop integration

* python/glib.py: Added.
	- Registers the glib mainloop when you import this module

* python/services.py: Removed (renamed to service.py)

* python/service.py: Added.
	- (class Server): renamed Name

* python/__init__.py: Bump ro version (0,41,0)
	- don't import the decorators or service module
   	  by default.  These now reside in the dbus.service namespace

* python/_dbus.py (Bus::__init__): Add code run the main loop
  setup function on creation

* python/examples/example-service.py,
  python/examples/example-signal-emitter.py: update examples

* python/examples/gconf-proxy-service.py,
  python/examples/gconf-proxy-service2.py: TODO fix these up

* doc/TODO: Addition
	- Added a Python Bindings 1.0 section
	- added "Add match on args or match on details to match rules"
2005-07-12 18:16:07 +00:00
Colin Walters
8c095eea8f 2005-07-10 Colin Walters <walters@verbum.org>
* doc/TODO: Knock off some GLib items with this patch.

	* glib/dbus-gvalue-utils.c (_dbus_gtype_can_signal_error)
	(_dbus_gvalue_signals_error): New functions.

	* glib/dbus-gvalue-utils.h: Prototype them.

	* glib/dbus-gobject.c (arg_iterate): Update to handle return vals
	and change to not output const/retval flags for input args.  All
	callers updated.
	(invoke_object_method): Refactor to handle return values.  Add
	some more comments in various places.  Remove debug g_print.

	* glib/dbus-binding-tool-glib.h (DBUS_GLIB_ANNOTATION_RETURNVAL): New.

	* glib/dbus-binding-tool-glib.c (dbus_g_type_get_marshal_name):
	Handle G_TYPE_NONE.
	(compute_gsignature): New function; refactored from code from
	compute_marshaller and compute_marshaller_name.  Enhance to
	handle return values and async ops more cleanly.  Update for
	async ops returning NONE instead of BOOLEAN.
	(compute_marshaller, compute_marshaller_name): Call compute_gsignature
	and output appropriate string.
	(generate_glue): Handle return value annotation.  Also don't dump
	constness flag for input arguments.

	* glib/Makefile.am (DBUS_GLIB_INTERNALS): New variable; contains
	files shared between installed library and utilities.
	(libdbus_glib_1_la_SOURCES): Move some stuf into DBUS_GLIB_INTERNALS.
	(libdbus_gtool_la_SOURCES): Suck in DBUS_GLIB_INTERNALS so the
	binding tool can access gtype utility functions.

	* test/glib/test-service-glib.c:
	* test/glib/test-service-glib.xml:
	* test/glib/test-dbus-glib.c: Add some tests for return values.
2005-07-10 22:54:19 +00:00