From: acid-burn Date: Thu, 11 Feb 2010 13:15:33 +0000 (+0100) Subject: NetworkWizard/NetworkWizard.py: * fix automatic interface selection if only one netwo... X-Git-Url: http://code.vuplus.com/gitweb/?p=vuplus_dvbapp;a=commitdiff_plain;h=30eb05e6ba834df51db97db306bfb1cab94c9b20 NetworkWizard/NetworkWizard.py: * fix automatic interface selection if only one network adapter is available in some situations. refs #218 --- diff --git a/lib/python/Plugins/SystemPlugins/NetworkWizard/NetworkWizard.py b/lib/python/Plugins/SystemPlugins/NetworkWizard/NetworkWizard.py index 150dba9..a8b34ac 100755 --- a/lib/python/Plugins/SystemPlugins/NetworkWizard/NetworkWizard.py +++ b/lib/python/Plugins/SystemPlugins/NetworkWizard/NetworkWizard.py @@ -104,6 +104,9 @@ class NetworkWizard(WizardLanguage, Rc): self.rescanTimer.stop() self.Adapterlist = iNetwork.getAdapterList() self.InstalledInterfaceCount = len(self.Adapterlist) + if self.Adapterlist is not None: + if self.InstalledInterfaceCount == 1 and self.selectedInterface is None: + self.selectedInterface = self.Adapterlist[0] self.originalAth0State = iNetwork.getAdapterAttribute('ath0', 'up') self.originalEth0State = iNetwork.getAdapterAttribute('eth0', 'up') self.originalWlan0State = iNetwork.getAdapterAttribute('wlan0', 'up')