X-Git-Url: https://git.cweiske.de/enigma2.git/blobdiff_plain/f47d06efc863945909f6095eae5d88c755168fd6..1e1c01fece5a4a86a762af265e382da5dbb2d8cb:/lib/python/Components/Harddisk.py diff --git a/lib/python/Components/Harddisk.py b/lib/python/Components/Harddisk.py index a6389770..ca77e56f 100644 --- a/lib/python/Components/Harddisk.py +++ b/lib/python/Components/Harddisk.py @@ -103,7 +103,8 @@ class Harddisk: def unmount(self): cmd = "/bin/umount " + self.devidex + "part*" - os.system(cmd) + res = os.system(cmd) + return (res >> 8) def createPartition(self): cmd = "/sbin/sfdisk -f " + self.devidex + "disc" @@ -123,9 +124,11 @@ class Harddisk: return (res >> 8) def createMovieFolder(self): - res = os.system("mkdir /hdd/movie") + res = os.system("mkdir /hdd/movies") return (res >> 8) + errorList = [ _("Everything is fine"), _("Creating partition failed"), _("Mkfs failed"), _("Mount failed"), _("Create movie folder failed"), _("Unmount failed")] + def initialize(self): self.unmount() @@ -169,6 +172,12 @@ class HarddiskManager: if hddNum > 8: break + def HDDCount(self): + cnt = 0 + for hd in self.hdd: + cnt = cnt + 1 + return cnt + def HDDList(self): list = [ ] for hd in self.hdd: