mirror of
https://github.com/freedomofpress/dangerzone.git
synced 2025-04-28 18:02:38 +02:00
Fix get_resource_path for Mac app bundle
This commit is contained in:
parent
13aac3348a
commit
329fa4639b
2 changed files with 10 additions and 2 deletions
|
@ -239,8 +239,14 @@ class Common(object):
|
||||||
"share",
|
"share",
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
# In linux...
|
if platform.system() == "Darwin":
|
||||||
prefix = os.path.join(sys.prefix, "share/dangerzone")
|
# macOS
|
||||||
|
prefix = os.path.join(
|
||||||
|
os.path.dirname(os.path.dirname(sys.executable)), "Resources/share"
|
||||||
|
)
|
||||||
|
else:
|
||||||
|
# Linux
|
||||||
|
prefix = os.path.join(sys.prefix, "share/dangerzone")
|
||||||
|
|
||||||
resource_path = os.path.join(prefix, filename)
|
resource_path = os.path.join(prefix, filename)
|
||||||
return resource_path
|
return resource_path
|
||||||
|
|
|
@ -123,10 +123,12 @@ class DockerInstaller(QtWidgets.QDialog):
|
||||||
print(f"Install failed: {exception}")
|
print(f"Install failed: {exception}")
|
||||||
self.task_label.setText(f"Install failed: {exception}")
|
self.task_label.setText(f"Install failed: {exception}")
|
||||||
self.install_t = None
|
self.install_t = None
|
||||||
|
self.progress.hide()
|
||||||
self.cancel_button.setEnabled(True)
|
self.cancel_button.setEnabled(True)
|
||||||
|
|
||||||
def install_clicked(self):
|
def install_clicked(self):
|
||||||
self.task_label.setText("Installing Docker")
|
self.task_label.setText("Installing Docker")
|
||||||
|
self.progress.show()
|
||||||
self.install_button.hide()
|
self.install_button.hide()
|
||||||
self.cancel_button.setEnabled(False)
|
self.cancel_button.setEnabled(False)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue