Changed the onclick handlers for Keyboard CLICKCODES to let updateFocus() scroll the canvas into view as needed, because (at least on iOS) the code that tries prevent the page from scrolling has an annoying "jerking" side-effect; also fixed the old Node web server code that would install onclick handlers for disk images, triggering automatic conversion of JSON to IMG files

This commit is contained in:
Jeff Parsons 2017-06-26 11:05:01 -07:00 committed by Jeff Parsons
commit 7ca8fa18a1
12 changed files with 19 additions and 18 deletions

View file

@ -715,7 +715,7 @@ HTTPAPI.processDumpAPI = function(req, res)
if (sDisk.indexOf("..") < 0 || req.app.settings.port == 8088) {
sFormat = req.query[DumpAPI.QUERY.FORMAT] || DumpAPI.FORMAT.JSON;
fComments = (req.query[DumpAPI.QUERY.COMMENTS]? true : false);
fComments = !!req.query[DumpAPI.QUERY.COMMENTS];
var sSize = req.query[DumpAPI.QUERY.MBHD];
if (sSize) {
sSize = (sSize * 1000).toString();
@ -751,7 +751,7 @@ HTTPAPI.processDumpAPI = function(req, res)
if (sFile.indexOf("..") < 0 || req.app.settings.port == 8088) {
sFormat = req.query[DumpAPI.QUERY.FORMAT] || DumpAPI.FORMAT.JSON;
fComments = (req.query[DumpAPI.QUERY.COMMENTS]? true : false);
fComments = !!req.query[DumpAPI.QUERY.COMMENTS];
var fDecimal;
if (req.query[DumpAPI.QUERY.DECIMAL]) {
fDecimal = (req.query[DumpAPI.QUERY.DECIMAL] == "true");
@ -793,7 +793,7 @@ HTTPAPI.dumpDisk = function(err, disk, res)
sAttachment = path.basename(disk.sDiskPath);
var i = sAttachment.lastIndexOf('.');
if (i > 0) sAttachment = sAttachment.substring(0, i+1) + DumpAPI.FORMAT.IMG;
sResponse = disk.convertToIMG();
sResponse = disk.convertToIMG(true);
} else {
// res.charset = "utf-8";
sMIMEType = "application/json; charset=utf-8";