Add option for /media instead of /hdd to allow accessing ALL external Memory Devices
authorStephan Reichholf <sreichholf@users.schwerkraft.elitedvb.net>
Thu, 19 Feb 2009 19:45:17 +0000 (19:45 +0000)
committerStephan Reichholf <sreichholf@users.schwerkraft.elitedvb.net>
Thu, 19 Feb 2009 19:45:17 +0000 (19:45 +0000)
webinterface/src/WebChilds/Toplevel.py
webinterface/src/WebIfConfig.py
webinterface/src/plugin.py

index 623432d..0d17817 100755 (executable)
@@ -29,9 +29,9 @@ class Toplevel(resource.Resource):
         self.putChild("upload",UploadResource())
         self.putChild("servicelist",ServiceList(self.session))
         self.putChild("streamcurrent",RedirecToCurrentStreamResource(session))
-
-        if config.plugins.Webinterface.includehdd.value is True:
-            self.putChild("hdd",static.File("/hdd"))
+            
+        if config.plugins.Webinterface.includemedia.value is True:
+            self.putChild("media",static.File("/media"))
 
     def render(self, req):
         fp = open(util.sibpath(WebInterface.__file__, "web-data/tpl/default")+"/index.html")
index f4a43d5..3db68a8 100644 (file)
@@ -83,7 +83,7 @@ class WebIfConfigScreen(ConfigListScreen,Screen):
         Screen.__init__(self, session)
         self.list = []
         self.list.append(getConfigListEntry(_("Start Webinterface"), config.plugins.Webinterface.enable))
-        self.list.append(getConfigListEntry(_("Enable /hdd"), config.plugins.Webinterface.includehdd))
+        self.list.append(getConfigListEntry(_("Enable /media"), config.plugins.Webinterface.includemedia))
         self.list.append(getConfigListEntry(_("Allow zapping via Webinterface"), config.plugins.Webinterface.allowzapping))
         self.list.append(getConfigListEntry(_("Autowrite timer"), config.plugins.Webinterface.autowritetimer))
         self.list.append(getConfigListEntry(_("Load movie-length"), config.plugins.Webinterface.loadmovielength))
@@ -302,5 +302,5 @@ class WebIfInterfaceConfigScreen(Screen, ConfigListScreen):
         config.plugins.Webinterface.interfaces.save()
         config.plugins.Webinterface.interfacecount.value = config.plugins.Webinterface.interfacecount.value - 1;
         config.plugins.Webinterface.interfacecount.save()
-        config.save()
+        config.plugins.Webinterface.save()
         self.close()
\ No newline at end of file
index f6c6b3e..f3c85b1 100644 (file)
@@ -27,7 +27,7 @@ DEBUGFILE= "/tmp/twisted.log"
 config.plugins.Webinterface = ConfigSubsection()
 config.plugins.Webinterface.enable = ConfigYesNo(default = True)
 config.plugins.Webinterface.allowzapping = ConfigYesNo(default = True)
-config.plugins.Webinterface.includehdd = ConfigYesNo(default = False)
+config.plugins.Webinterface.includemedia = ConfigYesNo(default = False)
 config.plugins.Webinterface.autowritetimer = ConfigYesNo(default = False)
 config.plugins.Webinterface.loadmovielength = ConfigYesNo(default = False)
 config.plugins.Webinterface.version = ConfigText(__version__) # used to make the versioninfo accessible enigma2-wide, not confgurable in GUI.