x3d-tidy 1.0.62 → 1.0.64
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/build/publish.pl +1 -1
- package/package.json +1 -1
- package/src/convert.js +3 -1
- package/src/main.js +5 -0
package/build/publish.pl
CHANGED
package/package.json
CHANGED
package/src/convert.js
CHANGED
|
@@ -35,6 +35,7 @@ async function main (argv)
|
|
|
35
35
|
catch (error)
|
|
36
36
|
{
|
|
37
37
|
electron .ipcRenderer .send ("error", error .message || error)
|
|
38
|
+
electron .ipcRenderer .send ("exit", 1)
|
|
38
39
|
}
|
|
39
40
|
}
|
|
40
41
|
|
|
@@ -109,6 +110,7 @@ async function convert (argv)
|
|
|
109
110
|
Browser .setBrowserOption ("PrimitiveQuality", "HIGH");
|
|
110
111
|
Browser .setBrowserOption ("TextureQuality", "HIGH");
|
|
111
112
|
|
|
113
|
+
await Browser .loadComponents (Browser .getProfile ("Full"))
|
|
112
114
|
await Browser .loadURL (new X3D .MFString (input))
|
|
113
115
|
|
|
114
116
|
Browser .currentScene .setMetaData ("converter", `${pkg .name} V${pkg .version}, ${pkg .homepage}`)
|
|
@@ -130,7 +132,7 @@ async function convert (argv)
|
|
|
130
132
|
|
|
131
133
|
if (args .output)
|
|
132
134
|
{
|
|
133
|
-
const output = path .resolve (process .cwd (), args .output)
|
|
135
|
+
const output = path .resolve (args .cwd || process .cwd (), args .output)
|
|
134
136
|
|
|
135
137
|
if (path .extname (output))
|
|
136
138
|
fs .writeFileSync (output, getContents ({ ...options, type: path .extname (output) }))
|
package/src/main.js
CHANGED
|
@@ -40,6 +40,11 @@ electron .app .whenReady () .then (async () =>
|
|
|
40
40
|
process .stderr .write ("\n")
|
|
41
41
|
})
|
|
42
42
|
|
|
43
|
+
electron .ipcMain .on ("exit", (event, code = 0) =>
|
|
44
|
+
{
|
|
45
|
+
process .exit (code)
|
|
46
|
+
})
|
|
47
|
+
|
|
43
48
|
await window .loadFile (path .join (__dirname, "window.html"))
|
|
44
49
|
|
|
45
50
|
window .webContents .send ("convert", process .argv)
|