Improve paramater names in model dialog window

This commit is contained in:
Ryan Huffman 2018-10-20 11:26:12 -07:00
parent f1258e4445
commit 9d13902cd3
2 changed files with 6 additions and 6 deletions

View file

@ -222,9 +222,9 @@ Rectangle {
newModelDialog.sendToScript({
method: "newModelDialogAdd",
params: {
textInput: modelURL.text,
checkBox: dynamic.checked,
comboBox: collisionType.currentIndex,
url: modelURL.text,
dynamic: dynamic.checked,
collisionShapeIndex: collisionType.currentIndex,
grabbable: grabbable.checked
}
});

View file

@ -442,9 +442,9 @@ var toolBar = (function () {
function handleNewModelDialogResult(result) {
if (result) {
var url = result.textInput;
var url = result.url;
var shapeType;
switch (result.comboBox) {
switch (result.collisionShapeIndex) {
case SHAPE_TYPE_SIMPLE_HULL:
shapeType = "simple-hull";
break;
@ -464,7 +464,7 @@ var toolBar = (function () {
shapeType = "none";
}
var dynamic = result.checkBox !== null ? result.checkBox : DYNAMIC_DEFAULT;
var dynamic = result.dynamic !== null ? result.dynamic : DYNAMIC_DEFAULT;
if (shapeType === "static-mesh" && dynamic) {
// The prompt should prevent this case
print("Error: model cannot be both static mesh and dynamic. This should never happen.");