1
0
mirror of https://github.com/gryf/wicd.git synced 2025-12-20 04:48:00 +01:00

Refactored networking.py to be more modular.

Added docstrings to wnettools.py
Fixed wired autoconnect bug due to missing parenthesis on a method call.
Moved connection monitoring code out of daemon.py and into monitor.py, which is run as a separate, child process of daemon.py, to reduce delays in dbus reponse time while connection status and autoreconnect code is running.
Added full support for running the gui without the tray icon using the --no-tray option.
Some minor changes to code to be more readable/efficient/pythonic.
This commit is contained in:
imdano
2008-03-09 22:09:22 +00:00
parent ae0dddb22d
commit 0653f3f40b
8 changed files with 807 additions and 618 deletions

View File

@@ -247,11 +247,10 @@ def get_gettext():
return _
def to_unicode(x):
""" Attempts to convert a string to unicode """
""" Attempts to convert a string to utf-8. """
try: # This may never fail, but let's be safe
default_encoding = locale.getpreferredencoding()
except:
print 'Could not get default encoding'
default_encoding = None
if default_encoding: