feat: print the pictures the game's print kits send

the game page's ajPrint (printImage) had nothing taking it: the picture now goes on a page of its own in a hidden window that runs no script, and the system print dialog opens.
This commit is contained in:
Burrowdev committed 2026-10-23 21:52:59 +03:00
1 parent b52c9194f5
commit 77be498599
3 files changed
+50

No files matched your search

+2
View File
@@ -26,6 +26,8 @@ contextBridge.exposeInMainWorld("client", {
showFile: file => ipcRenderer.send("showFile", file),
toggleFullscreen: () => ipcRenderer.send("toggleFullscreen"),
openPage: url => ipcRenderer.send("openPage", url),
// a picture from the game to print (main.js): {image, width, height}
printImage: picture => ipcRenderer.send("printImage", picture),
// the player's own theatre video file, which the game page may then load; "" when stopped.
ownVideo: link => ipcRenderer.invoke("ownVideo", link),
// Discord rich presence (discord.js): {appId, state, start, url}, or null.