Mercurial > hg-stable
changeset 26867:ad443e8d9334
hgweb: remove unused colorPart() from mercurial.js
Looks like the function wasn't ever used since its introduction in
0dba955c2636, since setColor() below always used "rgb(255, 255, 255)" notation
which doesn't need hex digits.
author | Anton Shestakov <av6@dwimlabs.net> |
---|---|
date | Sat, 24 Oct 2015 09:47:33 +0100 |
parents | 0f75461a9698 |
children | a2aa39a725a1 |
files | mercurial/templates/static/mercurial.js |
diffstat | 1 files changed, 0 insertions(+), 12 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/templates/static/mercurial.js Sun Oct 18 18:49:59 2015 +0200 +++ b/mercurial/templates/static/mercurial.js Sat Oct 24 09:47:33 2015 +0100 @@ -50,18 +50,6 @@ this.cell_height = this.box_size; } - function colorPart(num) { - num *= 255 - num = num < 0 ? 0 : num; - num = num > 255 ? 255 : num; - var digits = Math.round(num).toString(16); - if (num < 16) { - return '0' + digits; - } else { - return digits; - } - } - this.setColor = function(color, bg, fg) { // Set the colour.