chore : fix jshint errors "thanks" to caret version range from grunt-contrib-jshint

This commit is contained in:
jdescottes 2016-01-16 15:28:28 +01:00
parent cd8d5c0b52
commit 73b165ef0c
2 changed files with 13 additions and 13 deletions

View File

@ -9,6 +9,15 @@
var TRANSPARENT_COLOR = 'rgba(0, 0, 0, 0)';
var componentToHex = function (c) {
var hex = c.toString(16);
return hex.length == 1 ? '0' + hex : hex;
};
var rgbToHex = function (r, g, b) {
return '#' + componentToHex(r) + componentToHex(g) + componentToHex(b);
};
var toHexString_ = function(color) {
if (color === TRANSPARENT_COLOR) {
return color;
@ -25,15 +34,6 @@
}
};
var rgbToHex = function (r, g, b) {
return '#' + componentToHex(r) + componentToHex(g) + componentToHex(b);
};
var componentToHex = function (c) {
var hex = c.toString(16);
return hex.length == 1 ? '0' + hex : hex;
};
var getFrameColors = function (frame) {
var frameColors = {};
for (var x = 0 ; x < frame.length ; x++) {

View File

@ -24,15 +24,15 @@
}
};
var rgbToHex = function (r, g, b) {
return '#' + componentToHex(r) + componentToHex(g) + componentToHex(b);
};
var componentToHex = function (c) {
var hex = c.toString(16);
return hex.length == 1 ? '0' + hex : hex;
};
var rgbToHex = function (r, g, b) {
return '#' + componentToHex(r) + componentToHex(g) + componentToHex(b);
};
var imageDataToGrid = function (imageData, width, height, transparent) {
// Draw the zoomed-up pixels to a different canvas context
var grid = [];