Skip to content

Commit

Permalink
Try resource dir as library path first
Browse files Browse the repository at this point in the history
Signed-off-by: falkTX <falktx@falktx.com>
  • Loading branch information
falkTX committed Jun 4, 2023
1 parent 43c3478 commit 214a5aa
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion source/frontend/carla_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,13 @@ def __init__(self, appName = "Carla2", libPrefix = None):
path = "H:\\PawPawBuilds\\targets\\win32\\lib\\qt5\\plugins"
QApplication.addLibraryPath(path)

# Try resource dir as library path first
if os.path.exists(os.path.join(pathResources, "styles", "carlastyle.json")):
QApplication.addLibraryPath(pathResources)
stylesDir = pathResources

# Use binary dir as library path
if os.path.exists(pathBinaries):
elif os.path.exists(pathBinaries):
QApplication.addLibraryPath(pathBinaries)
stylesDir = pathBinaries

Expand Down

0 comments on commit 214a5aa

Please sign in to comment.