sunrize 2.3.5 → 2.4.1
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 +13 -13
- package/src/Application/Application.js +3 -3
- package/src/Application/Document.js +1 -1
- package/src/Application/Footer.js +10 -5
- package/src/Application/Tabs.js +13 -5
- package/src/Bits/X3DUOM.js +0 -3
- package/src/Controls/Tabs.js +4 -3
- package/src/Editors/AnimationEditor.js +193 -180
- package/src/Editors/OutlineEditor.js +51 -55
- package/src/Editors/OutlineView.js +89 -53
- package/src/Editors/RouteGraph.js +2381 -0
- package/src/Tools/Grids/GridTool.js +6 -2
- package/src/Tools/Grids/X3DGridNodeTool.js +1 -1
- package/src/Tools/Rendering/X3DGeometryNodeTool.js +2 -3
- package/src/Tools/Text/TextTool.js +1 -14
- package/src/Tools.js +3 -0
- package/src/Undo/Editor.js +39 -10
- package/src/Undo/UndoManager.js +18 -7
- package/src/assets/X3DUOM.xml +11 -9
- package/src/assets/html/application-template.html +1 -1
- package/src/assets/html/application.html +1 -1
- package/src/assets/themes/default.css +361 -37
- package/src/assets/themes/system-colors.css +17 -3
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sunrize",
|
|
3
3
|
"productName": "Sunrize X3D Editor",
|
|
4
|
-
"version": "2.
|
|
4
|
+
"version": "2.4.1",
|
|
5
5
|
"description": "Sunrize — A Multi-Platform X3D Editor",
|
|
6
6
|
"main": "src/main.js",
|
|
7
7
|
"bin": {
|
|
@@ -83,23 +83,23 @@
|
|
|
83
83
|
"url": "https://patreon.com/X_ITE"
|
|
84
84
|
},
|
|
85
85
|
"devDependencies": {
|
|
86
|
-
"@electron-forge/cli": "^
|
|
87
|
-
"@electron-forge/maker-deb": "^
|
|
88
|
-
"@electron-forge/maker-dmg": "^
|
|
89
|
-
"@electron-forge/maker-rpm": "^
|
|
90
|
-
"@electron-forge/maker-squirrel": "^
|
|
91
|
-
"@electron-forge/maker-zip": "^
|
|
92
|
-
"@electron-forge/publisher-github": "^
|
|
86
|
+
"@electron-forge/cli": "^8.0.1",
|
|
87
|
+
"@electron-forge/maker-deb": "^8.0.1",
|
|
88
|
+
"@electron-forge/maker-dmg": "^8.0.1",
|
|
89
|
+
"@electron-forge/maker-rpm": "^8.0.1",
|
|
90
|
+
"@electron-forge/maker-squirrel": "^8.0.1",
|
|
91
|
+
"@electron-forge/maker-zip": "^8.0.1",
|
|
92
|
+
"@electron-forge/publisher-github": "^8.0.1",
|
|
93
93
|
"@eslint/js": "^10.0.1",
|
|
94
|
-
"eslint": "^10.
|
|
95
|
-
"globals": "^17.
|
|
94
|
+
"eslint": "^10.12.0",
|
|
95
|
+
"globals": "^17.13.0",
|
|
96
96
|
"shell-tools": "^1.1.9"
|
|
97
97
|
},
|
|
98
98
|
"dependencies": {
|
|
99
99
|
"@vscode/codicons": "^0.0.45",
|
|
100
100
|
"capitalize": "^2.0.4",
|
|
101
101
|
"console": "^0.7.2",
|
|
102
|
-
"electron": "^44.
|
|
102
|
+
"electron": "^44.5.1",
|
|
103
103
|
"electron-prompt": "^1.7.0",
|
|
104
104
|
"electron-squirrel-startup": "^1.0.1",
|
|
105
105
|
"electron-tabs": "^1.0.4",
|
|
@@ -108,7 +108,7 @@
|
|
|
108
108
|
"jquery-ui-dist": "^1.13.3",
|
|
109
109
|
"jstree": "^3.3.17",
|
|
110
110
|
"material-icons": "^1.13.14",
|
|
111
|
-
"material-symbols": "^0.47.
|
|
111
|
+
"material-symbols": "^0.47.6",
|
|
112
112
|
"md5": "^2.3.0",
|
|
113
113
|
"mime-types": "^3.0.2",
|
|
114
114
|
"monaco-editor": "^0.55.1",
|
|
@@ -118,7 +118,7 @@
|
|
|
118
118
|
"string-similarity": "^4.0.4",
|
|
119
119
|
"tweakpane": "^4.0.5",
|
|
120
120
|
"update-electron-app": "^3.3.0",
|
|
121
|
-
"x_ite": "^16.4.
|
|
121
|
+
"x_ite": "^16.4.3",
|
|
122
122
|
"x_ite-off-parser": "^1.3.0",
|
|
123
123
|
"x_ite-sog-parser": "^2.1.0",
|
|
124
124
|
"x_ite-spz-parser": "^2.1.0",
|
|
@@ -97,7 +97,7 @@ module .exports = class Application
|
|
|
97
97
|
electron .ipcMain .on ("current-file", (event, currentFile) => this .currentFile = currentFile);
|
|
98
98
|
electron .ipcMain .on ("add-recent-location", (event, fileURL) => this .addRecentLocation (fileURL));
|
|
99
99
|
electron .ipcMain .on ("update-menu", (event, options) => this .updateMenu (options));
|
|
100
|
-
electron .ipcMain .on ("context-menu", (event,
|
|
100
|
+
electron .ipcMain .on ("context-menu", (event, ... args) => this .contextMenu (... args));
|
|
101
101
|
|
|
102
102
|
electron .ipcMain .handle ("open-files", async (event, urls) => this .openFiles (urls));
|
|
103
103
|
electron .ipcMain .handle ("file-path", async (event, options) => await this .showDialog (options));
|
|
@@ -966,11 +966,11 @@ module .exports = class Application
|
|
|
966
966
|
this .createWindow ();
|
|
967
967
|
}
|
|
968
968
|
|
|
969
|
-
contextMenu (id, menu)
|
|
969
|
+
contextMenu (id, menu, menuId)
|
|
970
970
|
{
|
|
971
971
|
const contextMenu = electron .Menu .buildFromTemplate (this .addMenuItemHandlers (id, this .filterSeparators (menu)));
|
|
972
972
|
|
|
973
|
-
contextMenu .on ("menu-will-close", () => this .mainWindow .webContents .send (
|
|
973
|
+
contextMenu .on ("menu-will-close", () => this .mainWindow .webContents .send ("context-menu-will-close", menuId));
|
|
974
974
|
|
|
975
975
|
contextMenu .popup ({ window: this .mainWindow });
|
|
976
976
|
}
|
|
@@ -955,7 +955,7 @@ module .exports = class Document extends Interface
|
|
|
955
955
|
grid ._visible .addInterest ("updateMenu", this);
|
|
956
956
|
tool .getValue () .getField ("isActive") .addInterest ("handleUndoForGrid", this, typeName);
|
|
957
957
|
|
|
958
|
-
UndoManager .shared .beginUndo (_
|
|
958
|
+
UndoManager .shared .beginUndo (_("Change Visibility of %s"), typeName);
|
|
959
959
|
|
|
960
960
|
if (visible)
|
|
961
961
|
{
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
const
|
|
4
|
-
Tabs
|
|
5
|
-
Console
|
|
6
|
-
|
|
7
|
-
|
|
4
|
+
Tabs = require ("../Controls/Tabs"),
|
|
5
|
+
Console = require ("../Editors/Console"),
|
|
6
|
+
RouteGraph = require ("../Editors/RouteGraph"),
|
|
7
|
+
$ = require ("jquery"),
|
|
8
|
+
_ = require ("./GetText");
|
|
8
9
|
|
|
9
10
|
module .exports = class Footer extends Tabs
|
|
10
11
|
{
|
|
@@ -26,11 +27,15 @@ module .exports = class Footer extends Tabs
|
|
|
26
27
|
this .addIconTextTab ("animation-editor","animation", _("Animation Editor"))
|
|
27
28
|
.find (".material-icons") .css ("color", "hsl(246, 40%, 48%)");
|
|
28
29
|
|
|
30
|
+
this .addIconTextTab ("route-graph","route", _("Route Graph"))
|
|
31
|
+
.find (".material-icons") .css ("color", "hsl(281, 40%, 48%)");
|
|
32
|
+
|
|
29
33
|
$("<div></div>")
|
|
30
34
|
.addClass (["toolbar", "vertical-toolbar"])
|
|
31
35
|
.appendTo (this .element);
|
|
32
36
|
|
|
33
|
-
this .console
|
|
37
|
+
this .console = new Console (this .getPanel ("console"));
|
|
38
|
+
this .routeGraph = new RouteGraph (this .getPanel ("route-graph"));
|
|
34
39
|
}
|
|
35
40
|
|
|
36
41
|
initTab (panel)
|
package/src/Application/Tabs.js
CHANGED
|
@@ -131,7 +131,9 @@ module .exports = new class Tabs
|
|
|
131
131
|
this .forwardToActiveTab ("document");
|
|
132
132
|
this .forwardToActiveTab ("script-editor");
|
|
133
133
|
this .forwardToActiveTab ("animation-members-list");
|
|
134
|
+
this .forwardToActiveTab ("route-graph");
|
|
134
135
|
this .forwardToActiveTab ("outline-editor");
|
|
136
|
+
this .forwardToActiveTab ("context-menu-will-close");
|
|
135
137
|
|
|
136
138
|
// Restore tabs.
|
|
137
139
|
this .restoreTabs (this .config .activeTab);
|
|
@@ -325,8 +327,8 @@ module .exports = new class Tabs
|
|
|
325
327
|
|
|
326
328
|
const menu = [
|
|
327
329
|
{
|
|
328
|
-
label: tab .url .startsWith ("file:") ? _("Copy Path") : _("Copy URL"),
|
|
329
|
-
|
|
330
|
+
label: tab .url .startsWith ("file:") || tab .url .startsWith ("id:") ? _("Copy Path") : _("Copy URL"),
|
|
331
|
+
enabled: !tab .url .startsWith ("id:"),
|
|
330
332
|
args: ["menuCopyURL", tab .getPosition ()],
|
|
331
333
|
},
|
|
332
334
|
{
|
|
@@ -339,7 +341,7 @@ module .exports = new class Tabs
|
|
|
339
341
|
default: return _("Reveal File in File Manager");
|
|
340
342
|
}
|
|
341
343
|
})(),
|
|
342
|
-
|
|
344
|
+
enabled: tab .url .startsWith ("file:"),
|
|
343
345
|
args: ["menuShowItemInFolder", tab .getPosition ()],
|
|
344
346
|
},
|
|
345
347
|
{ type: "separator" },
|
|
@@ -394,8 +396,14 @@ module .exports = new class Tabs
|
|
|
394
396
|
},
|
|
395
397
|
];
|
|
396
398
|
|
|
397
|
-
|
|
398
|
-
|
|
399
|
+
const menuId = Math .random ();
|
|
400
|
+
|
|
401
|
+
electron .ipcRenderer .send ("context-menu", "tabs-menu", menu, menuId);
|
|
402
|
+
electron .ipcRenderer .once ("context-menu-will-close", (event, id) =>
|
|
403
|
+
{
|
|
404
|
+
if (id === menuId)
|
|
405
|
+
$(tab .element) .trigger ("blur");
|
|
406
|
+
});
|
|
399
407
|
}
|
|
400
408
|
|
|
401
409
|
menuCopyURL (position)
|
package/src/Bits/X3DUOM.js
CHANGED
|
@@ -15,7 +15,4 @@ X3DUOM .find ("ConcreteNodes") .append (X_ITE .find ("ConcreteNode"));
|
|
|
15
15
|
X3DUOM .find ("AbstractNodeType[name=X3DOneSidedMaterialNode]")
|
|
16
16
|
.append (X3DUOM .find ("field[name=emissiveColor]") .first () .clone ());
|
|
17
17
|
|
|
18
|
-
// detune fix
|
|
19
|
-
X3DUOM .find ("field[name=detune]") .removeAttr ("minInclusive");
|
|
20
|
-
|
|
21
18
|
module .exports = X3DUOM;
|
package/src/Controls/Tabs.js
CHANGED
|
@@ -21,7 +21,7 @@ module .exports = class Tabs extends Interface
|
|
|
21
21
|
|
|
22
22
|
this .element .tabs ();
|
|
23
23
|
this .element .tabs ("option", "classes.ui-tabs", this .orientation);
|
|
24
|
-
this .element .on ("tabsactivate", () => this .
|
|
24
|
+
this .element .on ("tabsactivate", () => this .activateTab ());
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
addTabs () { }
|
|
@@ -31,12 +31,12 @@ module .exports = class Tabs extends Interface
|
|
|
31
31
|
this .config .file .setDefaultValues (Object .assign ({ active: 0 }, defaults));
|
|
32
32
|
|
|
33
33
|
if (this .element .tabs ("option", "active") === this .config .file .active)
|
|
34
|
-
this .
|
|
34
|
+
this .activateTab ();
|
|
35
35
|
else
|
|
36
36
|
this .element .tabs ("option", "active", this .config .file .active);
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
-
|
|
39
|
+
activateTab ()
|
|
40
40
|
{
|
|
41
41
|
const
|
|
42
42
|
active = this .element .tabs ("option", "active"),
|
|
@@ -48,6 +48,7 @@ module .exports = class Tabs extends Interface
|
|
|
48
48
|
return;
|
|
49
49
|
|
|
50
50
|
panel .data ("Tabs.initialized", true);
|
|
51
|
+
|
|
51
52
|
this .initTab (panel);
|
|
52
53
|
}
|
|
53
54
|
|