1
0
mirror of https://github.com/gryf/wicd.git synced 2026-01-03 20:34:17 +01:00

experimental:

- Use gobject.timeout_add_seconds instead of gobject.timeout_add when possible
- Merge some fixes from pluggablebackends
- Replace os.system usage with subprocess.call.
This commit is contained in:
imdano
2008-09-13 11:28:36 +00:00
parent 97e1123c8c
commit bbfcae834e
4 changed files with 24 additions and 5 deletions

View File

@@ -289,7 +289,14 @@ def main():
"""
monitor = ConnectionStatus()
gobject.timeout_add(2500, monitor.update_connection_status)
if daemon.GetCurrentBackend() == "ioctl":
to_time = 2.5
else:
to_time = 4
try:
gobject.timeout_add_seconds(to_time, monitor.update_connection_status)
except:
gobject.timeout_add(to_time * 1000, monitor.update_connection_status)
mainloop = gobject.MainLoop()
mainloop.run()