forked from bartvdbraak/blender
Added Center button to backdrop controls in node editor's side panel
Inlined backdrop's zoom ui limits and hard limits so that going to minimun and going back to 100 works
This commit is contained in:
parent
dc8078e667
commit
7b3a49af8c
@ -188,6 +188,7 @@ class NODE_PT_properties(bpy.types.Panel):
|
||||
|
||||
col = layout.column(align=True)
|
||||
col.label(text="Offset:")
|
||||
col.operator("node.view_all", text="Center")
|
||||
col.prop(snode, "backdrop_x", text="X")
|
||||
col.prop(snode, "backdrop_y", text="Y")
|
||||
col.operator("node.backimage_move", text="Move")
|
||||
|
@ -2312,6 +2312,7 @@ static void rna_def_space_node(BlenderRNA *brna)
|
||||
prop= RNA_def_property(srna, "backdrop_zoom", PROP_FLOAT, PROP_NONE);
|
||||
RNA_def_property_float_sdna(prop, NULL, "zoom");
|
||||
RNA_def_property_range(prop, 0.01f, FLT_MAX);
|
||||
RNA_def_property_ui_range(prop, 0.01, 100, 1, 2);
|
||||
RNA_def_property_ui_text(prop, "Backdrop Zoom", "Backdrop zoom factor");
|
||||
RNA_def_property_update(prop, NC_SPACE|ND_SPACE_NODE_VIEW, NULL);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user