X-Git-Url: https://git.cweiske.de/enigma2.git/blobdiff_plain/e25c93ddcc6a2c73b413fced441624703901e22d..eca375cca394a4f593cb45e8fa7534620b157aec:/lib/python/Components/FileList.py diff --git a/lib/python/Components/FileList.py b/lib/python/Components/FileList.py index 3091436f..09756e3c 100644 --- a/lib/python/Components/FileList.py +++ b/lib/python/Components/FileList.py @@ -190,3 +190,16 @@ class FileList(MenuList, HTMLComponent, GUIComponent): def postWidgetCreate(self, instance): instance.setContent(self.l) + + def execBegin(self): + harddiskmanager.on_partition_list_change.append(self.partitionListChanged) + + def execEnd(self): + harddiskmanager.on_partition_list_change.remove(self.partitionListChanged) + + def refresh(self): + self.changeDir(self.current_directory, self.getFilename()) + + def partitionListChanged(self, action, device): + if self.current_directory is None: + self.refresh()