-
-
Notifications
You must be signed in to change notification settings - Fork 169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
forwarding system tray #22
Comments
2011-09-10 19:33:06: lindi commented
|
2011-09-11 08:32:37: pmarek commented
|
As lindi pointed out, we can't afford to lose the connection to the dbus-daemon so each end will have to run its own daemon and need to be able to forward from one to the other. The dbus documentation is rather lacking, so is the dbus-python doc Finally, dbus needs to be started by something and I don't think that the xpra server should be responsible for that (then again, I may be biased as this is a large part of what winswitch does). Otherwise, you also have to start all the agents (ssh, gpg, ...) and parse some xdg directories.
xpra "--start-child=dbus-launch firefox" start :100
xpra --xvfb=Xvfb-dbus-wrapper ... The only problem with these two solutions is how the xpra server can then locate the dbus server instance to connect to.. (and this also applies when starting with " |
2011-09-26 08:35:22: lindi commented
|
A good start would be desktop notifications: org.freedesktop.Notifications and also here (openmoko) We need to "claim" this bus name (how we do that seems totally undocumented...) Then this can easily be tested with: import pynotify
pynotify.init("Test Notifications")
n = pynotify.Notification("Title", "message")
n.show() |
2011-09-30 11:30:18: lindi commented
|
Thanks, I just figured it out, I've got some code in progress that forwards it to to the other end via xpra + pynotify. |
2011-09-30 11:43:27: lindi commented
|
I ended up with code very similar to yours, but the signature is slightly different, here is the code I used to find the right values: import gobject
gobject.threads_init()
from dbus import glib
glib.init_threads()
import dbus
bus = dbus.SessionBus()
remote_object = bus.get_object("org.freedesktop.Notifications", "/org/freedesktop/Notifications")
print ("Introspection data:\n")
print remote_object.Introspect() |
If someone stumbles on here looking for the code to use for claiming a dbus name, it is in the: request = bus.request_name(BUS_NAME, dbus.bus.NAME_FLAG_REPLACE_EXISTING) flags may vary... |
Mostly done in r202 for *nix. This is using pynotify for now (quick and dirty), this whole area will need to be re-worked anyway when adding support for osx, win32, growl, appindicators, etc.. Also, still left to do:
|
2011-10-13 18:29:08: antoine commented
|
2011-10-14 10:07:45: antoine commented
|
2011-11-08 20:08:33: pmarek commented
|
2011-11-09 04:19:56: antoine commented
|
2011-11-09 08:11:14: pmarek commented
|
2011-11-09 11:35:01: antoine commented
|
2011-11-09 11:47:39: pmarek commented
|
2011-11-09 11:53:09: pmarek commented
|
2011-11-09 11:55:39: pmarek commented
|
2011-12-01 18:38:47: totaam commented
|
Never mind: import dbus has to be: import dbus.glib As the import has side effects... which make it all work. |
ability to use dbus.glib for forwarding notifications to the client in r323 Not sure how to tell the packagers about the update to the package's dependencies, I am updating my own build files.. |
Renaming this ticket to match the work that was done on it, and re-opening the dbus forwarding feature request under #450 |
Issue migrated from trac ticket # 22
component: server | priority: major | resolution: worksforme | keywords: dbus
2011-09-10 19:21:48: pmarek created the issue
The text was updated successfully, but these errors were encountered: