INCOMPLETE, DONT PUSH:

refactor: reorganize state management and update import paths across modules and start changing json parsing
This commit is contained in:
Vxrtrauter
2025-10-09 16:42:18 +02:00
parent 5da7989157
commit 53b2bb912e
12 changed files with 65 additions and 43 deletions
+17
View File
@@ -0,0 +1,17 @@
from core.utils.data.state import state
from core.utils.data.tracker import get_item_index
from core.utils.wrappers import run_thread
import threading
def download_selected(item, ):
if item is not None:
if state.debug:
print(f"network {item.text()}")
run_thread(threading.Thread(target=get_item_index, args=(item.text(), self.postnames, self.postlinks, state.debug)))
else:
if state.debug:
print("No item selected for download.")
+10
View File
@@ -0,0 +1,10 @@
def split_data(data):
json = json.loads(data)
count = json["count"]
posts = json["data"]
query = json["query"]
success = json["success"]
return count, posts, query, success