Fixed multi file ipc load speeds

This commit is contained in:
2026-02-26 02:00:36 -06:00
parent 2e84ad9fc1
commit 597ac2b06a
7 changed files with 31 additions and 61 deletions

View File

@@ -87,6 +87,16 @@ class IPCServer(Singleton):
conn.close()
break
if "FILES|" in msg:
import json
data = msg.split("FILES|")[1].strip()
files = json.loads(data)
if files:
event_system.emit("handle-files-from-ipc", (files,))
conn.close()
break
if "DIR|" in msg:
file = msg.split("DIR|")[1].strip()
if file:

View File

@@ -21,6 +21,12 @@ class IPCSignalsMixin:
self.broadcast_message, "handle-file", (fpath,)
)
def handle_files_from_ipc(self, uris: list) -> None:
logger.debug(f"Files From IPC: {uris}")
GLib.idle_add(
self.broadcast_message, "handle-files", (uris,)
)
def handle_dir_from_ipc(self, fpath: str) -> None:
logger.debug(f"Dir From IPC: {fpath}")
GLib.idle_add(