From f81d7e5b59b8f49a80a41dfa4642870e9132a1f2 Mon Sep 17 00:00:00 2001 From: yyc12345 Date: Sat, 2 May 2020 15:10:08 +0800 Subject: [PATCH] lazy --- SuperScriptViewer/static/site.js | 8 ++++++-- SuperScriptViewer/templates/viewer.html | 5 ++--- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/SuperScriptViewer/static/site.js b/SuperScriptViewer/static/site.js index c201b66..c646a74 100644 --- a/SuperScriptViewer/static/site.js +++ b/SuperScriptViewer/static/site.js @@ -3,7 +3,6 @@ currentSettings = { "plink": true, "properties": true, "highlight": true, - "keyboard": true, "move": true }; $(document).ready(function () { @@ -70,7 +69,8 @@ function highlightLink(target) { } // double one-click, only cancel highlight and don't apply any hightlight - if (realTarget == previousHighlight) { + // or user disable hightlight + if ((realTarget == previousHighlight) || !currentSettings["highlight"]) { previousHighlight = ""; } else { //apply new highlight @@ -97,6 +97,10 @@ function highlightLink(target) { } function queryInfo(obj) { + // confirm user enable this function + if (!currentSettings["properties"]) + return; + $.post(window.location, { operation: "info", diff --git a/SuperScriptViewer/templates/viewer.html b/SuperScriptViewer/templates/viewer.html index cb8ab1a..787322c 100644 --- a/SuperScriptViewer/templates/viewer.html +++ b/SuperScriptViewer/templates/viewer.html @@ -9,7 +9,7 @@ - +
@@ -99,8 +99,7 @@

Action:
Interactive property inspector
Highlight focused object
- Use keyboard to move viewer
- Move objects + Move objects