Merge branch 'master' of deluge-torrent.org:deluge
This commit is contained in:
commit
44d3e2fa2f
|
@ -3,23 +3,23 @@
|
|||
<head>
|
||||
<title>Deluge: Web UI ${version}</title>
|
||||
|
||||
<link rel="shortcut icon" href="/icons/deluge.png" type="image/png" />
|
||||
<link rel="icon" href="/icons/deluge.png" type="image/png" />
|
||||
<link rel="shortcut icon" href="${base}icons/deluge.png" type="image/png" />
|
||||
<link rel="icon" href="${base}icons/deluge.png" type="image/png" />
|
||||
|
||||
<!-- Stylesheets -->
|
||||
% for stylesheet in stylesheets:
|
||||
<link rel="stylesheet" type="text/css" href="${stylesheet}" />
|
||||
<link rel="stylesheet" type="text/css" href="${base}${stylesheet}" />
|
||||
% endfor
|
||||
|
||||
<!-- Javascript -->
|
||||
% for script in scripts:
|
||||
<script type="text/javascript" src="${script}"></script>
|
||||
<script type="text/javascript" src="${base}${script}"></script>
|
||||
% endfor
|
||||
<script type="text/javascript">
|
||||
Deluge.debug = ${str(debug).lower()};
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div style="background-image: url('/themes/default/tree/loading.gif');"></div>
|
||||
<div style="background-image: url('${base}themes/default/tree/loading.gif');"></div>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -57,12 +57,13 @@ Ext.deluge.add.FileWindow = Ext.extend(Ext.deluge.add.Window, {
|
|||
this.form = this.add({
|
||||
xtype: 'form',
|
||||
baseCls: 'x-plain',
|
||||
labelWidth: 55,
|
||||
labelWidth: 35,
|
||||
autoHeight: true,
|
||||
fileUpload: true,
|
||||
items: [{
|
||||
xtype: 'fileuploadfield',
|
||||
id: 'torrentFile',
|
||||
width: 280,
|
||||
emptyText: _('Select a torrent'),
|
||||
fieldLabel: _('File'),
|
||||
name: 'file',
|
||||
|
|
|
@ -450,7 +450,6 @@ class TopLevel(resource.Resource):
|
|||
return resource.Resource.getChild(self, path, request)
|
||||
|
||||
def render(self, request):
|
||||
|
||||
debug = False
|
||||
if 'debug' in request.args:
|
||||
debug_arg = request.args.get('debug')[-1]
|
||||
|
@ -474,9 +473,10 @@ class TopLevel(resource.Resource):
|
|||
else:
|
||||
scripts = self.scripts[:]
|
||||
|
||||
base = request.args.get('base', [''])[-1]
|
||||
template = Template(filename=rpath("index.html"))
|
||||
request.setHeader("content-type", "text/html; charset=utf-8")
|
||||
return template.render(scripts=scripts, stylesheets=self.stylesheets, debug=debug)
|
||||
return template.render(scripts=scripts, stylesheets=self.stylesheets, debug=debug, base=base)
|
||||
|
||||
class ServerContextFactory:
|
||||
|
||||
|
|
Loading…
Reference in New Issue