mirror of
https://github.com/overte-org/overte.git
synced 2025-08-06 19:59:28 +02:00
fixinig the controller settings page and have menu option on by default
This commit is contained in:
parent
2a3004079e
commit
82422edb59
5 changed files with 293 additions and 264 deletions
|
@ -18,7 +18,7 @@ import "../../controls-uit" as HifiControls
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: info
|
id: info
|
||||||
|
|
||||||
|
anchors.fill: parent
|
||||||
signal canceled()
|
signal canceled()
|
||||||
signal restart()
|
signal restart()
|
||||||
|
|
||||||
|
|
|
@ -8,6 +8,7 @@
|
||||||
|
|
||||||
import QtQuick 2.7
|
import QtQuick 2.7
|
||||||
import QtQuick.Controls 2.2
|
import QtQuick.Controls 2.2
|
||||||
|
import QtQuick.Layouts 1.3
|
||||||
import QtGraphicalEffects 1.0
|
import QtGraphicalEffects 1.0
|
||||||
import Qt.labs.settings 1.0
|
import Qt.labs.settings 1.0
|
||||||
import "../../styles-uit"
|
import "../../styles-uit"
|
||||||
|
@ -15,237 +16,275 @@ import "../../controls"
|
||||||
import "../../controls-uit" as HifiControls
|
import "../../controls-uit" as HifiControls
|
||||||
import "../../dialogs"
|
import "../../dialogs"
|
||||||
import "../../dialogs/preferences"
|
import "../../dialogs/preferences"
|
||||||
|
import "tabletWindows"
|
||||||
|
import "../audio"
|
||||||
|
|
||||||
PreferencesDialog {
|
Item {
|
||||||
id: root
|
id: controllerSettings
|
||||||
objectName: "ControlSettings"
|
height: parent.height
|
||||||
title: "Control Settings"
|
width: parent.width
|
||||||
showCategories: ["VR Movement", inputConfigurationComponents]
|
|
||||||
property var settings: Settings {
|
|
||||||
category: root.objectName
|
|
||||||
property alias x: root.x
|
|
||||||
property alias y: root.y
|
|
||||||
property alias width: root.width
|
|
||||||
property alias height: root.height
|
|
||||||
}
|
|
||||||
Component {
|
|
||||||
id: inputConfigurationComponents
|
|
||||||
|
|
||||||
Preference {
|
HifiConstants { id: hifi }
|
||||||
|
|
||||||
StackView {
|
TabBar {
|
||||||
id: stack
|
id: bar
|
||||||
initialItem: inputConfiguration
|
spacing: 0
|
||||||
property alias messageVisible: imageMessageBox.visible
|
width: parent.width
|
||||||
property alias selectedPlugin: box.currentText
|
|
||||||
Rectangle {
|
|
||||||
id: inputConfiguration
|
|
||||||
anchors.fill: parent
|
|
||||||
|
|
||||||
HifiConstants { id: hifi }
|
TabButton {
|
||||||
|
height: parent.height
|
||||||
color: hifi.colors.baseGray
|
text: qsTr("Settings")
|
||||||
|
onClicked: {
|
||||||
property var pluginSettings: null
|
stackView.clear();
|
||||||
|
stackView.push(controllerPreferencesComponent);
|
||||||
HifiControls.ImageMessageBox {
|
}
|
||||||
id: imageMessageBox
|
}
|
||||||
anchors.fill: parent
|
TabButton {
|
||||||
z: 2000
|
height: parent.height
|
||||||
imageWidth: 442
|
text: qsTr("Calibration")
|
||||||
imageHeight: 670
|
onClicked: {
|
||||||
source: "../../../images/calibration-help.png"
|
stackView.clear();
|
||||||
}
|
stackView.push(inputConfigurationComponent);
|
||||||
|
|
||||||
Rectangle {
|
|
||||||
width: inputConfiguration.width
|
|
||||||
height: 1
|
|
||||||
color: hifi.colors.baseGrayShadow
|
|
||||||
x: -hifi.dimensions.contentMargin.x
|
|
||||||
}
|
|
||||||
|
|
||||||
RalewayRegular {
|
|
||||||
id: header
|
|
||||||
text: "Control Settings"
|
|
||||||
size: 22
|
|
||||||
color: "white"
|
|
||||||
|
|
||||||
anchors.top: inputConfiguration.top
|
|
||||||
anchors.left: inputConfiguration.left
|
|
||||||
anchors.leftMargin: 20
|
|
||||||
anchors.topMargin: 20
|
|
||||||
}
|
|
||||||
|
|
||||||
Separator {
|
|
||||||
id: headerSeparator
|
|
||||||
width: inputConfiguration.width
|
|
||||||
anchors.top: header.bottom
|
|
||||||
anchors.topMargin: 10
|
|
||||||
}
|
|
||||||
|
|
||||||
HiFiGlyphs {
|
|
||||||
id: sourceGlyph
|
|
||||||
text: hifi.glyphs.source
|
|
||||||
size: 36
|
|
||||||
color: hifi.colors.blueHighlight
|
|
||||||
|
|
||||||
anchors.top: headerSeparator.bottom
|
|
||||||
anchors.left: inputConfiguration.left
|
|
||||||
anchors.leftMargin: 40
|
|
||||||
anchors.topMargin: 20
|
|
||||||
}
|
|
||||||
|
|
||||||
RalewayRegular {
|
|
||||||
id: configuration
|
|
||||||
text: "SELECT DEVICE"
|
|
||||||
size: 15
|
|
||||||
color: hifi.colors.lightGrayText
|
|
||||||
|
|
||||||
|
|
||||||
anchors.top: headerSeparator.bottom
|
|
||||||
anchors.left: sourceGlyph.right
|
|
||||||
anchors.leftMargin: 10
|
|
||||||
anchors.topMargin: 30
|
|
||||||
}
|
|
||||||
|
|
||||||
Row {
|
|
||||||
id: configRow
|
|
||||||
z: 999
|
|
||||||
anchors.top: sourceGlyph.bottom
|
|
||||||
anchors.topMargin: 20
|
|
||||||
anchors.left: sourceGlyph.left
|
|
||||||
anchors.leftMargin: 40
|
|
||||||
spacing: 10
|
|
||||||
HifiControls.ComboBox {
|
|
||||||
id: box
|
|
||||||
width: 160
|
|
||||||
z: 999
|
|
||||||
editable: true
|
|
||||||
colorScheme: hifi.colorSchemes.dark
|
|
||||||
model: inputPlugins()
|
|
||||||
label: ""
|
|
||||||
|
|
||||||
onCurrentIndexChanged: {
|
|
||||||
changeSource();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
HifiControls.CheckBox {
|
|
||||||
id: checkBox
|
|
||||||
colorScheme: hifi.colorSchemes.dark
|
|
||||||
text: "show all input devices"
|
|
||||||
|
|
||||||
onClicked: {
|
|
||||||
inputPlugins();
|
|
||||||
changeSource();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
Separator {
|
|
||||||
id: configurationSeparator
|
|
||||||
z: 0
|
|
||||||
width: inputConfiguration.width
|
|
||||||
anchors.top: configRow.bottom
|
|
||||||
anchors.topMargin: 10
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
HiFiGlyphs {
|
|
||||||
id: sliderGlyph
|
|
||||||
text: hifi.glyphs.sliders
|
|
||||||
size: 36
|
|
||||||
color: hifi.colors.blueHighlight
|
|
||||||
|
|
||||||
anchors.top: configurationSeparator.bottom
|
|
||||||
anchors.left: inputConfiguration.left
|
|
||||||
anchors.leftMargin: 40
|
|
||||||
anchors.topMargin: 20
|
|
||||||
}
|
|
||||||
|
|
||||||
RalewayRegular {
|
|
||||||
id: configurationHeader
|
|
||||||
text: "CONFIGURATION"
|
|
||||||
size: 15
|
|
||||||
color: hifi.colors.lightGrayText
|
|
||||||
|
|
||||||
|
|
||||||
anchors.top: configurationSeparator.bottom
|
|
||||||
anchors.left: sliderGlyph.right
|
|
||||||
anchors.leftMargin: 10
|
|
||||||
anchors.topMargin: 30
|
|
||||||
}
|
|
||||||
|
|
||||||
Loader {
|
|
||||||
id: loader
|
|
||||||
asynchronous: false
|
|
||||||
|
|
||||||
width: inputConfiguration.width
|
|
||||||
anchors.left: inputConfiguration.left
|
|
||||||
anchors.right: inputConfiguration.right
|
|
||||||
anchors.top: configurationHeader.bottom
|
|
||||||
anchors.topMargin: 10
|
|
||||||
anchors.bottom: inputConfiguration.bottom
|
|
||||||
|
|
||||||
source: InputConfiguration.configurationLayout(box.currentText);
|
|
||||||
onLoaded: {
|
|
||||||
if (loader.item.hasOwnProperty("pluginName")) {
|
|
||||||
if (box.currentText === "Vive") {
|
|
||||||
loader.item.pluginName = "OpenVR";
|
|
||||||
} else {
|
|
||||||
loader.item.pluginName = box.currentText;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (loader.item.hasOwnProperty("displayInformation")) {
|
|
||||||
loader.item.displayConfiguration();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
function inputPlugins() {
|
|
||||||
if (checkBox.checked) {
|
|
||||||
return InputConfiguration.inputPlugins();
|
|
||||||
} else {
|
|
||||||
return InputConfiguration.activeInputPlugins();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function initialize() {
|
|
||||||
changeSource();
|
|
||||||
}
|
|
||||||
|
|
||||||
function changeSource() {
|
|
||||||
loader.source = "";
|
|
||||||
var source = "";
|
|
||||||
if (box.currentText == "Vive") {
|
|
||||||
source = InputConfiguration.configurationLayout("OpenVR");
|
|
||||||
} else {
|
|
||||||
source = InputConfiguration.configurationLayout(box.currentText);
|
|
||||||
}
|
|
||||||
|
|
||||||
loader.source = source;
|
|
||||||
if (source === "") {
|
|
||||||
box.label = "(not configurable)";
|
|
||||||
} else {
|
|
||||||
box.label = "";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Timer {
|
|
||||||
id: timer
|
|
||||||
repeat: false
|
|
||||||
interval: 300
|
|
||||||
onTriggered: initialize()
|
|
||||||
}
|
|
||||||
|
|
||||||
Component.onCompleted: {
|
|
||||||
timer.start();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
StackView {
|
||||||
|
id: stackView
|
||||||
|
anchors.top: bar.bottom
|
||||||
|
anchors.bottom: controllerSettings.bottom
|
||||||
|
anchors.left: controllerSettings.left
|
||||||
|
anchors.right: controllerSettings.right
|
||||||
|
|
||||||
|
initialItem: controllerPreferencesComponent
|
||||||
|
}
|
||||||
|
|
||||||
|
Component {
|
||||||
|
id: inputConfigurationComponent
|
||||||
|
StackView {
|
||||||
|
id: stack
|
||||||
|
initialItem: inputConfiguration
|
||||||
|
property alias messageVisible: imageMessageBox.visible
|
||||||
|
property alias selectedPlugin: box.currentText
|
||||||
|
Rectangle {
|
||||||
|
id: inputConfiguration
|
||||||
|
anchors.fill: parent
|
||||||
|
|
||||||
|
HifiConstants { id: hifi }
|
||||||
|
|
||||||
|
color: hifi.colors.baseGray
|
||||||
|
|
||||||
|
property var pluginSettings: null
|
||||||
|
|
||||||
|
HifiControls.ImageMessageBox {
|
||||||
|
id: imageMessageBox
|
||||||
|
anchors.fill: parent
|
||||||
|
z: 2000
|
||||||
|
imageWidth: 442
|
||||||
|
imageHeight: 670
|
||||||
|
source: "../../../images/calibration-help.png"
|
||||||
|
}
|
||||||
|
|
||||||
|
Rectangle {
|
||||||
|
width: inputConfiguration.width
|
||||||
|
height: 1
|
||||||
|
color: hifi.colors.baseGrayShadow
|
||||||
|
x: -hifi.dimensions.contentMargin.x
|
||||||
|
}
|
||||||
|
|
||||||
|
RalewayRegular {
|
||||||
|
id: header
|
||||||
|
text: "Control Settings"
|
||||||
|
size: 22
|
||||||
|
color: "white"
|
||||||
|
|
||||||
|
anchors.top: inputConfiguration.top
|
||||||
|
anchors.left: inputConfiguration.left
|
||||||
|
anchors.leftMargin: 20
|
||||||
|
anchors.topMargin: 20
|
||||||
|
}
|
||||||
|
|
||||||
|
Separator {
|
||||||
|
id: headerSeparator
|
||||||
|
width: inputConfiguration.width
|
||||||
|
anchors.top: header.bottom
|
||||||
|
anchors.topMargin: 10
|
||||||
|
}
|
||||||
|
|
||||||
|
HiFiGlyphs {
|
||||||
|
id: sourceGlyph
|
||||||
|
text: hifi.glyphs.source
|
||||||
|
size: 36
|
||||||
|
color: hifi.colors.blueHighlight
|
||||||
|
|
||||||
|
anchors.top: headerSeparator.bottom
|
||||||
|
anchors.left: inputConfiguration.left
|
||||||
|
anchors.leftMargin: 40
|
||||||
|
anchors.topMargin: 20
|
||||||
|
}
|
||||||
|
|
||||||
|
RalewayRegular {
|
||||||
|
id: configuration
|
||||||
|
text: "SELECT DEVICE"
|
||||||
|
size: 15
|
||||||
|
color: hifi.colors.lightGrayText
|
||||||
|
|
||||||
|
|
||||||
|
anchors.top: headerSeparator.bottom
|
||||||
|
anchors.left: sourceGlyph.right
|
||||||
|
anchors.leftMargin: 10
|
||||||
|
anchors.topMargin: 30
|
||||||
|
}
|
||||||
|
|
||||||
|
Row {
|
||||||
|
id: configRow
|
||||||
|
z: 999
|
||||||
|
anchors.top: sourceGlyph.bottom
|
||||||
|
anchors.topMargin: 20
|
||||||
|
anchors.left: sourceGlyph.left
|
||||||
|
anchors.leftMargin: 40
|
||||||
|
spacing: 10
|
||||||
|
HifiControls.ComboBox {
|
||||||
|
id: box
|
||||||
|
width: 160
|
||||||
|
z: 999
|
||||||
|
editable: true
|
||||||
|
colorScheme: hifi.colorSchemes.dark
|
||||||
|
model: inputPlugins()
|
||||||
|
label: ""
|
||||||
|
|
||||||
|
onCurrentIndexChanged: {
|
||||||
|
changeSource();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
HifiControls.CheckBox {
|
||||||
|
id: checkBox
|
||||||
|
colorScheme: hifi.colorSchemes.dark
|
||||||
|
text: "show all input devices"
|
||||||
|
|
||||||
|
onClicked: {
|
||||||
|
inputPlugins();
|
||||||
|
changeSource();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Separator {
|
||||||
|
id: configurationSeparator
|
||||||
|
z: 0
|
||||||
|
width: inputConfiguration.width
|
||||||
|
anchors.top: configRow.bottom
|
||||||
|
anchors.topMargin: 10
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
HiFiGlyphs {
|
||||||
|
id: sliderGlyph
|
||||||
|
text: hifi.glyphs.sliders
|
||||||
|
size: 36
|
||||||
|
color: hifi.colors.blueHighlight
|
||||||
|
|
||||||
|
anchors.top: configurationSeparator.bottom
|
||||||
|
anchors.left: inputConfiguration.left
|
||||||
|
anchors.leftMargin: 40
|
||||||
|
anchors.topMargin: 20
|
||||||
|
}
|
||||||
|
|
||||||
|
RalewayRegular {
|
||||||
|
id: configurationHeader
|
||||||
|
text: "CONFIGURATION"
|
||||||
|
size: 15
|
||||||
|
color: hifi.colors.lightGrayText
|
||||||
|
|
||||||
|
|
||||||
|
anchors.top: configurationSeparator.bottom
|
||||||
|
anchors.left: sliderGlyph.right
|
||||||
|
anchors.leftMargin: 10
|
||||||
|
anchors.topMargin: 30
|
||||||
|
}
|
||||||
|
|
||||||
|
Loader {
|
||||||
|
id: loader
|
||||||
|
asynchronous: false
|
||||||
|
|
||||||
|
width: inputConfiguration.width
|
||||||
|
anchors.left: inputConfiguration.left
|
||||||
|
anchors.right: inputConfiguration.right
|
||||||
|
anchors.top: configurationHeader.bottom
|
||||||
|
anchors.topMargin: 10
|
||||||
|
anchors.bottom: inputConfiguration.bottom
|
||||||
|
|
||||||
|
source: InputConfiguration.configurationLayout(box.currentText);
|
||||||
|
onLoaded: {
|
||||||
|
if (loader.item.hasOwnProperty("pluginName")) {
|
||||||
|
if (box.currentText === "Vive") {
|
||||||
|
loader.item.pluginName = "OpenVR";
|
||||||
|
} else {
|
||||||
|
loader.item.pluginName = box.currentText;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (loader.item.hasOwnProperty("displayInformation")) {
|
||||||
|
loader.item.displayConfiguration();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function inputPlugins() {
|
||||||
|
if (checkBox.checked) {
|
||||||
|
return InputConfiguration.inputPlugins();
|
||||||
|
} else {
|
||||||
|
return InputConfiguration.activeInputPlugins();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function initialize() {
|
||||||
|
changeSource();
|
||||||
|
}
|
||||||
|
|
||||||
|
function changeSource() {
|
||||||
|
loader.source = "";
|
||||||
|
var source = "";
|
||||||
|
if (box.currentText == "Vive") {
|
||||||
|
source = InputConfiguration.configurationLayout("OpenVR");
|
||||||
|
} else {
|
||||||
|
source = InputConfiguration.configurationLayout(box.currentText);
|
||||||
|
}
|
||||||
|
|
||||||
|
loader.source = source;
|
||||||
|
if (source === "") {
|
||||||
|
box.label = "(not configurable)";
|
||||||
|
} else {
|
||||||
|
box.label = "";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Timer {
|
||||||
|
id: timer
|
||||||
|
repeat: false
|
||||||
|
interval: 300
|
||||||
|
onTriggered: initialize()
|
||||||
|
}
|
||||||
|
|
||||||
|
Component.onCompleted: {
|
||||||
|
timer.start();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Component {
|
||||||
|
id: controllerPreferencesComponent
|
||||||
|
TabletPreferencesDialog {
|
||||||
|
anchors.fill: stackView
|
||||||
|
id: controllerPrefereneces
|
||||||
|
objectName: "TabletControllerPreferences"
|
||||||
|
showCategories: ["VR Movement"]
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,6 +19,7 @@ Item {
|
||||||
id: dialog
|
id: dialog
|
||||||
width: parent.width
|
width: parent.width
|
||||||
height: parent.height
|
height: parent.height
|
||||||
|
anchors.fill: parent
|
||||||
|
|
||||||
HifiConstants { id: hifi }
|
HifiConstants { id: hifi }
|
||||||
property var sections: []
|
property var sections: []
|
||||||
|
@ -158,14 +159,15 @@ Item {
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: footer
|
id: footer
|
||||||
height: 40
|
height: dialog.height * 0.15
|
||||||
|
anchors.bottom: dialog.bottom
|
||||||
|
|
||||||
anchors {
|
anchors {
|
||||||
bottom: keyboard.top
|
bottom: keyboard.top
|
||||||
left: parent.left
|
left: parent.left
|
||||||
right: parent.right
|
right: parent.right
|
||||||
}
|
}
|
||||||
|
|
||||||
color: hifi.colors.baseGray
|
color: hifi.colors.baseGray
|
||||||
|
|
||||||
Row {
|
Row {
|
||||||
|
|
|
@ -236,8 +236,13 @@ Menu::Menu() {
|
||||||
// Settings > Controls...
|
// Settings > Controls...
|
||||||
action = addActionToQMenuAndActionHash(settingsMenu, "Controls...");
|
action = addActionToQMenuAndActionHash(settingsMenu, "Controls...");
|
||||||
connect(action, &QAction::triggered, [] {
|
connect(action, &QAction::triggered, [] {
|
||||||
qApp->showDialog(QString("hifi/tablet/ControllerSettings.qml"),
|
auto tablet = DependencyManager::get<TabletScriptingInterface>()->getTablet("com.highfidelity.interface.tablet.system");
|
||||||
QString("hifi/tablet/ControllerSettings.qml"), "ControlSettings");
|
auto hmd = DependencyManager::get<HMDScriptingInterface>();
|
||||||
|
tablet->loadQMLSource("hifi/tablet/ControllerSettings.qml");
|
||||||
|
|
||||||
|
if (!hmd->getShouldShowTablet()) {
|
||||||
|
hmd->toggleShouldShowTablet();
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// Settings > Audio...
|
// Settings > Audio...
|
||||||
|
|
|
@ -1150,8 +1150,7 @@ function setupModelMenus() {
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: "Entities",
|
menuItemName: "Entities",
|
||||||
isSeparator: true,
|
isSeparator: true
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
if (!Menu.menuItemExists("Edit", "Delete")) {
|
if (!Menu.menuItemExists("Edit", "Delete")) {
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
|
@ -1161,7 +1160,6 @@ function setupModelMenus() {
|
||||||
text: "delete"
|
text: "delete"
|
||||||
},
|
},
|
||||||
afterItem: "Entities",
|
afterItem: "Entities",
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
modelMenuAddedDelete = true;
|
modelMenuAddedDelete = true;
|
||||||
}
|
}
|
||||||
|
@ -1169,15 +1167,13 @@ function setupModelMenus() {
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: "Parent Entity to Last",
|
menuItemName: "Parent Entity to Last",
|
||||||
afterItem: "Entities",
|
afterItem: "Entities"
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
|
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: "Unparent Entity",
|
menuItemName: "Unparent Entity",
|
||||||
afterItem: "Parent Entity to Last",
|
afterItem: "Parent Entity to Last"
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
|
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
|
@ -1185,8 +1181,7 @@ function setupModelMenus() {
|
||||||
menuItemName: MENU_CREATE_ENTITIES_GRABBABLE,
|
menuItemName: MENU_CREATE_ENTITIES_GRABBABLE,
|
||||||
afterItem: "Unparent Entity",
|
afterItem: "Unparent Entity",
|
||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isChecked: Settings.getValue(SETTING_EDIT_PREFIX + MENU_CREATE_ENTITIES_GRABBABLE, true),
|
isChecked: Settings.getValue(SETTING_EDIT_PREFIX + MENU_CREATE_ENTITIES_GRABBABLE, true)
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
|
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
|
@ -1194,87 +1189,75 @@ function setupModelMenus() {
|
||||||
menuItemName: MENU_ALLOW_SELECTION_LARGE,
|
menuItemName: MENU_ALLOW_SELECTION_LARGE,
|
||||||
afterItem: MENU_CREATE_ENTITIES_GRABBABLE,
|
afterItem: MENU_CREATE_ENTITIES_GRABBABLE,
|
||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isChecked: Settings.getValue(SETTING_EDIT_PREFIX + MENU_ALLOW_SELECTION_LARGE, true),
|
isChecked: Settings.getValue(SETTING_EDIT_PREFIX + MENU_ALLOW_SELECTION_LARGE, true)
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: MENU_ALLOW_SELECTION_SMALL,
|
menuItemName: MENU_ALLOW_SELECTION_SMALL,
|
||||||
afterItem: MENU_ALLOW_SELECTION_LARGE,
|
afterItem: MENU_ALLOW_SELECTION_LARGE,
|
||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isChecked: Settings.getValue(SETTING_EDIT_PREFIX + MENU_ALLOW_SELECTION_SMALL, true),
|
isChecked: Settings.getValue(SETTING_EDIT_PREFIX + MENU_ALLOW_SELECTION_SMALL, true)
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: MENU_ALLOW_SELECTION_LIGHTS,
|
menuItemName: MENU_ALLOW_SELECTION_LIGHTS,
|
||||||
afterItem: MENU_ALLOW_SELECTION_SMALL,
|
afterItem: MENU_ALLOW_SELECTION_SMALL,
|
||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isChecked: Settings.getValue(SETTING_EDIT_PREFIX + MENU_ALLOW_SELECTION_LIGHTS, false),
|
isChecked: Settings.getValue(SETTING_EDIT_PREFIX + MENU_ALLOW_SELECTION_LIGHTS, false)
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: "Select All Entities In Box",
|
menuItemName: "Select All Entities In Box",
|
||||||
afterItem: "Allow Selecting of Lights",
|
afterItem: "Allow Selecting of Lights"
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: "Select All Entities Touching Box",
|
menuItemName: "Select All Entities Touching Box",
|
||||||
afterItem: "Select All Entities In Box",
|
afterItem: "Select All Entities In Box"
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
|
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: "Export Entities",
|
menuItemName: "Export Entities",
|
||||||
afterItem: "Entities",
|
afterItem: "Entities"
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: "Import Entities",
|
menuItemName: "Import Entities",
|
||||||
afterItem: "Export Entities",
|
afterItem: "Export Entities"
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: "Import Entities from URL",
|
menuItemName: "Import Entities from URL",
|
||||||
afterItem: "Import Entities",
|
afterItem: "Import Entities"
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
|
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: MENU_AUTO_FOCUS_ON_SELECT,
|
menuItemName: MENU_AUTO_FOCUS_ON_SELECT,
|
||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isChecked: Settings.getValue(SETTING_AUTO_FOCUS_ON_SELECT) === "true",
|
isChecked: Settings.getValue(SETTING_AUTO_FOCUS_ON_SELECT) === "true"
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: MENU_EASE_ON_FOCUS,
|
menuItemName: MENU_EASE_ON_FOCUS,
|
||||||
afterItem: MENU_AUTO_FOCUS_ON_SELECT,
|
afterItem: MENU_AUTO_FOCUS_ON_SELECT,
|
||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isChecked: Settings.getValue(SETTING_EASE_ON_FOCUS) === "true",
|
isChecked: Settings.getValue(SETTING_EASE_ON_FOCUS) === "true"
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE,
|
menuItemName: MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE,
|
||||||
afterItem: MENU_EASE_ON_FOCUS,
|
afterItem: MENU_EASE_ON_FOCUS,
|
||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isChecked: Settings.getValue(SETTING_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE) !== "false",
|
isChecked: Settings.getValue(SETTING_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE) !== "false"
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
Menu.addMenuItem({
|
Menu.addMenuItem({
|
||||||
menuName: "Edit",
|
menuName: "Edit",
|
||||||
menuItemName: MENU_SHOW_ZONES_IN_EDIT_MODE,
|
menuItemName: MENU_SHOW_ZONES_IN_EDIT_MODE,
|
||||||
afterItem: MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE,
|
afterItem: MENU_SHOW_LIGHTS_AND_PARTICLES_IN_EDIT_MODE,
|
||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isChecked: Settings.getValue(SETTING_SHOW_ZONES_IN_EDIT_MODE) !== "false",
|
isChecked: Settings.getValue(SETTING_SHOW_ZONES_IN_EDIT_MODE) !== "false"
|
||||||
grouping: "Advanced"
|
|
||||||
});
|
});
|
||||||
|
|
||||||
Entities.setLightsArePickable(false);
|
Entities.setLightsArePickable(false);
|
||||||
|
|
Loading…
Reference in a new issue