Fix empty Cycles render devices panel showing in preferences on macOS
There is no GPU rendering support on macOS, so showing the panel only adds confusion. Also hide the panels in builds without Cycles.
This commit is contained in:
parent
dad228a19c
commit
f17dfd575c
|
@ -575,6 +575,12 @@ class USERPREF_PT_system_sound(SystemPanel, CenterAlignMixIn, Panel):
|
|||
class USERPREF_PT_system_cycles_devices(SystemPanel, CenterAlignMixIn, Panel):
|
||||
bl_label = "Cycles Render Devices"
|
||||
|
||||
@classmethod
|
||||
def poll(cls, context):
|
||||
# No GPU rendering on macOS currently.
|
||||
import sys
|
||||
return bpy.app.build_options.cycles and sys.platform != "darwin"
|
||||
|
||||
def draw_centered(self, context, layout):
|
||||
prefs = context.preferences
|
||||
|
||||
|
|
Loading…
Reference in New Issue