Le Wed, 18 Feb 2009 17:04:29 +1100, Jiri Baum <[email protected]> a écrit :
> Hello, > > I'm trying to use one-to-one D-Tubes in python. I've got them working > (the objects can call and signal each other) but Empathy puts up an > error message saying that it wasn't handled. I asked on the > #telepathy, and smcv and wjt told me that for the time being, I have > to do an Empathy-specific thing, with the proper interface coming in > MC5. > > As far as I can tell, this should be the EmpathyTubeHandler, which > appears in the python-empathy library as empathy.TubeHandler; > however, when I try to instantiate that class, I get: > NotImplementedError: empathy.TubeHandler is an abstract widget I don't know what is empathy.TubeHandler. Maybe an Empathy developper can reply here? > I also tried requesting the name > "org.gnome.Empathy.DTubeHandler.%s"%SERVICE from D-Bus; that looks > like it's close to the right thing, because when the tube arrives, > Empathy falls over (mostly because I don't have any real object > attached there). You just need to have a real object attached on there and implement the D-Bus method HandleTube on the D-Bus interface org.gnome.Empathy.TubeHandler. Empathy will call this D-Bus method. An example in Python using 1-1 tubes with Empathy can be found here: - receiving and accepting the tube offer: http://git.collabora.co.uk/?p=user/alban/rhythmbox.git;a=blob;f=plugins/rb-tp-import/rb-tp-import/__init__.py;hb=refs/heads/telepathy This example uses stream tube but you can adapt for a D-Bus tube. Maybe what I do manually in this rhythmbox plugin can be done with empathy.TubeHandler? I was not aware of empathy.TubeHandler. My plugin does not import anything from empathy. > Google finds very little in the way of either documentation or code... Sorry, there is no documentation for that :-( > What am I doing wrong, please? Is there a function in python-empathy > that I should be calling? Example code that I should be copying? > Documentation that I should be reading? > > > The code I'm using is: http://www.baum.com.au/~jiri/tubes/example.py > and my understanding: > http://www.baum.com.au/~jiri/tubes/tubes-howto.html > > Jiri -- Alban _______________________________________________ telepathy mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/telepathy
