[Bug 48210] Could TpBaseChannel be more flexible?

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Wed May 30 15:26:02 CEST 2012


https://bugs.freedesktop.org/show_bug.cgi?id=48210

--- Comment #4 from Simon McVittie <simon.mcvittie at collabora.co.uk> 2012-05-30 06:26:02 PDT ---
(In reply to comment #0)
> GabbleMucChannel is a TpBaseChannel subclass. To support this "disappearing and
> reappearing" feature, some more functions will need to be added to
> TpBaseChannel:
> 
> > void tp_base_channel_unregister (TpBaseChannel *chan);
> 
> This removes the channel from the bus. It does not emit Close and does not set
> TpExportableChannel:channel-destroyed.

Is there actually a use-case for this, bearing in mind that a disappearing
channel that had previously appeared should always emit Closed?

I think if anything, what you want is a way to emulate closing, not immediately
respawn, unregister from D-Bus, but not be destroyed by the channel manager. So
the two-way decision the channel manager currently makes when a channel closes:

* channel-destroyed?
  - if yes, free it
  - if no, respawn it

becomes a tristate:

* channel-destroyed?
  - if yes, free it
  - if no, channel-respawning? (new property, reopened() would set this TRUE)
    - if yes, emit NewChannel
    - if no, do nothing special

disappear() would set channel-destroyed = channel-respawning = FALSE, then emit
::closed (to get Closed and ChannelClosed), and only then unregister.

I'm not really sure that I see the use-case for disappear(), though?

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA Contact for the bug.
You are the assignee for the bug.



More information about the telepathy-bugs mailing list