Bug 27860 - Document that observers can be used to implement non-interactive approvers
Summary: Document that observers can be used to implement non-interactive approvers
Alias: None
Product: Telepathy
Classification: Unclassified
Component: tp-spec (show other bugs)
Version: git master
Hardware: Other All
: medium normal
Assignee: Telepathy bugs list
QA Contact: Telepathy bugs list
URL: http://git.collabora.co.uk/?p=user/jo...
Whiteboard: review+
Keywords: patch
Depends on:
Reported: 2010-04-27 06:44 UTC by Will Thompson
Modified: 2011-02-01 00:17 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Note You need to log in before you can comment on or make changes to this bug.
Description Will Thompson 2010-04-27 06:44:54 UTC
So it turns out that you can implement non-interactive approvers (for instance, to shoot down spam IM channels before the tray icon blinks at the user, or to grab a SASL channel before the user is prompted for a password) as observers, as follows:

• When ObserveChannels() is called,
• Call Claim() on the CDO;
• Then return from ObserveChannels();
• and then Claim will return successfully if you claimed the channels, and failure if someone else got there first.

This should be documented somewhere.
Comment 1 Simon McVittie 2011-01-03 04:40:24 UTC
I think such pseudo-approvers SHOULD have DelayApprovers=TRUE (from Bug #32267).
Comment 2 Jonny Lamb 2011-01-03 07:50:17 UTC
Here you go. I commented out the DelayApprovers=TRUE bit because it's not merged yet.
Comment 3 Simon McVittie 2011-01-03 09:12:08 UTC
Looks good.
Comment 4 Jonny Lamb 2011-02-01 00:17:56 UTC
Oops, not sure why I hadn't merged this. Done now.

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.