From ce1303e9e65035768b3d60265a1f9d8d1f705587 Mon Sep 17 00:00:00 2001 From: Athanasius Date: Sat, 31 Dec 2022 16:16:52 +0000 Subject: [PATCH] UI: Make a frame to hold each plugin's UI NB: Currently breaks some core/internal plugin code, due to use of `parent.children` and the like. That will get addressed in subsequent commits. --- EDMarketConnector.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/EDMarketConnector.py b/EDMarketConnector.py index 556660ce..23136e97 100755 --- a/EDMarketConnector.py +++ b/EDMarketConnector.py @@ -562,7 +562,12 @@ class AppWindow(object): plugin_no = 0 for plugin in plug.PLUGINS: - appitem = plugin.get_app(frame) + # Per plugin frame + plugin_frame = tk.Frame( + frame, + name=f"plugin_{plugin_no + 1}" + ) + appitem = plugin.get_app(plugin_frame) if appitem: plugin_no += 1 tk.Frame( @@ -576,6 +581,9 @@ class AppWindow(object): else: appitem.grid(columnspan=2, sticky=tk.EW) + else: + plugin_frame.destroy() + # LANG: Update button in main window self.button = ttk.Button( frame,