diff --git a/src/cadence.py b/src/cadence.py index da36084..1df02a4 100755 --- a/src/cadence.py +++ b/src/cadence.py @@ -55,7 +55,16 @@ try: from dbus.mainloop.pyqt5 import DBusQtMainLoop haveDBus = True except: - haveDBus = False + kxstudioWorkaround = "/opt/kxstudio/python3/dist-packages/dbus/mainloop" + if os.path.exists(kxstudioWorkaround): + try: + sys.path.insert(0, kxstudioWorkaround) + from pyqt5 import DBusQtMainLoop + haveDBus = True + except: + haveDBus = False + else: + haveDBus = False # ------------------------------------------------------------------------------------------------------------ # Check for PulseAudio and Wine @@ -2272,7 +2281,7 @@ class CadenceMainW(QMainWindow, ui_cadence.Ui_CadenceMainW): usingAlsaLoop = bool(GlobalSettings.value("ALSA-Audio/BridgeIndexType", iAlsaFileNone, type=int) == iAlsaFileLoop) - self.cb_jack_autostart.setChecked(GlobalSettings.value("JACK/AutoStart", False, type=bool)) + self.cb_jack_autostart.setChecked(GlobalSettings.value("JACK/AutoStart", wantJackStart, type=bool)) self.cb_a2j_autostart.setChecked(GlobalSettings.value("A2J/AutoStart", True, type=bool)) self.cb_pulse_autostart.setChecked(GlobalSettings.value("Pulse2JACK/AutoStart", havePulseAudio and not usingAlsaLoop, type=bool)) diff --git a/src/cadence_session_start.py b/src/cadence_session_start.py index 6f26a70..8ed1f8f 100755 --- a/src/cadence_session_start.py +++ b/src/cadence_session_start.py @@ -46,7 +46,7 @@ def forceReset(): # Start JACK, A2J and Pulse, according to user settings def startSession(systemStarted, secondSystemStartAttempt): # Check if JACK is set to auto-start - if systemStarted and not GlobalSettings.value("JACK/AutoStart", False, type=bool): + if systemStarted and not GlobalSettings.value("JACK/AutoStart", wantJackStart, type=bool): print("JACK is set to NOT auto-start on login") return True diff --git a/src/shared_cadence.py b/src/shared_cadence.py index f69abeb..5d14ef6 100644 --- a/src/shared_cadence.py +++ b/src/shared_cadence.py @@ -72,6 +72,11 @@ iAlsaFileMax = 4 GlobalSettings = QSettings("Cadence", "GlobalSettings") +# ------------------------------------------------------------------------------------------------------------ +# KXStudio Check + +wantJackStart = os.path.exists("/usr/share/kxstudio/config/config/Cadence/GlobalSettings.conf") + # ------------------------------------------------------------------------------------------------------------ # Get Process list