Added audio analysis page

This commit is contained in:
ppravatto
2024-06-16 14:24:36 +02:00
parent 5f513b1c76
commit 87295d6e9d
6 changed files with 3488 additions and 3394 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -17,6 +17,7 @@ from artemis.ui.dbmanager import UIdbmanager
from artemis.ui.signaleditor import UIsignaleditor
from artemis.ui.downloader import UIDownloader
from artemis.ui.spaceweather import UIspaceweather
from artemis.ui.audioanalysis import UIAudioAnalysis
from artemis.ui.documentsmanager import UIdocumentsmanager
from artemis.ui.categoryeditor import UIcategoryeditor
@@ -64,6 +65,7 @@ class UIArtemis(QObject):
self.preferences = UIPreferences(self)
self.dbmanager = UIdbmanager(self)
self.spaceweather = UIspaceweather(self)
self.audioanalysis = UIAudioAnalysis(self)
self.docmanager = UIdocumentsmanager(self)
self.sigeditor = UIsignaleditor(self)
self.cateditor = UIcategoryeditor(self)
@@ -84,6 +86,7 @@ class UIArtemis(QObject):
self._window.updateDb.connect(self.update_db)
self._window.updateArtemis.connect(self.update_artemis)
self._window.showSpaceWeather.connect(self.show_space_weather_ui)
self._window.showAudioAnalysis.connect(self.show_audio_analysis_ui)
self._window.openDbDirectory.connect(self.open_db_directory)
self._window.showCatManager.connect(self.open_cat_manager)
@@ -211,6 +214,12 @@ class UIArtemis(QObject):
self.spaceweather.load_spaceweather_ui()
def show_audio_analysis_ui(self):
""" Open the space weather windows
"""
self.audioanalysis.load_audioanalysis_ui()
def show_documentsmanager_ui(self):
""" Open the documents manager windows
"""

View File

@@ -0,0 +1,29 @@
from PySide6.QtQml import QQmlApplicationEngine
from PySide6.QtCore import QObject, Slot, Signal
class UIAudioAnalysis(QObject):
# Python > QML Signals
show_ui = Signal()
def __init__(self, parent):
super().__init__()
self._parent = parent
self._engine = QQmlApplicationEngine()
self._engine.load('qrc:/ui/AudioAnalysis.qml')
self._window = self._engine.rootObjects()[0]
self._connect()
def _connect(self):
# QML > Python connections
# Python > QML connections
self.show_ui.connect(self._window.show)
def load_audioanalysis_ui(self):
self.show_ui.emit()