mirror of
https://github.com/bombsquad-community/plugin-manager.git
synced 2025-10-08 14:54:36 +00:00
Fixing Build + Screen Messages
This commit is contained in:
parent
cb7b85190e
commit
f6bf4d3bd4
2 changed files with 6 additions and 1 deletions
|
|
@ -80,9 +80,11 @@ class Plugin:
|
|||
with open(self.install_path, "wb") as fout:
|
||||
fout.write(response.read())
|
||||
self.enable()
|
||||
_ba.screenmessage("Plugin Installed")
|
||||
|
||||
def uninstall(self):
|
||||
os.remove(self.install_path)
|
||||
_ba.screenmessage("Plugin Uninstalled")
|
||||
|
||||
def _set_status(self, to_enable=True):
|
||||
if self.entry_point not in ba.app.config["Plugins"]:
|
||||
|
|
@ -92,10 +94,12 @@ class Plugin:
|
|||
def enable(self):
|
||||
self._set_status(to_enable=True)
|
||||
ba.app.config.apply_and_commit()
|
||||
_ba.screenmessage("Plugin Enabled")
|
||||
|
||||
def disable(self):
|
||||
self._set_status(to_enable=False)
|
||||
ba.app.config.commit()
|
||||
_ba.screenmessage("Plugin Disabled")
|
||||
|
||||
|
||||
class PluginWindow(popup.PopupWindow):
|
||||
|
|
@ -218,6 +222,7 @@ class PluginWindow(popup.PopupWindow):
|
|||
ba.containerwidget(edit=self._root_widget, transition='out_scale')
|
||||
return None
|
||||
|
||||
|
||||
class PluginManager:
|
||||
def __init__(self):
|
||||
self.request_headers = HEADERS
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
},
|
||||
{
|
||||
"name": "Vishal",
|
||||
"email": null,
|
||||
"email": "vishal.u338@gmail.com",
|
||||
"discord": "𝑽𝑰𝑺𝑯𝑼𝑼𝑼#2921"
|
||||
}
|
||||
],
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue