dashboard-windows: match the mailbox class by undecorated methods

WebSocketSend is a MobX @action.bound method, a getter on the prototype in
the page (a plain method only in the offline checker's sandbox), so the
Mailbox signature never matched live. Use SendMessage,
SendMessageAndWaitForResponse and RegisterHandler instead; note the pitfall
at protoMethods in finders.js.
This commit is contained in:
Pierre Kisters committed 2026-09-27 20:12:32 +02:00
1 parent 9f5538003f
commit 9fdb21e598
2 files changed
+5 -2

No files matched your search

+4 -1
View File
@@ -27,7 +27,10 @@
// "props": { "k": value } data properties (own or inherited) equal to // "props": { "k": value } data properties (own or inherited) equal to
// the given JSON primitives; getters never run, // the given JSON primitives; getters never run,
// "has": ["k", ...] properties present (`in`, incl. getters), // "has": ["k", ...] properties present (`in`, incl. getters),
// "protoMethods": ["m", ...] (class) methods on its prototype chain, // "protoMethods": ["m", ...] (class) methods on its prototype chain
// (plain methods only: decorated ones, e.g.
// MobX @action.bound, are getters in the
// page, though methods offline),
// "methods": ["m", ...] (instance) methods on its prototype chain, // "methods": ["m", ...] (instance) methods on its prototype chain,
// "getters": ["g", ...] getters on its prototype chain } // "getters": ["g", ...] getters on its prototype chain }
// Fields that only scripts/check-signatures.mjs uses: "expects" (strings the // Fields that only scripts/check-signatures.mjs uses: "expects" (strings the
+1 -1
View File
@@ -106,7 +106,7 @@
"mailbox": { "mailbox": {
"module": { "includes": ["\"mailbox_send \"", "WebSocketSend(", "\"vrcompositor_systemlayer\""] }, "module": { "includes": ["\"mailbox_send \"", "WebSocketSend(", "\"vrcompositor_systemlayer\""] },
"exports": { "exports": {
"Mailbox": { "type": "class", "protoMethods": ["SendMessage", "WebSocketSend"] } "Mailbox": { "type": "class", "protoMethods": ["SendMessage", "SendMessageAndWaitForResponse", "RegisterHandler"] }
} }
}, },
"sceneGraph": { "sceneGraph": {