summaryrefslogtreecommitdiff
path: root/Base/home/anon/www
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2020-03-31 19:10:08 +0200
committerAndreas Kling <kling@serenityos.org>2020-03-31 19:10:08 +0200
commit839beb52f372c90ae258ae4a9496c5a854351be2 (patch)
tree1460918341095812fcd6c626d07f3d2b6935943f /Base/home/anon/www
parenta8dc6501de196a1e5c2c23c29bea59f99a1e8892 (diff)
downloadserenity-839beb52f372c90ae258ae4a9496c5a854351be2.zip
Base: Tweak the canvas demo page to stop using fractional RGB values
This is a hack to workaround missing support for fractional values in "rgb(r,g,b)" color parsing.
Diffstat (limited to 'Base/home/anon/www')
-rw-r--r--Base/home/anon/www/demo.html2
1 files changed, 1 insertions, 1 deletions
diff --git a/Base/home/anon/www/demo.html b/Base/home/anon/www/demo.html
index 8dce42375b..6fb53719e1 100644
--- a/Base/home/anon/www/demo.html
+++ b/Base/home/anon/www/demo.html
@@ -38,7 +38,7 @@ function update() {
var r = Math.random() * 255;
var g = Math.random() * 255;
var b = Math.random() * 255;
- var color = "rgb(" + r + "," + g + "," + b + ")";
+ var color = "rgb(" + ~~r + "," + ~~g + "," + ~~b + ")";
ctx.fillStyle = color;
const spread = 35;
var x = mouseX + (Math.random() * spread) - (spread / 2);