Skip to content
This repository was archived by the owner on Oct 18, 2024. It is now read-only.

Commit 640b424

Browse files
authored
Add endpoint to update the context-menu
1 parent ba81b43 commit 640b424

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/server/api/menuBar.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,13 @@ router.post("/label", (req, res) => {
1616
state.activeMenuBar.tray.setTitle(label);
1717
});
1818

19+
router.post("/context-menu", (req, res) => {
20+
res.sendStatus(200);
21+
const { contextMenu } = req.body;
22+
23+
state_1.default.activeMenuBar.tray.setContextMenu(buildMenu(contextMenu));
24+
});
25+
1926
router.post("/show", (req, res) => {
2027
res.sendStatus(200);
2128

0 commit comments

Comments
 (0)