Commit Graph

17 Commits

Author SHA1 Message Date
Snarling
b9b5a62105
Fix electron link handling (#396) 2023-02-25 17:42:26 -05:00
Snarling
f266906f6f
ELECTRON: security fix (#319) 2023-01-10 19:12:23 -05:00
Olivier Gagnon
48f80f25d6 fmt and lint 2022-04-06 19:30:08 -04:00
phyzical
ee6c13d33b add app id for notifications and other magic 2022-04-04 22:15:46 +08:00
hydroflame
e392e6d71f
Merge pull request #2780 from MartinFournier/feat/electron-store-winposition
Store Electron window position in user settings
2022-01-26 12:57:09 -05:00
Martin Fournier
855a4e622d Add Electron preload script to allow communication
Adds a channel to communicate between the main process & the renderer
process, so that the game can easily ship data back to the main process.

It uses the Electron contextBridge & ipcRenderer/ipcMain.

Connects those events to various save functions. Adds triggered events
on game save, game load, and imported game. Adds way for the Electron
app to ask for certain actions or data.

Hook handlers to disable automatic restore

Allows to temporarily disable restore when the game just did an import
or deleted a save game. Prevents looping screens.
2022-01-26 03:56:19 -05:00
Martin Fournier
ca5f51b7f0 Keep Electron window position in settings
This allows the app to be kept at the same location it was previously.
2022-01-26 03:39:50 -05:00
hydroflame
862835e452
Merge pull request #2777 from MartinFournier/feat/electron-linux-icon
Add missing steam app icon for linux
2022-01-26 00:40:18 -05:00
Martin Fournier
df0a86966a Add icon for linux 2022-01-23 16:52:19 -05:00
Martin Fournier
ee416dc06e Set nativeWindowOpen to fix deprecation warning 2022-01-23 13:01:40 -05:00
Martin Fournier
63413a646a Prevent external files to be opened by electron 2022-01-11 11:04:58 -05:00
Olivier Gagnon
ab15481cd6 try to fix the game hanging 2022-01-09 14:11:33 -05:00
Martin Fournier
0b88922ab7 Add zoom to electron app 2022-01-04 21:20:42 -05:00
Martin Fournier
bdef14b029 Add API server information menu item 2022-01-03 10:29:56 -05:00
Martin Fournier
b402cc7f6e Add warning on game close if user launched browser 2021-12-31 04:22:04 -05:00
Martin Fournier
bf1a2b56ba Use global references for electron event handlers
I messed up the handlers reference in the last commit so the events
were not properly attached. Changed it to use global variables for now.
2021-12-30 09:12:55 -05:00
Martin Fournier
a098289856 Refactor electron app into multiple files
Gracefully handle http-server start error & cleanup logs
2021-12-29 08:46:56 -05:00