Skip to content

Commit

Permalink
GameSettings: Hide proton settings on macOS
Browse files Browse the repository at this point in the history
  • Loading branch information
loathingKernel committed Dec 17, 2023
1 parent bc485ed commit 85d2937
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions rare/components/tabs/settings/game_settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,10 @@ def __init__(self, is_default, parent=None):

if platform.system() != "Windows":
self.linux_settings = LinuxAppSettings()
self.proton_settings = ProtonSettings(self.linux_settings, self.wrapper_settings)
self.ui.proton_layout.addWidget(self.proton_settings)
if platform.system() != "Darwin":
self.proton_settings = ProtonSettings(self.linux_settings, self.wrapper_settings)
self.ui.proton_layout.addWidget(self.proton_settings)
self.proton_settings.environ_changed.connect(self.env_vars.reset_model)

# FIXME: Remove the spacerItem and margins from the linux settings
# FIXME: This should be handled differently at soem point in the future
Expand All @@ -57,8 +59,6 @@ def __init__(self, is_default, parent=None):
lambda active: self.wrapper_settings.add_wrapper("mangohud")
if active else self.wrapper_settings.delete_wrapper("mangohud"))
self.linux_settings.environ_changed.connect(self.env_vars.reset_model)
self.proton_settings.environ_changed.connect(self.env_vars.reset_model)

else:
self.ui.linux_settings_widget.setVisible(False)

Expand All @@ -77,7 +77,10 @@ def load_settings(self, app_name):
proton = self.wrapper_settings.wrappers.get("proton", "")
if proton:
proton = proton.text
self.proton_settings.load_settings(app_name, proton)
if platform.system() != "Darwin":
self.proton_settings.load_settings(app_name, proton)
else:
proton = ""
if proton:
self.linux_settings.ui.wine_groupbox.setEnabled(False)
else:
Expand Down

0 comments on commit 85d2937

Please sign in to comment.