@sapui5/sap.ui.vk 1.136.2 → 1.136.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/sap/ui/vk/.library +1 -1
- package/src/sap/ui/vk/AnimationPlayback.js +1 -1
- package/src/sap/ui/vk/AnimationPlayer.js +1 -1
- package/src/sap/ui/vk/AnimationSequence.js +1 -1
- package/src/sap/ui/vk/AnimationTimeSlider.js +1 -1
- package/src/sap/ui/vk/AnimationTrack.js +1 -1
- package/src/sap/ui/vk/Annotation.js +1 -1
- package/src/sap/ui/vk/BaseNodeProxy.js +1 -1
- package/src/sap/ui/vk/Camera.js +1 -1
- package/src/sap/ui/vk/ContentConnector.js +19 -15
- package/src/sap/ui/vk/ContentManager.js +1 -1
- package/src/sap/ui/vk/ContentResource.js +3 -2
- package/src/sap/ui/vk/Core.js +1 -1
- package/src/sap/ui/vk/DownloadManager.js +1 -1
- package/src/sap/ui/vk/DrawerToolbar.js +140 -19
- package/src/sap/ui/vk/DrawerToolbarButton.js +5 -1
- package/src/sap/ui/vk/DvlException.js +1 -1
- package/src/sap/ui/vk/FlexibleControl.js +1 -1
- package/src/sap/ui/vk/FlexibleControlLayoutData.js +1 -1
- package/src/sap/ui/vk/Highlight.js +1 -1
- package/src/sap/ui/vk/ImageContentManager.js +1 -1
- package/src/sap/ui/vk/JointUtils.js +1 -1
- package/src/sap/ui/vk/LayerProxy.js +1 -1
- package/src/sap/ui/vk/Loco.js +1 -1
- package/src/sap/ui/vk/Material.js +1 -1
- package/src/sap/ui/vk/NativeViewport.js +1 -1
- package/src/sap/ui/vk/NodeHierarchy.js +1 -1
- package/src/sap/ui/vk/NodeProxy.js +1 -1
- package/src/sap/ui/vk/NodeUtils.js +1 -1
- package/src/sap/ui/vk/Notifications.js +1 -1
- package/src/sap/ui/vk/OrthographicCamera.js +1 -1
- package/src/sap/ui/vk/PerspectiveCamera.js +1 -1
- package/src/sap/ui/vk/ProgressIndicator.js +1 -1
- package/src/sap/ui/vk/RedlineCollaboration.js +1 -1
- package/src/sap/ui/vk/RedlineConversation.js +1 -1
- package/src/sap/ui/vk/RedlineDesign.js +1 -1
- package/src/sap/ui/vk/RedlineElement.js +1 -1
- package/src/sap/ui/vk/RedlineElementComment.js +1 -1
- package/src/sap/ui/vk/RedlineElementEllipse.js +1 -1
- package/src/sap/ui/vk/RedlineElementFreehand.js +1 -1
- package/src/sap/ui/vk/RedlineElementLine.js +1 -1
- package/src/sap/ui/vk/RedlineElementRectangle.js +1 -1
- package/src/sap/ui/vk/RedlineElementText.js +1 -1
- package/src/sap/ui/vk/RedlineSurface.js +1 -1
- package/src/sap/ui/vk/SafeArea.js +1 -1
- package/src/sap/ui/vk/Scene.js +16 -1
- package/src/sap/ui/vk/SceneTree.js +3 -4
- package/src/sap/ui/vk/StepNavigation.js +1 -2
- package/src/sap/ui/vk/Texture.js +1 -1
- package/src/sap/ui/vk/ToggleMenuButton.js +1 -1
- package/src/sap/ui/vk/ToggleMenuItem.js +1 -1
- package/src/sap/ui/vk/Toolbar.js +68 -102
- package/src/sap/ui/vk/View.js +1 -1
- package/src/sap/ui/vk/ViewGallery.js +1 -1
- package/src/sap/ui/vk/ViewGalleryThumbnail.js +1 -1
- package/src/sap/ui/vk/ViewGroup.js +1 -1
- package/src/sap/ui/vk/ViewManager.js +1 -1
- package/src/sap/ui/vk/ViewStateManager.js +1 -1
- package/src/sap/ui/vk/ViewStateManagerBase.js +1 -1
- package/src/sap/ui/vk/Viewer.js +469 -234
- package/src/sap/ui/vk/Viewport.js +1 -1
- package/src/sap/ui/vk/ViewportBase.js +1 -1
- package/src/sap/ui/vk/dvl/BaseNodeProxy.js +1 -1
- package/src/sap/ui/vk/dvl/ContentManager.js +1 -1
- package/src/sap/ui/vk/dvl/GraphicsCore.js +1 -1
- package/src/sap/ui/vk/dvl/LayerProxy.js +1 -1
- package/src/sap/ui/vk/dvl/NodeHierarchy.js +1 -1
- package/src/sap/ui/vk/dvl/NodeProxy.js +1 -1
- package/src/sap/ui/vk/dvl/Scene.js +1 -1
- package/src/sap/ui/vk/dvl/ViewStateManager.js +1 -1
- package/src/sap/ui/vk/dvl/Viewport.js +1 -1
- package/src/sap/ui/vk/ecad/ElementsPanel.js +984 -212
- package/src/sap/ui/vk/ecad/LayersPanel.js +283 -145
- package/src/sap/ui/vk/i18n/messagebundle.properties +64 -37
- package/src/sap/ui/vk/library.js +11 -4
- package/src/sap/ui/vk/measurements/Angle.js +1 -1
- package/src/sap/ui/vk/measurements/Area.js +1 -1
- package/src/sap/ui/vk/measurements/Distance.js +1 -1
- package/src/sap/ui/vk/measurements/Edge.js +1 -1
- package/src/sap/ui/vk/measurements/Face.js +1 -1
- package/src/sap/ui/vk/measurements/Feature.js +1 -1
- package/src/sap/ui/vk/measurements/Vertex.js +1 -1
- package/src/sap/ui/vk/pdf/ContentManager.js +1 -1
- package/src/sap/ui/vk/pdf/Viewport.js +5 -8
- package/src/sap/ui/vk/svg/BaseNodeProxy.js +1 -1
- package/src/sap/ui/vk/svg/ContentDeliveryService.js +1 -1
- package/src/sap/ui/vk/svg/ContentManager.js +2 -1
- package/src/sap/ui/vk/svg/NodeHierarchy.js +1 -1
- package/src/sap/ui/vk/svg/NodeProxy.js +1 -1
- package/src/sap/ui/vk/svg/OrthographicCamera.js +1 -1
- package/src/sap/ui/vk/svg/Scene.js +1 -1
- package/src/sap/ui/vk/svg/SceneBuilder.js +12 -4
- package/src/sap/ui/vk/svg/ViewStateManager.js +2 -2
- package/src/sap/ui/vk/svg/Viewport.js +192 -2
- package/src/sap/ui/vk/themes/base/fonts/SAP-VE-icons-bold-v1.8.woff2 +0 -0
- package/src/sap/ui/vk/themes/base/fonts/SAP-VE-icons-regular-v1.8.woff2 +0 -0
- package/src/sap/ui/vk/themes/base/library.source.less +1 -1
- package/src/sap/ui/vk/themes/sap_belize_base/library.source.less +1 -1
- package/src/sap/ui/vk/themes/sap_bluecrystal_base/library.source.less +1 -1
- package/src/sap/ui/vk/themes/sap_hcb/library.source.less +1 -1
- package/src/sap/ui/vk/themes/sap_horizon/library.source.less +0 -5
- package/src/sap/ui/vk/themes/sap_horizon_dark/library.source.less +0 -5
- package/src/sap/ui/vk/themes/sap_horizon_hcb/library.source.less +0 -5
- package/src/sap/ui/vk/themes/sap_horizon_hcw/library.source.less +0 -5
- package/src/sap/ui/vk/thirdparty/pdf.worker.js +1 -1
- package/src/sap/ui/vk/threejs/AnimationHelper.js +1 -1
- package/src/sap/ui/vk/threejs/BaseNodeProxy.js +1 -1
- package/src/sap/ui/vk/threejs/Billboard.js +1 -1
- package/src/sap/ui/vk/threejs/Callout.js +1 -1
- package/src/sap/ui/vk/threejs/ContentDeliveryService.js +1 -1
- package/src/sap/ui/vk/threejs/ContentManager.js +1 -1
- package/src/sap/ui/vk/threejs/DetailView.js +1 -1
- package/src/sap/ui/vk/threejs/HighlightPlayer.js +1 -1
- package/src/sap/ui/vk/threejs/Material.js +1 -1
- package/src/sap/ui/vk/threejs/NodeHierarchy.js +1 -1
- package/src/sap/ui/vk/threejs/NodeProxy.js +1 -1
- package/src/sap/ui/vk/threejs/OrthographicCamera.js +1 -1
- package/src/sap/ui/vk/threejs/PerspectiveCamera.js +1 -1
- package/src/sap/ui/vk/threejs/PointCloudGroup.js +1 -1
- package/src/sap/ui/vk/threejs/Scene.js +1 -1
- package/src/sap/ui/vk/threejs/SceneBuilder.js +12 -1
- package/src/sap/ui/vk/threejs/Texture.js +1 -1
- package/src/sap/ui/vk/threejs/Thrustline.js +1 -1
- package/src/sap/ui/vk/threejs/ViewStateManager.js +1 -1
- package/src/sap/ui/vk/threejs/Viewport.js +1 -1
- package/src/sap/ui/vk/threejs/v2/ViewStateManager.js +1 -1
- package/src/sap/ui/vk/tools/AnchorPointTool.js +1 -1
- package/src/sap/ui/vk/tools/AnchorPointToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/AxisAngleRotationTool.js +1 -1
- package/src/sap/ui/vk/tools/AxisAngleRotationToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/CreateEllipseTool.js +1 -1
- package/src/sap/ui/vk/tools/CreateEllipseToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/CreateParametricGizmo.js +1 -1
- package/src/sap/ui/vk/tools/CreatePathTool.js +1 -1
- package/src/sap/ui/vk/tools/CreatePathToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/CreateRectangleTool.js +1 -1
- package/src/sap/ui/vk/tools/CreateRectangleToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/CreateTextTool.js +1 -1
- package/src/sap/ui/vk/tools/CreateTextToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/CrossSectionTool.js +1 -1
- package/src/sap/ui/vk/tools/CrossSectionToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/DuplicateSvgElementTool.js +1 -1
- package/src/sap/ui/vk/tools/DuplicateSvgElementToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/ExplodeTool.js +1 -1
- package/src/sap/ui/vk/tools/ExplodeToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/Gizmo.js +1 -1
- package/src/sap/ui/vk/tools/HitTestTool.js +1 -1
- package/src/sap/ui/vk/tools/MoveTool.js +1 -1
- package/src/sap/ui/vk/tools/MoveToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/PointCloudSelectionTool.js +1 -1
- package/src/sap/ui/vk/tools/PointCloudSelectionToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/RectSelectTool.js +1 -1
- package/src/sap/ui/vk/tools/RedlineTool.js +1 -1
- package/src/sap/ui/vk/tools/RedlineToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/RotateOrbitTool.js +1 -1
- package/src/sap/ui/vk/tools/RotateTool.js +1 -1
- package/src/sap/ui/vk/tools/RotateToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/RotateTurntableTool.js +1 -1
- package/src/sap/ui/vk/tools/ScaleTool.js +1 -1
- package/src/sap/ui/vk/tools/ScaleToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/SceneOrientationTool.js +1 -1
- package/src/sap/ui/vk/tools/SceneOrientationToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/Tool.js +1 -1
- package/src/sap/ui/vk/tools/TooltipTool.js +1 -1
- package/src/sap/ui/vk/tools/TooltipToolGizmo.js +1 -1
- package/src/sap/ui/vk/tools/TooltipToolHandler.js +5 -0
- package/src/sap/ui/vk/tools/TransformSvgElementTool.js +1 -1
- package/src/sap/ui/vk/tools/TransformSvgElementToolGizmo.js +1 -1
- package/src/sap/ui/vk/totara/TotaraLoader.js +4 -0
- package/src/sap/ui/vk/ToolbarRenderer.js +0 -41
- package/src/sap/ui/vk/ViewerRenderer.js +0 -48
- package/src/sap/ui/vk/ecad/ElementsPanelRenderer.js +0 -41
- package/src/sap/ui/vk/ecad/LayersPanelRenderer.js +0 -41
- package/src/sap/ui/vk/themes/base/fonts/SAP-VE-icons-bold-v1.4.woff2 +0 -0
- package/src/sap/ui/vk/themes/base/fonts/SAP-VE-icons-regular-v1.4.woff2 +0 -0
|
@@ -32,6 +32,7 @@ sap.ui.define([
|
|
|
32
32
|
"../colorToABGR",
|
|
33
33
|
"../abgrToColor",
|
|
34
34
|
"./MiniMap",
|
|
35
|
+
"./Element",
|
|
35
36
|
"sap/m/Dialog",
|
|
36
37
|
"sap/base/Log",
|
|
37
38
|
"sap/base/i18n/Localization"
|
|
@@ -61,6 +62,7 @@ sap.ui.define([
|
|
|
61
62
|
colorToABGR,
|
|
62
63
|
abgrToColor,
|
|
63
64
|
MiniMap,
|
|
65
|
+
ElementSVG,
|
|
64
66
|
Dialog,
|
|
65
67
|
Log,
|
|
66
68
|
Localization
|
|
@@ -74,7 +76,7 @@ sap.ui.define([
|
|
|
74
76
|
*
|
|
75
77
|
* @public
|
|
76
78
|
* @author SAP SE
|
|
77
|
-
* @version 1.136.
|
|
79
|
+
* @version 1.136.3
|
|
78
80
|
* @extends sap.ui.vk.ViewportBase
|
|
79
81
|
* @alias sap.ui.vk.svg.Viewport
|
|
80
82
|
*/
|
|
@@ -127,6 +129,13 @@ sap.ui.define([
|
|
|
127
129
|
}
|
|
128
130
|
});
|
|
129
131
|
|
|
132
|
+
const EcadLayerZone = {
|
|
133
|
+
Top: "Top",
|
|
134
|
+
Inner: "Inner",
|
|
135
|
+
Bottom: "Bottom",
|
|
136
|
+
Unknown: ""
|
|
137
|
+
};
|
|
138
|
+
|
|
130
139
|
var basePrototype = Viewport.getMetadata().getParent().getClass().prototype;
|
|
131
140
|
|
|
132
141
|
Viewport.prototype.init = function() {
|
|
@@ -216,6 +225,11 @@ sap.ui.define([
|
|
|
216
225
|
this._currentViewIndex = 0;
|
|
217
226
|
this._currentView = null;
|
|
218
227
|
|
|
228
|
+
this._pcbRotateAngle = 0.0; // ECAD, to rotate board
|
|
229
|
+
this._pcbVisibleSurface = EcadLayerZone.Unknown;
|
|
230
|
+
this._topElements = []; // ECAD, elements from all top layers
|
|
231
|
+
this._bottomElements = []; // ECAD, elements from all bottom layers
|
|
232
|
+
|
|
219
233
|
vkCore.getEventBus().subscribe("sap.ui.vk", "viewStateApplied", this._onViewStateApplied, this);
|
|
220
234
|
|
|
221
235
|
Localization.attachChange(this._onLocalizationChanged.bind(this));
|
|
@@ -379,6 +393,15 @@ sap.ui.define([
|
|
|
379
393
|
if (scene) {
|
|
380
394
|
this.setCamera(new OrthographicCamera());
|
|
381
395
|
|
|
396
|
+
if (this.isECAD()) {
|
|
397
|
+
// get layer zone info from scene metadata
|
|
398
|
+
const zones = this._extractLayersZone();
|
|
399
|
+
// find elements belong to top & bottom layers
|
|
400
|
+
this._topElements = [];
|
|
401
|
+
this._bottomElements = [];
|
|
402
|
+
this._scanTree(zones, this._scene.getRootElement());
|
|
403
|
+
}
|
|
404
|
+
|
|
382
405
|
/**
|
|
383
406
|
* Viewport gets invalidated only when a node is created that needs content to be downloaded (in ContentLoadingFinished event handler)
|
|
384
407
|
* But when creating an image out of annotation, the annotation is downloaded only the first (reused every other time)
|
|
@@ -556,10 +579,18 @@ sap.ui.define([
|
|
|
556
579
|
}
|
|
557
580
|
var node = this.hitTest(x, y, true);
|
|
558
581
|
|
|
582
|
+
if (this.isECAD() && node) {
|
|
583
|
+
const element = this.findElement(node);
|
|
584
|
+
if (element == null) {
|
|
585
|
+
return this; // nothing found, must be ECAD orphan node
|
|
586
|
+
}
|
|
587
|
+
node = element;
|
|
588
|
+
}
|
|
589
|
+
|
|
559
590
|
if (!isDoubleClick) {
|
|
560
591
|
this.tapObject(node);
|
|
561
592
|
|
|
562
|
-
if (node
|
|
593
|
+
if (node != null) {
|
|
563
594
|
this.fireNodeClicked({ nodeRef: node, x: x, y: y }, true, true);
|
|
564
595
|
}
|
|
565
596
|
} else if (!this.getFreezeCamera()) {
|
|
@@ -586,8 +617,21 @@ sap.ui.define([
|
|
|
586
617
|
var parameters = {
|
|
587
618
|
picked: nodeRef ? [nodeRef] : []
|
|
588
619
|
};
|
|
620
|
+
|
|
589
621
|
this.fireNodesPicked(parameters);
|
|
590
622
|
|
|
623
|
+
// if ECAD scene then include all children
|
|
624
|
+
if (this.isECAD() && nodeRef) {
|
|
625
|
+
const include = (ref) => {
|
|
626
|
+
if (ref != null) {
|
|
627
|
+
parameters.picked.push(ref);
|
|
628
|
+
ref.children.forEach(include);
|
|
629
|
+
}
|
|
630
|
+
};
|
|
631
|
+
parameters.picked = [];
|
|
632
|
+
include(nodeRef);
|
|
633
|
+
}
|
|
634
|
+
|
|
591
635
|
if (this.getSelectionMode() === SelectionMode.Exclusive) {
|
|
592
636
|
this.exclusiveSelectionHandler(parameters.picked);
|
|
593
637
|
} else if (this.getSelectionMode() === SelectionMode.Sticky) {
|
|
@@ -693,8 +737,26 @@ sap.ui.define([
|
|
|
693
737
|
rect = this._camera._transformRect(rect);
|
|
694
738
|
var selection = new Set();
|
|
695
739
|
this._scene.getRootElement()._findRectElementsRecursive(selection, rect, vsm._mask);
|
|
740
|
+
|
|
741
|
+
if (this.isECAD() && selection.size !== 0) {
|
|
742
|
+
const output = new Set();
|
|
743
|
+
const include = (ref, output) => {
|
|
744
|
+
if (ref != null) {
|
|
745
|
+
output.add(ref);
|
|
746
|
+
ref.children.forEach((child) => include(child, output));
|
|
747
|
+
}
|
|
748
|
+
};
|
|
749
|
+
selection.forEach(ref => {
|
|
750
|
+
const element = this.findElement(ref);
|
|
751
|
+
if (element != null) {
|
|
752
|
+
include(element, output);
|
|
753
|
+
}
|
|
754
|
+
});
|
|
755
|
+
return Array.from(output);
|
|
756
|
+
}
|
|
696
757
|
return Array.from(selection);
|
|
697
758
|
}
|
|
759
|
+
|
|
698
760
|
return [];
|
|
699
761
|
};
|
|
700
762
|
|
|
@@ -756,6 +818,12 @@ sap.ui.define([
|
|
|
756
818
|
}
|
|
757
819
|
}, this);
|
|
758
820
|
}
|
|
821
|
+
// when scene is available & content has been loaded -> proceed with initial view
|
|
822
|
+
if (this.isECAD()) {
|
|
823
|
+
this._pcbVisibleSurface = EcadLayerZone.Bottom;
|
|
824
|
+
// do the flip to make top layers elements visible without mirroring
|
|
825
|
+
this.flipPcb(true);
|
|
826
|
+
}
|
|
759
827
|
|
|
760
828
|
if (event && (!this._camera._initialZoom || this._camera._initialZoom === -1)) {
|
|
761
829
|
// this block should be called only once after loading all the content, if there is no camera information in the initial view
|
|
@@ -1685,5 +1753,127 @@ sap.ui.define([
|
|
|
1685
1753
|
return screenPos;
|
|
1686
1754
|
};
|
|
1687
1755
|
|
|
1756
|
+
Viewport.prototype.isECAD = function() {
|
|
1757
|
+
return this._scene?.isECADScene() ?? false;
|
|
1758
|
+
};
|
|
1759
|
+
|
|
1760
|
+
Viewport.prototype._extractMetadata = function(metadata) {
|
|
1761
|
+
if (metadata.length != undefined) {
|
|
1762
|
+
const map = new Map();
|
|
1763
|
+
metadata.forEach(function(entry) {
|
|
1764
|
+
if (entry.category === "ecad") {
|
|
1765
|
+
map.set(entry.tag, entry.value);
|
|
1766
|
+
}
|
|
1767
|
+
});
|
|
1768
|
+
return map;
|
|
1769
|
+
}
|
|
1770
|
+
return null;
|
|
1771
|
+
};
|
|
1772
|
+
|
|
1773
|
+
Viewport.prototype._extractLayersZone = function() {
|
|
1774
|
+
const zones = new Map();
|
|
1775
|
+
const metadata = this._scene.getSceneMetadata();
|
|
1776
|
+
const layers = metadata.find((el) => el.category === "ecad" && el.tag === "Layers");
|
|
1777
|
+
|
|
1778
|
+
if (layers) {
|
|
1779
|
+
const list = layers.value.split("|");
|
|
1780
|
+
list.forEach(function(name) {
|
|
1781
|
+
const zone = metadata.find((el) => el.category === name && el.tag === "Zone");
|
|
1782
|
+
zones.set(name, zone ? zone.value : EcadLayerZone.Unknown);
|
|
1783
|
+
}, this);
|
|
1784
|
+
}
|
|
1785
|
+
return zones;
|
|
1786
|
+
};
|
|
1787
|
+
|
|
1788
|
+
Viewport.prototype._scanTree = function(zones, nodeRef) {
|
|
1789
|
+
const metadata = this._extractMetadata(nodeRef.userData.metadata || {});
|
|
1790
|
+
if (metadata) {
|
|
1791
|
+
const layer = metadata.get("layer");
|
|
1792
|
+
if (layer) {
|
|
1793
|
+
const zone = zones.get(layer);
|
|
1794
|
+
switch (zone) {
|
|
1795
|
+
case EcadLayerZone.Top:
|
|
1796
|
+
this._topElements.push(nodeRef);
|
|
1797
|
+
break;
|
|
1798
|
+
case EcadLayerZone.Bottom:
|
|
1799
|
+
this._bottomElements.push(nodeRef);
|
|
1800
|
+
break;
|
|
1801
|
+
default:
|
|
1802
|
+
break;
|
|
1803
|
+
}
|
|
1804
|
+
return; // don't go further down the hierarchy
|
|
1805
|
+
}
|
|
1806
|
+
}
|
|
1807
|
+
nodeRef.children.forEach(this._scanTree.bind(this, zones));
|
|
1808
|
+
};
|
|
1809
|
+
|
|
1810
|
+
function makeRotateMatrix(x) {
|
|
1811
|
+
const sin = Math.sin(x);
|
|
1812
|
+
const cos = Math.cos(x);
|
|
1813
|
+
return [cos, -sin, sin, cos, 0, 0];
|
|
1814
|
+
}
|
|
1815
|
+
Viewport.prototype._setRootTransform = function() {
|
|
1816
|
+
const rotate = makeRotateMatrix(this._pcbRotateAngle);
|
|
1817
|
+
const reflect = [this._pcbVisibleSurface === EcadLayerZone.Top ? 1 : -1, 0, 0, 1, 0, 0];
|
|
1818
|
+
const root = this._scene.getRootElement();
|
|
1819
|
+
root.setMatrix(ElementSVG._multiplyMatrices(reflect, rotate));
|
|
1820
|
+
};
|
|
1821
|
+
|
|
1822
|
+
Viewport.prototype.findElement = function(ref) {
|
|
1823
|
+
while (ref != null) {
|
|
1824
|
+
const metadata = this._extractMetadata(ref.userData.metadata ?? {});
|
|
1825
|
+
|
|
1826
|
+
if (metadata?.has("type")) {
|
|
1827
|
+
return ref;
|
|
1828
|
+
}
|
|
1829
|
+
ref = ref.parent;
|
|
1830
|
+
}
|
|
1831
|
+
return null;
|
|
1832
|
+
};
|
|
1833
|
+
|
|
1834
|
+
Viewport.prototype.rotatePcbCW = function() {
|
|
1835
|
+
if (this.isECAD()) {
|
|
1836
|
+
this._pcbRotateAngle += this._pcbVisibleSurface === EcadLayerZone.Top
|
|
1837
|
+
? -Math.PI / 2
|
|
1838
|
+
: Math.PI / 2;
|
|
1839
|
+
this._setRootTransform();
|
|
1840
|
+
this.zoomTo(ZoomTo.Visible);
|
|
1841
|
+
}
|
|
1842
|
+
};
|
|
1843
|
+
|
|
1844
|
+
Viewport.prototype.rotatePcbCCW = function() {
|
|
1845
|
+
if (this.isECAD()) {
|
|
1846
|
+
this._pcbRotateAngle += this._pcbVisibleSurface === EcadLayerZone.Top
|
|
1847
|
+
? Math.PI / 2
|
|
1848
|
+
: -Math.PI / 2;
|
|
1849
|
+
this._setRootTransform();
|
|
1850
|
+
this.zoomTo(ZoomTo.Visible);
|
|
1851
|
+
}
|
|
1852
|
+
};
|
|
1853
|
+
|
|
1854
|
+
Viewport.prototype.flipPcb = function(skipReflect) {
|
|
1855
|
+
if (this.isECAD() && this._viewStateManager) {
|
|
1856
|
+
this._pcbVisibleSurface = (this._pcbVisibleSurface === EcadLayerZone.Top ? EcadLayerZone.Bottom : EcadLayerZone.Top);
|
|
1857
|
+
|
|
1858
|
+
if (!skipReflect) {
|
|
1859
|
+
this._setRootTransform();
|
|
1860
|
+
this.zoomTo(ZoomTo.Visible);
|
|
1861
|
+
}
|
|
1862
|
+
// hide everything first
|
|
1863
|
+
this._viewStateManager.setVisibilityState(this._scene.getRootElement(), false, true, true);
|
|
1864
|
+
// show elements from top or bottom layers
|
|
1865
|
+
switch (this._pcbVisibleSurface) {
|
|
1866
|
+
case EcadLayerZone.Top:
|
|
1867
|
+
this._viewStateManager.setVisibilityState(this._topElements, true, true, true);
|
|
1868
|
+
break;
|
|
1869
|
+
case EcadLayerZone.Bottom:
|
|
1870
|
+
this._viewStateManager.setVisibilityState(this._bottomElements, true, true, true);
|
|
1871
|
+
break;
|
|
1872
|
+
default:
|
|
1873
|
+
break;
|
|
1874
|
+
}
|
|
1875
|
+
}
|
|
1876
|
+
};
|
|
1877
|
+
|
|
1688
1878
|
return Viewport;
|
|
1689
1879
|
});
|
|
Binary file
|
|
Binary file
|
|
@@ -8,8 +8,3 @@
|
|
|
8
8
|
@import "../base/library.source.less";
|
|
9
9
|
@import "../../../../../sap/ui/core/themes/sap_horizon/base.less";
|
|
10
10
|
@import "../../../../../sap/ui/core/themes/sap_horizon/global.less";
|
|
11
|
-
|
|
12
|
-
@font-face {
|
|
13
|
-
font-family: 'vk-icons';
|
|
14
|
-
src: url('../base/fonts/SAP-VE-icons-bold-v1.4.woff2') format('woff2');
|
|
15
|
-
}
|
|
@@ -8,8 +8,3 @@
|
|
|
8
8
|
@import "../base/library.source.less";
|
|
9
9
|
@import "../../../../../sap/ui/core/themes/sap_horizon_dark/base.less";
|
|
10
10
|
@import "../../../../../sap/ui/core/themes/sap_horizon_dark/global.less";
|
|
11
|
-
|
|
12
|
-
@font-face {
|
|
13
|
-
font-family: 'vk-icons';
|
|
14
|
-
src: url('../base/fonts/SAP-VE-icons-bold-v1.4.woff2') format('woff2');
|
|
15
|
-
}
|
|
@@ -8,8 +8,3 @@
|
|
|
8
8
|
@import "../base/library.source.less";
|
|
9
9
|
@import "../../../../../sap/ui/core/themes/sap_horizon_hcb/base.less";
|
|
10
10
|
@import "../../../../../sap/ui/core/themes/sap_horizon_hcb/global.less";
|
|
11
|
-
|
|
12
|
-
@font-face {
|
|
13
|
-
font-family: 'vk-icons';
|
|
14
|
-
src: url('../base/fonts/SAP-VE-icons-bold-v1.4.woff2') format('woff2');
|
|
15
|
-
}
|
|
@@ -8,8 +8,3 @@
|
|
|
8
8
|
@import "../base/library.source.less";
|
|
9
9
|
@import "../../../../../sap/ui/core/themes/sap_horizon_hcw/base.less";
|
|
10
10
|
@import "../../../../../sap/ui/core/themes/sap_horizon_hcw/global.less";
|
|
11
|
-
|
|
12
|
-
@font-face {
|
|
13
|
-
font-family: 'vk-icons';
|
|
14
|
-
src: url('../base/fonts/SAP-VE-icons-bold-v1.4.woff2') format('woff2');
|
|
15
|
-
}
|
|
@@ -54306,7 +54306,7 @@ class PDFDocument {
|
|
|
54306
54306
|
if (PDF_VERSION_REGEXP.test(version)) {
|
|
54307
54307
|
this._version = version;
|
|
54308
54308
|
} else {
|
|
54309
|
-
warn(`Invalid PDF header version: 1.136.
|
|
54309
|
+
warn(`Invalid PDF header version: 1.136.3`);
|
|
54310
54310
|
}
|
|
54311
54311
|
}
|
|
54312
54312
|
parseStartXRef() {
|
|
@@ -33,7 +33,7 @@ sap.ui.define([
|
|
|
33
33
|
* @class Provides a class to communicate with content delivery service.
|
|
34
34
|
* @private
|
|
35
35
|
* @author SAP SE
|
|
36
|
-
* @version 1.136.
|
|
36
|
+
* @version 1.136.3
|
|
37
37
|
* @extends sap.ui.base.ManagedObject
|
|
38
38
|
* @alias sap.ui.vk.threejs.ContentDeliveryService
|
|
39
39
|
*/
|
|
@@ -112,7 +112,7 @@ sap.ui.define([
|
|
|
112
112
|
* @param {object} [mSettings] Initial settings for the new ContentManager object.
|
|
113
113
|
* @protected
|
|
114
114
|
* @author SAP SE
|
|
115
|
-
* @version 1.136.
|
|
115
|
+
* @version 1.136.3
|
|
116
116
|
* @extends sap.ui.vk.ContentManager
|
|
117
117
|
* @alias sap.ui.vk.threejs.ContentManager
|
|
118
118
|
* @since 1.50.0
|
|
@@ -31,7 +31,7 @@ sap.ui.define([
|
|
|
31
31
|
* @class Provides the interface for the material.
|
|
32
32
|
* @public
|
|
33
33
|
* @author SAP SE
|
|
34
|
-
* @version 1.136.
|
|
34
|
+
* @version 1.136.3
|
|
35
35
|
* @extends sap.ui.vk.Material
|
|
36
36
|
* @alias sap.ui.vk.threejs.Material
|
|
37
37
|
* @experimental Since 1.60.0 This class is experimental and might be modified or removed in future versions.
|
|
@@ -104,7 +104,7 @@ sap.ui.define([
|
|
|
104
104
|
*
|
|
105
105
|
* @private
|
|
106
106
|
* @author SAP SE
|
|
107
|
-
* @version 1.136.
|
|
107
|
+
* @version 1.136.3
|
|
108
108
|
*/
|
|
109
109
|
var SceneBuilder = function(rootNode, contentResource, resolve, reject) {
|
|
110
110
|
this._rootNode = rootNode;
|
|
@@ -270,6 +270,9 @@ sap.ui.define([
|
|
|
270
270
|
|
|
271
271
|
if (vkScene) {
|
|
272
272
|
this._vkScene = vkScene;
|
|
273
|
+
if (this._sceneMetadata) {
|
|
274
|
+
this._vkScene.setSceneMetadata(this._sceneMetadata);
|
|
275
|
+
}
|
|
273
276
|
}
|
|
274
277
|
return this;
|
|
275
278
|
};
|
|
@@ -4496,5 +4499,13 @@ sap.ui.define([
|
|
|
4496
4499
|
markerNodes.set(newMarkerNodeId, { coordinateSpace: this._vkScene.PoiCoordinateSpaces.ReferenceNodeSpace });
|
|
4497
4500
|
};
|
|
4498
4501
|
|
|
4502
|
+
SceneBuilder.prototype.setSceneMetadata = function(metadata) {
|
|
4503
|
+
if (this._vkScene) {
|
|
4504
|
+
this._vkScene.setSceneMetadata(metadata);
|
|
4505
|
+
} else {
|
|
4506
|
+
this._sceneMetadata = metadata;
|
|
4507
|
+
}
|
|
4508
|
+
};
|
|
4509
|
+
|
|
4499
4510
|
return SceneBuilder;
|
|
4500
4511
|
});
|
|
@@ -21,7 +21,7 @@ sap.ui.define([
|
|
|
21
21
|
* @class Provides the interface for the material.
|
|
22
22
|
* @public
|
|
23
23
|
* @author SAP SE
|
|
24
|
-
* @version 1.136.
|
|
24
|
+
* @version 1.136.3
|
|
25
25
|
* @extends sap.ui.vk.Texture
|
|
26
26
|
* @alias sap.ui.vk.threejs.Texture
|
|
27
27
|
* @experimental Since 1.60.0 This class is experimental and might be modified or removed in future versions.
|
|
@@ -67,7 +67,7 @@ sap.ui.define([
|
|
|
67
67
|
* @param {object} [mSettings] Initial settings for the new ViewStateManager object.
|
|
68
68
|
* @public
|
|
69
69
|
* @author SAP SE
|
|
70
|
-
* @version 1.136.
|
|
70
|
+
* @version 1.136.3
|
|
71
71
|
* @extends sap.ui.vk.ViewStateManagerBase
|
|
72
72
|
* @alias sap.ui.vk.threejs.ViewStateManager
|
|
73
73
|
* @since 1.32.0
|
|
@@ -43,7 +43,7 @@ sap.ui.define([
|
|
|
43
43
|
* @param {object} [mSettings] Initial settings for the new ViewStateManager object.
|
|
44
44
|
* @private
|
|
45
45
|
* @author SAP SE
|
|
46
|
-
* @version 1.136.
|
|
46
|
+
* @version 1.136.3
|
|
47
47
|
* @extends sap.ui.vk.threejs.ViewStateManager
|
|
48
48
|
* @alias sap.ui.vk.threejs.v2.ViewStateManager
|
|
49
49
|
* @since 1.99.0
|
|
@@ -32,7 +32,7 @@ sap.ui.define([
|
|
|
32
32
|
* @param {object} [mSettings] An optional map/JSON object with initial property values, aggregated objects etc. for the new tool instance.
|
|
33
33
|
* @public
|
|
34
34
|
* @author SAP SE
|
|
35
|
-
* @version 1.136.
|
|
35
|
+
* @version 1.136.3
|
|
36
36
|
* @extends sap.ui.vk.tools.Tool
|
|
37
37
|
* @alias sap.ui.vk.tools.AnchorPointTool
|
|
38
38
|
*/
|
|
@@ -32,7 +32,7 @@ sap.ui.define([
|
|
|
32
32
|
* @param {object} [mSettings] An optional map/JSON object with initial property values, aggregated objects etc. for the new tool instance.
|
|
33
33
|
* @public
|
|
34
34
|
* @author SAP SE
|
|
35
|
-
* @version 1.136.
|
|
35
|
+
* @version 1.136.3
|
|
36
36
|
* @extends sap.ui.vk.tools.Tool
|
|
37
37
|
* @alias sap.ui.vk.tools.AxisAngleRotationTool
|
|
38
38
|
*/
|
|
@@ -34,7 +34,7 @@ sap.ui.define([
|
|
|
34
34
|
* @param {object} [mSettings] An optional map/JSON object with initial property values, aggregated objects etc. for the new tool instance.
|
|
35
35
|
* @public
|
|
36
36
|
* @author SAP SE
|
|
37
|
-
* @version 1.136.
|
|
37
|
+
* @version 1.136.3
|
|
38
38
|
* @extends sap.ui.vk.tools.Tool
|
|
39
39
|
* @alias sap.ui.vk.tools.CreateEllipseTool
|
|
40
40
|
*/
|