diff options
| author | AAGaming <aa@bigdumb.gq> | 2022-06-01 17:50:10 -0400 |
|---|---|---|
| committer | AAGaming <aa@bigdumb.gq> | 2022-06-01 17:50:10 -0400 |
| commit | 86e23686aacccfe22a24e1d63c57f037b7ce2a4d (patch) | |
| tree | a7b899385d8d4523f966497778a31ddc14a270b2 /backend/browser.py | |
| parent | bd1b2e82fdc6ff1725bab61593e1f54d0b975fe0 (diff) | |
| download | decky-loader-86e23686aacccfe22a24e1d63c57f037b7ce2a4d.tar.gz decky-loader-86e23686aacccfe22a24e1d63c57f037b7ce2a4d.zip | |
React Plugin install dialog (closes #75)
Diffstat (limited to 'backend/browser.py')
| -rw-r--r-- | backend/browser.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/backend/browser.py b/backend/browser.py index 323fb9c3..a62e282a 100644 --- a/backend/browser.py +++ b/backend/browser.py @@ -80,10 +80,13 @@ class PluginBrowser: async def request_plugin_install(self, artifact, version, hash): request_id = str(time()) self.install_requests[request_id] = PluginInstallContext(artifact, version, hash) - tab = await get_tab("QuickAccess") + tab = await get_tab("SP") await tab.open_websocket() - await tab.evaluate_js(f"addPluginInstallPrompt('{artifact}', '{version}', '{request_id}')") + await tab.evaluate_js(f"DeckyPluginLoader.addPluginInstallPrompt('{artifact}', '{version}', '{request_id}')") async def confirm_plugin_install(self, request_id): request = self.install_requests.pop(request_id) - await self._install(request.gh_url, request.version, request.hash)
\ No newline at end of file + await self._install(request.gh_url, request.version, request.hash) + + def cancel_plugin_install(self, request_id): + self.install_requests.pop(request_id)
\ No newline at end of file |
