Bug 27618 - add TP_CONNECTION_FEATURE_CAPABILITIES
Summary: add TP_CONNECTION_FEATURE_CAPABILITIES
Status: RESOLVED FIXED
Alias: None
Product: Telepathy
Classification: Unclassified
Component: tp-glib (show other bugs)
Version: git master
Hardware: Other All
: medium enhancement
Assignee: Guillaume Desmottes
QA Contact: Telepathy bugs list
URL: http://git.collabora.co.uk/?p=user/ca...
Whiteboard: review+
Keywords: patch
Depends on: 27511
Blocks: 21332
  Show dependency treegraph
 
Reported: 2010-04-13 06:18 UTC by Guillaume Desmottes
Modified: 2010-04-14 05:56 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Guillaume Desmottes 2010-04-13 06:18:17 UTC
From bug #27511

"""
* You should be able to ask the Connection for its RequestableChannelClasses,
as a Capabilities object (this is a feature in the sense of Bug #21097, IMO -
perhaps TP_CONNECTION_FEATURE_CAPABILITIES)
"""
Comment 1 Guillaume Desmottes 2010-04-13 08:06:16 UTC
http://git.collabora.co.uk/?p=user/cassidy/telepathy-glib;a=shortlog;h=refs/heads/conn-caps-27618

This is based on my capabilities branch so bug #27511 should be reviewed first.
Comment 2 Simon McVittie 2010-04-13 08:24:07 UTC
> +  PROP_CAPABILIES,

That's not how you spell capabilities.

> +   * The %TP_CAPABILITIES object representing the capabilities of this

The #TpCapabilities object ...

> +   * To wait for a valid capabilities, call tp_proxy_prepare_async() with

To wait for valid capability information, ...

> +  self->priv->capabilities = _tp_capabilities_new (g_value_get_boxed (value),

You need to check that the GValue contains the right boxed type first. If it doesn't, consider the connection to have no capabilities, or make the capabilities feature fail, or something.
Comment 3 Guillaume Desmottes 2010-04-14 02:26:21 UTC
(In reply to comment #2)
> > +  PROP_CAPABILIES,
> 
> That's not how you spell capabilities.

Oops; fixed.

> > +   * The %TP_CAPABILITIES object representing the capabilities of this
> 
> The #TpCapabilities object ...

done.

> > +   * To wait for a valid capabilities, call tp_proxy_prepare_async() with
> 
> To wait for valid capability information, ...

fixed.

> > +  self->priv->capabilities = _tp_capabilities_new (g_value_get_boxed (value),
> 
> You need to check that the GValue contains the right boxed type first. If it
> doesn't, consider the connection to have no capabilities, or make the
> capabilities feature fail, or something.

Done.
Comment 4 Simon McVittie 2010-04-14 04:45:34 UTC
Looks good to me.
Comment 5 Guillaume Desmottes 2010-04-14 05:56:48 UTC
Merged. Will be in 0.11.3


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.