diff options
-rw-r--r-- | pyload/__init__.py | 4 | ||||
-rw-r--r-- | pyload/config/Parser.py | 4 | ||||
-rw-r--r-- | pyload/manager/Addon.py | 2 | ||||
-rw-r--r-- | pyload/manager/Plugin.py | 2 | ||||
-rw-r--r-- | pyload/plugin/Plugin.py | 2 | ||||
-rw-r--r-- | pyload/webui/app/pyloadweb.py | 16 | ||||
-rw-r--r-- | pyload/webui/themes/Next/tml/base.html | 70 | ||||
-rw-r--r-- | pyload/webui/themes/Next/tml/captcha.html | 64 | ||||
-rw-r--r-- | pyload/webui/themes/Next/tml/filemanager.html | 48 | ||||
-rw-r--r-- | pyload/webui/themes/Next/tml/folder.html | 10 | ||||
-rw-r--r-- | pyload/webui/themes/Next/tml/home.html | 16 | ||||
-rw-r--r-- | pyload/webui/themes/Next/tml/pathchooser.html | 22 |
12 files changed, 130 insertions, 130 deletions
diff --git a/pyload/__init__.py b/pyload/__init__.py index 39f6c8bee..e29c81ad7 100644 --- a/pyload/__init__.py +++ b/pyload/__init__.py @@ -84,9 +84,9 @@ try: except IOError: if os.name == "posix": - configdir = os.path.join(homedir, ".pyload-beta") + configdir = os.path.join(homedir, ".pyload") else: - configdir = os.path.join(homedir, "pyload-beta") + configdir = os.path.join(homedir, "pyload") try: if not os.path.exists(configdir): diff --git a/pyload/config/Parser.py b/pyload/config/Parser.py index 84c08f17c..9682b38b6 100644 --- a/pyload/config/Parser.py +++ b/pyload/config/Parser.py @@ -300,8 +300,8 @@ class ConfigParser(object): if not name in plugins: print "delete config " + name del self.plugin[name] - - + + def getMetaData(self, section, option): """ get all config data for an option """ return self.config[section][option] diff --git a/pyload/manager/Addon.py b/pyload/manager/Addon.py index 0bd51c943..26a2735cf 100644 --- a/pyload/manager/Addon.py +++ b/pyload/manager/Addon.py @@ -110,7 +110,7 @@ class AddonManager(object): pluginClass = self.core.pluginManager.loadClass(type, pluginname) if not pluginClass: continue - + plugin = pluginClass(self.core, self) plugins.append(plugin) self.pluginMap[pluginClass.__name__] = plugin diff --git a/pyload/manager/Plugin.py b/pyload/manager/Plugin.py index 222ed9c93..739fa3538 100644 --- a/pyload/manager/Plugin.py +++ b/pyload/manager/Plugin.py @@ -55,7 +55,7 @@ class PluginManager(object): sys.path.append(abspath("")) self.loadTypes() - + configs = [] for type in self.TYPES: diff --git a/pyload/plugin/Plugin.py b/pyload/plugin/Plugin.py index 486dbeb0f..6a39507fd 100644 --- a/pyload/plugin/Plugin.py +++ b/pyload/plugin/Plugin.py @@ -88,7 +88,7 @@ class Base(object): def getPluginConfSection(self): - return "%s_%s" % (self.__class__.__name__, getattr(self, "_%s__type" % self.__class__.__name__)) + return "%s_%s" % (self.__class__.__name__, getattr(self, "_%s__type" % self.__class__.__name__)) #: Deprecated method diff --git a/pyload/webui/app/pyloadweb.py b/pyload/webui/app/pyloadweb.py index d71d0d306..85f3f8ca1 100644 --- a/pyload/webui/app/pyloadweb.py +++ b/pyload/webui/app/pyloadweb.py @@ -517,14 +517,14 @@ def info(): else: extra = tuple() - data = {"python": sys.version, - "os": " ".join((os.name, sys.platform) + extra), - "version": PYLOAD.getServerVersion(), - "folder": abspath(PYLOAD_DIR), "config": abspath(""), - "download": abspath(conf["general"]["download_folder"]["value"]), + data = {"python" : sys.version, + "os" : " ".join((os.name, sys.platform) + extra), + "version" : PYLOAD.getServerVersion(), + "folder" : abspath(PYLOAD_DIR), "config": abspath(""), + "download" : abspath(conf["general"]["download_folder"]["value"]), "freespace": formatSize(PYLOAD.freeSpace()), - "remote": conf["remote"]["port"]["value"], - "webif": conf["webinterface"]["port"]["value"], - "language": conf["general"]["language"]["value"]} + "remote" : conf["remote"]["port"]["value"], + "webif" : conf["webui"]["port"]["value"], + "language" : conf["general"]["language"]["value"]} return render_to_response("info.html", data, [pre_processor]) diff --git a/pyload/webui/themes/Next/tml/base.html b/pyload/webui/themes/Next/tml/base.html index 750c855be..1bc2ea3b3 100644 --- a/pyload/webui/themes/Next/tml/base.html +++ b/pyload/webui/themes/Next/tml/base.html @@ -54,13 +54,13 @@ - </ul> + </ul> {% else %} <span style="padding-right: 2px;">{{_("Please Login!")}}</span> {% endif %} {% endblock %} - </div> + </div> <nav class="navbar navbar-default"> <div class="container-fluid"> @@ -75,57 +75,57 @@ <a class="navbar-brand" href="#"><img id="head-logo" src="/img/pyload-logo.png" alt="pyLoad" style="height:30px;"/></a> </div> - <a href="/"></a> + <a href="/"></a> <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1"> <ul class="nav navbar-nav"> - + {% macro selected(name, right=False) -%} {% if name in url -%}class="{% if right -%}right {% endif %}selected"{%- endif %} {% if not name in url and right -%}class="right"{%- endif %} {%- endmacro %} - {% block menu %} - <li> - <a href="/" title=""><span class="glyphicon glyphicon-home"></span> {{_("Home")}}</a> - </li> - <li {{ selected('queue') }}> - <a href="/queue/" title=""><span class="glyphicon glyphicon-tasks"></span> {{_("Queue")}}</a> - </li> - <li {{ selected('collector') }}> - <a href="/collector/" title=""><span class="glyphicon glyphicon-magnet"></span> {{_("Collector")}}</a> - </li> - <li {{ selected('downloads') }}> - <a href="/downloads/" title=""> <span class="glyphicon glyphicon-download"></span> {{_("Downloads")}}</a> - </li> -{# <li {{ selected('filemanager') }}>#} -{# <a href="/filemanager/" title=""><span class="glyphicon glyphicon-magnet"></span> {{_("FileManager")}}</a>#} -{# </li>#} - <li {{ selected('logs', True) }}> - <a href="/logs/" class="action index" accesskey="x" rel="nofollow"><span class="glyphicon glyphicon-list"></span> {{_("Logs")}}</a> - </li> - <li {{ selected('settings', True) }}> - <a href="/settings/" class="action index" accesskey="x" rel="nofollow"><span class="glyphicon glyphicon-wrench"></span> {{_("Config")}}</a> - </li> - {% endblock %} + {% block menu %} + <li> + <a href="/" title=""><span class="glyphicon glyphicon-home"></span> {{_("Home")}}</a> + </li> + <li {{ selected('queue') }}> + <a href="/queue/" title=""><span class="glyphicon glyphicon-tasks"></span> {{_("Queue")}}</a> + </li> + <li {{ selected('collector') }}> + <a href="/collector/" title=""><span class="glyphicon glyphicon-magnet"></span> {{_("Collector")}}</a> + </li> + <li {{ selected('downloads') }}> + <a href="/downloads/" title=""> <span class="glyphicon glyphicon-download"></span> {{_("Downloads")}}</a> + </li> +{# <li {{ selected('filemanager') }}>#} +{# <a href="/filemanager/" title=""><span class="glyphicon glyphicon-magnet"></span> {{_("FileManager")}}</a>#} +{# </li>#} + <li {{ selected('logs', True) }}> + <a href="/logs/" class="action index" accesskey="x" rel="nofollow"><span class="glyphicon glyphicon-list"></span> {{_("Logs")}}</a> + </li> + <li {{ selected('settings', True) }}> + <a href="/settings/" class="action index" accesskey="x" rel="nofollow"><span class="glyphicon glyphicon-wrench"></span> {{_("Config")}}</a> + </li> + {% endblock %} </ul> <ul class="nav navbar-nav navbar-right"> <li><a href="/info" class="action info" rel="nofollow"><span class="glyphicon glyphicon-user"></span> {{user.name}}</a></li> - {% if user.is_admin %} - <li><a href="/admin" class="action profile" rel="nofollow"><span class="glyphicon glyphicon-cog"></span></a></li> - {% endif %} + {% if user.is_admin %} + <li><a href="/admin" class="action profile" rel="nofollow"><span class="glyphicon glyphicon-cog"></span></a></li> + {% endif %} <li><a href="/info" class="action info" rel="nofollow"><span class="glyphicon glyphicon-info-sign"></span></a></li> </ul> </div><!-- /.navbar-collapse --> </div><!-- /.container-fluid --> - - </div> + + </div> </nav> - <div style="clear:both;"></div> + <div style="clear:both;"></div> </div> {% if perms.STATUS %} @@ -167,7 +167,7 @@ {% block statusbar %} {% endblock %} {% for message in messages %} - <b><p>{{message}}</p></b> + <b><p>{{message}}</p></b> {% endfor %} <div id="load-indicator" style="opacity: 0; float: right; margin-top: -10px;"> @@ -178,7 +178,7 @@ {% block content %} {% endblock content %} - <hr style="clear: both;" /> + <hr style="clear: both;" /> <div id="foot" style="with: 98%; margin-left: 10px; margin-right:10px">© 2008-2011 pyLoad Team <a href="#top" class="action top" accesskey="x"><span>{{_("Back to top")}}</span></a><br /> diff --git a/pyload/webui/themes/Next/tml/captcha.html b/pyload/webui/themes/Next/tml/captcha.html index 5a5893b72..9602278b6 100644 --- a/pyload/webui/themes/Next/tml/captcha.html +++ b/pyload/webui/themes/Next/tml/captcha.html @@ -1,40 +1,40 @@ <!-- Captcha box --> <div id="cap_box" > - <form id="cap_form" class="form-group" action="/json/set_captcha" method="POST" enctype="multipart/form-data" onsubmit="return false;"> - - <h3>{{_("Captcha reading")}}</h3> - <p id="cap_title">{{_("Please read the text on the captcha.")}}</p> - - <div id="cap_textual"> - - <input id="cap_id" name="cap_id" type="hidden" value="" /> - + <form id="cap_form" class="form-group" action="/json/set_captcha" method="POST" enctype="multipart/form-data" onsubmit="return false;"> + + <h3>{{_("Captcha reading")}}</h3> + <p id="cap_title">{{_("Please read the text on the captcha.")}}</p> + + <div id="cap_textual"> + + <input id="cap_id" name="cap_id" type="hidden" value="" /> + <div class="form-group"> - <label>{{_("Captcha")}}</label> - <span ></br> - <img id="cap_textual_img" style="border: 1px solid #bbb; padding: 3px 3px 3px 3px;" src=""> - </span> + <label>{{_("Captcha")}}</label> + <span ></br> + <img id="cap_textual_img" style="border: 1px solid #bbb; padding: 3px 3px 3px 3px;" src=""> + </span> </div> <div class="form-group"> - <label>{{_("Text")}}</label> - <input class="form-control" id="cap_result" name="cap_result" type="text" size="20" /> - <p class="small">{{_("Input the text on the captcha.")}}</p> - </div> - - <div id="cap_positional" style="text-align: center"> - <img id="cap_positional_img" src="" style="margin: 10px; cursor:pointer"> - </div> - - <div id="button_bar" style="text-align: center"> - <span> - <button class="btn btn-primary" id="cap_submit" type="submit" style="float: right; margin-left: 5px;">{{_("Submit")}}</button> - <button class="btn btn-default" id="cap_reset" type="reset" style="float: right">{{_("Close")}}</button> - </span> - </div> - - <div class="spacer"></div> - - </form> + <label>{{_("Text")}}</label> + <input class="form-control" id="cap_result" name="cap_result" type="text" size="20" /> + <p class="small">{{_("Input the text on the captcha.")}}</p> + </div> + + <div id="cap_positional" style="text-align: center"> + <img id="cap_positional_img" src="" style="margin: 10px; cursor:pointer"> + </div> + + <div id="button_bar" style="text-align: center"> + <span> + <button class="btn btn-primary" id="cap_submit" type="submit" style="float: right; margin-left: 5px;">{{_("Submit")}}</button> + <button class="btn btn-default" id="cap_reset" type="reset" style="float: right">{{_("Close")}}</button> + </span> + </div> + + <div class="spacer"></div> + + </form> </div>
\ No newline at end of file diff --git a/pyload/webui/themes/Next/tml/filemanager.html b/pyload/webui/themes/Next/tml/filemanager.html index 9d3aded8f..c940f3f79 100644 --- a/pyload/webui/themes/Next/tml/filemanager.html +++ b/pyload/webui/themes/Next/tml/filemanager.html @@ -26,9 +26,9 @@ document.addEvent("domready", function(){ <span> <b>{{ file.name }}</b> <span class="buttons" style="opacity:0"> - <img title="{{_("Rename Directory")}}" class="rename" style="cursor: pointer" height="12px" src="/img/pencil.png" /> - - <img title="{{_("Delete Directory")}}" class="delete" style="margin-left: -10px; cursor: pointer" width="12px" height="12px" src="/img/delete.png" /> + <img title="{{_("Rename Directory")}}" class="rename" style="cursor: pointer" height="12px" src="/img/pencil.png" /> + + <img title="{{_("Delete Directory")}}" class="delete" style="margin-left: -10px; cursor: pointer" width="12px" height="12px" src="/img/delete.png" /> </span> </span> </li> @@ -39,30 +39,30 @@ document.addEvent("domready", function(){ <input type="hidden" name="path" class="path" value="{{ fld.path }}" /> <input type="hidden" name="name" class="name" value="{{ fld.name }}" /> <span> - <b>{{ fld.name }}</b> - <span class="buttons" style="opacity:0"> - <img title="{{_("Rename Directory")}}" class="rename" style="cursor: pointer" height="12px" src="/img/pencil.png" /> - - <img title="{{_("Delete Directory")}}" class="delete" style="margin-left: -10px; cursor: pointer" width="12px" height="12px" src="/img/delete.png" /> - - <img title="{{_("Add subdirectory")}}" class="mkdir" style="margin-left: -10px; cursor: pointer" width="12px" height="12px" src="/img/add_folder.png" /> - </span> + <b>{{ fld.name }}</b> + <span class="buttons" style="opacity:0"> + <img title="{{_("Rename Directory")}}" class="rename" style="cursor: pointer" height="12px" src="/img/pencil.png" /> + + <img title="{{_("Delete Directory")}}" class="delete" style="margin-left: -10px; cursor: pointer" width="12px" height="12px" src="/img/delete.png" /> + + <img title="{{_("Add subdirectory")}}" class="mkdir" style="margin-left: -10px; cursor: pointer" width="12px" height="12px" src="/img/add_folder.png" /> + </span> </span> {% if (fld.folders|length + fld.files|length) > 0 %} - {% if open %} - <ul> - {% else %} - <ul style="display:none"> - {% endif %} - {% for child in fld.folders %} - {{ display_folder(child) }} - {% endfor %} - {% for child in fld.files %} - {{ display_file(child) }} - {% endfor %} - </ul> + {% if open %} + <ul> + {% else %} + <ul style="display:none"> + {% endif %} + {% for child in fld.folders %} + {{ display_folder(child) }} + {% endfor %} + {% for child in fld.files %} + {{ display_file(child) }} + {% endfor %} + </ul> {% else %} - <div style="display:none">{{ _("Folder is empty") }}</div> + <div style="display:none">{{ _("Folder is empty") }}</div> {% endif %} </li> {%- endmacro %} diff --git a/pyload/webui/themes/Next/tml/folder.html b/pyload/webui/themes/Next/tml/folder.html index 9a87ffddc..4453e8c87 100644 --- a/pyload/webui/themes/Next/tml/folder.html +++ b/pyload/webui/themes/Next/tml/folder.html @@ -4,11 +4,11 @@ <span> <b>{{ name }}</b> <span class="buttons" style="opacity:0"> - <img title="{{_("Rename Directory")}}" class="rename" style="cursor: pointer" height="12px" src="/img/pencil.png" /> - - <img title="{{_("Delete Directory")}}" class="delete" style="margin-left: -10px; cursor: pointer" width="12px" height="12px" src="/img/delete.png" /> - - <img title="{{_("Add subdirectory")}}" class="mkdir" style="margin-left: -10px; cursor: pointer" width="12px" height="12px" src="/img/add_folder.png" /> + <img title="{{_("Rename Directory")}}" class="rename" style="cursor: pointer" height="12px" src="/img/pencil.png" /> + + <img title="{{_("Delete Directory")}}" class="delete" style="margin-left: -10px; cursor: pointer" width="12px" height="12px" src="/img/delete.png" /> + + <img title="{{_("Add subdirectory")}}" class="mkdir" style="margin-left: -10px; cursor: pointer" width="12px" height="12px" src="/img/add_folder.png" /> </span> </span> <div style="display:none">{{ _("Folder is empty") }}</div> diff --git a/pyload/webui/themes/Next/tml/home.html b/pyload/webui/themes/Next/tml/home.html index 57d442bd1..2ff1ad58b 100644 --- a/pyload/webui/themes/Next/tml/home.html +++ b/pyload/webui/themes/Next/tml/home.html @@ -7,21 +7,21 @@ var em; var operafix = (navigator.userAgent.toLowerCase().search("opera") >= 0); document.addEvent("domready", function(){ - em = new EntryManager(); + em = new EntryManager(); }); var EntryManager = new Class({ initialize: function(){ this.json = new Request.JSON({ - url: "json/links", + url: "json/links", secure: false, async: true, - onSuccess: this.update.bind(this), - initialDelay: 0, - delay: 2500, - limit: 30000 - }); - + onSuccess: this.update.bind(this), + initialDelay: 0, + delay: 2500, + limit: 30000 + }); + this.ids = [{% for link in content %} {% if forloop.last %} {{ link.id }} diff --git a/pyload/webui/themes/Next/tml/pathchooser.html b/pyload/webui/themes/Next/tml/pathchooser.html index 6dcc4314d..471ed868a 100644 --- a/pyload/webui/themes/Next/tml/pathchooser.html +++ b/pyload/webui/themes/Next/tml/pathchooser.html @@ -1,6 +1,6 @@ <html> <head> - <script class="javascript"> + <script class="javascript"> function chosen() { opener.ifield.value = document.forms[0].p.value; @@ -24,21 +24,21 @@ setValid(); } - </script> - <link rel="stylesheet" type="text/css" href="/css/pathchooser.css"/> + </script> + <link rel="stylesheet" type="text/css" href="/css/pathchooser.css"/> </head> <body{% if type == 'file' %}{% if not oldfile %} onload="setInvalid();"{% endif %}{% endif %}> <center> <div id="paths"> - <form method="get" action="?" onSubmit="chosen();" onReset="exit();"> - <input type="text" name="p" value="{{ oldfile|default(cwd) }}" size="60" onfocus="setValid();"> - <input type="submit" value="Ok" name="send"> - </form> + <form method="get" action="?" onSubmit="chosen();" onReset="exit();"> + <input type="text" name="p" value="{{ oldfile|default(cwd) }}" size="60" onfocus="setValid();"> + <input type="submit" value="Ok" name="send"> + </form> {% if type == 'folder' %} - <span class="path_abs_rel">{{_("Path")}}: <a href="{{ "/pathchooser" + cwd|path_make_absolute|quotepath }}"{% if absolute %} style="text-decoration: underline;"{% endif %}>{{_("absolute")}}</a> | <a href="{{ "/pathchooser/" + cwd|path_make_relative|quotepath }}"{% if not absolute %} style="text-decoration: underline;"{% endif %}>{{_("relative")}}</a></span> + <span class="path_abs_rel">{{_("Path")}}: <a href="{{ "/pathchooser" + cwd|path_make_absolute|quotepath }}"{% if absolute %} style="text-decoration: underline;"{% endif %}>{{_("absolute")}}</a> | <a href="{{ "/pathchooser/" + cwd|path_make_relative|quotepath }}"{% if not absolute %} style="text-decoration: underline;"{% endif %}>{{_("relative")}}</a></span> {% else %} - <span class="path_abs_rel">{{_("Path")}}: <a href="{{ "/filechooser/" + cwd|path_make_absolute|quotepath }}"{% if absolute %} style="text-decoration: underline;"{% endif %}>{{_("absolute")}}</a> | <a href="{{ "/filechooser/" + cwd|path_make_relative|quotepath }}"{% if not absolute %} style="text-decoration: underline;"{% endif %}>{{_("relative")}}</a></span> + <span class="path_abs_rel">{{_("Path")}}: <a href="{{ "/filechooser/" + cwd|path_make_absolute|quotepath }}"{% if absolute %} style="text-decoration: underline;"{% endif %}>{{_("absolute")}}</a> | <a href="{{ "/filechooser/" + cwd|path_make_relative|quotepath }}"{% if not absolute %} style="text-decoration: underline;"{% endif %}>{{_("relative")}}</a></span> {% endif %} </div> <table border="0" cellspacing="0" cellpadding="3"> @@ -48,13 +48,13 @@ <th>{{_("type")}}</th> <th>{{_("last modified")}}</th> </tr> - {% if parentdir %} + {% if parentdir %} <tr> <td colspan="4"> <a href="{% if type == 'folder' %}{{ "/pathchooser/" + parentdir|quotepath }}{% else %}{{ "/filechooser/" + parentdir|quotepath }}{% endif %}"><span class="parentdir">{{_("parent directory")}}</span></a> </td> </tr> - {% endif %} + {% endif %} {% for file in files %} <tr> {% if type == 'folder' %} |