dbus/python/examples example-signal-emitter.py, 1.4,
1.5 example-signal-recipient.py, 1.4, 1.5
John Palmieri
johnp at freedesktop.org
Mon May 23 17:21:10 PDT 2005
- Previous message: dbus/python Makefile.am, 1.11, 1.12 _dbus.py, 1.3, 1.4 decorators.py,
1.1, 1.2 matchrules.py, NONE, 1.1
- Next message: dbus ChangeLog,1.776,1.777
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvs/dbus/dbus/python/examples
In directory gabe:/tmp/cvs-serv31356/python/examples
Modified Files:
example-signal-emitter.py example-signal-recipient.py
Log Message:
* python/decorators.py: import dbus_bindings
* python/matchrules.py (SignalMatchRule, SignalMatchTree,
SignalMatchNode): new classes that implement wildcard signal
callback matching using a tree lookup. Heavily modified from a
patch sent by Celso Pinto (fd.o bug #3241)
* _dbus.py (add_signal_receiver, remove_signal_receiver, _signal_func):
use new match classes to handle signals.
Index: example-signal-emitter.py
===================================================================
RCS file: /cvs/dbus/dbus/python/examples/example-signal-emitter.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- example-signal-emitter.py 1 May 2005 19:34:58 -0000 1.4
+++ example-signal-emitter.py 24 May 2005 00:21:07 -0000 1.5
@@ -10,15 +10,15 @@
@dbus.signal('org.designfu.TestService')
def HelloSignal(self, message):
# The signal is emitted when this method exits
- # You can have code here if you wish
+ # You can have code here if you wish
pass
@dbus.method('org.designfu.TestService')
def emitHelloSignal(self):
#you emit signals by calling the signal's skeleton method
- self.HelloSignal("Hello")
- return "Signal emitted"
-
+ self.HelloSignal("Hello")
+ return "Signal emitted"
+
session_bus = dbus.SessionBus()
service = dbus.Service("org.designfu.TestService", bus=session_bus)
object = TestObject(service)
Index: example-signal-recipient.py
===================================================================
RCS file: /cvs/dbus/dbus/python/examples/example-signal-recipient.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- example-signal-recipient.py 1 May 2005 19:34:58 -0000 1.4
+++ example-signal-recipient.py 24 May 2005 00:21:07 -0000 1.5
@@ -12,8 +12,8 @@
def emit_signal():
#call the emitHelloSignal method async
- object.emitHelloSignal(dbus_interface="org.designfu.TestService",
- reply_handler = handle_reply, error_handler = handle_error)
+ object.emitHelloSignal(dbus_interface="org.designfu.TestService")
+ #reply_handler = handle_reply, error_handler = handle_error)
return True
bus = dbus.SessionBus()
- Previous message: dbus/python Makefile.am, 1.11, 1.12 _dbus.py, 1.3, 1.4 decorators.py,
1.1, 1.2 matchrules.py, NONE, 1.1
- Next message: dbus ChangeLog,1.776,1.777
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the dbus-commit
mailing list