@@ -50,8+52,8 @@ class NetworkAdapterSelection(Screen,HelpableScreen):
Screen.__init__(self, session)
HelpableScreen.__init__(self)
Screen.__init__(self, session)
HelpableScreen.__init__(self)
- self.wlan_errortext = _("No working wireless networkadapter found.\nPlease verify that you have attached a compatible WLAN USB Stick and your Network is configured correctly.")
- self.lan_errortext = _("No working local networkadapter found.\nPlease verify that you have attached a network cable and your Network is configured correctly.")
+ self.wlan_errortext = _("No working wireless network adapter found.\nPlease verify that you have attached a compatible WLAN device and your network is configured correctly.")
+ self.lan_errortext = _("No working local network adapter found.\nPlease verify that you have attached a network cable and your network is configured correctly.")
self.oktext = _("Press OK on your remote control to continue.")
self.restartLanRef = None
self.oktext = _("Press OK on your remote control to continue.")
self.restartLanRef = None
@@ -62,23+64,23 @@ class NetworkAdapterSelection(Screen,HelpableScreen):
self.adapters = [(iNetwork.getFriendlyAdapterName(x),x) for x in iNetwork.getAdapterList()]
self.adapters = [(iNetwork.getFriendlyAdapterName(x),x) for x in iNetwork.getAdapterList()]
@@ -516,7+526,7 @@ class AdapterSetup(Screen, ConfigListScreen, HelpableScreen):
if self.iface == "wlan0" or self.iface == "ath0" :
if self["config"].getCurrent() == self.hiddenSSID:
if config.plugins.wlan.essid.value == 'hidden...':
if self.iface == "wlan0" or self.iface == "ath0" :
if self["config"].getCurrent() == self.hiddenSSID:
if config.plugins.wlan.essid.value == 'hidden...':
- self.session.openWithCallback(self.VirtualKeyBoardSSIDCallback, VirtualKeyBoard, title = (_("Enter WLAN networkname/SSID:")), text = config.plugins.wlan.essid.value)
+ self.session.openWithCallback(self.VirtualKeyBoardSSIDCallback, VirtualKeyBoard, title = (_("Enter WLAN networkname/SSID:")), text = config.plugins.wlan.essid.value)
if self["config"].getCurrent() == self.encryptionKey:
self.session.openWithCallback(self.VirtualKeyBoardKeyCallback, VirtualKeyBoard, title = (_("Enter WLAN passphrase/key:")), text = config.plugins.wlan.encryption.psk.value)
if self["config"].getCurrent() == self.encryptionKey:
self.session.openWithCallback(self.VirtualKeyBoardKeyCallback, VirtualKeyBoard, title = (_("Enter WLAN passphrase/key:")), text = config.plugins.wlan.encryption.psk.value)
@@ -600,7+610,7 @@ class AdapterSetup(Screen, ConfigListScreen, HelpableScreen):
- self.applyConfigRef = self.session.openWithCallback(self.applyConfigfinishedCB, MessageBox, _("Please wait while activating your network configuration..."), type = MessageBox.TYPE_INFO, enable_input = False)
+ self.applyConfigRef = self.session.openWithCallback(self.applyConfigfinishedCB, MessageBox, _("Please wait for activation of your network configuration..."), type = MessageBox.TYPE_INFO, enable_input = False)
else:
self.cancel()
else:
self.cancel()
@@ -616,10+626,10 @@ class AdapterSetup(Screen, ConfigListScreen, HelpableScreen):
- self.session.openWithCallback(self.secondIfaceFoundCB, MessageBox, _("Your network configuration has been activated.\nA second configured interface has been found.\n\nDo you want to disable the second networkinterface?"), default = True)
+ self.session.openWithCallback(self.secondIfaceFoundCB, MessageBox, _("Your network configuration has been activated.\nA second configured interface has been found.\n\nDo you want to disable the second networkinterface?"), default = True)
else:
if self.finished_cb:
else:
if self.finished_cb:
- self.session.openWithCallback(self.finished_cb, MessageBox, _("Your network configuration has been activated."), type = MessageBox.TYPE_INFO, timeout = 10)
+ self.session.openWithCallback(lambda x : self.finished_cb(), MessageBox, _("Your network configuration has been activated."), type = MessageBox.TYPE_INFO, timeout = 10)
else:
self.session.openWithCallback(self.ConfigfinishedCB, MessageBox, _("Your network configuration has been activated."), type = MessageBox.TYPE_INFO, timeout = 10)
else:
self.session.openWithCallback(self.ConfigfinishedCB, MessageBox, _("Your network configuration has been activated."), type = MessageBox.TYPE_INFO, timeout = 10)
@@ -642,15+652,10 @@ class AdapterSetup(Screen, ConfigListScreen, HelpableScreen):
@@ -670,8+675,7 @@ class AdapterSetup(Screen, ConfigListScreen, HelpableScreen):
def cleanup(self):
iNetwork.stopLinkStateConsole()
def cleanup(self):
iNetwork.stopLinkStateConsole()
- iNetwork.stopDeactivateInterfaceConsole()
-
+
class AdapterSetupConfiguration(Screen, HelpableScreen):
def __init__(self, session,iface):
class AdapterSetupConfiguration(Screen, HelpableScreen):
def __init__(self, session,iface):
@@ -695,7+699,7 @@ class AdapterSetupConfiguration(Screen, HelpableScreen):
self.oktext = _("Press OK on your remote control to continue.")
self.reboottext = _("Your Dreambox will restart after pressing OK on your remote control.")
self.oktext = _("Press OK on your remote control to continue.")
self.reboottext = _("Your Dreambox will restart after pressing OK on your remote control.")
- self.errortext = _("No working wireless interface found.\n Please verify that you have attached a compatible WLAN device or enable you local network interface.")
+ self.errortext = _("No working wireless network interface found.\n Please verify that you have attached a compatible WLAN device or enable your local network interface.")
@@ -727,7+731,7 @@ class AdapterSetupConfiguration(Screen, HelpableScreen):
"right": self.right,
}, -2)
"right": self.right,
}, -2)
- iNetwork.getInterfaces(self.updateStatusbar)
+ self.updateStatusbar()
self.onLayoutFinish.append(self.layoutFinished)
self.onClose.append(self.cleanup)
self.onLayoutFinish.append(self.layoutFinished)
self.onClose.append(self.cleanup)
@@ -820,7+824,7 @@ class AdapterSetupConfiguration(Screen, HelpableScreen):
if self["menulist"].getCurrent()[1] == 'dns':
self["description"].setText(_("Edit the Nameserver configuration of your Dreambox.\n" ) + self.oktext )
if self["menulist"].getCurrent()[1] == 'scanwlan':
if self["menulist"].getCurrent()[1] == 'dns':
self["description"].setText(_("Edit the Nameserver configuration of your Dreambox.\n" ) + self.oktext )
if self["menulist"].getCurrent()[1] == 'scanwlan':
- self["description"].setText(_("Scan your network for wireless Access Points and connect to them using your WLAN USB Stick\n" ) + self.oktext )
+ self["description"].setText(_("Scan your network for wireless Access Points and connect to them using your selected wireless device.\n" ) + self.oktext )
if self["menulist"].getCurrent()[1] == 'wlanstatus':
self["description"].setText(_("Shows the state of your wireless LAN connection.\n" ) + self.oktext )
if self["menulist"].getCurrent()[1] == 'lanrestart':
if self["menulist"].getCurrent()[1] == 'wlanstatus':
self["description"].setText(_("Shows the state of your wireless LAN connection.\n" ) + self.oktext )
if self["menulist"].getCurrent()[1] == 'lanrestart':
@@ -903,11+907,11 @@ class AdapterSetupConfiguration(Screen, HelpableScreen):
else:
self.mainmenu = self.genMainMenu()
self["menulist"].l.setList(self.mainmenu)
else:
self.mainmenu = self.genMainMenu()
self["menulist"].l.setList(self.mainmenu)
- iNetwork.getInterfaces(self.updateStatusbar)
+ self.updateStatusbar()
else:
self.mainmenu = self.genMainMenu()
self["menulist"].l.setList(self.mainmenu)
else:
self.mainmenu = self.genMainMenu()
self["menulist"].l.setList(self.mainmenu)
- iNetwork.getInterfaces(self.updateStatusbar)
+ self.updateStatusbar()
def WlanStatusClosed(self, *ret):
if ret is not None and len(ret):
def WlanStatusClosed(self, *ret):
if ret is not None and len(ret):
@@ -915,7+919,7 @@ class AdapterSetupConfiguration(Screen, HelpableScreen):
iStatus.stopWlanConsole()
self.mainmenu = self.genMainMenu()
self["menulist"].l.setList(self.mainmenu)
iStatus.stopWlanConsole()
self.mainmenu = self.genMainMenu()
self["menulist"].l.setList(self.mainmenu)
- iNetwork.getInterfaces(self.updateStatusbar)
+ self.updateStatusbar()
def WlanScanClosed(self,*ret):
if ret[0] is not None:
def WlanScanClosed(self,*ret):
if ret[0] is not None:
@@ -925,7+929,7 @@ class AdapterSetupConfiguration(Screen, HelpableScreen):
iStatus.stopWlanConsole()
self.mainmenu = self.genMainMenu()
self["menulist"].l.setList(self.mainmenu)
iStatus.stopWlanConsole()
self.mainmenu = self.genMainMenu()
self["menulist"].l.setList(self.mainmenu)
- iNetwork.getInterfaces(self.updateStatusbar)
+ self.updateStatusbar()
def restartLan(self, ret = False):
if (ret == True):
def restartLan(self, ret = False):
if (ret == True):
@@ -942,6+946,7 @@ class AdapterSetupConfiguration(Screen, HelpableScreen):
def restartfinishedCB(self,data):
if data is True:
def restartfinishedCB(self,data):
if data is True:
+ self.updateStatusbar()
self.session.open(MessageBox, _("Finished restarting your network"), type = MessageBox.TYPE_INFO, timeout = 10, default = False)
def dataAvail(self,data):
self.session.open(MessageBox, _("Finished restarting your network"), type = MessageBox.TYPE_INFO, timeout = 10, default = False)
def dataAvail(self,data):
@@ -950,9+955,9 @@ class AdapterSetupConfiguration(Screen, HelpableScreen):
pattern = re_compile("Link detected: yes")
for item in result:
if re_search(pattern, item):
pattern = re_compile("Link detected: yes")
for item in result:
if re_search(pattern, item):
- self["statuspic"].setPixmapNum(1)
- else:
self["statuspic"].setPixmapNum(0)
self["statuspic"].setPixmapNum(0)
+ else:
+ self["statuspic"].setPixmapNum(1)
self["statuspic"].show()
def showErrorMessage(self):
self["statuspic"].show()
def showErrorMessage(self):
@@ -983,7+988,6 @@ class NetworkAdapterTest(Screen):