The Tauri bridge

tauriBridge() is the JS half of the Tauri shell (shells/tauri). Every call goes to one Rust command, bridge, which implements the protocol natively. Games don't call it directly: nativeBridge() (src/shells.tjs) picks it inside a Tauri shell.

Pause and resume come from the web view's own visibilitychange, which the system web views fire on hide and minimise, and from the shell where it knows more. The shell sends every event as a Tauri event named tosijs-native: plus the event (tosijs-native:owned, tosijs-native:pause). Tauri allows no . in an event name, so one is sent as - (tosijs-native:store-changed).