mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-04-14 12:48:18 +10:00
gui.py: Add FeatureUnlock configurability
This commit is contained in:
@@ -478,20 +478,8 @@ class BuildOpenCore:
|
||||
# Used to enable Audio support for non-standard dGPUs
|
||||
self.enable_kext("AppleALC.kext", self.constants.applealc_version, self.constants.applealc_path)
|
||||
|
||||
def check_firewire(model):
|
||||
# MacBooks never supported FireWire
|
||||
# Pre-Thunderbolt MacBook Airs as well
|
||||
if model.startswith("MacBookPro"):
|
||||
return True
|
||||
elif model.startswith("MacBookAir"):
|
||||
if smbios_data.smbios_dictionary[self.model]["CPU Generation"] < cpu_data.cpu_data.sandy_bridge.value:
|
||||
return False
|
||||
elif model.startswith("MacBook"):
|
||||
return False
|
||||
else:
|
||||
return True
|
||||
|
||||
if self.constants.firewire_boot is True and check_firewire(self.model) is True:
|
||||
if self.constants.firewire_boot is True and generate_smbios.check_firewire(self.model) is True:
|
||||
# Enable FireWire Boot Support
|
||||
# Applicable for both native FireWire and Thunderbolt to FireWire adapters
|
||||
print("- Enabling FireWire Boot Support")
|
||||
|
||||
@@ -857,12 +857,13 @@ Supported Options:
|
||||
change_menu = input("Set FeatreUnlock (ie. 1): ")
|
||||
if change_menu == "1":
|
||||
self.constants.fu_status = True
|
||||
self.constants.fu_arguments = ""
|
||||
self.constants.fu_arguments = None
|
||||
elif change_menu == "2":
|
||||
self.constants.fu_status = True
|
||||
self.constants.fu_arguments = " -disable_sidecar_mac"
|
||||
elif change_menu == "3":
|
||||
self.constants.fu_status = False
|
||||
self.constants.fu_arguments = None
|
||||
else:
|
||||
print("Invalid input, returning to previous menu")
|
||||
self.set_fu_settings()
|
||||
|
||||
@@ -124,8 +124,8 @@ class Constants:
|
||||
self.override_smbios = "Default" # Set SMBIOS model used
|
||||
|
||||
## FeatureUnlock Settings
|
||||
self.fu_status = True # Enable FeatureUnlock
|
||||
self.fu_arguments = "" # Set FeatureUnlock arguments
|
||||
self.fu_status = True # Enable FeatureUnlock
|
||||
self.fu_arguments = None # Set FeatureUnlock arguments
|
||||
|
||||
## Latebloom Settings
|
||||
self.latebloom_status = False # Latebloom Enabled
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
from data import smbios_data, os_data
|
||||
from data import smbios_data, os_data, cpu_data
|
||||
from resources import utilities
|
||||
|
||||
|
||||
@@ -98,3 +98,16 @@ def find_model_off_board(board):
|
||||
key = "MacPro5,1"
|
||||
return key
|
||||
return None
|
||||
|
||||
def check_firewire(model):
|
||||
# MacBooks never supported FireWire
|
||||
# Pre-Thunderbolt MacBook Airs as well
|
||||
if model.startswith("MacBookPro"):
|
||||
return True
|
||||
elif model.startswith("MacBookAir"):
|
||||
if smbios_data.smbios_dictionary[model]["CPU Generation"] < cpu_data.cpu_data.sandy_bridge.value:
|
||||
return False
|
||||
elif model.startswith("MacBook"):
|
||||
return False
|
||||
else:
|
||||
return True
|
||||
Reference in New Issue
Block a user