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:
authorBastien Montagne <montagne29@wanadoo.fr>2019-06-15 00:16:04 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2019-06-15 00:21:12 +0300
commit23254ce4ee6b21b202549b421cf1d98f6a03b33d (patch)
tree77ebd72c7f1cd2776e058f04b5e6e49f14a327ec /source/blender/python
parentf64070185808f153d141b26e63942424a1b258b1 (diff)
Cleanup: Rename: Static Override -> Library Override.
Better to make internal code naming match official/UI naming to some extent, this will reduce confusion in the future. This is 'breaking' scripts and files that would use that feature, but since it is not yet officially supported nor exposed in 2.80, as far as that release is concerned, it is effectively a 'no functional changes' commit.
Diffstat (limited to 'source/blender/python')
-rw-r--r--source/blender/python/intern/bpy_app.c26
-rw-r--r--source/blender/python/intern/bpy_rna.c34
2 files changed, 30 insertions, 30 deletions
diff --git a/source/blender/python/intern/bpy_app.c b/source/blender/python/intern/bpy_app.c
index 9ffb4cb4821..a3dd8ef93f2 100644
--- a/source/blender/python/intern/bpy_app.c
+++ b/source/blender/python/intern/bpy_app.c
@@ -392,25 +392,25 @@ static PyObject *bpy_app_autoexec_fail_message_get(PyObject *UNUSED(self), void
return PyC_UnicodeFromByte(G.autoexec_fail);
}
-PyDoc_STRVAR(bpy_app_use_static_override_doc,
- "Boolean, whether static override is exposed in UI or not.");
-static PyObject *bpy_app_use_static_override_get(PyObject *UNUSED(self), void *UNUSED(closure))
+PyDoc_STRVAR(bpy_app_use_override_library_doc,
+ "Boolean, whether library override is exposed in UI or not.");
+static PyObject *bpy_app_use_override_library_get(PyObject *UNUSED(self), void *UNUSED(closure))
{
- return PyBool_FromLong((long)BKE_override_static_is_enabled());
+ return PyBool_FromLong((long)BKE_override_library_is_enabled());
}
-static int bpy_app_use_static_override_set(PyObject *UNUSED(self),
- PyObject *value,
- void *UNUSED(closure))
+static int bpy_app_use_override_library_set(PyObject *UNUSED(self),
+ PyObject *value,
+ void *UNUSED(closure))
{
const int param = PyC_Long_AsBool(value);
if (param == -1 && PyErr_Occurred()) {
- PyErr_SetString(PyExc_TypeError, "bpy.app.use_static_override must be a boolean");
+ PyErr_SetString(PyExc_TypeError, "bpy.app.use_override_library must be a boolean");
return -1;
}
- BKE_override_static_enable((const bool)param);
+ BKE_override_library_enable((const bool)param);
return 0;
}
@@ -497,10 +497,10 @@ static PyGetSetDef bpy_app_getsets[] = {
(char *)bpy_app_debug_doc,
(void *)G_DEBUG_IO},
- {(char *)"use_static_override",
- bpy_app_use_static_override_get,
- bpy_app_use_static_override_set,
- (char *)bpy_app_use_static_override_doc,
+ {(char *)"use_override_library",
+ bpy_app_use_override_library_get,
+ bpy_app_use_override_library_set,
+ (char *)bpy_app_use_override_library_doc,
NULL},
{(char *)"use_event_simulate",
bpy_app_global_flag_get,
diff --git a/source/blender/python/intern/bpy_rna.c b/source/blender/python/intern/bpy_rna.c
index 01d0a1f0c19..8385bff0256 100644
--- a/source/blender/python/intern/bpy_rna.c
+++ b/source/blender/python/intern/bpy_rna.c
@@ -3681,27 +3681,27 @@ static PyObject *pyrna_struct_is_property_readonly(BPy_StructRNA *self, PyObject
return PyBool_FromLong(!RNA_property_editable(&self->ptr, prop));
}
-PyDoc_STRVAR(pyrna_struct_is_property_overridable_static_doc,
- ".. method:: is_property_overridable_static(property)\n"
+PyDoc_STRVAR(pyrna_struct_is_property_overridable_library_doc,
+ ".. method:: is_property_overridable_library(property)\n"
"\n"
" Check if a property is statically overridable.\n"
"\n"
" :return: True when the property is statically overridable.\n"
" :rtype: boolean\n");
-static PyObject *pyrna_struct_is_property_overridable_static(BPy_StructRNA *self, PyObject *args)
+static PyObject *pyrna_struct_is_property_overridable_library(BPy_StructRNA *self, PyObject *args)
{
PropertyRNA *prop;
const char *name;
PYRNA_STRUCT_CHECK_OBJ(self);
- if (!PyArg_ParseTuple(args, "s:is_property_overridable_static", &name)) {
+ if (!PyArg_ParseTuple(args, "s:is_property_overridable_library", &name)) {
return NULL;
}
if ((prop = RNA_struct_find_property(&self->ptr, name)) == NULL) {
PyErr_Format(PyExc_TypeError,
- "%.200s.is_property_overridable_static(\"%.200s\") not found",
+ "%.200s.is_property_overridable_library(\"%.200s\") not found",
RNA_struct_identifier(self->ptr.type),
name);
return NULL;
@@ -3711,14 +3711,14 @@ static PyObject *pyrna_struct_is_property_overridable_static(BPy_StructRNA *self
}
PyDoc_STRVAR(
- pyrna_struct_property_overridable_static_set_doc,
- ".. method:: property_overridable_static_set(property)\n"
+ pyrna_struct_property_overridable_library_set_doc,
+ ".. method:: property_overridable_library_set(property)\n"
"\n"
" Define a property as statically overridable or not (only for custom properties!).\n"
"\n"
" :return: True when the overridable status of the property was successfully set.\n"
" :rtype: boolean\n");
-static PyObject *pyrna_struct_property_overridable_static_set(BPy_StructRNA *self, PyObject *args)
+static PyObject *pyrna_struct_property_overridable_library_set(BPy_StructRNA *self, PyObject *args)
{
PropertyRNA *prop;
const char *name;
@@ -3726,20 +3726,20 @@ static PyObject *pyrna_struct_property_overridable_static_set(BPy_StructRNA *sel
PYRNA_STRUCT_CHECK_OBJ(self);
- if (!PyArg_ParseTuple(args, "sp:property_overridable_static_set", &name, &is_overridable)) {
+ if (!PyArg_ParseTuple(args, "sp:property_overridable_library_set", &name, &is_overridable)) {
return NULL;
}
if ((prop = RNA_struct_find_property(&self->ptr, name)) == NULL) {
PyErr_Format(PyExc_TypeError,
- "%.200s.property_overridable_static_set(\"%.200s\") not found",
+ "%.200s.property_overridable_library_set(\"%.200s\") not found",
RNA_struct_identifier(self->ptr.type),
name);
return NULL;
}
return PyBool_FromLong(
- (long)RNA_property_overridable_static_set(&self->ptr, prop, (bool)is_overridable));
+ (long)RNA_property_overridable_library_set(&self->ptr, prop, (bool)is_overridable));
}
PyDoc_STRVAR(pyrna_struct_path_resolve_doc,
@@ -5476,14 +5476,14 @@ static struct PyMethodDef pyrna_struct_methods[] = {
(PyCFunction)pyrna_struct_is_property_readonly,
METH_VARARGS,
pyrna_struct_is_property_readonly_doc},
- {"is_property_overridable_static",
- (PyCFunction)pyrna_struct_is_property_overridable_static,
+ {"is_property_overridable_library",
+ (PyCFunction)pyrna_struct_is_property_overridable_library,
METH_VARARGS,
- pyrna_struct_is_property_overridable_static_doc},
- {"property_overridable_static_set",
- (PyCFunction)pyrna_struct_property_overridable_static_set,
+ pyrna_struct_is_property_overridable_library_doc},
+ {"property_overridable_library_set",
+ (PyCFunction)pyrna_struct_property_overridable_library_set,
METH_VARARGS,
- pyrna_struct_property_overridable_static_set_doc},
+ pyrna_struct_property_overridable_library_set_doc},
{"path_resolve",
(PyCFunction)pyrna_struct_path_resolve,
METH_VARARGS,