Import canvas version from old ESPTerm repo
branch canvas, 0caadb6f412855052e4a3276a8411cc36166ea4a
This commit is contained in:
+8
-19
@@ -41,7 +41,12 @@
|
||||
<h1><!-- Screen title gets loaded here by JS --></h1>
|
||||
|
||||
<div id="term-wrap">
|
||||
<div id="screen" class="theme-%theme%"></div>
|
||||
<div id="screen" class="theme-%theme%">
|
||||
<input id="softkb-input" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false" />
|
||||
<div id="touch-select-menu">
|
||||
<button id="touch-select-copy-btn">Copy</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="action-buttons">
|
||||
<button data-n="1"></button><!--
|
||||
@@ -52,10 +57,9 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<textarea id="softkb-input" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"></textarea>
|
||||
|
||||
<nav id="term-nav">
|
||||
<a href="#" onclick="kbOpen(true);return false" class="mq-tablet-max"><i class="icn-keyboard"></i><span><?= tr('term_nav.keybd') ?></span></a><!--
|
||||
<a href="#" onclick="toggleFitScreen();return false" class="mq-tablet-max"><i id="resize-button-icon" class="icn-resize-small"></i></a><!--
|
||||
--><a href="#" onclick="kbOpen(true);return false" class="mq-tablet-max"><i class="icn-keyboard"></i><span><?= tr('term_nav.keybd') ?></span></a><!--
|
||||
--><a href="#" onclick="TermUpl.open();return false"><i class="icn-download"></i><span><?= tr('term_nav.upload') ?></span></a><!--
|
||||
--><a href="<?= url('cfg_term') ?>" class="x-term-conf-btn"><i class="icn-configure"></i><span><?= tr('term_nav.config') ?></span></a><!--
|
||||
--><a href="<?= url('cfg_wifi') ?>" class="x-term-conf-btn"><i class="icn-wifi"></i><span><?= tr('term_nav.wifi') ?></span></a><!--
|
||||
@@ -68,15 +72,6 @@
|
||||
window.noAutoShow = true;
|
||||
termInit(); // the screen will be loaded via ajax
|
||||
Screen.load('%j:labels_seq%');
|
||||
|
||||
// auto-clear the input box
|
||||
$('#softkb-input').on('input', function(e) {
|
||||
setTimeout(function(){
|
||||
var str = $('#softkb-input').val();
|
||||
$('#softkb-input').val('');
|
||||
Input.sendString(str);
|
||||
}, 1);
|
||||
});
|
||||
} catch(e) {
|
||||
console.error(e);
|
||||
console.error("Fail, reloading in 3s…");
|
||||
@@ -84,10 +79,4 @@
|
||||
location.reload(true);
|
||||
}, 3000);
|
||||
}
|
||||
|
||||
function kbOpen(yes) {
|
||||
var i = qs('#softkb-input');
|
||||
if (yes) i.focus();
|
||||
else i.blur();
|
||||
}
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user