View difference between Paste ID: f9cewNg0 and riE1SnQx
SHOW: | | - or go back to the newest paste.
1-
function displayCanvas() {
1+
    if (isNaN(chas) || isNaN(mins)) {
2-
    var chas = +document.getElementById("hours").value;
2+
        alert("Руки бы поломать таким");
3-
    var mins = +document.getElementById("minutes").value;
3+
4-
    var canvasHTML = document.getElementById('myCanvas');
4+
5-
    var contextHTML = canvasHTML.getContext('2d');
5+
    if (chas > 24 || mins > 24) {
6-
    contextHTML.strokeRect(0, 0, canvasHTML.width, canvasHTML.height);
6+
        alert("Руки бы поломать таким");
7-
 
7+
8-
    //Расчет координат центра и радиуса часов
8+
    }