Browse Source

Misc

tags/1.9.4
falkTX 10 years ago
parent
commit
a01a717f8a
2 changed files with 15 additions and 13 deletions
  1. +4
    -4
      source/carla_database.py
  2. +11
    -9
      source/carla_host.py

+ 4
- 4
source/carla_database.py View File

@@ -315,16 +315,16 @@ def checkPluginAU(filename, tool):
return runCarlaDiscovery(PLUGIN_AU, "AU", filename, tool) return runCarlaDiscovery(PLUGIN_AU, "AU", filename, tool)


def checkPluginCSOUND(filename, tool): def checkPluginCSOUND(filename, tool):
return runCarlaDiscovery(PLUGIN_CSOUND, "CSOUND", filename, tool)
return runCarlaDiscovery(PLUGIN_FILE_CSOUND, "CSOUND", filename, tool)


def checkPluginGIG(filename, tool): def checkPluginGIG(filename, tool):
return runCarlaDiscovery(PLUGIN_GIG, "GIG", filename, tool)
return runCarlaDiscovery(PLUGIN_FILE_GIG, "GIG", filename, tool)


def checkPluginSF2(filename, tool): def checkPluginSF2(filename, tool):
return runCarlaDiscovery(PLUGIN_SF2, "SF2", filename, tool)
return runCarlaDiscovery(PLUGIN_FILE_SF2, "SF2", filename, tool)


def checkPluginSFZ(filename, tool): def checkPluginSFZ(filename, tool):
return runCarlaDiscovery(PLUGIN_SFZ, "SFZ", filename, tool)
return runCarlaDiscovery(PLUGIN_FILE_SFZ, "SFZ", filename, tool)


# ------------------------------------------------------------------------------------------------------------ # ------------------------------------------------------------------------------------------------------------
# Separate Thread for Plugin Search # Separate Thread for Plugin Search


+ 11
- 9
source/carla_host.py View File

@@ -719,26 +719,27 @@ class HostWindow(QMainWindow):
@pyqtSlot() @pyqtSlot()
def slot_fileOpen(self): def slot_fileOpen(self):
fileFilter = self.tr("Carla Project File (*.carxp)") fileFilter = self.tr("Carla Project File (*.carxp)")
filenameTry = QFileDialog.getOpenFileName(self, self.tr("Open Carla Project File"), self.fSavedSettings[CARLA_KEY_MAIN_PROJECT_FOLDER], filter=fileFilter)[0]
filenameTry = QFileDialog.getOpenFileName(self, self.tr("Open Carla Project File"), self.fSavedSettings[CARLA_KEY_MAIN_PROJECT_FOLDER], filter=fileFilter)


if not filenameTry: if not filenameTry:
return return
filename = filenameTry if isinstance(filenameTry, str) else filenameTry[0]


newFile = True newFile = True


if self.fContainer.getPluginCount() > 0: if self.fContainer.getPluginCount() > 0:
ask = QMessageBox.question(self, self.tr("Question"), self.tr("There are some plugins loaded, do you want to remove them now?"), ask = QMessageBox.question(self, self.tr("Question"), self.tr("There are some plugins loaded, do you want to remove them now?"),
QMessageBox.Yes | QMessageBox.No, QMessageBox.No) QMessageBox.Yes | QMessageBox.No, QMessageBox.No)
newFile = ask == QMessageBox.Yes
newFile = (ask == QMessageBox.Yes)


if newFile: if newFile:
self.fContainer.removeAllPlugins() self.fContainer.removeAllPlugins()
self.fProjectFilename = filenameTry
self.fProjectFilename = filename
self.setProperWindowTitle() self.setProperWindowTitle()
self.loadProjectNow() self.loadProjectNow()
else: else:
filenameOld = self.fProjectFilename filenameOld = self.fProjectFilename
self.fProjectFilename = filenameTry
self.fProjectFilename = filename
self.loadProjectNow() self.loadProjectNow()
self.fProjectFilename = filenameOld self.fProjectFilename = filenameOld


@@ -748,16 +749,17 @@ class HostWindow(QMainWindow):
return self.saveProjectNow() return self.saveProjectNow()


fileFilter = self.tr("Carla Project File (*.carxp)") fileFilter = self.tr("Carla Project File (*.carxp)")
filenameTry = QFileDialog.getSaveFileName(self, self.tr("Save Carla Project File"), self.fSavedSettings[CARLA_KEY_MAIN_PROJECT_FOLDER], filter=fileFilter)[0]
filenameTry = QFileDialog.getSaveFileName(self, self.tr("Save Carla Project File"), self.fSavedSettings[CARLA_KEY_MAIN_PROJECT_FOLDER], filter=fileFilter)


if not filenameTry: if not filenameTry:
return return
filename = filenameTry if isinstance(filenameTry, str) else filenameTry[0]


if not filenameTry.endswith(".carxp"):
filenameTry += ".carxp"
if not filename.endswith(".carxp"):
filename += ".carxp"


if self.fProjectFilename != filenameTry:
self.fProjectFilename = filenameTry
if self.fProjectFilename != filename:
self.fProjectFilename = filename
self.setProperWindowTitle() self.setProperWindowTitle()


self.saveProjectNow() self.saveProjectNow()


Loading…
Cancel
Save