summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2010-10-26 16:42:52 +0200
committerGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2010-10-26 16:42:52 +0200
commit9f1e50de4a446d6661fb6b89f058c8f2fd319e68 (patch)
tree7baf47b107fb8a9d145009319707afa1023255de
parentprocess renice (diff)
downloadpyload-9f1e50de4a446d6661fb6b89f058c8f2fd319e68.tar.xz
closed #166, #169, #173, #174
-rw-r--r--module/plugins/hooks/UnRar.py2
-rw-r--r--module/plugins/hoster/MegauploadCom.py10
-rw-r--r--module/pyunrar.py1
-rw-r--r--module/web/media/default/css/window.css2
-rw-r--r--module/web/templates/default/base.html1
-rw-r--r--module/web/templates/default/window.html2
6 files changed, 11 insertions, 7 deletions
diff --git a/module/plugins/hooks/UnRar.py b/module/plugins/hooks/UnRar.py
index f47c08e89..46b9aac6a 100644
--- a/module/plugins/hooks/UnRar.py
+++ b/module/plugins/hooks/UnRar.py
@@ -35,7 +35,7 @@ class UnRar(Hook):
__config__ = [ ("activated", "bool", "Activated", False),
("fullpath", "bool", "extract full path", True),
("overwrite", "bool", "overwrite files", True),
- ("passwordfile", "str", "unrar passoword file", "unrar_passwords.txt"),
+ ("passwordfile", "str", "unrar password file", "unrar_passwords.txt"),
("deletearchive", "bool", "delete archives when done", False),
("ramwarning", "bool", "warn about low ram", True),
("renice", "int", "Cpu Priority", 10)]
diff --git a/module/plugins/hoster/MegauploadCom.py b/module/plugins/hoster/MegauploadCom.py
index 48ca4f920..1cc3c7aaf 100644
--- a/module/plugins/hoster/MegauploadCom.py
+++ b/module/plugins/hoster/MegauploadCom.py
@@ -7,6 +7,8 @@ from module.plugins.Hoster import Hoster
from module.network.Request import getURL
+from module.unescape import unescape
+
def getInfo(urls):
url = "http://megaupload.com/mgr_linkcheck.php"
@@ -19,7 +21,7 @@ def getInfo(urls):
i += 1
api = getURL(url, {}, post)
- api = [x.split("&") for x in re.split(r"&?(?=id[\d]+=)", api)]
+ api = [re.split(r"&(?!amp;|#\d+;)", x) for x in re.split(r"&?(?=id[\d]+=)", api)]
result = []
i=0
@@ -35,7 +37,7 @@ def getInfo(urls):
else:
status = 3
- name = tmp[3][1]
+ name = unescape(tmp[3][1])
size = tmp[1][1]
result.append( (name, size, status, urls[i] ) )
@@ -137,7 +139,7 @@ class MegauploadCom(Hoster):
api = self.load(url, {}, post)
self.log.debug("MU API: %s" % api)
- api = [x.split("&") for x in re.split(r"&?(?=id[\d]+=)", api)]
+ api = [re.split(r"&(?!amp;|#\d+;)", x) for x in re.split(r"&?(?=id[\d]+=)", api)]
for data in api:
if data[0].startswith("id"):
@@ -145,7 +147,7 @@ class MegauploadCom(Hoster):
if tmp[0][1] == "1":
self.offline()
- name = tmp[3][1]
+ name = unescape(tmp[3][1])
#size = tmp[1][1]
self.api["name"] = name
diff --git a/module/pyunrar.py b/module/pyunrar.py
index 01dc40a75..a01cb633a 100644
--- a/module/pyunrar.py
+++ b/module/pyunrar.py
@@ -94,6 +94,7 @@ class Unrar():
self.encrypted = None
self.headerEncrypted = None
self.smallestFiles = None
+ self.biggestFiles = {"size" : 0}
self.password = None
if not tmpdir:
self.tmpdir = mkdtemp()
diff --git a/module/web/media/default/css/window.css b/module/web/media/default/css/window.css
index dfe62a1f3..8b13ab798 100644
--- a/module/web/media/default/css/window.css
+++ b/module/web/media/default/css/window.css
@@ -7,7 +7,7 @@
left:50%;
top:150px;
margin-left: -350px;
- position: absolute;
+ position: fixed;
background: #FFF;
display:none;
}
diff --git a/module/web/templates/default/base.html b/module/web/templates/default/base.html
index 43699d770..8cd44615d 100644
--- a/module/web/templates/default/base.html
+++ b/module/web/templates/default/base.html
@@ -128,6 +128,7 @@ function bg_hide(){
function show(){
bg_show();
+ $("add_form").reset();
$("add_box").setStyle('display', 'block');
add_box.start('opacity',1)
}
diff --git a/module/web/templates/default/window.html b/module/web/templates/default/window.html
index 3ed79f876..3613c6df7 100644
--- a/module/web/templates/default/window.html
+++ b/module/web/templates/default/window.html
@@ -1,6 +1,6 @@
{% load i18n %}
<iframe id="upload_target" name="upload_target" src="" style="display: none; width:0;height:0"></iframe>
-<div id="add_bg" style="filter:alpha(opacity:80);KHTMLOpacity:0.80;MozOpacity:0.80;opacity:0.80; background:#000; width:100%; height: 100%; position:absolute; top:0px; left:0px; display:none;">&nbsp;</div>
+<div id="add_bg" style="filter:alpha(opacity:80);KHTMLOpacity:0.80;MozOpacity:0.80;opacity:0.80; background:#000; width:100%; height: 100%; position:fixed; top:0; left:0; display:none;">&nbsp;</div>
<!--<div id="add_box" style="left:50%; top:200px; margin-left: -450px; width: 900px; position: absolute; background: #FFF; padding: 10px 10px 10px 10px; display:none;">-->
<!--<div style="width: 900px; text-align: right;"><b onclick="AddBox();">[Close]</b></div>-->