Adding missed file, add password prompt and instructions.
This commit is contained in:
19
attic/jotblk/.gcloudignore
Normal file
19
attic/jotblk/.gcloudignore
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
# This file specifies files that are *not* uploaded to Google Cloud
|
||||||
|
# using gcloud. It follows the same syntax as .gitignore, with the addition of
|
||||||
|
# "#!include" directives (which insert the entries of the given .gitignore-style
|
||||||
|
# file at that point).
|
||||||
|
#
|
||||||
|
# For more information, run:
|
||||||
|
# $ gcloud topic gcloudignore
|
||||||
|
#
|
||||||
|
.gcloudignore
|
||||||
|
# If you would like to upload your .git directory, .gitignore file or files
|
||||||
|
# from your .gitignore file, remove the corresponding line
|
||||||
|
# below:
|
||||||
|
.git
|
||||||
|
.gitignore
|
||||||
|
|
||||||
|
# Python pycache:
|
||||||
|
__pycache__/
|
||||||
|
# Ignored by the build system
|
||||||
|
/setup.cfg
|
||||||
@ -18,3 +18,5 @@ And separately (to run a webserver on http://localhost:8080):
|
|||||||
```
|
```
|
||||||
./run.sh
|
./run.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Before use, type password. Default is: xyzzy
|
||||||
|
|||||||
@ -184,26 +184,34 @@ function Update() {
|
|||||||
ctx.textBaseline = 'middle';
|
ctx.textBaseline = 'middle';
|
||||||
ctx.save();
|
ctx.save();
|
||||||
ctx.scale(canvas.width / 64 , canvas.height / 17);
|
ctx.scale(canvas.width / 64 , canvas.height / 17);
|
||||||
|
ctx.fillStyle = '#750';
|
||||||
|
if (window.onkeydown === Login) {
|
||||||
|
ctx.fillRect(10, 0, 1, 1);
|
||||||
|
} else {
|
||||||
for (var j = 0; j < 16; ++j) {
|
for (var j = 0; j < 16; ++j) {
|
||||||
for (var i = 0; i < 64; ++i) {
|
for (var i = 0; i < 64; ++i) {
|
||||||
if (pos === i + j * 64) {
|
if (pos === i + j * 64) {
|
||||||
ctx.fillStyle = '#750';
|
|
||||||
ctx.fillRect(i, j, 1, 1);
|
ctx.fillRect(i, j, 1, 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
ctx.save();
|
ctx.save();
|
||||||
var m = ctx.measureText('W');
|
var m = ctx.measureText('W');
|
||||||
var w = m.width;
|
var w = m.width;
|
||||||
var h = m.fontBoundingBoxAscent + m.fontBoundingBoxDescent;
|
var h = m.fontBoundingBoxAscent + m.fontBoundingBoxDescent;
|
||||||
ctx.scale(1 / w, 1 / h);
|
ctx.scale(1 / w, 1 / h);
|
||||||
|
ctx.fillStyle = '#fb0';
|
||||||
|
if (window.onkeydown === Login) {
|
||||||
|
ctx.fillText('password:', 0.5 * w * 9, 0.5 * h);
|
||||||
|
} else {
|
||||||
for (var j = 0; j < 16; ++j) {
|
for (var j = 0; j < 16; ++j) {
|
||||||
for (var i = 0; i < 64; ++i) {
|
for (var i = 0; i < 64; ++i) {
|
||||||
var ch = String.fromCharCode(blocks[i + j * 64 + scr * 1024]);
|
var ch = String.fromCharCode(blocks[i + j * 64 + scr * 1024]);
|
||||||
ctx.fillStyle = '#fb0';
|
|
||||||
ctx.fillText(ch, (i + 0.5) * w, (j + 0.5) * h);
|
ctx.fillText(ch, (i + 0.5) * w, (j + 0.5) * h);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
ctx.fillStyle = '#750';
|
ctx.fillStyle = '#750';
|
||||||
ctx.textAlign = 'right';
|
ctx.textAlign = 'right';
|
||||||
var info = '';
|
var info = '';
|
||||||
|
|||||||
Reference in New Issue
Block a user