mirror of
https://github.com/AleziaKurdis/overte.git
synced 2025-08-16 09:50:49 +02:00
Style Group options
This commit is contained in:
parent
c29a900588
commit
b0ef570ce0
4 changed files with 183 additions and 51 deletions
12
scripts/vr-edit/assets/tools/group/group-label.svg
Normal file
12
scripts/vr-edit/assets/tools/group/group-label.svg
Normal file
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg width="351px" height="82px" viewBox="0 0 351 82" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<!-- Generator: Sketch 45.2 (43514) - http://www.bohemiancoding.com/sketch -->
|
||||
<title>GROUP</title>
|
||||
<desc>Created with Sketch.</desc>
|
||||
<defs></defs>
|
||||
<g id="Group-Tool" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
||||
<g id="Group---Default---Locked-Buttons" transform="translate(-1026.000000, -1040.000000)" fill="#ffffff">
|
||||
<path d="M1062.572,1040.704 C1042.748,1040.704 1026.396,1054.928 1026.396,1081.136 C1026.396,1107.792 1038.38,1121.792 1060.78,1121.792 C1071.196,1121.792 1080.716,1118.768 1088.444,1113.952 L1088.444,1075.76 L1059.884,1075.76 L1061.564,1087.744 L1072.428,1087.744 L1072.428,1106.672 C1068.956,1108.576 1065.036,1109.472 1060.892,1109.472 C1049.468,1109.472 1043.644,1101.968 1043.644,1081.248 C1043.644,1061.088 1052.38,1052.912 1063.356,1052.912 C1069.74,1052.912 1074.108,1054.928 1079.148,1059.072 L1087.996,1050 C1081.5,1044.4 1073.66,1040.704 1062.572,1040.704 Z M1126.972,1089.648 L1118.572,1089.648 L1118.572,1120 L1102.108,1120 L1102.108,1042.496 L1126.3,1042.496 C1147.02,1042.496 1157.548,1050 1157.548,1065.68 C1157.548,1075.984 1152.508,1082.144 1142.204,1086.624 L1162.252,1120 L1143.548,1120 L1126.972,1089.648 Z M1118.572,1078 L1127.196,1078 C1135.82,1078 1140.524,1074.416 1140.524,1065.68 C1140.524,1057.728 1135.932,1054.256 1125.964,1054.256 L1118.572,1054.256 L1118.572,1078 Z M1200.332,1040.704 C1221.612,1040.704 1234.716,1055.264 1234.716,1081.248 C1234.716,1106.672 1221.612,1121.792 1200.332,1121.792 C1179.052,1121.792 1165.836,1107.12 1165.836,1081.248 C1165.836,1055.936 1179.052,1040.704 1200.332,1040.704 Z M1200.332,1053.024 C1189.356,1053.024 1183.196,1060.976 1183.196,1081.248 C1183.196,1101.52 1189.58,1109.472 1200.332,1109.472 C1211.42,1109.472 1217.356,1101.52 1217.356,1081.248 C1217.356,1060.976 1211.42,1053.024 1200.332,1053.024 Z M1305.052,1094.464 L1305.052,1042.496 L1288.588,1042.496 L1288.588,1093.68 C1288.588,1104.096 1284.556,1109.248 1275.484,1109.248 C1266.524,1109.248 1262.492,1104.096 1262.492,1093.68 L1262.492,1042.496 L1246.028,1042.496 L1246.028,1094.464 C1246.028,1110.592 1255.884,1121.792 1275.484,1121.792 C1295.084,1121.792 1305.052,1110.032 1305.052,1094.464 Z M1344.364,1042.496 C1364.076,1042.496 1376.172,1050.56 1376.172,1067.472 C1376.172,1085.392 1363.404,1093.568 1345.708,1093.568 L1336.86,1093.568 L1336.86,1120 L1320.396,1120 L1320.396,1042.496 L1344.364,1042.496 Z M1344.364,1081.472 C1353.436,1081.472 1359.148,1078 1359.148,1067.472 C1359.148,1058.4 1353.772,1054.368 1344.14,1054.368 L1336.86,1054.368 L1336.86,1081.472 L1344.364,1081.472 Z" id="GROUP"></path>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 2.8 KiB |
12
scripts/vr-edit/assets/tools/group/ungroup-label.svg
Normal file
12
scripts/vr-edit/assets/tools/group/ungroup-label.svg
Normal file
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg width="496px" height="82px" viewBox="0 0 496 82" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<!-- Generator: Sketch 45.2 (43514) - http://www.bohemiancoding.com/sketch -->
|
||||
<title>UNGROUP</title>
|
||||
<desc>Created with Sketch.</desc>
|
||||
<defs></defs>
|
||||
<g id="Group-Tool" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
||||
<g id="Group---Default---Locked-Buttons" transform="translate(-955.000000, -1480.000000)" fill="#ffffff">
|
||||
<path d="M1014.188,1534.464 L1014.188,1482.496 L997.724,1482.496 L997.724,1533.68 C997.724,1544.096 993.692,1549.248 984.62,1549.248 C975.66,1549.248 971.628,1544.096 971.628,1533.68 L971.628,1482.496 L955.164,1482.496 L955.164,1534.464 C955.164,1550.592 965.02,1561.792 984.62,1561.792 C1004.22,1561.792 1014.188,1550.032 1014.188,1534.464 Z M1087.996,1560 L1087.996,1482.496 L1073.1,1482.496 L1073.1,1516.544 C1073.1,1528.08 1074.556,1538.832 1075.34,1544.096 L1050.252,1482.496 L1029.532,1482.496 L1029.532,1560 L1044.428,1560 L1044.428,1529.872 C1044.428,1515.536 1043.084,1505.456 1042.188,1498.512 L1066.828,1560 L1087.996,1560 Z M1136.604,1480.704 C1116.78,1480.704 1100.428,1494.928 1100.428,1521.136 C1100.428,1547.792 1112.412,1561.792 1134.812,1561.792 C1145.228,1561.792 1154.748,1558.768 1162.476,1553.952 L1162.476,1515.76 L1133.916,1515.76 L1135.596,1527.744 L1146.46,1527.744 L1146.46,1546.672 C1142.988,1548.576 1139.068,1549.472 1134.924,1549.472 C1123.5,1549.472 1117.676,1541.968 1117.676,1521.248 C1117.676,1501.088 1126.412,1492.912 1137.388,1492.912 C1143.772,1492.912 1148.14,1494.928 1153.18,1499.072 L1162.028,1490 C1155.532,1484.4 1147.692,1480.704 1136.604,1480.704 Z M1201.004,1529.648 L1192.604,1529.648 L1192.604,1560 L1176.14,1560 L1176.14,1482.496 L1200.332,1482.496 C1221.052,1482.496 1231.58,1490 1231.58,1505.68 C1231.58,1515.984 1226.54,1522.144 1216.236,1526.624 L1236.284,1560 L1217.58,1560 L1201.004,1529.648 Z M1192.604,1518 L1201.228,1518 C1209.852,1518 1214.556,1514.416 1214.556,1505.68 C1214.556,1497.728 1209.964,1494.256 1199.996,1494.256 L1192.604,1494.256 L1192.604,1518 Z M1274.364,1480.704 C1295.644,1480.704 1308.748,1495.264 1308.748,1521.248 C1308.748,1546.672 1295.644,1561.792 1274.364,1561.792 C1253.084,1561.792 1239.868,1547.12 1239.868,1521.248 C1239.868,1495.936 1253.084,1480.704 1274.364,1480.704 Z M1274.364,1493.024 C1263.388,1493.024 1257.228,1500.976 1257.228,1521.248 C1257.228,1541.52 1263.612,1549.472 1274.364,1549.472 C1285.452,1549.472 1291.388,1541.52 1291.388,1521.248 C1291.388,1500.976 1285.452,1493.024 1274.364,1493.024 Z M1379.084,1534.464 L1379.084,1482.496 L1362.62,1482.496 L1362.62,1533.68 C1362.62,1544.096 1358.588,1549.248 1349.516,1549.248 C1340.556,1549.248 1336.524,1544.096 1336.524,1533.68 L1336.524,1482.496 L1320.06,1482.496 L1320.06,1534.464 C1320.06,1550.592 1329.916,1561.792 1349.516,1561.792 C1369.116,1561.792 1379.084,1550.032 1379.084,1534.464 Z M1418.396,1482.496 C1438.108,1482.496 1450.204,1490.56 1450.204,1507.472 C1450.204,1525.392 1437.436,1533.568 1419.74,1533.568 L1410.892,1533.568 L1410.892,1560 L1394.428,1560 L1394.428,1482.496 L1418.396,1482.496 Z M1418.396,1521.472 C1427.468,1521.472 1433.18,1518 1433.18,1507.472 C1433.18,1498.4 1427.804,1494.368 1418.172,1494.368 L1410.892,1494.368 L1410.892,1521.472 L1418.396,1521.472 Z" id="UNGROUP"></path>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 3.4 KiB |
|
@ -31,6 +31,7 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
|
||||
menuOverlays = [],
|
||||
menuHoverOverlays = [],
|
||||
menuEnabled = [],
|
||||
|
||||
optionsOverlays = [],
|
||||
optionsOverlaysIDs = [], // Text ids (names) of options overlays.
|
||||
|
@ -522,36 +523,6 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
},
|
||||
|
||||
OPTONS_PANELS = {
|
||||
groupOptions: [
|
||||
{
|
||||
id: "groupButton",
|
||||
type: "button",
|
||||
properties: {
|
||||
dimensions: { x: 0.07, y: 0.03, z: 0.01 },
|
||||
localPosition: { x: 0, y: 0.025, z: 0.005 },
|
||||
color: { red: 200, green: 200, blue: 200 }
|
||||
},
|
||||
label: " GROUP",
|
||||
enabledColor: { red: 64, green: 240, blue: 64 },
|
||||
callback: {
|
||||
method: "groupButton"
|
||||
}
|
||||
},
|
||||
{
|
||||
id: "ungroupButton",
|
||||
type: "button",
|
||||
properties: {
|
||||
dimensions: { x: 0.07, y: 0.03, z: 0.01 },
|
||||
localPosition: { x: 0, y: -0.025, z: 0.005 },
|
||||
color: { red: 200, green: 200, blue: 200 }
|
||||
},
|
||||
label: "UNGROUP",
|
||||
enabledColor: { red: 240, green: 64, blue: 64 },
|
||||
callback: {
|
||||
method: "ungroupButton"
|
||||
}
|
||||
}
|
||||
],
|
||||
colorOptions: [
|
||||
{
|
||||
id: "colorCircle",
|
||||
|
@ -711,7 +682,11 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
id: "stretchFinishButton",
|
||||
type: "newButton",
|
||||
properties: {
|
||||
localPosition: { x: 0, y: 0.02, z: 0.005 }
|
||||
localPosition: {
|
||||
x: 0,
|
||||
y: UIT.dimensions.panel.y / 2 - 0.0280 - UIT.dimensions.buttonDimensions.y / 2,
|
||||
z: UIT.dimensions.panel.z / 2 + UIT.dimensions.buttonDimensions.z / 2
|
||||
}
|
||||
},
|
||||
newLabel: {
|
||||
url: "../assets/tools/common/finish-label.svg",
|
||||
|
@ -791,7 +766,11 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
id: "cloneFinishButton",
|
||||
type: "newButton",
|
||||
properties: {
|
||||
localPosition: { x: 0, y: 0.02, z: 0.005 }
|
||||
localPosition: {
|
||||
x: 0,
|
||||
y: UIT.dimensions.panel.y / 2 - 0.0280 - UIT.dimensions.buttonDimensions.y / 2,
|
||||
z: UIT.dimensions.panel.z / 2 + UIT.dimensions.buttonDimensions.z / 2
|
||||
}
|
||||
},
|
||||
newLabel: {
|
||||
url: "../assets/tools/common/finish-label.svg",
|
||||
|
@ -802,6 +781,90 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
}
|
||||
}
|
||||
],
|
||||
groupOptions: [
|
||||
{
|
||||
id: "groupActionsLabel",
|
||||
type: "image",
|
||||
properties: {
|
||||
color: UIT.colors.white,
|
||||
url: "../assets/tools/common/actions-label.svg",
|
||||
scale: 0.0276,
|
||||
localPosition: {
|
||||
x: -UIT.dimensions.panel.x / 2 + UIT.dimensions.leftMargin + 0.0276 / 2,
|
||||
y: UIT.dimensions.panel.y / 2 - UIT.dimensions.topMargin - 0.0047 / 2,
|
||||
z: UIT.dimensions.panel.z / 2 + UIT.dimensions.imageOverlayOffset
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
id: "groupRule1",
|
||||
type: "horizontalRule",
|
||||
properties: {
|
||||
localPosition: {
|
||||
x: 0,
|
||||
y: UIT.dimensions.panel.y / 2 - 0.0199,
|
||||
z: UIT.dimensions.panel.z / 2 + UIT.dimensions.imageOverlayOffset
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
id: "groupButton",
|
||||
type: "newButton",
|
||||
properties: {
|
||||
dimensions: {
|
||||
x: UIT.dimensions.buttonDimensions.x,
|
||||
y: 0.0680,
|
||||
z: UIT.dimensions.buttonDimensions.z
|
||||
},
|
||||
localPosition: {
|
||||
x: 0,
|
||||
y: UIT.dimensions.panel.y / 2 - 0.0280 - 0.0680 / 2,
|
||||
z: UIT.dimensions.panel.z / 2 + UIT.dimensions.buttonDimensions.z / 2
|
||||
},
|
||||
color: UIT.colors.baseGrayShadow
|
||||
},
|
||||
enabledColor: UIT.colors.greenShadow,
|
||||
highlightColor: UIT.colors.greenHighlight,
|
||||
newLabel: {
|
||||
url: "../assets/tools/group/group-label.svg",
|
||||
scale: 0.0351,
|
||||
color: UIT.colors.baseGray
|
||||
},
|
||||
labelEnabledColor: UIT.colors.white,
|
||||
callback: {
|
||||
method: "groupButton"
|
||||
}
|
||||
},
|
||||
{
|
||||
id: "ungroupButton",
|
||||
type: "newButton",
|
||||
properties: {
|
||||
dimensions: {
|
||||
x: UIT.dimensions.buttonDimensions.x,
|
||||
y: 0.0680,
|
||||
z: UIT.dimensions.buttonDimensions.z
|
||||
},
|
||||
localPosition: {
|
||||
x: 0,
|
||||
y: -UIT.dimensions.panel.y / 2 + 0.0120 + 0.0680 / 2,
|
||||
z: UIT.dimensions.panel.z / 2 + UIT.dimensions.buttonDimensions.z / 2
|
||||
},
|
||||
color: UIT.colors.baseGrayShadow
|
||||
|
||||
},
|
||||
enabledColor: UIT.colors.redAccent,
|
||||
highlightColor: UIT.colors.redHighlight,
|
||||
newLabel: {
|
||||
url: "../assets/tools/group/ungroup-label.svg",
|
||||
scale: 0.0496,
|
||||
color: UIT.colors.baseGray
|
||||
},
|
||||
labelEnabledColor: UIT.colors.white,
|
||||
callback: {
|
||||
method: "ungroupButton"
|
||||
}
|
||||
}
|
||||
],
|
||||
physicsOptions: [
|
||||
{
|
||||
id: "propertiesLabel",
|
||||
|
@ -1084,7 +1147,11 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
id: "deleteFinishButton",
|
||||
type: "newButton",
|
||||
properties: {
|
||||
localPosition: { x: 0, y: 0.02, z: 0.005 }
|
||||
localPosition: {
|
||||
x: 0,
|
||||
y: UIT.dimensions.panel.y / 2 - 0.0280 - UIT.dimensions.buttonDimensions.y / 2,
|
||||
z: UIT.dimensions.panel.z / 2 + UIT.dimensions.buttonDimensions.z / 2
|
||||
}
|
||||
},
|
||||
newLabel: {
|
||||
url: "../assets/tools/common/finish-label.svg",
|
||||
|
@ -1376,7 +1443,8 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
intersectionEnabled,
|
||||
highlightedItem,
|
||||
highlightedItems,
|
||||
highlightedSource,
|
||||
highlightedSourceOverlays,
|
||||
highlightedSourceItems,
|
||||
isHighlightingButton,
|
||||
isHighlightingNewButton, // TODO: Delete when no longer needed.
|
||||
isHighlightingMenuButton,
|
||||
|
@ -1477,6 +1545,7 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
properties.parentID = menuPanelOverlay;
|
||||
itemID = Overlays.addOverlay(UI_ELEMENTS[MENU_ITEMS[i].type].overlay, properties);
|
||||
menuOverlays[i] = itemID;
|
||||
menuEnabled[i] = true;
|
||||
|
||||
if (MENU_ITEMS[i].label) {
|
||||
properties = Object.clone(UI_ELEMENTS.label.properties);
|
||||
|
@ -1629,7 +1698,8 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
properties = Object.merge(properties, optionsItems[i].newLabel);
|
||||
properties.url = Script.resolvePath(properties.url);
|
||||
properties.parentID = optionsOverlays[optionsOverlays.length - 1];
|
||||
Overlays.addOverlay(UI_ELEMENTS.image.overlay, properties);
|
||||
id = Overlays.addOverlay(UI_ELEMENTS.image.overlay, properties);
|
||||
optionsOverlaysLabels[i] = id;
|
||||
}
|
||||
|
||||
if (optionsItems[i].type === "barSlider") {
|
||||
|
@ -2187,6 +2257,7 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
function update(intersection, groupsCount, entitiesCount) {
|
||||
var intersectedItem = NONE,
|
||||
intersectionItems,
|
||||
color,
|
||||
parentProperties,
|
||||
localPosition,
|
||||
parameter,
|
||||
|
@ -2260,6 +2331,7 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
if (intersectedItem !== NONE) {
|
||||
intersectionItems = MENU_ITEMS;
|
||||
intersectionOverlays = menuOverlays;
|
||||
intersectionEnabled = menuEnabled;
|
||||
} else {
|
||||
intersectedItem = optionsOverlays.indexOf(intersection.overlayID);
|
||||
if (intersectedItem !== NONE) {
|
||||
|
@ -2271,7 +2343,7 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
}
|
||||
|
||||
// Highlight clickable item.
|
||||
if (intersectedItem !== highlightedItem || intersectionOverlays !== highlightedSource) {
|
||||
if (intersectedItem !== highlightedItem || intersectionOverlays !== highlightedSourceOverlays) {
|
||||
if (intersectedItem !== NONE && intersectionItems[intersectedItem] &&
|
||||
(intersectionItems[intersectedItem].command !== undefined
|
||||
|| intersectionItems[intersectedItem].callback !== undefined)) {
|
||||
|
@ -2283,13 +2355,20 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
});
|
||||
} else if (isHighlightingNewButton) {
|
||||
// Unhighlight button.
|
||||
Overlays.editOverlay(highlightedSource[highlightedItem], {
|
||||
color: UIT.colors.baseGrayShadow
|
||||
if (highlightedSourceItems[highlightedItem].enabledColor !== undefined && optionsEnabled[highlightedItem]) {
|
||||
color = highlightedSourceItems[highlightedItem].enabledColor;
|
||||
} else {
|
||||
color = highlightedSourceItems[highlightedItem].properties.color !== undefined
|
||||
? highlightedSourceItems[highlightedItem].properties.color
|
||||
: UI_ELEMENTS.newButton.properties.color;
|
||||
}
|
||||
Overlays.editOverlay(highlightedSourceOverlays[highlightedItem], {
|
||||
color: color
|
||||
});
|
||||
} else if (isHighlightingSlider || isHighlightingColorCircle) {
|
||||
// Lower old slider or color circle.
|
||||
Overlays.editOverlay(highlightedSource[highlightedItem], {
|
||||
localPosition: highlightedItems[highlightedItem].properties.localPosition
|
||||
Overlays.editOverlay(highlightedSourceOverlays[highlightedItem], {
|
||||
localPosition: highlightedSourceItems[highlightedItem].properties.localPosition
|
||||
});
|
||||
}
|
||||
// Update status variables.
|
||||
|
@ -2337,9 +2416,13 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
visible: true
|
||||
});
|
||||
} else if (isHighlightingNewButton) {
|
||||
Overlays.editOverlay(intersectionOverlays[highlightedItem], {
|
||||
color: UIT.colors.greenHighlight
|
||||
});
|
||||
if (intersectionEnabled[highlightedItem]) {
|
||||
Overlays.editOverlay(intersectionOverlays[highlightedItem], {
|
||||
color: intersectionItems[highlightedItem].highlightColor !== undefined
|
||||
? intersectionItems[highlightedItem].highlightColor
|
||||
: UIT.colors.greenHighlight
|
||||
});
|
||||
}
|
||||
} else if (!isHighlightingMenuButton) {
|
||||
Overlays.editOverlay(highlightOverlay, {
|
||||
parentID: intersectionOverlays[intersectedItem],
|
||||
|
@ -2367,13 +2450,20 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
});
|
||||
} else if (isHighlightingNewButton) {
|
||||
// Unhighlight button.
|
||||
Overlays.editOverlay(highlightedSource[highlightedItem], {
|
||||
color: UIT.colors.baseGrayShadow
|
||||
if (highlightedSourceItems[highlightedItem].enabledColor !== undefined && optionsEnabled[highlightedItem]) {
|
||||
color = highlightedSourceItems[highlightedItem].enabledColor;
|
||||
} else {
|
||||
color = highlightedSourceItems[highlightedItem].properties.color !== undefined
|
||||
? highlightedSourceItems[highlightedItem].properties.color
|
||||
: UI_ELEMENTS.newButton.properties.color;
|
||||
}
|
||||
Overlays.editOverlay(highlightedSourceOverlays[highlightedItem], {
|
||||
color: color
|
||||
});
|
||||
} else if (isHighlightingSlider || isHighlightingColorCircle) {
|
||||
// Lower slider or color circle.
|
||||
Overlays.editOverlay(highlightedSource[highlightedItem], {
|
||||
localPosition: highlightedItems[highlightedItem].properties.localPosition
|
||||
Overlays.editOverlay(highlightedSourceOverlays[highlightedItem], {
|
||||
localPosition: highlightedSourceItems[highlightedItem].properties.localPosition
|
||||
});
|
||||
}
|
||||
// Update status variables.
|
||||
|
@ -2385,7 +2475,8 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
isHighlightingColorCircle = false;
|
||||
isHighlightingPicklist = false;
|
||||
}
|
||||
highlightedSource = intersectionOverlays;
|
||||
highlightedSourceOverlays = intersectionOverlays;
|
||||
highlightedSourceItems = intersectionItems;
|
||||
}
|
||||
|
||||
// Press/unpress button.
|
||||
|
@ -2536,9 +2627,16 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
isGroupButtonEnabled = enableGroupButton;
|
||||
Overlays.editOverlay(optionsOverlays[groupButtonIndex], {
|
||||
color: isGroupButtonEnabled
|
||||
? OPTONS_PANELS.groupOptions[groupButtonIndex].enabledColor
|
||||
? (highlightedItem === groupButtonIndex
|
||||
? OPTONS_PANELS.groupOptions[groupButtonIndex].highlightColor
|
||||
: OPTONS_PANELS.groupOptions[groupButtonIndex].enabledColor)
|
||||
: OPTONS_PANELS.groupOptions[groupButtonIndex].properties.color
|
||||
});
|
||||
Overlays.editOverlay(optionsOverlaysLabels[groupButtonIndex], {
|
||||
color: isGroupButtonEnabled
|
||||
? OPTONS_PANELS.groupOptions[groupButtonIndex].labelEnabledColor
|
||||
: OPTONS_PANELS.groupOptions[groupButtonIndex].newLabel.color
|
||||
});
|
||||
optionsEnabled[groupButtonIndex] = enableGroupButton;
|
||||
}
|
||||
|
||||
|
@ -2547,9 +2645,16 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
isUngroupButtonEnabled = enableUngroupButton;
|
||||
Overlays.editOverlay(optionsOverlays[ungroupButtonIndex], {
|
||||
color: isUngroupButtonEnabled
|
||||
? OPTONS_PANELS.groupOptions[ungroupButtonIndex].enabledColor
|
||||
? (highlightedItem === ungroupButtonIndex
|
||||
? OPTONS_PANELS.groupOptions[ungroupButtonIndex].highlightColor
|
||||
: OPTONS_PANELS.groupOptions[ungroupButtonIndex].enabledColor)
|
||||
: OPTONS_PANELS.groupOptions[ungroupButtonIndex].properties.color
|
||||
});
|
||||
Overlays.editOverlay(optionsOverlaysLabels[ungroupButtonIndex], {
|
||||
color: isUngroupButtonEnabled
|
||||
? OPTONS_PANELS.groupOptions[ungroupButtonIndex].labelEnabledColor
|
||||
: OPTONS_PANELS.groupOptions[ungroupButtonIndex].newLabel.color
|
||||
});
|
||||
optionsEnabled[ungroupButtonIndex] = enableUngroupButton;
|
||||
}
|
||||
}
|
||||
|
@ -2628,7 +2733,7 @@ ToolsMenu = function (side, leftInputs, rightInputs, uiCommandCallback) {
|
|||
intersectionOverlays = null;
|
||||
intersectionEnabled = null;
|
||||
highlightedItem = NONE;
|
||||
highlightedSource = null;
|
||||
highlightedSourceOverlays = null;
|
||||
isHighlightingButton = false;
|
||||
isHighlightingMenuButton = false;
|
||||
isHighlightingSlider = false;
|
||||
|
|
|
@ -21,6 +21,9 @@ UIT = (function () {
|
|||
baseGray: { red: 0x40, green: 0x40, blue: 0x40 },
|
||||
baseGrayShadow: { red: 0x25, green: 0x25, blue: 0x25 },
|
||||
darkGray: { red: 0x12, green: 0x12, blue: 0x12 },
|
||||
redAccent: { red: 0xc6, green: 0x21, blue: 0x47 },
|
||||
redHighlight: { red: 0xea, green: 0x4c, blue: 0x5f },
|
||||
greenShadow: { red: 0x35, green: 0x9d, blue: 0x85 },
|
||||
greenHighlight: { red: 0x1f, green: 0xc6, blue: 0xa6 },
|
||||
blueHighlight: { red: 0x00, green: 0xbf, blue: 0xef }
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue