Python: Rename bpy.data.grease_pencils_v3 to bpy.data.grease_pencils
This renames `bpy.data.grease_pencils_v3` to `bpy.data.grease_pencils`. Part of #125058. Pull Request: https://projects.blender.org/blender/blender/pulls/146904
This commit is contained in:
committed by
Falk David
parent
1067112c11
commit
d2269441bb
@@ -34,7 +34,7 @@ def create_object_data(obj_type, name):
|
||||
if obj_type == 'VOLUME':
|
||||
return bpy.data.volumes.new(name)
|
||||
if obj_type == 'GREASEPENCIL':
|
||||
return bpy.data.grease_pencils_v3.new(name)
|
||||
return bpy.data.grease_pencils.new(name)
|
||||
if obj_type == 'ARMATURE':
|
||||
return bpy.data.armatures.new(name)
|
||||
if obj_type == 'LATTICE':
|
||||
|
||||
@@ -135,7 +135,7 @@ class Library(_types.ID):
|
||||
# we could make this an attribute in rna.
|
||||
attr_links = (
|
||||
"actions", "armatures", "brushes", "cameras",
|
||||
"curves", "grease_pencils_v3", "collections", "images",
|
||||
"curves", "grease_pencils", "collections", "images",
|
||||
"lights", "lattices", "materials", "metaballs",
|
||||
"meshes", "node_groups", "objects", "scenes",
|
||||
"sounds", "speakers", "textures", "texts",
|
||||
|
||||
@@ -37,7 +37,7 @@ def update_factory_startup_scenes():
|
||||
|
||||
|
||||
def update_factory_startup_grease_pencils():
|
||||
for grease_pencil in bpy.data.grease_pencils_v3:
|
||||
for grease_pencil in bpy.data.grease_pencils:
|
||||
grease_pencil.onion_keyframe_type = 'ALL'
|
||||
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ def update_factory_startup_scenes():
|
||||
|
||||
|
||||
def update_factory_startup_grease_pencils():
|
||||
for grease_pencil in bpy.data.grease_pencils_v3:
|
||||
for grease_pencil in bpy.data.grease_pencils:
|
||||
grease_pencil.onion_keyframe_type = 'ALL'
|
||||
|
||||
|
||||
|
||||
@@ -2915,7 +2915,7 @@ class WM_OT_batch_rename(Operator):
|
||||
'CURVE': ("curves", iface_("Curve(s)"), bpy.types.Curve),
|
||||
'META': ("metaballs", iface_("Metaball(s)"), bpy.types.MetaBall),
|
||||
'VOLUME': ("volumes", iface_("Volume(s)"), bpy.types.Volume),
|
||||
'GREASEPENCIL': ("grease_pencils_v3", iface_("Grease Pencil(s)"), bpy.types.GreasePencil),
|
||||
'GREASEPENCIL': ("grease_pencils", iface_("Grease Pencil(s)"), bpy.types.GreasePencil),
|
||||
'ARMATURE': ("armatures", iface_("Armature(s)"), bpy.types.Armature),
|
||||
'LATTICE': ("lattices", iface_("Lattice(s)"), bpy.types.Lattice),
|
||||
'LIGHT': ("lights", iface_("Light(s)"), bpy.types.Light),
|
||||
|
||||
@@ -106,7 +106,7 @@ class DopesheetFilterPopoverBase:
|
||||
flow.prop(dopesheet, "show_armatures", text="Armatures")
|
||||
if bpy.data.cameras:
|
||||
flow.prop(dopesheet, "show_cameras", text="Cameras")
|
||||
if bpy.data.grease_pencils_v3:
|
||||
if bpy.data.grease_pencils:
|
||||
flow.prop(dopesheet, "show_gpencil", text="Grease Pencil Objects")
|
||||
if bpy.data.lights:
|
||||
flow.prop(dopesheet, "show_lights", text="Lights")
|
||||
|
||||
@@ -511,7 +511,7 @@ class OUTLINER_PT_filter(Panel):
|
||||
row = sub.row()
|
||||
row.label(icon='CAMERA_DATA')
|
||||
row.prop(space, "use_filter_object_camera", text="Cameras")
|
||||
if bpy.data.grease_pencils_v3:
|
||||
if bpy.data.grease_pencils:
|
||||
row = sub.row()
|
||||
row.label(icon='STROKE')
|
||||
row.prop(space, "use_filter_object_grease_pencil", text="Grease Pencil")
|
||||
|
||||
Reference in New Issue
Block a user