From 22741543395d26e4377537df57f3a645cad6cd33 Mon Sep 17 00:00:00 2001 From: jmoenig Date: Wed, 15 Jul 2020 09:20:05 +0200 Subject: [PATCH] made keyboard handler (more) invisible thanks, @bromagosa, for the settings! --- HISTORY.md | 3 +++ snap.html | 2 +- src/morphic.js | 10 ++++++---- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/HISTORY.md b/HISTORY.md index 85c35ed5..0b1b8f0f 100755 --- a/HISTORY.md +++ b/HISTORY.md @@ -2,6 +2,9 @@ ## in development: +### 2020-07-15 +* morphic: made keyboard handler (more) invisible, thanks, Bernat! + ### 2020-07-13 * paint, symbols: new iconic buttons for grow, shrink and flip actions, thanks, Jadga! * sketch: tweaked layout to match the paint editor's diff --git a/snap.html b/snap.html index 99f5f5f7..3418a7b9 100755 --- a/snap.html +++ b/snap.html @@ -4,7 +4,7 @@ Snap! Build Your Own Blocks 6.0.1 - dev - - + diff --git a/src/morphic.js b/src/morphic.js index 7d2dd9be..00de3a01 100644 --- a/src/morphic.js +++ b/src/morphic.js @@ -1268,7 +1268,7 @@ /*global window, HTMLCanvasElement, FileReader, Audio, FileList, Map*/ -var morphicVersion = '2020-July-10'; +var morphicVersion = '2020-July-15'; var modules = {}; // keep track of additional loaded modules var useBlurredShadows = true; @@ -11909,11 +11909,13 @@ WorldMorph.prototype.initKeyboardHandler = function () { kbd = document.createElement('textarea'); kbd.setAttribute('id', 'morphic_keyboard'); kbd.setAttribute('style', 'caret-color:transparent;'); + kbd.style.position = 'absolute'; + kbd.style.overflow = "hidden"; + kbd.style.border = 'none'; + kbd.style.resize = 'none'; + kbd.wrap = "off"; kbd.world = this; kbd.style.zIndex = -1; - kbd.style.position = 'absolute'; - kbd.wrap = "off"; - kbd.style.overflow = "hidden"; kbd.autofocus = true; document.body.appendChild(kbd); this.keyboardHandler = kbd;