Skip to content

Commit

Permalink
post-merge commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Félix committed Nov 22, 2023
1 parent 111428b commit 0a18be9
Showing 1 changed file with 3 additions and 22 deletions.
25 changes: 3 additions & 22 deletions panoptic_back/panoptic/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@
import qtawesome as qta
import requests
import uvicorn
from PyQt5.QtCore import QSize, QThread, pyqtSignal
from PyQt5.QtCore import QSize
from PyQt5.QtGui import QCursor

import panoptic
from panoptic.utils import get_datadir

PORT = 2626
PORT = 8000
HOST = False
THREAD = None

Expand All @@ -35,16 +35,6 @@ def api(path):
QPushButton, QLineEdit, QFileDialog, QListWidget, QDesktopWidget
from PyQt5 import QtCore, QtGui

class InitThread(QThread):
initialization_complete = pyqtSignal()

def __init__(self, ui):
super().__init__()
self.ui = ui

def run(self):
self.ui.init_projects()
self.initialization_complete.emit()

class IconLabel(QWidget):

Expand Down Expand Up @@ -334,15 +324,6 @@ def load_project(self, event=None):
requests.post(api("project"), json={"project": os.environ["PANOPTIC_DATA"]})
self.init_folders()

def start_init_thread(self):
self.init_projects()
self.on_initialization_complete()
# self.init_thread = InitThread(self)
# self.init_thread.initialization_complete.connect(self.on_initialization_complete)
# self.init_thread.start()

def on_initialization_complete(self):
self._set_processing(False, "Initialisation terminée")

def on_fastapi_start():
ui.server_status.setText('Initialisation...')
Expand Down Expand Up @@ -403,7 +384,7 @@ def start():
global ui
ui = MiniUI()
ui.show()
ui.start_init_thread()
ui.init_projects()
sys.exit(app.exec_())
else:
if not FOLDER:
Expand Down

0 comments on commit 0a18be9

Please sign in to comment.