diff options
author | Marcel Holtmann <marcel@holtmann.org> | 2008-03-14 21:49:50 +0000 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2008-03-14 21:49:50 +0000 |
commit | d8edaa380cac107763805e3a9afcf5ac24879403 (patch) | |
tree | 684aedf3fdb35be18cb9240f2d3f2dc92817f8a3 | |
parent | b4fcae17e8a9f6242b752bfb9808248cadbde43b (diff) |
Fix style for strings and print
-rwxr-xr-x | hcid/simple-agent | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/hcid/simple-agent b/hcid/simple-agent index bdb35cfc..cd906b2d 100755 --- a/hcid/simple-agent +++ b/hcid/simple-agent @@ -10,25 +10,26 @@ class Agent(dbus.service.Object): @dbus.service.method("org.bluez.Agent", in_signature='', out_signature='') def Release(self): - print("Release") + print 'Release' mainloop.quit() @dbus.service.method("org.bluez.Agent", in_signature='o', out_signature='s') def RequestPasskey(self, device): - print("RequestPasskey (" + device + ")") - return "1234" + print 'RequestPasskey (' + device + ')' + return '1234' @dbus.service.method("org.bluez.Agent", in_signature='s', out_signature='') def ConfirmModeChange(self, mode): - print("ConfirmModeChange (" + mode + ")") + print 'ConfirmModeChange (' + mode + ')' return @dbus.service.method("org.bluez.Agent", in_signature='', out_signature='') def Cancel(self): - print("Cancel") + print 'Cancel' + return if __name__ == '__main__': dbus.mainloop.glib.DBusGMainLoop(set_as_default=True) @@ -40,14 +41,14 @@ if __name__ == '__main__': adapter = dbus.Interface(bus.get_object('org.bluez', path), 'org.bluez.Adapter') - path = "/test/agent" + path = '/test/agent' object = Agent(bus, path) adapter.RegisterAgent(path) - print("Agent registered") + print 'Agent registered' mainloop = gobject.MainLoop() mainloop.run() #adapter.UnregisterAgent(path) - #print("Agent unregistered") + #print 'Agent unregistered' |