Fix enable delete on login

This commit is contained in:
Deon George 2020-07-05 22:02:06 +10:00
parent a713113df3
commit 6139db24d3
2 changed files with 13 additions and 11 deletions

View File

@ -352,6 +352,7 @@ Frame.prototype.parse = function(text) {
this.frame_fields.push({
ftype: fieldtype,
flength: fieldlen,
fchar: fieldchar,
r: r,
c: c,
attribute: {i:i,f:f,b:b},

19
main.js
View File

@ -43,7 +43,7 @@ while(bbs.online) {
if (action == false) {
read = console.inkey(K_NONE,inkey_timeout);
}
log(LOG_DEBUG,'READ: ['+read+']');
log(LOG_DEBUG,'READ: ['+read+'] ('+read.charCodeAt(0)+')');
inkey_timeout = 60000; // Set our key timeout to 60s
system.node_list[bbs.node_num-1].action=0xff; // to ensure our node status is updated correctly
@ -230,7 +230,7 @@ while(bbs.online) {
// End of field entry.
case '#':
case '\r':
log(LOG_DEBUG,'- MODE_FIELD:FRAME_TYPE_RESPONSE: ['+read+'] A');
log(LOG_DEBUG,'- MODE_FIELD:FRAME_TYPE_RESPONSE: ['+read+']');
// Next Field
fn++;
@ -250,20 +250,21 @@ while(bbs.online) {
break;
case '*':
log(LOG_DEBUG,'- MODE_FIELD:FRAME_TYPE_RESPONSE: ['+read+'] B');
log(LOG_DEBUG,'- MODE_FIELD:FRAME_TYPE_RESPONSE: ['+read+']');
//$current['prevmode'] = MODE_FIELD;
action = ACTION_STAR;
break;
case KEY_DEL:
log(LOG_DEBUG,'- MODE_FIELD:FRAME_TYPE_RESPONSE: ['+read+'] C');
/*
if ($this->fo->setFieldCurrentInputDelete())
$client->send(LEFT.$this->fo::$if_filler.LEFT);
// Delete Key pressed
case CTRL_H:
log(LOG_DEBUG,'- MODE_FIELD:FRAME_TYPE_RESPONSE: ['+read+']'+' cf:'+(cf ? cf.fvalue.length : '{}')+' ct:'+cf.ftype);
*/
if (cf.fvalue.length > 0) {
cf.fvalue = cf.fvalue.substring(0,cf.fvalue.length-1);
console.write(KEY_ESC+'[D'+cf.fchar+KEY_ESC+'[D');
}
break;