[Python-apps-commits] r2619 - in packages/wicd/trunk/debian (3 files)
hanska-guest at users.alioth.debian.org
hanska-guest at users.alioth.debian.org
Sun Mar 15 23:11:19 UTC 2009
Date: Sunday, March 15, 2009 @ 23:11:18
Author: hanska-guest
Revision: 2619
09-fix_wire_plugging_detection.patch, added, thanks to Giuseppe
Martino (Closes: #503738)
Added:
packages/wicd/trunk/debian/patches/09-fix_wire_plugging_detection.patch
Modified:
packages/wicd/trunk/debian/changelog
packages/wicd/trunk/debian/patches/series
Modified: packages/wicd/trunk/debian/changelog
===================================================================
--- packages/wicd/trunk/debian/changelog 2009-03-15 23:04:20 UTC (rev 2618)
+++ packages/wicd/trunk/debian/changelog 2009-03-15 23:11:18 UTC (rev 2619)
@@ -3,8 +3,10 @@
* debian/patches/:
- 08-fix_GetIP.patch added, thanks to Giuseppe Martino
(Closes: #519433)
+ - 09-fix_wire_plugging_detection.patch, added, thanks to Giuseppe
+ Martino (Closes: #503738)
- -- David Paleino <d.paleino at gmail.com> Mon, 16 Mar 2009 00:03:30 +0100
+ -- David Paleino <d.paleino at gmail.com> Mon, 16 Mar 2009 00:10:41 +0100
wicd (1.5.9-4) unstable; urgency=low
Added: packages/wicd/trunk/debian/patches/09-fix_wire_plugging_detection.patch
===================================================================
--- packages/wicd/trunk/debian/patches/09-fix_wire_plugging_detection.patch (rev 0)
+++ packages/wicd/trunk/debian/patches/09-fix_wire_plugging_detection.patch 2009-03-15 23:11:18 UTC (rev 2619)
@@ -0,0 +1,55 @@
+Fix detection of wire plugging/unplugging.
+Patch provided by Giuseppe Martino <denever at truelite.it>, thank you!
+---
+ wicd/monitor.py | 11 +++++++++++
+ wicd/wicd-daemon.py | 12 ++++++++++++
+ 2 files changed, 23 insertions(+)
+
+--- wicd-1.5.9.orig/wicd/monitor.py
++++ wicd-1.5.9/wicd/monitor.py
+@@ -64,6 +64,7 @@ class ConnectionStatus(object):
+ self.last_reconnect_time = time.time()
+ self.signal_changed = False
+ self.iwconfig = ""
++ self.plugged = False
+
+ def check_for_wired_connection(self, wired_ip):
+ """ Checks for an active wired connection.
+@@ -160,6 +161,16 @@ class ConnectionStatus(object):
+
+ # Check for wired.
+ wired_ip = wired.GetWiredIP()
++
++ if wired_ip is None:
++ if not self.plugged and wired.CheckPluggedIn():
++ daemon.SendWirePluggedSignal()
++ self.plugged = True
++
++ if self.plugged and not wired.CheckPluggedIn():
++ daemon.SendWireUnpluggedSignal()
++ self.plugged = False
++
+ wired_found = self.check_for_wired_connection(wired_ip)
+ if wired_found:
+ self.update_state(misc.WIRED, wired_ip=wired_ip)
+--- wicd-1.5.9.orig/wicd/wicd-daemon.py
++++ wicd-1.5.9/wicd/wicd-daemon.py
+@@ -669,6 +669,18 @@ class ConnectionWizard(dbus.service.Obje
+
+ @dbus.service.method('org.wicd.daemon')
+ @dbus.service.signal(dbus_interface='org.wicd.daemon', signature='')
++ def SendWirePluggedSignal(self):
++ """ Emits a signal announcing wire is plugged. """
++ pass
++
++ @dbus.service.method('org.wicd.daemon')
++ @dbus.service.signal(dbus_interface='org.wicd.daemon', signature='')
++ def SendWireUnpluggedSignal(self):
++ """ Emits a signal announcing wire is unplugged. """
++ pass
++
++ @dbus.service.method('org.wicd.daemon')
++ @dbus.service.signal(dbus_interface='org.wicd.daemon', signature='')
+ def SendStartScanSignal(self):
+ """ Emits a signal announcing a scan has started. """
+ pass
Modified: packages/wicd/trunk/debian/patches/series
===================================================================
--- packages/wicd/trunk/debian/patches/series 2009-03-15 23:04:20 UTC (rev 2618)
+++ packages/wicd/trunk/debian/patches/series 2009-03-15 23:11:18 UTC (rev 2619)
@@ -6,3 +6,4 @@
06-add_LC_MESSAGES_parsing.patch
07-add_resolvconf_support.patch
08-fix_GetIP.patch
+09-fix_wire_plugging_detection.patch
More information about the Python-apps-commits
mailing list