summaryrefslogtreecommitdiff
path: root/backend/plugin.py
diff options
context:
space:
mode:
authorJonas Dellinger <jonas@dellinger.dev>2022-05-26 13:30:14 +0200
committerJonas Dellinger <jonas@dellinger.dev>2022-05-26 13:30:14 +0200
commit71dd0ea449469ed38e784b9c73b673eece680446 (patch)
tree15914a2b7979296b8c04cac0e75191eb9f955919 /backend/plugin.py
parenta06efc08bc01a4a014d916ff1e219a0f17d0c480 (diff)
parent4b923c1dc70eaa4a3ca58d9e9f3218785b2fe919 (diff)
downloaddecky-loader-71dd0ea449469ed38e784b9c73b673eece680446.tar.gz
decky-loader-71dd0ea449469ed38e784b9c73b673eece680446.zip
Cleanup after merge
Diffstat (limited to 'backend/plugin.py')
-rw-r--r--backend/plugin.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/backend/plugin.py b/backend/plugin.py
index 7d3f36f3..e6cceffd 100644
--- a/backend/plugin.py
+++ b/backend/plugin.py
@@ -10,8 +10,6 @@ from signal import SIGINT, signal
from sys import exit
from time import time
-from injector import inject_to_tab
-
class PluginWrapper:
def __init__(self, file, plugin_directory, plugin_path) -> None:
@@ -24,12 +22,20 @@ class PluginWrapper:
json = load(open(path.join(plugin_path, plugin_directory, "plugin.json"), "r"))
+ self.legacy = False
+ self.main_view_html = json["main_view_html"] if "main_view_html" in json else ""
+ self.tile_view_html = json["tile_view_html"] if "tile_view_html" in json else ""
+ self.legacy = self.main_view_html or self.tile_view_html
+
self.name = json["name"]
self.author = json["author"]
self.flags = json["flags"]
self.passive = not path.isfile(self.file)
+ def __str__(self) -> str:
+ return self.name
+
def _init(self):
signal(SIGINT, lambda s, f: exit(0))