sunrize 1.8.9 → 1.8.10

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "sunrize",
3
3
  "productName": "Sunrize X3D Editor",
4
- "version": "1.8.9",
4
+ "version": "1.8.10",
5
5
  "description": "A Multi-Platform X3D Editor",
6
6
  "main": "src/main.js",
7
7
  "bin": {
@@ -90,7 +90,7 @@
90
90
  "dependencies": {
91
91
  "capitalize": "^2.0.4",
92
92
  "console": "^0.7.2",
93
- "electron": "^36.2.0",
93
+ "electron": "^36.3.1",
94
94
  "electron-prompt": "^1.7.0",
95
95
  "electron-squirrel-startup": "^1.0.1",
96
96
  "electron-tabs": "^1.0.4",
@@ -99,7 +99,7 @@
99
99
  "jquery-ui-dist": "^1.13.3",
100
100
  "jstree": "^3.3.17",
101
101
  "material-icons": "^1.13.14",
102
- "material-symbols": "^0.31.2",
102
+ "material-symbols": "^0.31.3",
103
103
  "md5": "^2.3.0",
104
104
  "mime-types": "^3.0.1",
105
105
  "monaco-editor": "^0.50.0",
@@ -109,7 +109,7 @@
109
109
  "string-similarity": "^4.0.4",
110
110
  "tweakpane": "^3.1.10",
111
111
  "update-electron-app": "^3.1.1",
112
- "x_ite": "^11.5.9",
112
+ "x_ite": "^11.5.10",
113
113
  "x3d-traverse": "^1.0.12"
114
114
  }
115
115
  }
@@ -16,6 +16,7 @@ Object .assign (X3D .X3DComposedGeometryNode .prototype,
16
16
  geometry ._attrib = this ._attrib;
17
17
  geometry ._fogCoord = this ._fogCoord;
18
18
  geometry ._color = this ._color;
19
+ geometry ._texCoord = this ._texCoord;
19
20
  geometry ._tangent = this ._tangent;
20
21
  geometry ._normal = this ._normal;
21
22
  geometry ._coord = this ._coord;
@@ -1199,6 +1199,8 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
1199
1199
 
1200
1200
  undoManager .beginUndo (_("Turn Prototype »%s« into Extern Prototype"), proto .getName ());
1201
1201
 
1202
+ this .removeProtoDeclaration (executionContext, proto .getName (), undoManager);
1203
+
1202
1204
  scene .setWorldURL (url .pathToFileURL (filePath));
1203
1205
 
1204
1206
  await this .importX3D (scene, x3dSyntax, new UndoManager ());
@@ -1219,7 +1221,6 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
1219
1221
  externproto ._url = new X3D .MFString (relativePath + hash, absolutePath + hash);
1220
1222
 
1221
1223
  this .replaceProtoNodes (executionContext, proto, externproto, undoManager);
1222
- this .removeProtoDeclaration (executionContext, proto .getName (), undoManager);
1223
1224
 
1224
1225
  undoManager .endUndo ();
1225
1226
  }
@@ -1288,21 +1289,21 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
1288
1289
  */
1289
1290
  static updateExternProtoDeclaration (executionContext, name, externproto, undoManager = UndoManager .shared)
1290
1291
  {
1291
- const oldName = externproto .getName ()
1292
+ const oldName = externproto .getName ();
1292
1293
 
1293
- undoManager .beginUndo (_("Update Extern Prototype Declaration »%s«"), name)
1294
+ undoManager .beginUndo (_("Update Extern Prototype Declaration »%s«"), name);
1294
1295
 
1295
- executionContext .updateExternProtoDeclaration (name, externproto)
1296
+ executionContext .updateExternProtoDeclaration (name, externproto);
1296
1297
 
1297
1298
  undoManager .registerUndo (() =>
1298
1299
  {
1299
1300
  if (oldName)
1300
- this .updateExternProtoDeclaration (executionContext, oldName, externproto, undoManager)
1301
+ this .updateExternProtoDeclaration (executionContext, oldName, externproto, undoManager);
1301
1302
  else
1302
- this .removeExternProtoDeclaration (executionContext, name, undoManager)
1303
+ this .removeExternProtoDeclaration (executionContext, name, undoManager);
1303
1304
  });
1304
1305
 
1305
- this .requestUpdateInstances (executionContext, undoManager)
1306
+ this .requestUpdateInstances (executionContext, undoManager);
1306
1307
 
1307
1308
  undoManager .endUndo ();
1308
1309
  }
@@ -1315,18 +1316,18 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
1315
1316
  */
1316
1317
  static removeExternProtoDeclaration (executionContext, name, undoManager = UndoManager .shared)
1317
1318
  {
1318
- const oldExternProtos = new Map (Array .from (executionContext .externprotos, p => [p .getName (), p]))
1319
+ const oldExternProtos = new Map (Array .from (executionContext .externprotos, p => [p .getName (), p]));
1319
1320
 
1320
- undoManager .beginUndo (_("Remove Extern Prototype Declaration »%s«"), name)
1321
+ undoManager .beginUndo (_("Remove Extern Prototype Declaration »%s«"), name);
1321
1322
 
1322
- executionContext .removeExternProtoDeclaration (name)
1323
+ executionContext .removeExternProtoDeclaration (name);
1323
1324
 
1324
1325
  undoManager .registerUndo (() =>
1325
1326
  {
1326
- this .setExternProtoDeclarations (executionContext, oldExternProtos, undoManager)
1327
+ this .setExternProtoDeclarations (executionContext, oldExternProtos, undoManager);
1327
1328
  });
1328
1329
 
1329
- this .requestUpdateInstances (executionContext, undoManager)
1330
+ this .requestUpdateInstances (executionContext, undoManager);
1330
1331
 
1331
1332
  undoManager .endUndo ();
1332
1333
  }
@@ -1339,30 +1340,30 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
1339
1340
  */
1340
1341
  static setExternProtoDeclarations (executionContext, externprotos, undoManager = UndoManager .shared)
1341
1342
  {
1342
- const oldExternProtos = new Map (Array .from (executionContext .externprotos, p => [p .getName (), p]))
1343
+ const oldExternProtos = new Map (Array .from (executionContext .externprotos, p => [p .getName (), p]));
1343
1344
 
1344
- undoManager .beginUndo (_("Update Extern Prototype Declarations"))
1345
+ undoManager .beginUndo (_("Update Extern Prototype Declarations"));
1345
1346
 
1346
1347
  for (const name of oldExternProtos .keys ())
1347
- executionContext .removeExternProtoDeclaration (name)
1348
+ executionContext .removeExternProtoDeclaration (name);
1348
1349
 
1349
1350
  if (Array .isArray (externprotos))
1350
1351
  {
1351
1352
  for (const externproto of externprotos)
1352
- executionContext .updateExternProtoDeclaration (externproto .getName (), externproto)
1353
+ executionContext .updateExternProtoDeclaration (externproto .getName (), externproto);
1353
1354
  }
1354
1355
  else
1355
1356
  {
1356
1357
  for (const [name, externproto] of externprotos)
1357
- executionContext .updateExternProtoDeclaration (name, externproto)
1358
+ executionContext .updateExternProtoDeclaration (name, externproto);
1358
1359
  }
1359
1360
 
1360
1361
  undoManager .registerUndo (() =>
1361
1362
  {
1362
- this .setExternProtoDeclarations (executionContext, oldExternProtos, undoManager)
1363
+ this .setExternProtoDeclarations (executionContext, oldExternProtos, undoManager);
1363
1364
  });
1364
1365
 
1365
- this .requestUpdateInstances (executionContext, undoManager)
1366
+ this .requestUpdateInstances (executionContext, undoManager);
1366
1367
 
1367
1368
  undoManager .endUndo ();
1368
1369
  }
@@ -1378,26 +1379,27 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
1378
1379
  {
1379
1380
  const
1380
1381
  numProtos = executionContext .protos .length,
1381
- x3dSyntax = await this .exportX3D (externproto .getInternalScene (), [externproto .getProtoDeclaration ()])
1382
+ x3dSyntax = await this .exportX3D (externproto .getInternalScene (), [externproto .getProtoDeclaration ()]);
1383
+
1384
+ undoManager .beginUndo (_("Turn Extern Prototype »%s« into Prototype"), externproto .getName ());
1382
1385
 
1383
- undoManager .beginUndo (_("Turn Extern Prototype »%s« into Prototype"), externproto .getName ())
1386
+ this .removeExternProtoDeclaration (executionContext, externproto .getName (), undoManager);
1384
1387
 
1385
- await this .importX3D (executionContext, x3dSyntax, undoManager)
1388
+ await this .importX3D (executionContext, x3dSyntax, undoManager);
1386
1389
 
1387
1390
  const
1388
1391
  protos = Array .from (executionContext .protos),
1389
1392
  importedProtos = protos .splice (numProtos, protos .length - numProtos),
1390
- proto = importedProtos .at (-1)
1393
+ proto = importedProtos .at (-1);
1391
1394
 
1392
1395
  for (const proto of importedProtos .reverse ())
1393
1396
  {
1394
- protos .unshift (proto)
1395
- this .rewriteURLs (executionContext, proto, externproto .getInternalScene () .worldURL, executionContext .worldURL, new UndoManager ())
1397
+ protos .unshift (proto);
1398
+ this .rewriteURLs (executionContext, proto, externproto .getInternalScene () .worldURL, executionContext .worldURL, new UndoManager ());
1396
1399
  }
1397
1400
 
1398
- this .setProtoDeclarations (executionContext, protos, undoManager)
1399
- this .replaceProtoNodes (executionContext, externproto, proto, undoManager)
1400
- this .removeExternProtoDeclaration (executionContext, externproto .getName (), undoManager)
1401
+ this .setProtoDeclarations (executionContext, protos, undoManager);
1402
+ this .replaceProtoNodes (executionContext, externproto, proto, undoManager);
1401
1403
 
1402
1404
  undoManager .endUndo ();
1403
1405
  }