Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'release/scripts/startup/bl_ui/properties_freestyle.py')
-rw-r--r--release/scripts/startup/bl_ui/properties_freestyle.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/release/scripts/startup/bl_ui/properties_freestyle.py b/release/scripts/startup/bl_ui/properties_freestyle.py
index d9f28040b16..b1992127932 100644
--- a/release/scripts/startup/bl_ui/properties_freestyle.py
+++ b/release/scripts/startup/bl_ui/properties_freestyle.py
@@ -33,7 +33,7 @@ class RenderFreestyleButtonsPanel:
def poll(cls, context):
scene = context.scene
with_freestyle = bpy.app.build_options.freestyle
- return scene and with_freestyle and(scene.view_render.engine in cls.COMPAT_ENGINES)
+ return scene and with_freestyle and(context.engine in cls.COMPAT_ENGINES)
class RENDER_PT_freestyle(RenderFreestyleButtonsPanel, Panel):
@@ -75,7 +75,7 @@ class ViewLayerFreestyleButtonsPanel:
with_freestyle = bpy.app.build_options.freestyle
return (scene and with_freestyle and rd.use_freestyle and
- scene.view_layers.active and(scene.view_render.engine in cls.COMPAT_ENGINES))
+ scene.view_layers.active and(context.engine in cls.COMPAT_ENGINES))
class ViewLayerFreestyleEditorButtonsPanel(ViewLayerFreestyleButtonsPanel):
@@ -185,7 +185,6 @@ class VIEWLAYER_PT_freestyle_lineset(ViewLayerFreestyleEditorButtonsPanel, Panel
scene = context.scene
rd = scene.render
- view_render = scene.view_render
view_layer = scene.view_layers.active
freestyle = view_layer.freestyle_settings
@@ -782,7 +781,7 @@ class VIEWLAYER_PT_freestyle_linestyle(ViewLayerFreestyleEditorButtonsPanel, Pan
layout.separator()
row = layout.row()
- if view_render.use_shading_nodes:
+ if scene.render.use_shading_nodes:
row.prop(linestyle, "use_nodes")
else:
row.prop(linestyle, "use_texture")
@@ -813,7 +812,7 @@ class MaterialFreestyleButtonsPanel:
material = context.material
with_freestyle = bpy.app.build_options.freestyle
return with_freestyle and material and scene and scene.render.use_freestyle and \
- (scene.view_render.engine in cls.COMPAT_ENGINES)
+ (context.engine in cls.COMPAT_ENGINES)
class MATERIAL_PT_freestyle_line(MaterialFreestyleButtonsPanel, Panel):