diff options
| author | Stefan Pluecken <stefan.pluecken@multimedia-labs.de> | 2006-12-18 17:05:47 +0000 |
|---|---|---|
| committer | Stefan Pluecken <stefan.pluecken@multimedia-labs.de> | 2006-12-18 17:05:47 +0000 |
| commit | 7a6022a72e1729a029d2356f6425bb8b8bcf2454 (patch) | |
| tree | 9f2c5b7ed7d2e0c8af13b6be58ebd098a8205671 /lib | |
| parent | 1ffe12e9f2a7ebe19ecc6b3380e104ad31fc8717 (diff) | |
| download | enigma2-7a6022a72e1729a029d2356f6425bb8b8bcf2454.tar.gz enigma2-7a6022a72e1729a029d2356f6425bb8b8bcf2454.zip | |
don't allow leaving the software update plugin while ipkg is running
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/python/Components/Ipkg.py | 8 | ||||
| -rw-r--r-- | lib/python/Plugins/SystemPlugins/SoftwareUpdate/plugin.py | 9 |
2 files changed, 12 insertions, 5 deletions
diff --git a/lib/python/Components/Ipkg.py b/lib/python/Components/Ipkg.py index 25e19797..df700d6b 100644 --- a/lib/python/Components/Ipkg.py +++ b/lib/python/Components/Ipkg.py @@ -104,4 +104,10 @@ class Ipkg: self.callbackList.append(callback) def getFetchedList(self): - return self.fetchedList
\ No newline at end of file + return self.fetchedList + + def stop(self): + self.cmd.kill() + + def isRunning(self): + return self.cmd.running() diff --git a/lib/python/Plugins/SystemPlugins/SoftwareUpdate/plugin.py b/lib/python/Plugins/SystemPlugins/SoftwareUpdate/plugin.py index 19ab3eea..dc494e6f 100644 --- a/lib/python/Plugins/SystemPlugins/SoftwareUpdate/plugin.py +++ b/lib/python/Plugins/SystemPlugins/SoftwareUpdate/plugin.py @@ -327,10 +327,11 @@ class UpdatePlugin(Screen): pass def exit(self): - if self.packages != 0 and self.error == 0: - self.session.openWithCallback(self.exitAnswer, MessageBox, _("Upgrade finished. Do you want to reboot your Dreambox?")) - else: - self.close() + if not self.ipkg.isRunning(): + if self.packages != 0 and self.error == 0: + self.session.openWithCallback(self.exitAnswer, MessageBox, _("Upgrade finished. Do you want to reboot your Dreambox?")) + else: + self.close() def exitAnswer(self, result): if result is not None and result: |
