[Bf-committers] adding "load_ui" and "use_scripts" to the "read_homefile" operator ?
Gaia
gaia.clary at machinimatrix.org
Sun Mar 23 12:53:17 CET 2014
hi.
Please can anybody indicate if adding "load_ui" and "use_scripts" to the
"read_homefile" operator is an acceptable addition to the Python API ?
Details:
The operator"wm.read_homefile" accepts an alternative filepath.
I made a patch that allows to also specify the "load_ui" and
"use_scripts" flags.
In a python script now i can do:
# What we can do in 2.70 ======================
props = layout.operator("wm.read_homefile", text=name, icon='FILE')
props.filepath = an_alternative_homefile
#What my patch would make possible if accepted:
props.load_ui = False
props.use_scripts = False
Note: I believe that allowing to set the load_ui flag from the API is
harmless.
But regarding the use_scripts flag i am not so sure because of security.
If there is no immediate complains about this idea then i will cleanup
my patch and prepare a Task for review.
cheers,
Gaia
More information about the Bf-committers
mailing list