mirror of
https://github.com/overte-org/overte.git
synced 2025-08-10 13:07:04 +02:00
change location of menu item Create Entities As Grabbable
This commit is contained in:
parent
06b3b84145
commit
e295ab2778
1 changed files with 13 additions and 16 deletions
|
@ -213,6 +213,8 @@ function hideMarketplace() {
|
||||||
// }
|
// }
|
||||||
|
|
||||||
var TOOLS_PATH = Script.resolvePath("assets/images/tools/");
|
var TOOLS_PATH = Script.resolvePath("assets/images/tools/");
|
||||||
|
var GRABBABLE_ENTITIES_MENU_CATEGORY = "Edit";
|
||||||
|
var GRABBABLE_ENTITIES_MENU_ITEM = "Create Entities As Grabbable";
|
||||||
|
|
||||||
var toolBar = (function () {
|
var toolBar = (function () {
|
||||||
var EDIT_SETTING = "io.highfidelity.isEditting"; // for communication with other scripts
|
var EDIT_SETTING = "io.highfidelity.isEditting"; // for communication with other scripts
|
||||||
|
@ -222,21 +224,6 @@ var toolBar = (function () {
|
||||||
systemToolbar = null,
|
systemToolbar = null,
|
||||||
tablet = null;
|
tablet = null;
|
||||||
|
|
||||||
// add a menu item for setting newly created entities as grabbable
|
|
||||||
var GRABBABLE_ENTITIES_MENU_CATEGORY = "Developer";
|
|
||||||
var GRABBABLE_ENTITIES_MENU_ITEM = "Create Entities As Grabbable";
|
|
||||||
|
|
||||||
if (Menu.menuExists(GRABBABLE_ENTITIES_MENU_CATEGORY) &&
|
|
||||||
!Menu.menuItemExists(GRABBABLE_ENTITIES_MENU_CATEGORY, GRABBABLE_ENTITIES_MENU_ITEM)) {
|
|
||||||
Menu.addMenuItem({
|
|
||||||
menuName: GRABBABLE_ENTITIES_MENU_CATEGORY,
|
|
||||||
menuItemName: GRABBABLE_ENTITIES_MENU_ITEM,
|
|
||||||
isCheckable: true,
|
|
||||||
isChecked: true,
|
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
function createNewEntity(properties) {
|
function createNewEntity(properties) {
|
||||||
var dimensions = properties.dimensions ? properties.dimensions : DEFAULT_DIMENSIONS;
|
var dimensions = properties.dimensions ? properties.dimensions : DEFAULT_DIMENSIONS;
|
||||||
var position = getPositionToCreateEntity();
|
var position = getPositionToCreateEntity();
|
||||||
|
@ -922,11 +909,21 @@ function setupModelMenus() {
|
||||||
afterItem: "Parent Entity to Last",
|
afterItem: "Parent Entity to Last",
|
||||||
grouping: "Advanced"
|
grouping: "Advanced"
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Menu.addMenuItem({
|
||||||
|
menuName: GRABBABLE_ENTITIES_MENU_CATEGORY,
|
||||||
|
menuItemName: GRABBABLE_ENTITIES_MENU_ITEM,
|
||||||
|
afterItem: "Unparent Entity",
|
||||||
|
isCheckable: true,
|
||||||
|
isChecked: true,
|
||||||
|
grouping: "Advanced"
|
||||||
|
});
|
||||||
|
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: "Allow Selecting of Large Models",
|
menuItemName: "Allow Selecting of Large Models",
|
||||||
shortcutKey: "CTRL+META+L",
|
shortcutKey: "CTRL+META+L",
|
||||||
afterItem: "Unparent Entity",
|
afterItem: GRABBABLE_ENTITIES_MENU_ITEM,
|
||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isChecked: true,
|
isChecked: true,
|
||||||
grouping: "Advanced"
|
grouping: "Advanced"
|
||||||
|
|
Loading…
Reference in a new issue