Christian Persch [Thu, 13 May 2010 17:01:04 +0000 (19:01 +0200)]
Make GVariant handling in PropertiesChanged more efficient
There's no need to re-build the a{sv} array, just get it right out of
the parameters. Also avoid some string copies.
Signed-off-by: David Zeuthen <davidz@redhat.com>
Christian Persch [Thu, 13 May 2010 17:20:26 +0000 (19:20 +0200)]
Plug some mem leaks
g_variant_get (v, "s", &str) returns a string copy; use "&s" instead.
Signed-off-by: David Zeuthen <davidz@redhat.com>
David Zeuthen [Thu, 13 May 2010 20:32:11 +0000 (16:32 -0400)]
GDBus: Add GDBusAuthObserver param in g_dbus_connection_new_for_address()
This is to match g_dbus_connection_new(). This extension allows us to
extend GDBusAuthObserver to also be used in client-side authentication
in the future (right now it's only used on the server-side).
David Zeuthen [Thu, 13 May 2010 20:20:31 +0000 (16:20 -0400)]
GDBus: Rename ::deny-authentication-peer to ::authorize-authenticated-peer
Matthias Clasen [Thu, 13 May 2010 18:25:29 +0000 (14:25 -0400)]
Remove the credentials argument from g_unix_connect_send_credentials()
Instead, make it always send the current credentials.
David Zeuthen [Thu, 13 May 2010 18:01:41 +0000 (14:01 -0400)]
GDBus: Make message serialization routines take capabilities param
This is needed to e.g. allow encoding maybe types (once we add
G_DBUS_CAPABILITY_FLAGS_MAYBE_TYPES) if, and only if, that capability
has been negotiated with the peer (via authentication).
Matthias Clasen [Thu, 13 May 2010 17:09:58 +0000 (13:09 -0400)]
remove the redundant interface_name parameter
David Zeuthen [Thu, 13 May 2010 15:56:15 +0000 (11:56 -0400)]
GDBus: Catch up with new PropertiesChanged signal
After a long discussion, this has finally been standardized in the
D-Bus spec. See
http://lists.freedesktop.org/archives/dbus/2010-May/012667.html
http://lists.freedesktop.org/archives/dbus/2010-May/012712.html
Signed-off-by: David Zeuthen <davidz@redhat.com>
Matthias Clasen [Thu, 13 May 2010 05:04:29 +0000 (01:04 -0400)]
Fill out the export section of the migration guide
Matthias Clasen [Thu, 13 May 2010 04:39:26 +0000 (00:39 -0400)]
Add an example of exporting a GObject
This is more manual work than dbus-glib.
David Zeuthen [Thu, 13 May 2010 03:12:14 +0000 (23:12 -0400)]
GDBus: add 'monitor' verb to gdbus(1)
This uncovered a bug in name watching if the name wasn't activatable.
Also provoked the need for on_connection variants of g_bus_watch_name
(added g_bus_watch_proxy's variant as well).
David Zeuthen [Thu, 13 May 2010 02:09:18 +0000 (22:09 -0400)]
GDBus: Make gdbus(1) print annotations when introspecting data
Also make the gdbus-example-server include some example
annotations. The output looks like this:
$ gdbus introspect --session --dest org.gtk.GDBus.TestServer --object-path /org/gtk/GDBus/TestObject
node /org/gtk/GDBus/TestObject {
interface org.freedesktop.DBus.Properties {
methods:
Get(in s interface_name,
in s property_name,
out v value);
GetAll(in s interface_name,
out a{sv} properties);
Set(in s interface_name,
in s property_name,
in v value);
signals:
PropertiesChanged(s interface_name,
a{sv} changed_properties);
};
interface org.freedesktop.DBus.Introspectable {
methods:
Introspect(out s xml_data);
};
interface org.freedesktop.DBus.Peer {
methods:
Ping();
GetMachineId(out s machine_uuid);
};
@org.gtk.GDBus.Annotation("OnInterface")
@org.gtk.GDBus.Annotation("AlsoOnInterface")
interface org.gtk.GDBus.TestInterface {
methods:
@org.gtk.GDBus.Annotation("OnMethod")
HelloWorld(in s greeting,
out s response);
EmitSignal(@org.gtk.GDBus.Annotation.("OnArg")
in d speed_in_mph);
GimmeStdout();
signals:
@org.gtk.GDBus.Annotation("Onsignal")
VelocityChanged(d speed_in_mph,
@org.gtk.GDBus.Annotation.("OnArg_NonFirst")
s speed_as_string);
properties:
@org.gtk.GDBus.Annotation("OnProperty")
@org.gtk.GDBus.Annotation("OnAnnotation_YesThisIsCrazy")
readonly s FluxCapicitorName = 'DeLorean';
readwrite s Title = 'Back To C!';
readonly s ReadingAlwaysThrowsError;
readwrite s WritingAlwaysThrowsError = "There's no home like home";
writeonly s OnlyWritable;
readonly s Foo = 'Tick';
readonly s Bar = 'Tock';
};
};
Matthias Clasen [Thu, 13 May 2010 01:51:06 +0000 (21:51 -0400)]
Add a note about implemented standard interfaces
David Zeuthen [Thu, 13 May 2010 00:43:40 +0000 (20:43 -0400)]
GDBusProxy: Remove error in get_cached_property() and add set_cached_property()
This makes it possible to use the cached properties mechanism even if
constructing the proxy with the DO_NOT_LOAD_PROPERTIES flag.
This is useful for cases where you obtain the and track object
properties out-of-band. For example, in udisks, the plan is to have
something like this
Manager.GetObjects (out ao paths, out aa{sa{sv}} all_properties);
Manager.ObjectAdded (o path, a{sa{sv}} all_properties);
Manager.ObjectChanged (o path, a{sa{sv}} all_properties);
Manager.ObjectRemoved (o path, a{sa{sv}} all_properties);
E.g. the first GetObjects() call will return *all* data about *all*
exported objects. Further, this way a client will only need to listen
these three signals (three AddMatch) on the Manager object and it will
never need to do GetAll() etc (e.g. can use DO_NOT_LOAD_PROPERTIES).
(Of course this only works if the client is interested in all
objects... while this is true for udisks it is generally not true for
other D-Bus services).
Also use expected_interface to check for programming errors.
Matthias Clasen [Wed, 12 May 2010 21:56:56 +0000 (17:56 -0400)]
Add some more verbiage
David Zeuthen [Wed, 12 May 2010 19:49:48 +0000 (15:49 -0400)]
GDBus: Add an example of a GDBusProxy subclass
Matthias Clasen [Wed, 12 May 2010 17:01:40 +0000 (13:01 -0400)]
Update an example to the latest auth observer api
Matthias Clasen [Wed, 12 May 2010 17:01:02 +0000 (13:01 -0400)]
Correct env var names
and add a note about priority
Matthias Clasen [Wed, 12 May 2010 16:13:57 +0000 (12:13 -0400)]
placeholder for more migration docs
Matthias Clasen [Wed, 12 May 2010 03:26:51 +0000 (23:26 -0400)]
Update TODO list
Matthias Clasen [Wed, 12 May 2010 03:18:48 +0000 (23:18 -0400)]
mention inline use of floating variants
Matthias Clasen [Wed, 12 May 2010 02:51:14 +0000 (22:51 -0400)]
Remove properties from GDBusMethodInvocation class
Matthias Clasen [Wed, 12 May 2010 02:50:40 +0000 (22:50 -0400)]
Document remove_filter
Matthias Clasen [Wed, 12 May 2010 02:35:59 +0000 (22:35 -0400)]
Document DBUS address env vars
Matthias Clasen [Wed, 12 May 2010 02:03:40 +0000 (22:03 -0400)]
Trivial: tweak section heading
Matthias Clasen [Wed, 12 May 2010 02:00:54 +0000 (22:00 -0400)]
Trivial formatting fix
Matthias Clasen [Wed, 12 May 2010 02:00:06 +0000 (22:00 -0400)]
Fill out the proxy section of the migration guide
Matthias Clasen [Wed, 12 May 2010 01:59:42 +0000 (21:59 -0400)]
Don't refer to nonexisting API.
Matthias Clasen [Wed, 12 May 2010 01:32:29 +0000 (21:32 -0400)]
Fix a typo
Matthias Clasen [Wed, 12 May 2010 01:30:53 +0000 (21:30 -0400)]
Complete the name owning section of the migration guide
Matthias Clasen [Wed, 12 May 2010 00:57:44 +0000 (20:57 -0400)]
Match up parameter names
and similar cleanups to make gtk-doc happy.
Matthias Clasen [Wed, 12 May 2010 00:03:44 +0000 (20:03 -0400)]
Line up prototypes
Matthias Clasen [Tue, 11 May 2010 21:15:11 +0000 (17:15 -0400)]
More gdbus migration stuff
Matthias Clasen [Tue, 11 May 2010 19:50:19 +0000 (15:50 -0400)]
Strip copyright headers from examples
These are included wholesale in the docs, and the copyright
headers make them even more overwhelming. Plus, we don't have
copyright headers on examples anywhere else.
Matthias Clasen [Tue, 11 May 2010 19:42:15 +0000 (15:42 -0400)]
Trivial: rename a file
David Zeuthen [Tue, 11 May 2010 16:04:37 +0000 (12:04 -0400)]
GDBus: Update TODO list
David Zeuthen [Mon, 10 May 2010 20:20:59 +0000 (16:20 -0400)]
GDBus: In gdbus(1), try Get() if GetAll() fails
This fixes a problem with services that doesn't implement GetAll() for
one reason or another.
$ gdbus introspect --session --dest org.freedesktop.ReserveDevice1.Audio0 --object-path /org/freedesktop/ReserveDevice1/Audio0
node /org/freedesktop/ReserveDevice1/Audio0 {
interface org.freedesktop.ReserveDevice1 {
methods:
RequestRelease(in i priority,
out b result);
properties:
readonly i Priority = 0;
readonly s ApplicationName = 'PulseAudio Sound Server';
readonly s ApplicationDeviceName = 'Internal Audio Analog Stereo';
};
interface org.freedesktop.DBus.Properties {
methods:
Get(in s interface,
in s property,
out v value);
};
interface org.freedesktop.DBus.Introspectable {
methods:
Introspect(out s data);
};
};
David Zeuthen [Mon, 10 May 2010 18:43:08 +0000 (14:43 -0400)]
GDBus: Add TODO item about a need to validate data / messages
David Zeuthen [Mon, 10 May 2010 18:07:13 +0000 (14:07 -0400)]
GDBus Add TODO items about finding and launching bus instances
David Zeuthen [Mon, 10 May 2010 17:31:54 +0000 (13:31 -0400)]
GDBus: Use GVariant instead of GHashTable for GDBusProxy::g-properties-changed
David Zeuthen [Mon, 10 May 2010 15:47:08 +0000 (11:47 -0400)]
GDBus: Use call() instead of invoke_method()
Lots of people been suggesting this. We still use MethodInvocation /
method_invocation for handling incoming method calls so use call()
instead of invoke_method() helps to separate the client and server
facilities. Which is a good thing(tm).
Matthias Clasen [Mon, 10 May 2010 12:07:28 +0000 (08:07 -0400)]
More copyright year updates
Matthias Clasen [Mon, 10 May 2010 12:07:07 +0000 (08:07 -0400)]
Trivia
Matthias Clasen [Mon, 10 May 2010 02:13:18 +0000 (22:13 -0400)]
Cosmetic fixes
Use P_() for properties, fix up indentation, etc.
Matthias Clasen [Sun, 9 May 2010 17:14:55 +0000 (13:14 -0400)]
Update copyright years to include 2010
Matthias Clasen [Sun, 9 May 2010 17:09:54 +0000 (13:09 -0400)]
Microoptimize string reallocations
Matthias Clasen [Sun, 9 May 2010 16:41:02 +0000 (12:41 -0400)]
Move some platform sources around
gunixcredentialsmessage.h ought to live with other UNIX headers,
and the credentials are moved from dbus-specific to just GIO sources.
Also move gfiledescriptorbased.c to the UNIX sources.
Matthias Clasen [Sun, 9 May 2010 16:24:56 +0000 (12:24 -0400)]
Mention multithreading as a reason for not using libdbus
David Zeuthen [Sun, 9 May 2010 14:02:56 +0000 (10:02 -0400)]
GDBus: Rework GCredentials type
These changes are is related to
https://bugzilla.gnome.org/show_bug.cgi?id=617483
and IRC discussions with danw.
Matthias Clasen [Sun, 9 May 2010 06:27:09 +0000 (02:27 -0400)]
Add some conceptual changes
Matthias Clasen [Sun, 9 May 2010 05:44:11 +0000 (01:44 -0400)]
Some documentation tweaks
Add links to the D-Bus docs in some places, and various
other additions.
Matthias Clasen [Sun, 9 May 2010 00:10:57 +0000 (20:10 -0400)]
Document length parameter of g_settings_get/set_strv
This parameter was not mentioned in the doc comment, as pointed
out in bug 617767.
David Zeuthen [Fri, 7 May 2010 19:02:37 +0000 (15:02 -0400)]
GDBus: add TODO item about maybe having to rework ::g-properties-changed
David Zeuthen [Fri, 7 May 2010 18:57:20 +0000 (14:57 -0400)]
GDBus: add TODO item about the need to rewrite private GDBusAuth* classes
David Zeuthen [Fri, 7 May 2010 18:56:01 +0000 (14:56 -0400)]
Add TODO item about wanting G_DBUS_NONCE_TCP_TMPDIR
David Zeuthen [Fri, 7 May 2010 18:36:07 +0000 (14:36 -0400)]
GDBus: Document environment variables in "Running GIO applications"
Matthias Clasen [Fri, 7 May 2010 00:54:04 +0000 (20:54 -0400)]
A quick cheat sheet
David Zeuthen [Thu, 6 May 2010 23:39:16 +0000 (19:39 -0400)]
GDBus: add a man page for gdbus(1)
Matthias Clasen [Thu, 6 May 2010 22:15:00 +0000 (18:15 -0400)]
Mention D-Bus functionality in the overview
Matthias Clasen [Thu, 6 May 2010 21:52:54 +0000 (17:52 -0400)]
Add a migration chapter for dbus bits
Also split migration.xml into separate files per chapter, it was
getting unwieldy.
David Zeuthen [Thu, 6 May 2010 21:41:31 +0000 (17:41 -0400)]
GDBus: Add more symbols to pltcheck.sh's SKIP variable
In particular, add these symbols
g_memdup
g_print
g_random_int
g_propagate_prefixed_e
g_thread_create_full
g_int_hash
g_file_open_tmp
g_thread_self
g_usleep
David Zeuthen [Thu, 6 May 2010 21:31:51 +0000 (17:31 -0400)]
GDBus: Add new symbols to gio.symbols
David Zeuthen [Thu, 6 May 2010 20:34:23 +0000 (16:34 -0400)]
GDBus: Fix up i18n
David Zeuthen [Thu, 6 May 2010 20:02:08 +0000 (16:02 -0400)]
Add "Since: 2.26" to all new GDBus API
David Zeuthen [Thu, 6 May 2010 19:31:45 +0000 (15:31 -0400)]
Set up gtk-doc for GDBus
Also move send_credentials() and receive_credentials() to
GUnixConnection. This code might change, discussion is still ongoing
in
https://bugzilla.gnome.org/show_bug.cgi?id=617483.
David Zeuthen [Thu, 6 May 2010 18:13:59 +0000 (14:13 -0400)]
Initial GDBus code-drop from GDBus-standalone repo
Things compile and the test-suite passes. Still need to hook up
gio.symbols and docs. There are still a bunch of TODOs left in the
sources that needs to be addressed.
Signed-off-by: David Zeuthen <davidz@redhat.com>
Javier Jardón [Thu, 6 May 2010 04:28:54 +0000 (06:28 +0200)]
Clean Glib header #include issues: gthread
Javier Jardón [Wed, 5 May 2010 16:32:03 +0000 (18:32 +0200)]
Clean Glib header #include issues: gmem
Javier Jardón [Wed, 5 May 2010 16:24:33 +0000 (18:24 +0200)]
Clean Glib header #include issues: gtestutils
Javier Jardón [Wed, 5 May 2010 16:12:04 +0000 (18:12 +0200)]
Clean Glib header #include issues: gasyncqueue
Javier Jardón [Wed, 5 May 2010 15:32:12 +0000 (17:32 +0200)]
Do not include "glib.h" in gio files
Tor Lillqvist [Wed, 5 May 2010 06:43:30 +0000 (09:43 +0300)]
Minor updates to README.win32.
Xan Lopez [Tue, 4 May 2010 16:09:01 +0000 (18:09 +0200)]
Fix typo in limits documentation
Torsten Schönfeld [Mon, 26 Apr 2010 21:38:41 +0000 (23:38 +0200)]
gio: Add a boxed type for GFileAttributeMatcher
https://bugzilla.gnome.org/show_bug.cgi?id=616892
Tor Lillqvist [Mon, 3 May 2010 16:56:46 +0000 (19:56 +0300)]
Fix list of sources in the gio Visual Studio project
List the additional sources needed in gio/Makefile.am, not in
gio.vcprojin. Fix broken usage of sort. Filter out Unix-only source
files.
Tor Lillqvist [Mon, 3 May 2010 16:24:35 +0000 (19:24 +0300)]
Fix misspelled identifier in the Win32 code
Dan Winship [Mon, 26 Apr 2010 02:54:12 +0000 (22:54 -0400)]
g_cancellable_release_fd: allow NULL cancellable
Almost all GCancellable methods silently do nothing if passed NULL for
the cancellable. Make g_cancellable_release_fd() do that as well.
Ryan Lortie [Sun, 2 May 2010 19:14:30 +0000 (14:14 -0500)]
GSettings: fix mixed use of a pointer
- used in some places as a move-along-as-we-go pointer
- used in other places as a pointer to the fixed base of an array
Switch all users to the first style to avoid a crasher.
Kjartan Maraas [Sat, 1 May 2010 12:25:22 +0000 (14:25 +0200)]
Updated Norwegian bokmål translation
Christian Persch [Wed, 28 Apr 2010 10:36:30 +0000 (12:36 +0200)]
Add API to get the compile and match flags from a GRegex
Bug #616967.
Shaun McCance [Fri, 30 Apr 2010 00:27:56 +0000 (19:27 -0500)]
[gvariant-varargs.xml] Fix some outdated documentation
Ryan Lortie [Mon, 26 Apr 2010 03:00:28 +0000 (22:00 -0500)]
GSettingsBackend API/ABI change
- add list() virtual method
- add 'default_value' flag to read() call
Dan Winship [Tue, 27 Apr 2010 13:25:45 +0000 (09:25 -0400)]
.gitignore updates for gsettings stuff
Jorge González [Tue, 27 Apr 2010 19:05:13 +0000 (21:05 +0200)]
Updated Spanish translation
Jorge González [Tue, 27 Apr 2010 18:59:07 +0000 (20:59 +0200)]
Updated Spanish translation
Dan Winship [Mon, 12 Apr 2010 14:21:20 +0000 (10:21 -0400)]
GSocket: fix garbled error messages on windows
socket_strerror() was assuming all "strerror" messages are shorter
than 128 bytes, which is certainly true on Linux, but apparently not
on Windows.
https://bugzilla.gnome.org/show_bug.cgi?id=615494
Alexander Larsson [Tue, 27 Apr 2010 07:23:07 +0000 (09:23 +0200)]
Allocate quarks in chunks to avoid overhead and fragmentation
See bug 616720 for some measurements.
David Zeuthen [Mon, 26 Apr 2010 20:37:02 +0000 (16:37 -0400)]
Bug 616877 – Several issues with g_socket_receive_message
The messages array was not reallocated correctly because it was using
malloc instead of realloc. Also, if the user requested messages but
none were received we would segfault. Rewrite the code to fix this
and, for better readability, use GPtrArray instead of rolling our own.
Also make the docs mention that the user need to free the returned
GSocketControlMessage objects using g_object_unref().
Clarify that *messages may be set to %NULL if there are no messages
(this will save pointless allocs of arrays).
Finally, the Win32 version didn't set messages to the expected value.
https://bugzilla.gnome.org/show_bug.cgi?id=616877
Signed-off-by: David Zeuthen <davidz@redhat.com>
Ryan Lortie [Mon, 26 Apr 2010 01:08:59 +0000 (20:08 -0500)]
docs and glib.symbols update
Christian Persch [Mon, 26 Apr 2010 01:07:26 +0000 (20:07 -0500)]
Add testcases for <range> and <choices>
Bug #616102.
Ryan Lortie [Mon, 26 Apr 2010 00:59:59 +0000 (19:59 -0500)]
Add range restriction to gschema-compiler
Patch from Christian Persch, with minor modifications.
Bug #616102
Ryan Lortie [Mon, 26 Apr 2010 00:10:44 +0000 (19:10 -0500)]
GVariant: add bind map for strings to byte arrays
Ryan Lortie [Mon, 26 Apr 2010 00:09:35 +0000 (19:09 -0500)]
Add g_variant_{new,get}_byte_array()
Now that strings are strictly utf8 this provides a convenient API for
storing non-utf8 string data.
Shaun McCance [Sat, 24 Apr 2010 02:08:27 +0000 (21:08 -0500)]
Make glib_compile_schemas point to a binary that exists
Ryan Lortie [Sun, 25 Apr 2010 18:36:36 +0000 (13:36 -0500)]
GVariant: strings are now utf8
- modify serialiser validation function to enforce utf8 encoding
- add documentation to g_variant_new_string(), g_variant_get_string(),
g_variant_dup_string()
- add 2 new test cases to check that it works
Tor Lillqvist [Sun, 25 Apr 2010 14:26:41 +0000 (17:26 +0300)]
Can't use stderr as a field name
Fran Diéguez [Sat, 24 Apr 2010 01:46:59 +0000 (03:46 +0200)]
Updated Galician translation
Matthias Clasen [Sat, 24 Apr 2010 00:50:27 +0000 (20:50 -0400)]
bump version
Matthias Clasen [Sat, 24 Apr 2010 00:49:02 +0000 (20:49 -0400)]
2.25.3
Matthias Clasen [Fri, 23 Apr 2010 23:57:14 +0000 (19:57 -0400)]
Rename in more places