mercurial/hgweb/webcommands.py
changeset 9557 dbe2bdd5e488
parent 9198 061eeb602354
parent 9402 5d49fdef6fd0
child 10245 207b94f6b65d
child 10263 25e572394f5c
equal deleted inserted replaced
9556:6aece8fc7f3c 9557:dbe2bdd5e488
   234         files.append(tmpl(template,
   234         files.append(tmpl(template,
   235                           node=ctx.hex(), file=f,
   235                           node=ctx.hex(), file=f,
   236                           parity=parity.next()))
   236                           parity=parity.next()))
   237 
   237 
   238     parity = paritygen(web.stripecount)
   238     parity = paritygen(web.stripecount)
   239     diffs = webutil.diffs(web.repo, tmpl, ctx, None, parity)
   239     style = web.config('web', 'style', 'paper')
       
   240     if 'style' in req.form:
       
   241         style = req.form['style'][0]
       
   242 
       
   243     diffs = webutil.diffs(web.repo, tmpl, ctx, None, parity, style)
   240     return tmpl('changeset',
   244     return tmpl('changeset',
   241                 diff=diffs,
   245                 diff=diffs,
   242                 rev=ctx.rev(),
   246                 rev=ctx.rev(),
   243                 node=ctx.hex(),
   247                 node=ctx.hex(),
   244                 parent=webutil.parents(ctx),
   248                 parent=webutil.parents(ctx),
   472     else:
   476     else:
   473         n = ctx.node()
   477         n = ctx.node()
   474         # path already defined in except clause
   478         # path already defined in except clause
   475 
   479 
   476     parity = paritygen(web.stripecount)
   480     parity = paritygen(web.stripecount)
   477     diffs = webutil.diffs(web.repo, tmpl, fctx or ctx, [path], parity)
   481     style = web.config('web', 'style', 'paper')
       
   482     if 'style' in req.form:
       
   483         style = req.form['style'][0]
       
   484 
       
   485     diffs = webutil.diffs(web.repo, tmpl, fctx or ctx, [path], parity, style)
   478     rename = fctx and webutil.renamelink(fctx) or []
   486     rename = fctx and webutil.renamelink(fctx) or []
   479     ctx = fctx and fctx or ctx
   487     ctx = fctx and fctx or ctx
   480     return tmpl("filediff",
   488     return tmpl("filediff",
   481                 file=path,
   489                 file=path,
   482                 node=hex(n),
   490                 node=hex(n),