diff options
| author | rejbasket <39080670+rejbasket@users.noreply.github.com> | 2021-12-08 22:18:41 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-12-08 22:18:41 +0100 |
| commit | 41ace3a9e53b52b4271554d7aedd88d533ee5f5e (patch) | |
| tree | 83dd3887459eeb79c95177bf318598ee01514fa1 /lib/extensions | |
| parent | 49d0f88278798a6c061ce70dd6c1aafb0b1f7a6a (diff) | |
add macOS and windows installer (#1352)
Diffstat (limited to 'lib/extensions')
| -rw-r--r-- | lib/extensions/print_pdf.py | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/extensions/print_pdf.py b/lib/extensions/print_pdf.py index e5cb25d8..97a806a7 100644 --- a/lib/extensions/print_pdf.py +++ b/lib/extensions/print_pdf.py @@ -73,7 +73,10 @@ class PrintPreviewServer(Thread): def __set_resources_path(self): if getattr(sys, 'frozen', False): - self.resources_path = os.path.join(sys._MEIPASS, 'print', 'resources') + if sys.platform == "darwin": + self.resources_path = os.path.join(sys._MEIPASS, "..", 'Resources', 'print', 'resources') + else: + self.resources_path = os.path.join(sys._MEIPASS, 'print', 'resources') else: self.resources_path = os.path.realpath(os.path.join(os.path.dirname(__file__), '..', '..', 'print', 'resources')) @@ -183,7 +186,10 @@ class PrintPreviewServer(Thread): class Print(InkstitchExtension): def build_environment(self): if getattr(sys, 'frozen', False): - print_dir = os.path.join(sys._MEIPASS, "print") + if sys.platform == "darwin": + print_dir = os.path.join(sys._MEIPASS, "..", 'Resources', "print") + else: + print_dir = os.path.join(sys._MEIPASS, "print") else: print_dir = os.path.realpath(os.path.join(os.path.dirname(__file__), "..", "..", "print")) |
