diff --git a/examples/edit.js b/examples/edit.js index 55b745a4e1..d778ff324d 100644 --- a/examples/edit.js +++ b/examples/edit.js @@ -260,6 +260,7 @@ var toolBar = (function () { cameraManager.disable(); } else { hasShownPropertiesTool = false; + cameraManager.enable(); entityListTool.setVisible(true); gridTool.setVisible(true); grid.setEnabled(true); @@ -669,11 +670,15 @@ function mouseMove(event) { lastMousePosition = { x: event.x, y: event.y }; + highlightEntityUnderCursor(lastMousePosition, false); idleMouseTimerId = Script.setTimeout(handleIdleMouse, IDLE_MOUSE_TIMEOUT); } function handleIdleMouse() { idleMouseTimerId = null; + if (isActive) { + highlightEntityUnderCursor(lastMousePosition, true); + } } function highlightEntityUnderCursor(position, accurateRay) { @@ -797,7 +802,6 @@ function mouseClickEvent(event) { selectionDisplay.select(selectedEntityID, event); if (Menu.isOptionChecked(MENU_AUTO_FOCUS_ON_SELECT)) { - cameraManager.enable(); cameraManager.focus(selectionManager.worldPosition, selectionManager.worldDimensions, Menu.isOptionChecked(MENU_EASE_ON_FOCUS)); @@ -1138,7 +1142,6 @@ Controller.keyReleaseEvent.connect(function (event) { } else if (event.text == "f") { if (isActive) { if (selectionManager.hasSelection()) { - cameraManager.enable(); cameraManager.focus(selectionManager.worldPosition, selectionManager.worldDimensions, Menu.isOptionChecked(MENU_EASE_ON_FOCUS)); diff --git a/examples/libraries/entityList.js b/examples/libraries/entityList.js index 3d6bf4d14f..66dc9f336f 100644 --- a/examples/libraries/entityList.js +++ b/examples/libraries/entityList.js @@ -49,7 +49,7 @@ EntityListTool = function(opts) { var selectedIDs = []; for (var i = 0; i < selectionManager.selections.length; i++) { - selectedIDs.push(selectionManager.selections[i].id); + selectedIDs.push(selectionManager.selections[i].id); // ? } var data = { @@ -70,7 +70,6 @@ EntityListTool = function(opts) { } selectionManager.setSelections(entityIDs); if (data.focus) { - cameraManager.enable(); cameraManager.focus(selectionManager.worldPosition, selectionManager.worldDimensions, Menu.isOptionChecked(MENU_EASE_ON_FOCUS));