aboutsummaryrefslogtreecommitdiff
path: root/src/webex/wxApi.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/webex/wxApi.ts')
-rw-r--r--src/webex/wxApi.ts12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/webex/wxApi.ts b/src/webex/wxApi.ts
index 128041e57..0bd444856 100644
--- a/src/webex/wxApi.ts
+++ b/src/webex/wxApi.ts
@@ -339,3 +339,15 @@ export function setExtendedPermissions(value: boolean): Promise<ExtendedPermissi
export function getExtendedPermissions(): Promise<ExtendedPermissionsResponse> {
return callBackend("get-extended-permissions", {});
}
+
+
+export function onUpdateNotification(f: () => void): () => void {
+ const port = chrome.runtime.connect({ name: "notifications" });
+ const listener = (): void => {
+ f();
+ };
+ port.onMessage.addListener(listener);
+ return () => {
+ port.onMessage.removeListener(listener);
+ };
+} \ No newline at end of file