Cycles Node Editor:
* Add Use Nodes button for World shader type * UI was not redrawing the Node area, when enabling "Use nodes", added check for it to the listener.
This commit is contained in:
@@ -241,7 +241,7 @@ class CyclesCamera_PT_dof(CyclesButtonsPanel, Panel):
|
|||||||
|
|
||||||
|
|
||||||
class Cycles_PT_context_material(CyclesButtonsPanel, Panel):
|
class Cycles_PT_context_material(CyclesButtonsPanel, Panel):
|
||||||
bl_label = "Surface"
|
bl_label = ""
|
||||||
bl_context = "material"
|
bl_context = "material"
|
||||||
bl_options = {'HIDE_HEADER'}
|
bl_options = {'HIDE_HEADER'}
|
||||||
|
|
||||||
|
@@ -61,6 +61,7 @@ class NODE_HT_header(Header):
|
|||||||
|
|
||||||
if snode.shader_type == 'WORLD':
|
if snode.shader_type == 'WORLD':
|
||||||
layout.template_ID(scene, "world", new="world.new")
|
layout.template_ID(scene, "world", new="world.new")
|
||||||
|
layout.prop(snode_id, "use_nodes")
|
||||||
|
|
||||||
elif snode.tree_type == 'TEXTURE':
|
elif snode.tree_type == 'TEXTURE':
|
||||||
layout.prop(snode, "texture_type", text="", expand=True)
|
layout.prop(snode, "texture_type", text="", expand=True)
|
||||||
|
@@ -214,6 +214,11 @@ static void node_area_listener(ScrArea *sa, wmNotifier *wmn)
|
|||||||
ED_area_tag_refresh(sa);
|
ED_area_tag_refresh(sa);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case NC_WORLD:
|
||||||
|
if(type==NTREE_SHADER) {
|
||||||
|
ED_area_tag_refresh(sa);
|
||||||
|
}
|
||||||
|
break;
|
||||||
case NC_OBJECT:
|
case NC_OBJECT:
|
||||||
if(type==NTREE_SHADER) {
|
if(type==NTREE_SHADER) {
|
||||||
if(wmn->data==ND_OB_SHADING)
|
if(wmn->data==ND_OB_SHADING)
|
||||||
|
Reference in New Issue
Block a user