From d6b217730bff25e826059eaa2dcb9bdf19ff389d Mon Sep 17 00:00:00 2001 From: oc Date: Fri, 18 May 2018 09:48:41 +0800 Subject: [PATCH] PGUP change floor --- _server/editor.js | 23 +++++++++++++++++++++++ 更新说明.txt | 8 +++----- 2 files changed, 26 insertions(+), 5 deletions(-) diff --git a/_server/editor.js b/_server/editor.js index 7f9d1fca..d2a6b517 100644 --- a/_server/editor.js +++ b/_server/editor.js @@ -542,6 +542,29 @@ editor.prototype.listen = function () { currDrawData = JSON.parse(JSON.stringify(reDo)); reDo = null; } + // PGUP和PGDOWN切换楼层 + if (e.keyCode==33) { + e.preventDefault(); + var index=editor.core.floorIds.indexOf(editor.currentFloorId); + if (index>0) { + var toId = editor.core.floorIds[index-1]; + editor_mode.onmode('nextChange'); + editor_mode.onmode('floor'); + document.getElementById('selectFloor').value = toId; + editor.changeFloor(toId); + } + } + if (e.keyCode==34) { + e.preventDefault(); + var index=editor.core.floorIds.indexOf(editor.currentFloorId); + if (index