diff --git a/scripts/vr-edit/modules/toolIcon.js b/scripts/vr-edit/modules/toolIcon.js index c9f955ecf5..7aa116af81 100644 --- a/scripts/vr-edit/modules/toolIcon.js +++ b/scripts/vr-edit/modules/toolIcon.js @@ -17,10 +17,12 @@ ToolIcon = function (side) { var SCALE_TOOL = 0, CLONE_TOOL = 1, + GROUP_TOOL = 2, ICON_COLORS = [ { red: 0, green: 240, blue: 240 }, - { red: 240, green: 0, blue: 240 } + { red: 240, green: 0, blue: 240 }, + { red: 240, green: 240, blue: 0 } ], LEFT_HAND = 0, @@ -100,6 +102,7 @@ ToolIcon = function (side) { return { SCALE_TOOL: SCALE_TOOL, CLONE_TOOL: CLONE_TOOL, + GROUP_TOOL: GROUP_TOOL, setHand: setHand, update: update, display: display, diff --git a/scripts/vr-edit/modules/toolMenu.js b/scripts/vr-edit/modules/toolMenu.js index 87588105ae..3af6063646 100644 --- a/scripts/vr-edit/modules/toolMenu.js +++ b/scripts/vr-edit/modules/toolMenu.js @@ -86,6 +86,11 @@ ToolMenu = function (side, leftInputs, rightInputs, setToolCallback) { position: { x: 0.06, y: 0.02, z: 0.0 }, color: { red: 240, green: 0, blue: 240 }, callback: "clone" + }, + { // Group + position: { x: 0.10, y: 0.02, z: 0.0 }, + color: { red: 240, green: 240, blue: 0 }, + callback: "group" } ], diff --git a/scripts/vr-edit/vr-edit.js b/scripts/vr-edit/vr-edit.js index da945a2668..dcfa702c46 100644 --- a/scripts/vr-edit/vr-edit.js +++ b/scripts/vr-edit/vr-edit.js @@ -25,6 +25,7 @@ TOOL_NONE = 0, TOOL_SCALE = 1, TOOL_CLONE = 2, + TOOL_GROUP = 3, toolSelected = TOOL_NONE, // Primary objects @@ -261,6 +262,7 @@ clearToolIcon: clearToolIcon, SCALE_TOOL: toolIcon.SCALE_TOOL, CLONE_TOOL: toolIcon.CLONE_TOOL, + GROUP_TOOL: toolIcon.GROUP_TOOL, display: display, update: update, clear: clear, @@ -1062,6 +1064,10 @@ toolSelected = TOOL_CLONE; ui.setToolIcon(ui.CLONE_TOOL); break; + case "group": + toolSelected = TOOL_GROUP; + ui.setToolIcon(ui.GROUP_TOOL); + break; default: debug("ERROR: Unexpected condition in setTool()!"); } @@ -1110,6 +1116,9 @@ case TOOL_CLONE: ui.setToolIcon(ui.CLONE_TOOL); break; + case TOOL_GROUP: + ui.setToolIcon(ui.GROUP_TOOL); + break; } if (isAppActive) {