dbus/python/examples example-service.py, 1.13, 1.14 gconf-proxy-service.py, 1.5, 1.6 gconf-proxy-service2.py, 1.4, 1.5

Robert McQueen robot101 at freedesktop.org
Sat Oct 29 15:04:03 PDT 2005


Update of /cvs/dbus/dbus/python/examples
In directory gabe:/tmp/cvs-serv13394/python/examples

Modified Files:
	example-service.py gconf-proxy-service.py 
	gconf-proxy-service2.py 
Log Message:
2005-10-29  Robert McQueen  <robot101 at debian.org>

        * python/dbus_bindings.pyx: Tweak 'raise AssertionError' to assert().
        Add checking for the end of struct character when marshalling a
        struct in MessageIter.append_strict.

        * python/examples/example-service.py,
        python/examples/gconf-proxy-service.py,
        python/examples/gconf-proxy-service2.py: Update to use gobject
        mainloop directly rather than appearing to depend on gtk.

        * python/test/test-client.py, python/test/test-server.py: Remove
        obsolete and broken test scripts for old bindings. We have up to date
        and working tests in test/python/.


Index: example-service.py
===================================================================
RCS file: /cvs/dbus/dbus/python/examples/example-service.py,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- example-service.py	15 Jul 2005 18:09:59 -0000	1.13
+++ example-service.py	29 Oct 2005 22:04:01 -0000	1.14
@@ -3,8 +3,7 @@
 import dbus
 import dbus.service
 import dbus.glib
-import pygtk
-import gtk
+import gobject
 
 class SomeObject(dbus.service.Object):
     def __init__(self, bus_name, object_path="/SomeObject"):
@@ -27,4 +26,5 @@
 name = dbus.service.BusName("org.designfu.SampleService", bus=session_bus)
 object = SomeObject(name)
 
-gtk.main()
+mainloop = gobject.MainLoop()
+mainloop.run()

Index: gconf-proxy-service.py
===================================================================
RCS file: /cvs/dbus/dbus/python/examples/gconf-proxy-service.py,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- gconf-proxy-service.py	12 Jul 2005 18:16:07 -0000	1.5
+++ gconf-proxy-service.py	29 Oct 2005 22:04:01 -0000	1.6
@@ -2,7 +2,7 @@
 #FIXME: Doesn't work with the new bindings
 import dbus
 
-import gtk
+import gobject
 import gconf
 
 class GConfService(dbus.Service):
@@ -39,4 +39,5 @@
 print ("GConf Proxy service started.")
 print ("Run 'gconf-proxy-client.py' to fetch a GConf key through the proxy...")
 
-gtk.main()
+mainloop = gobject.MainLoop()
+mainloop.run()

Index: gconf-proxy-service2.py
===================================================================
RCS file: /cvs/dbus/dbus/python/examples/gconf-proxy-service2.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- gconf-proxy-service2.py	12 Jul 2005 18:16:07 -0000	1.4
+++ gconf-proxy-service2.py	29 Oct 2005 22:04:01 -0000	1.5
@@ -2,7 +2,7 @@
 #FIXME: doesn't work with the new bindings
 import dbus
 
-import gtk
+import gobject
 import gconf
 
 class GConfService(dbus.Service):
@@ -35,4 +35,5 @@
 print ("GConf Proxy service started.")
 print ("Run 'gconf-proxy-client.py' to fetch a GConf key through the proxy...")
 
-gtk.main()
+mainloop = gobject.MainLoop()
+mainloop.run()



More information about the dbus-commit mailing list